Parent Directory | Revision Log
|Links to HEAD:||(view) (annotate)|
Slightly rudimentary support for view/buffer handling (C-x b and C-x k) The major thing that needs fixing is being currently unable to name and refer to views with a sensible (unique) string name.
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.
Export make-key-signature, key-signatures from gsharp-buffer
Remove gsharp-buffer:: prefix from key-signature (since it's exported).
Work-in-progress hooks for drawing routines, used for now for tenuto and staccato articulation marks. The quality of the graphical rendering of the marks is not really up to scratch; horizontal placement seems to be off by somewhere between half and one pixel, and of course a note with both marks on at once gets an ugly graphical clash. As I say, "work in progress".
Added the ESA menus the Gsharp menu.
Provide default values for commands expected to accept numeric arguments.
Fix gsharp-common :new-process t We need a lexical variable to use inside RUN, which may be called inside a new thread. (Also, we might need to have bound *ESA-INSTANCE*, so let's do that proactively.)
Make the Print Buffer To File command output eps if the pathname type is "eps". No error-checking for multiple pages or anything sensible like that.
Define a method on esa-current-buffer, not frame-current-buffer, after Troels' reworking. Also rewrite BUFFERS method so that if the window doesn't yet have a view nothing bad happens. This allows writing gsharp:gsharp and gsharp:edit-file in terms of executing commands on an (adopted) gsharp frame, reducing code duplication and also fixing a bad bug in gsharp:edit-file, which would destroy the layer/staff structure if the file's first layer spanned multiple staves.
Implemented play-buffer and made play-layer available in play menu
Support long ("lunga") notes and rests. It's a bit weird, because the lunga has the same notehead as a breve, but also has a stem; so having a NOTEHEAD of :long is a bit of a misnomer. Hey ho.
More likely space requirements handling. (More likely to actually work, that is. Thanks to Athas and hefner for the ideas and the debugging patience.)
Reverse the notehead rotation order for C-r. I apologise if this destroys someone's finger macros, but the current order is too illogical in the default state.
Support for breves and breve rests.
Better final accidentals: * look back through the current bar / layer, no further than the currently active key signature, to find a note on the same staff with the same pitch: if there is one, and the accidentals are the same, no need to have an accidental displayed. Remaining to do: * more or less any editing action should invalidate the already-computed final accidentals of the current bar. At present, final accidentals aren't recomputed often enough.
Printing to file. It's still somewhat hacky, but the worst of it is gone: * light glyphs ink is taken from the view, so we can construct a dark ink for light glyphs; * code to draw a single page is shared between the printing and screen-drawing routines; * new-page is called the right number of times; * the user is prompted for a filename (with a sensible default). Remaining stuff to do: * factor out a little bit more shared code between draw-buffer and print-buffer; * when creating the view, copy the current view; * be cleverer about the medium transformation.
Reducing my deviation from upstream, part $n$: M-: support.
Alright, let's try this: more correct key signatures, I hope. The major change to the protocol is that REMOVE-ELEMENT takes as a required argument the bar as well as the element; this allows more symmetric methods to be written for the various stealth mixin bits of functionality. Key signatures are elements, as before, within a layer. However, they are also kept on a list sorted by sequence in a slot of the staff, and KEYSIG is responsible for checking the relevant staff for other key signature elements. Editing actions or commands are also responsible for maintaining this list sorted in the right order. New almost-correct function for testing the temporal-and-logical ordering of elements. Drawing code now computes the correct key signature for the each staff; linebreaking is done with a conservative assumption for how wide the key signature will be. Please test.
Completed implementation of quartertone playback for regular temperaments. Fixed keybinding bug for microsharper.
Support for semi/sesqui sharp/flat. * don't declare the type of the accidentals slot any more; we can put that back in a little, after we work out a declarative way of defining all properties of accidentals. * microsharpen and microflatten commands and functions; define sharpen and flatten in terms of those (and knowing which accidentals are the tonal ones). Keybindings for the commands. * a more declarative table-based system for kerning accidentals, along with the ability to specify a per-glyph default (and a default default). Choose a sensible default default; also alter the :sharp/:sharp table when +4 steps away, as the previous value was colliding a little too much. * support for playing the semi accidentals in equal temperament. No support in linear temperament, as I don't know what they mean. * glyphs defined with a little too much liberal cut'n'paste. Some FIXMEs note the essential differences between the related glyphs.
Added support for regular temperaments
select-layer-by-layout commands and keybindings (C-down and C-up for now)
Somewhat hacky motion-by-layout commands (line- and page-based). These was by far the most annoying motion commands to be lacking when actually editing scores, in my opinion; C-a and C-e are absolutely wired into my fingers. Future candidates for inclusion: motion by layer (ideally in a way that's related to the layout, so that in the common case where there is one layer per staff the Right Thing happens); motion by note-in-associated-layer (lyrics). Also remove C-h binding for delete-current-element, and put Backspace in instead; this lets the ESA help bindings work.
Replaced (current-buffer *application-frame*) by (current-buffer) as required by ESA now. Also, untabified to make editing with Climacs easier.
Update for CVS HEAD mcclim. (The previous version, working with McCLIM 0.9.3, was tagged as works-with-McCLIM_0_9_3, or possibly that with the hyphens and underscores exchanged)
Fixes for ESA changes from Troels Henriksen.
Implemented a name change suggested by Magnus Johansson: Insert Measure Bar -> Insert Barline
Implemented the name change suggested by Magnus Johansson: Insert Staff After -> Insert Staff Below Insert Staff Before -> Insert Staff Above
Merge keysigN patch, with all its attendant horribleness.
Recompute measures in a :before method on redisplay-frame-pane as opposed to redisplay-frame-panes. This turns out to be necessary because redisplay-frame-panes is not always called. In particular redisplay-frame-pane is called from adopt-frame without going through redisplay-frame-panes, and adopt-frame is called when Gsharp is started from the CLIM desktop.
New commands: com-octave-up and com-octave-down that work for clusters, bound to Meta-U and Meta-D. They move the current note up/down by an entire octave. These commands are useful when the automatic pitch follower gets it wrong.
Display page numbers in the info pane.
Implemented commands to go to the beginning and to the end of the score, bound to M-< and M-> respectively.
Removed bogus menu entry.
Make the File menu basically work. I couldn't find a way of graying out or invalidating commands, but that's not a big deal really yet.
Make the Measure menu work again; have only one definition of com-forward/backward-measure. Document one or two commands; make com-erase-element take a numeric prefix parameter.
Movement by measure, bound to M-C-f and M-C-b.
Scrolling. * change space requirements after drawing to a score pane * intercept window-clear on score panes, so as not to reset sheet transformations, viewport positions, and so on, but just to clear the output record and draw in background ink.
Make the tempo (for playback only, currently) a segment slot; add command-line UI for setting it.
Implement octaviated treble clefs. This isn't terribly general, I concede; the clef protocol might need to be rethought. However, it does capture functionality which was previously expressed in multiple places in the functions B-POSITION, F-POSITION and BOTTOM-LINE.
Make rotate-notehead work again for rests. (thanks to Christophe Rhodes).
Gsharp now has an info pane (what Emacs calls a "mode-line").
Cleaned up some dead code.
Added a new package and a new file ESA-BUFFER allowing buffers to be named, to be associated with a file name, and to have a `needs-saving' and a `read-only' flag. Added a new package and a new file ESA-IO containing application-independent functionality to create buffers from files, and to save buffers to files. This package also supplies filename completion. Most of the code was adapted from Climacs. Abstracted out all Gsharp-specific I/O to ESA-IO. In particular, this means that we now have commands such as C-x C-s, and C-x C-w, which we didn't before. The old I/O code is still there. Cleanup is next.
Reorganized the command tables so that there are command tables that are specific to element types. Implemented find-applicable-gsharp-command-table that determines a command table based on the layer the cursor is in and (if any) the current element. Added `tie-left' and `tie-right' accessors to notes and lyrics elements and commands for modifying the ties. Ties are not rendered yet.
The default key signature of a staff is now represented by an instance of the new class `key-signature', rather than by just a vector. The commands `com-more-sharps' and `com-more-flats' now call new protocol generic functions on the key signature. I used the suggestion from the patch by Christophe Rhodes to introduce a new class `rhythmic-element' below `element' and move slots that have to do with duration to that new class (rbeams, lbeams, dots). The `key-signature' class does not inherit from `rhythmic-element', but instead directly from `element'. In order to avoid having to alter the external format yet again, the reader tests whether a vector was read as the key signature, and if so, replaces it by an instance of the new class. As a nice side effect, I was able to remove the symbol `invalidate-everything-using-staff' from the list of exported symbols of `measure.lisp', because it is now used by the :after methods on `more-sharps' and `more-flats', defined in the same package. What I haven't done (I'll let Christophe do it, unless he takes too long) is to incorporate the parts from Christophe's patch that make it possible to insert key signatures as elements into layers.
Fixed a bug reported by Christophe Rhodes. The symptoms were that the stems were not recomputed when the clef of the staff was changed. In fact, all elements that display on a staff need to be invalidated when the clef of the staff changes. Again, I used only the CLIM Desktop to accomplish this modification.
Make the C clef have the right octave. (FIXME: why are there two identical NOTE-POSITION methods?)
Prepared Gsharp for multi-buffer, multi-frame, and multi-view features. This modification involved getting rid of the frame-global `buffer' and `cursor' slots. Now, a new class `gsharp-pane', a subclass of score-pane, contains a slot for a view. The idea is that a pane has a particular view on display, and the view contains the buffer and the cursor to be displayed in the pane. Eventually C-x b will be used to change the view on display in the current pane, C-x k will kill the view (and if it is the last view that displays a certain modified buffer, the user will be asked to confirm), C-x 2 will clone the view into a new top-level window. There will also be commands to alter the class of the current view to obtain parts views etc. At least, this corresponds to my current thinking. This modification was obtained without using Emacs (except for typing this message). Instead I used the CLIM Desktop. Specifically, I used Climacs for editing source code with Swine for incremental compilation and calling Closure to read CLHS documentation, and the CLIM Listener to compile and execute Gsharp. While Climacs and the other tools still have some quirks, I must say I am VERY impressed with what they can already do.
Final (?) step in separating coordinate computation and drawing.
Removed the cursor-drawing code from the score-drawing functions. Instead we now store the x and y positions and the width of each bar. Cursor drawing is now implemented as looking up those stored values and draing the cursor based on them.
The input state is again visible.
Invalidated elements of layers using a staff that has its key signature altered.
Patch to allow the current note to be deleted. (thanks to Robert J. Macomber)
Fixed prompt bug in com-delete-staff-from-layer. (thanks to Robert J. Macomber)
Sync esa with climacs. Implement FIND-APPLICABLE-COMMAND-TABLE.
rescue MAKE-LAYER: make the gui.lisp command call it with a list of one staff, and make the constructor functions &allow-other-keys. (Possibly the &a-o-k should instead be just an additional keyword argument NAME).
Improved on the constructors for buffer-related classes.
remove the numbering stuff in favor of just calling POSITION each time. We are likely going to change the representation of sequences from lists to something more elaborate anyway (where it matters), so the numbering will not be relevant in the future.
Put back some more constructors. Two things need to be fixed ultimately: * Clefs should not be named objects. Instead, the exact type should probably be identified by subclassing * There is not compelling reason for bars to be subclassed. The distinction between melody and lyrics (and percussion, ultimately) is enough to enforce at the level of the layer.
Put back some of the constructor functions. Added more documentation about buffer protocols.
Removed the function MAKE-INITIALIZED-SEGMENT
Removed make-lyrics-element and make-empty-segment
Removed MAKE-CLUSTER and MAKE-REST in favor of MAKE-INSTANCE 'CLUSTER and MAKE-INSTANCE 'REST
Removed the function MAKE-LYRICS-STAFF in favor of MAKE-INSTANCE 'LYRICS-STAFF
Removed the function MAKE-FIVELINE-STAFF in favor of MAKE-INSTANCE 'FIVELINE-STAFF.
Removed MAKE-CLEF in favor of MAKE-INSTANCE 'CLEF
Removed the function MAKE-NOTE in favor of MAKE-INSTANCE 'NOTE
Improve and rename main entry point to `gsharp'. Export that symbol from the gsharp package.
Extracted midi-related computations to a new file: play.lisp Renamed notehead-duration to undotted-duration, which better reflects the intention.
Make the cursor be drawn in the right place. Dunno why we need to negate y-offset.
Implement command table switching. If we select a lyrics layer, then we want to be in lyrics mode -- activate the lyrics command table.
Removed Gsharp-specific code for double buffering. Replaced it by general mechanism now available in McCLIM. This should also fix the pixmap-focus bug, though I can't test that because I never could reproduce the problem.
More modifications to allow incremental redisplay. There is still a problem with beam drawing which has to be converted to use the correct superclass.
Fixed a bug in esa.lisp that made numeric arguments not work. Error messages are now displayed in the minibuffer. Some commands like forward-element, backward-element, and delete-element now accept numeric arguments. Prepared for incremental redisplay by changing inheritance of pixmap records. This is nontrivial, though, and will require some more thinking about. The best thing would be to fix McCLIM, but that looks nontrivial as well.
Changed the sheet transformation of the score pane to be the default for CLIM stream panes (0,0) in the upper-left corner. This was in order to simplify the rest of the code, and in particular the output recording stuff. There are probably some edge cases that don't yet work like they are supposed to with the possibility of off-by-a-pixel errors. Removed all the rectangle output records in favor of calls to draw-rectangle*. Temporarily removed the double buffering as a preparation for better seeing what is going on with incremental redisplay. Getting incremental redisplay to work might require fixing a problem in McCLIM which does not necessarily rely on the output-record protocol, but instead sometimes assume the existence of a slot in the record, whereas no such slot is required by the specification. The result is that the user cannot define his or her own output records and have them work with incremental redisplay.
fixed some minor problems
Climacs is now an ESA (Emacs-style application) using the new package that was abstracted out of Climacs.
Better filename completer that works for both SBCL and CMUCL. Gsharp no longer destroys the port before starting up. This is in preparation to run applications from the listener, or from some other application. Made some cosmetic changes after having learned about the existence of CONSTANTLY. *gsharp-frame* (is it still needed?) is no longer setf'ed but bound, so that each thread has its own copy. Added numbering of the segments of a buffer as :after method on initialize-instance on a buffer.
Lyrics input now allows for accents, provided that your keyboard is capable of generating dead keys for these accents. It only works for X11 at the moment, I would think. The way I do it is not great, since now I get messages about missing commands for the control keys. I have to think of a better way of doing it. Loading a file now calls select-layer so that the appropriate mode is selected. Loading the bach score with lyrics now immediately lets you edit the lyrics.
Gsharp definitely has lyrics. When a lyrics layer is selected, the ordinary alphabetic keys append characters to the preceding lyrics element. use C-Space to insert a new lyrics element. Use C-h to erase the last character of a lyrics element. It's a bit clunky, but it works. I seriously doubt the full power of Goatee is needed to edit lyrics. I noticed that (probably unintentionally) McCLIM can handle Unicode texts in the form of vectors of integers to draw-text. It probably just passes them on to the port-specific functions, and it happens to work with clx. It probably won't work on all backends, but it would be nice if it did. The default font on my machine can probably only do character codes up to 255, but with a good font, it should be able to do up to 65535. But right now, I can get the German national characters, which are needed for Bach. Check out the new file Scores/bach181-lyrics.gsh. In it, you will also notice that there is one place in which words overlap. To fix that (which is not just a lyrics problem, but also happens with clusters with many accidentals) Gsharp must learn to compute how much extra room an element might need, and adjust spacing accordingly, Unfortunately McCLIM does not handle input from a US-international keyboard, so I actually had to put in the ü's manually, but it should work for others. With lyrics, MIDI file generation is most likely broken, but I haven't checked that yet. It should just skip lyrics layers.
These current modifications are not in a good state yet. Some of them are terribly kludgy, but I do not think anything is broken. New files: modes.lisp containing key bindings sequence-dico.lisp: a dictionary that searches for objects associated with sequences (lists really). Utilities: Added some horribly kludgy Unicode support. Buffer: New types: lyrics-staff, melody-element, lyrics-element, melody-bar, lyrics-bar, melody-layer, lyrics-layer Layers are no longer ordered. Cursor: Removed functionality that used layer ordering. Gui: Removed commands that used layer ordering. Added new commands to navigate, insert, and delete layers. Factored out and improved command processing. Some menus in menu bar work better. Added new presentation methods and types. Still no support for typing lyrics, but you can see them if they are already in a .gsh file. Input state: It no longer contains the staff. Instead the current staff is the first in the list of staves in the current layer. Drawing: We can now draw lyrics. Score pane: Now has a lyrics-staff presentation type.
completions for staves, staff types, and clef types work better now (should no longer fail on parse error). improved rename-staff command and made staff names unique.
added preseentation types for staff and clef in score pane. score pane is no longer `use'd by other packages, exported symbols from score pane are explicitly prefixed by client code. removed presentation type for staff-line in score pane.
Staff types, staves, and clef types are now presentation types. Add staff commands prompt for existing staff and name, type, clef types, etc. for staff to insert. We still do not verify that staff name is unique. We also need to add completion for staff names. Updated documentation and release notes to reflect changes.
A '() somehow got forgotten after #-cmu
allow gsharp to compile under non-cmucl. Since this code is probably going to be removed anyway, we can bypass best practice restrictions from <http://www-jcsu.jesus.cam.ac.uk/~csr21/papers/features.pdf>.
General: removed presentation test code. in gui.lisp Staves as presentations: draw-staff now also takes a staff object as an argument so that we can use the CLIM present function inside draw-staff. added present method for a staff object on a textual view. modified com-inssert-layer-after to take no arguments, but instead to use accept to gather a staff object. Redisplay: pane is no longer cleared after each interaction, so redisplay is much smoother. Filename completion: added completable-pathname presentation type and an accept method for this type. The accept method uses a CMUCL-specific function (ext:ambiguous-files) to complete prefix pathnames. Contributions for other Lisp systems to make this work would be welcome. modified com-load-file and com-save-buffer-as to take no arguments, but instead to use accept to gather its file name. This modification probably should not have been necessary, as CLIM ought to use accept to gather unsupplied arguments, no?
Now that it is possible to start a second Gsharp after the first one exits, make the quit command call frame-exit in both CMUCL and SBCL.
Changed the implementation of keyboard macros to store functions instead of keys. Once we get numeric arguments, we must store thunks that call the commands with appropriate arguments.
Forgot to save buffer before committing.
Added Emacs-style keboard macro facility.
Workaround the :shift problem with #\# commands: add an unshifted variant.
Make the sbcl version of run-program search through $PATH for timidity
Updates since 0.2 release.
import of 0.2
This form allows you to request diffs between any two revisions of this file. For each of the two "sides" of the diff, select a symbolic revision name using the selection box, or choose 'Use Text Field' and enter a numeric revision.
|Powered by ViewVC 1.1.5|