/[gsharp]/gsharp/packages.lisp
ViewVC logotype

Contents of /gsharp/packages.lisp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.68 - (show annotations)
Mon Apr 20 15:04:47 2009 UTC (4 years, 11 months ago) by dlewis
Branch: MAIN
CVS Tags: HEAD
Changes since 1.67: +5 -1 lines
Basic time signature support. Only some sigs supported and spacing is basic.
Key and time signatures now share a staffwise-elements slot in the stave.
1 (defpackage :gsharp-utilities
2 (:shadow built-in-class)
3 (:use :clim-lisp :clim-mop)
4 (:export #:ninsert-element #:define-stealth-mixin
5 #:unicode-to-char #:char-to-unicode))
6
7 (defpackage :mf
8 (:use :cl)
9 (:export #:make-bezier-segment #:bezier-segment
10 #:make-open-path #:make-closed-path
11 #:closed-path #:concatenate-paths #:path-start
12 #:close-path
13 #:polygonalize
14 #:path-bounding-box
15 #:scan-lines
16 #:first-line #:nb-lines #:crossings
17 #:translate #:rotate #:scale #:slant #:reverse-path
18 #:draw-path #:with-pen
19 #:+razor+ #:+unit-square+
20 #:+quarter-circle+ #:+half-circle+ #:+full-circle+
21 #:superellipse
22 ;; mf-like stuff
23 #:paths #:mf #:paths #:control #:controls #:tension #:tensions
24 #:& #:-- #:--- #:curl #:direction #:cycle
25 #:left #:right #:up #:down))
26
27 (defpackage :sdl
28 (:use :common-lisp :mf)
29 (:export #:glyph #:staff-line-distance #:staff-line-offsets
30 #:stem-offsets #:bar-line-offsets
31 #:ledger-line-x-offsets #:ledger-line-y-offsets
32 #:notehead-right-offsets #:notehead-left-offsets
33 #:make-font #:glyph-offsets #:suspended-note-offset
34 #:beam-offsets #:beam-hang-sit-offset))
35
36 (defpackage :score-pane
37 (:use :clim :clim-extensions :clim-lisp :sdl :esa)
38 (:import-from :esa-io #:buffer)
39 (:shadow #:rest)
40 (:export #:draw-fiveline-staff #:draw-lyrics-staff
41 #:draw-stem #:draw-right-stem #:draw-left-stem
42 #:draw-ledger-line #:draw-bar-line #:draw-beam #:staff-step
43 #:draw-notehead #:draw-accidental #:draw-clef #:draw-rest #:draw-dot
44 #:draw-time-signature-component
45 #:draw-flags-up #:draw-flags-down
46 #:draw-tie-up #:draw-tie-down
47 #:with-score-pane #:with-vertical-score-position
48 #:with-staff-size #:with-notehead-right-offsets
49 #:with-suspended-note-offset
50 #:with-notehead-left-offsets #:with-light-glyphs #:score-pane
51 #:clef #:staff #:fiveline-staff #:lyrics-staff #:notehead
52 #:score-view #:number-of-pages #:current-page-number))
53
54 (defpackage :gsharp-buffer
55 (:use :common-lisp :gsharp-utilities :esa-buffer)
56 (:shadow #:rest)
57 (:export #:clef #:name #:lineno #:make-clef
58 #:staff #:fiveline-staff #:make-fiveline-staff
59 #:key-signatures #:time-signatures
60 #:staffwise-elements
61 #:lyrics-staff #:make-lyrics-staff
62 #:gsharp-condition
63 #:pitch #:accidentals #:dots #:note #:make-note
64 #:note-less #:note-equal #:bar
65 #:notehead #:rbeams #:lbeams #:dots #:element #:annotations
66 #:melody-element #:rhythmic-element #:notes
67 #:add-note #:find-note #:remove-note
68 #:cluster-upper-bound #:cluster-lower-bound
69 #:cluster #:make-cluster
70 #:rest #:make-rest
71 #:lyrics-element #:make-lyrics-element
72 #:slice #:elements
73 #:nb-elements #:elementno #:add-element
74 #:remove-element #:bar #:make-bar
75 #:melody-bar #:make-melody-bar
76 #:lyrics-bar #:make-lyrics-bar
77 #:layer #:lyrics-layer #:melody-layer
78 #:bars #:nb-bars #:barno #:add-bar #:remove-bar
79 #:slice #:make-slice
80 #:segment #:tempo #:slices #:sliceno
81 #:make-layer-for-staff #:make-bar-for-staff
82 #:head #:body #:tail #:make-layer #:buffer
83 #:layers #:nb-layers #:layerno
84 #:add-layer #:remove-layer #:segment
85 #:segments #:nb-segments #:segmentno #:staves
86 #:find-staff #:add-segment #:remove-segment
87 #:add-staff-before-staff #:add-staff-after-staff
88 #:remove-staff-from-buffer
89 #:rename-staff
90 #:add-staff-to-layer
91 #:remove-staff-from-layer
92 #:stem-direction #:undotted-duration #:duration
93 #:clef #:f-position #:b-position #:bottom-line
94 #:keysig #:staff-pos #:xoffset #:read-everything
95 #:read-buffer-from-stream
96 #:staffwise-element
97 #:key-signature #:make-key-signature
98 #:time-signature #:time-signature-components
99 #:alterations #:more-sharps #:more-flats
100 #:line-width #:lines-per-page #:min-width #:spacing-style
101 #:right-edge #:left-offset
102 #:left-margin #:text #:append-char #:erase-char
103 #:tie-right #:tie-left
104 #:needs-saving
105 #:tuning #:master-pitch-note #:master-pitch-freq
106 #:note-cents #:12-edo #:regular-temperament))
107
108 (defpackage :gsharp-numbering
109 (:use :gsharp-utilities :gsharp-buffer :clim-lisp)
110 (:shadowing-import-from :gsharp-buffer #:rest)
111 (:shadow #:number)
112 (:export #:number))
113
114 (defpackage :obseq
115 (:use :common-lisp)
116 (:export #:obseq #:obseq-elem #:obseq-next #:obseq-prev
117 #:obseq-first-undamaged-element
118 #:obseq-last-undamaged-element
119 #:cost-method #:obseq-cost-method #:seq-cost
120 #:total-cost #:combine-cost #:seq-cost-cannot-decrease
121 #:cost-less #:obseq-solve #:obseq-interval))
122
123 (defpackage :gsharp-measure
124 (:use :common-lisp :gsharp-numbering :gsharp-buffer :gsharp-utilities :obseq)
125 (:shadowing-import-from :gsharp-numbering #:number)
126 (:shadowing-import-from :gsharp-buffer #:rest)
127 (:export #:mark-modified #:modified-p #:measure
128 #:measure-min-dist #:measure-coeff
129 #:measure-bar-pos #:measure-seg-pos #:measure-bars #:measures
130 #:nb-measures #:measureno
131 #:recompute-measures #:measure-cost-method #:make-measure-cost-method
132 #:buffer-cost-method
133 #:reduced-width #:natural-width #:compress-factor
134 #:measure-seq-cost
135 #:note-position #:non-empty-cluster-p
136 #:top-note #:bot-note #:top-note-pos #:bot-note-pos
137 #:beam-groups #:final-stem-direction
138 #:group-notes-by-staff #:final-relative-note-xoffset
139 #:final-accidental #:final-relative-accidental-xoffset
140 #:final-relative-dot-xoffset #:final-absolute-dot-ypos
141 #:timeline #:timelines #:elasticity
142 #:smallest-gap #:elasticity-function))
143
144 (defpackage :gsharp-beaming
145 (:use :common-lisp)
146 (:export #:beaming-single #:beaming-double))
147
148 (defpackage :gsharp-cursor
149 (:shadowing-import-from :gsharp-buffer #:rest)
150 (:shadowing-import-from :gsharp-numbering #:number)
151 (:use :gsharp-utilities :gsharp-buffer :gsharp-numbering :clim-lisp)
152 (:export #:gsharp-cursor #:make-cursor #:end-of-bar-p #:beginning-of-bar-p
153 #:insert-element #:delete-element
154 #:forward-element #:backward-element
155 #:last-bar-p #:first-bar-p #:forward-bar #:backward-bar
156 #:insert-bar-before #:insert-bar-after #:delete-bar
157 #:in-last-bar #:in-first-bar #:end-of-bar
158 #:first-slice-p #:last-slice-p
159 #:forward-slice #:backward-slice
160 #:head-slice #:body-slice #:tail-slice
161 #:in-last-slice #:in-first-slice
162 #:select-layer #:delete-layer
163 #:first-segment-p #:last-segment-p
164 #:forward-segment #:backward-segment
165 #:insert-segment-before #:insert-segment-after
166 #:delete-segment
167 #:in-last-segment #:in-first-segment
168 #:cursor-element #:cursor-bar #:cursor-slice #:cursor-layer
169 #:cursor-segment #:cursor-buffer
170 #:current-cluster #:not-on-a-cluster
171 #:current-element #:not-on-an-element
172 ))
173
174 (defpackage :gsharp-drawing
175 (:use :clim :clim-lisp :gsharp-buffer :gsharp-measure :gsharp-cursor
176 :gsharp-utilities :sdl :gsharp-beaming :obseq)
177 (:shadowing-import-from :gsharp-buffer #:rest)
178 (:export #:draw-buffer #:draw-the-cursor #:print-buffer))
179
180 (defpackage :gsharp-play
181 (:use :common-lisp :midi :gsharp-buffer)
182 (:shadowing-import-from :gsharp-buffer #:rest)
183 (:export #:play-layer
184 #:play-segment
185 #:play-buffer))
186
187 (defpackage :gsharp-mxml
188 (:use :cl :gsharp-buffer :gsharp-measure)
189 (:shadowing-import-from :gsharp-buffer #:rest))
190
191 (defpackage :gsharp
192 (:use :clim :clim-lisp :gsharp-utilities :esa :esa-buffer :esa-io
193 :gsharp-buffer :gsharp-cursor :gsharp-drawing :gsharp-numbering
194 :gsharp-measure :sdl :midi
195 :gsharp-play)
196 (:shadowing-import-from :gsharp-numbering #:number)
197 (:shadowing-import-from :gsharp-buffer #:rest #:buffer)
198 (:export #:gsharp #:edit-file))
199
200 (in-package :gsharp-numbering)
201 (deftype number () 'cl:number)
202 (setf (find-class 'number) (find-class 'cl:number))
203
204 (in-package :gsharp-buffer)
205 (defun rest (list)
206 (cl:rest list))
207 (define-compiler-macro rest (list)
208 `(cl:rest ,list))
209 (define-setf-expander rest (list &environment env)
210 (get-setf-expansion `(cl:rest ,list) env))

  ViewVC Help
Powered by ViewVC 1.1.5