1 -*-outline-layout:(2 (-1 -1 0 :) 0);outline-stylish-prefixes:nil -*-
4 Features you cannot find in the doco as working, should be
5 mentioned here. This is an assorted collection of stuff that will be
6 done, might be done, or is an idea that I want to think about
8 Most of the items are marked in the code as well
9 Grep for TODO and ugh/ugr/urg.
12 . * rewrite context defs using Scheme
14 . * header for PS enteredby = "bla <bla@bar.com>"
15 . * ps/lily.ps see comments.
16 . * devise standard for functioning of Vertical_align_element.
17 . * staff size for post/prebreaks
19 . * input/star-spangled-banner
21 . * P.P.S. It can be cool in mudela-book to distinguish in
22 pre,postMudelaExample, whether MudelaExample is epsed or not: ( if
23 this fragment is floating eps, than 1, otherwise 2). say
24 preMudelaExample[eps]{}, and change it in document body sometimes.
25 . * fix singleStaffBracket
26 . * declare performers in \midi
28 . * \shape 1st dim skipped?
29 . * turn slope-damping on/off
31 . * fix height of / collisions with lyrics (chords),
32 see input/test/vertical-text.ly; input/test/repeat.ly
33 . * We need feta-din*.mf files for more sizes than 10.
34 . * fix dynamics decently, ie. use kerning & ligatures.
35 . * dots & rest collisions?
37 . * fix \mudelafile{} to have decent functionality
39 . * support_l_arr_ empty in staff-margin's G_staff_side_item
40 . * slurs colllide with lyrics.
41 . * Is there any reasonable way to do this: I would like to have one file
42 that can generate the same tune in two different modes without having
43 to go through and rewrite all the music in the other mode.
45 Long lyrics don't get a space at the end. They just run right up
46 against the next lyric. (I don't think this used to be the case.)
48 Lyrics and scripts collide.
50 \key b; \time 4/4; looks bad. The clef and time signature are too close.
52 restStyle=mensural doesn't seem to work (lots of characters not found
54 . * Phrasing: Indicating the textual underlay of a piece, or
55 otherwise dividing a piece into phrases.
57 There are distinct ways of specifying the first two (although at
58 present, they're not properly distinguished) but no distinct way to
59 specify the third. Should there be?
60 . * rest collision minimum dist.
62 . * spacing for prefatory matter
63 . * The line length is 7.5 inch (19.05
64 > cm) and the height of normal size is equivalent to the traditional raster 1
65 > size. (The Schott company sells Letraset sheets of musical symbols which are
66 > measured in raster sizes). It is agreed among most engravers I know that the
67 > standard size for adult readers in solo music should 70% of raster 1. Jeff's
68 > example was 75%, so I had to modify my file to match.
70 So that makes for a staff space of 4 2/3 point. I'll add the
71 dimensions to the TODO file.
72 . * accidentals closer to note head
73 . * to space the staffs/staffgroups contained in the score.
75 In the orchestscore.ly file, I tried:
78 \OrchestralScoreContext
79 minVerticalAlign = 3.0*\staffheight;
83 minVerticalAlign = 3.0*\staffheight;
87 minVerticalAlign = 3.0*\staffheight;
105 . * \selectmusic to cut pieces from music.
106 . * Morally pure LilyPond.
107 . * Remove mutopia ramblings.
108 . * Remove non-free software links.
109 . * Remove meta article LilyPond.
110 . * TODO: merge atom & molecule; make tree from molecule.
111 . * break priority setting from SCM.
113 . * remove [] in favour of auto-beamer
114 . * hangOnClef with non-breakable clefs.
115 . * Aha, the problem is the new TeX code generation for changing fonts.
116 > (The explanation below is mostly intended for Han-Wen and Jan)
117 > Before, the font was changed with macros declared separately for
118 > pure TeX and LaTeX, but now all the fonts are declared directly in
119 > the generated code using the low-level TeX commands. This circumvents
120 > the fontencoding mechanism of LaTeX and is a potential source of
121 > problems also for us users of the Latin-1 character set.
122 > I think it still works since the inputencoding latin1 is
123 > declared by ly2dvi, but it still means that e.g. an o with
124 > umlaut is typeset as a combination of the two symbols 'o' and
125 > 'umlaut' instead of as a single character, as would be the case
126 > if fontencoding OT1 had been used. This shouldn't give any
127 > difference in layout, though. One of the main argument for using
128 > fontencoding OT1 is for the hyphenation mechanism to work, an
129 > argument that's clearly irrelevant in our application. Yet we
130 > see the problem for August.
131 . * Abstraction for engravers:
132 . * make "in-between" engraver (Tie, Extender)
133 . * make wide_spanner_engraver (line_group_spanne,r staff_symbol)
134 . * remove Interval dim_ from Dimension_cache and rename the struct.
135 . * do scaled fonts generally
136 . * The Lilypond accidental symbols are available through the TeX macros,
137 \textflat, \textsharp and \textnatural defined in the init file
138 lilyponddefs.tex. All the symbols are defined in the files fetaXX.tex
139 where XX corresponds to the size. I don't know where (or even if) they
140 are installed but they are generated in the mf/out/ directory during the
142 . * make dependencies () a virtual function.
143 . * fix Repeated_music design
144 . * one big ly2dvi input that includes *all* tests.
145 . * store req -> element, element -> element causes for warnings
146 . * include examples in RPM.
147 . * fix partial measures in meaningful way.
148 . * add scripts to bars eg. |^"bla"
149 . * relative mode for mi2mu
150 . * uniformise recent feta contributions.
151 . * use SCM and Molecules for {accordeon stuff, }
152 . * bigger and fatter 4/4 C
153 . * sort out directory stuff.
155 . * -I option per filetype?
157 . * ly2dvi/lilypond logfile.
158 . * fractional chord durs.
159 . * hang Item on Spanner
160 . * do --safe for PS output?
161 . * convert-mudela --output
162 . * Staff_margin (with a partial measure.)
163 . * fix pletvisibility properties:
164 . * bracket on/off/no-bracket-when-beam
165 . * num on/off/no-num-when-beam
167 . * junk text{sharp,flat,etc}
168 . * fix convert-mudela manpage
169 . * decimal point in \paper {}
170 . * { \voiceone <a'4.*2/3 d''4.*2/3 fis''4.*2/3> [g''8 fis'' e''] d''4 |}
172 { \voicetwo d'4 d'2.*2/3 } spacing
173 . * tied notes for MIDI
174 . * sharp / flat on trills (in MIDI ??)
175 . * scm-ify \property values.
176 . * move class Lookup {} into scm
178 . * \breathmark TeX macro
179 . * add new glyphs to font.ly
180 . * formatting of input stuff.
181 . * \notes{ a \< b \cr } vs \notes{ a \< b \! }
182 . * space after bars?
183 . * 'hinterfleisch' before bar (e.g. wtk1-fugue2)?
184 . * Summary of minor spelling irregularities:
185 . * capitalization/use of underscores in property names
186 . * fix SkipBars -> skipBars
188 lbheel = \script { "bheel" 0 0 -1 0 0 }
189 rbheel = \script { "bheel" 0 0 1 0 0 }
190 lbtoe = \script { "btoe" 0 0 -1 0 0 }
191 rbtoe = \script { "btoe" 0 0 1 0 0 }
192 lfheel = \script { "fheel" 0 0 -1 0 0 }
193 rfheel = \script { "fheel" 0 0 1 0 0 }
194 lftoe = \script { "ftoe" 0 0 -1 0 0 }
195 rftoe = \script { "ftoe" 0 0 1 0 0 }
197 portato= \script { "portato" 0 -1 0 1 0 }
199 . * bottomnote for ly2dvi
202 . * compulsory hshift
203 . * Give # lines in linebreaking.
205 . * Align_element::padding ?
206 . * uniformise property names...
207 . * ydirection <-> yDirection
208 . * rather allow '_' in identifiers first (i.e. junk ^ and _),
210 . * typo checks on property names?
211 . * use streambufs and iostream
212 to provide IO handling for TeX stream, mudela stream, data-file.
213 . * seriously buffer TeX output (do profile of writing .5 mb TeX file.)
214 . * strip EXEs before installing
215 . * zip target for binary windows dist (JBR)
216 . * junking \skip req in lyrics
217 . * mi2mu empty staffs.
218 . * use Fourier transformation for rhythmic quantisation.
219 . * horizontal centering of dynamics
220 . * $DEPENDENCIES_OUTPUT support
221 . * Xdvi zooming ?! Try to understand GS garbage collection.
222 gs: Error: /undefined in draw_beam
224 . * fix vertical alignment and stafflines
225 . * declaring Performers
226 . * *.yo: fix pod manpage layout legacy
227 . * text-items clash with stems/beams
228 . * --include, -I option for ly2dvi (pass on to lily)
229 . * fix placement of beam-less abbrev
231 <{\voiceone cis4. cis8 cis4 | cis4 cis cis | r1 }
232 {\voicetwo cis,4 r r | r2. | r1 }> |
234 . * Musical_pitch (analogous to Duration and Rhythmic_req)
235 think about, analogous to pitch:
236 * { a4 a16 } c <-- duration of c?
237 * < a4 b8 > c <-- duration of c?
239 . * fix audio-items (don't use (input) requests, but copy data)
240 . * make sure all ex's have a mudela-version
241 . * do rest-collisions for Multi_measure_rests as well.
242 . * split error/warning in error/warning/non_fatal_error
243 . * add a Duration_convert member to Duration_iter to set parameters.
244 Junk global duration settings.
245 . * en-,discouraged linebreaking:
246 . * handle DISALLOW < penalty > FORCE
247 . * discourage breaking of slurs
248 . * fix variable define/lookup parser global<->paper
249 . * fix title/instrument placements; see input/test/title.ly
250 . * <\voiceone c4. \voicetwo c4>
251 . * add full cello suites to web site (kom op, Maarten!)
252 . * Rethink Time_description
253 \cadenza , \meter, \grouping should all be \properties
256 . * abbrev -> tremolo
257 . * abbreviation-beam -> (measured/unmeasured) tremolo
258 . * partial -> anacrouse
259 . * robustify Beam (in case of no stems, 32nd notes)
260 . * move paper vars into engraver properties
261 . * check for groff / troff/ nroff et
262 . * more intelligent file searching
263 . * disable spaces in TeX stuff
264 . * handle ^C for tmp/file creation.
265 . * make LilyPond RPM fully relocatable
266 . * dots & rest collisions.
267 . * the warning about the negative slur/tie length appears twice
269 . * better hshift (dots, distance, head dependent)
270 . * clefs (AG): The "8" should appear closer to the actual clef,
272 . * put errorlevel in Input class
273 . * junk nesting slurs
274 . * integrate midi-elts from mi2mu and lily?
275 . * distinguish between unset and empty properties.
278 . * the bracket is ugly (wings are too parabolic, should be more circular)
279 . * versioning for Feta
280 . * rewrite dynamic signs. They're kind of spaghetti now.
281 . * The `3' in the meter key is a one or two pixels too thin (at 600dpi)
283 . * design macro for penstroke with rounded endings
284 . * timesig C: fat yet less curved. Check out relations.
285 . * design decent macro for bulbed endings
286 . * printer dependencies.
287 . * y-refpoint for rests should be the 4th staffline (gclef: b')
288 . * clean-up eight+ rests
291 . * work out sizes of character fonts.
293 . * piano pedals: Ped/*
295 . * coda signs: Segno, O+
296 . * glissando, arpeggio
298 . * include important spacing dims in fetalog
299 . * scalability: use blot_diameter everywhere, make font chubbier for
303 . * GNU diff 2.7: diff -rN does not see a new directory with empty file
304 . * check out GCC signatures?
306 f = fopen ("/dev/null", "r")
309 . * tetex: mfplain.mem
310 .* 3RD PARTY PROJECTS:
311 . * make GCC warn about ctor that leaves member vars uninitialised.
313 . * 'double-fix' mode: ignore identical fix, rather than suggest
314 to revert patch direction when (more or less? exactly) the same
318 . * stack scripts in chords:
319 % fingering: footing:
320 < a-4 c-2 g-1 > < c-\ltoe e-\lheel >
322 . * slur parts as a script
323 . * stack parameterised scripts for fingering and footing:
326 . * automatically add a \version if not present.
329 . * convert-mudela -e empty.ly
331 . * emacs mudela-mode
332 . * should handle block comments too.
333 . * handle lexer modes (\header, \melodic, \lyric) etc.
336 . * fontlock: \melodic \melodic
338 . * use properties for:
344 . * optimal pagebreaking.
346 . * Unicode support? -> man 7 unicode
349 . * detect of 16/8 bit files
350 . * examples to go with it.
353 . * write a faster Spring_spacer (without matrices if possible)
354 . * relate energybound to linelen unitspace fontsize etc.
355 . * used fixed point fp?
358 . * output header info to MIDI too.
360 . * a musical dictionary. See Documentation/vocabulary-*, other
370 . * guitar chords (fret diagrams)
371 . * other chord name styles (american(?) style)
376 . * derive lily_stream, Dstream, texstream from ostream?
377 . * indentable stream as baseclass for TeX stream, lily stream, Dstream.
378 . * use dstream feature in mi2mu
379 . * integrate IO checking into stream class
386 . * add to MIDI output:
388 . * ornaments (and trills?)
393 > Would it be hard to add support for proper dynamics in MIDI output? I
394 > would really like to have this feature...
396 To answer this, I have to give a little background. Please say so if
399 Both audio and notation elements are created decentrally, when
400 LilyPond says "Interpreting music ... [8][16] etc." After all
401 elements are created, they are processed again to calculate all
402 parameters. After that is done, they are dumped onto the output (the
403 MIDI stream or the TeX file).
405 The audio and notation elements are created by objects called
406 performer and engraver respectively. They work by taking a chunk of
407 input (a so-called request), and using the request to create an audio
410 After some processing, the engraver sends the created elements to
411 its enclosing notation/performance context.
413 In the case of notation, engravers can also modify existing elements
414 created by sibling engravers. Eg. the beam-engraver will modify stems
415 when it creates a beam over a couple of stems. This is done in
416 Engraver::do_acknowledge_element () and
417 Engraver::do_process_acknowledged ().
419 In the case of audio, there are no mechanisms to modify existing audio
420 elements. After the audio elements are created, they are sent directly
421 to the enclosing context (an instance of Performer_group_performer),
422 through the method Performer::play ()
424 Concretely spoken, for dynamics you have to write a performer
425 (Dynamics_performer), that will take the input requests. If I
426 understand correctly, every MIDI note played must have its dynamic
427 strength set separately. That means the the Dynamics_performer must
428 set the strength of every Audio_note it finds. This means that one
429 has to modify existing Audio items. The best way of doing this is
430 with a broadcast/acknowledge process.
432 So the best way of handling this, is
434 1 supporting dynamic settings in Audio_note
436 2 mimicking the broadcast/acknowledge mechanism of the Engravers in
439 3 using that mechanism to write a Dynamics_performer that will modify
440 any notes it finds to set appropriate strengths.
442 You could also kludge this by deriving from Performer_group_performer
443 a performer that also sets dynamics within notes, but that is not the
444 elegant way to do it.
446 I'd say that the work involved is not hard, but you have to be fluent
447 with C++ and need some insight into the working of Notation Contexts
448 and friends. I guess I could do it in a day or so, but if you are not
449 so fluent with the inner workings of LilyPond, it could take you some
450 more time (A few more days?).
452 Please note, that I am *not* going to code this myself: my days are
453 valuable, and I think I have more interesting things to do than fixing
454 the MIDI output (I don't even have a soundcard). But I *do* want to help
455 you or other people with implementing this, so if you need help, don't
458 . * account for rhythmic position in measure
462 . * make separate class for Grace_*_engravers
463 (which is at Voice_gravs level)
464 . * make encapsulated spacing problems.
466 . * accidentals per Voice_group
468 . * Output class, handles : (smallish)
469 . * help text /(c) notice?
471 . * warning /errors/progress
472 . * abort on error/warning; exit status
473 . * quiet/ignore-version options
477 . * speed up PS code.
478 . * PS lines to .eps files
479 . * write custom prolog
484 . * remove links to non-free SW.
485 . * internal documentation
488 . * left/rightbeamcount
489 . * various other new properties.
494 . * Doc (C) stuff of sheet music
495 . * a better format? SGML? TeX? Info?
496 . * a better tutorial
498 . * more spanners (smallish)
502 . * Rewrite Stem, Beam and Rhythmic_grouping (hairy)
504 . * doc on Rhythmic_grouping
505 . * general shaving on Beam and Stem
506 . * use plet grouping
507 . * separate visual from rhythmic info even more
511 . * Ledger lines, should be separate item: Ledger_lines
512 . * set different line sizes / thicknesses
513 . * beam stem showthrough, inter beam sizes (french vs german style)
516 . * left/right note balls should be handled by Collision:
517 < \multi 2; { \stem 1; <b c> } { <f as b> } >
520 . * merge key{item} & localkey{item}?
521 . * spacing, national styles?
524 . * redo Notehead to allow digits as heads
525 . * add a \tablature {} lexer mode for easy entering
527 . * should adjust stemlength for flag number.
530 . * caching breakpoints
532 . * specify number of lines
535 . * \rhythms 4 16 16 16 16; c c c c c -> c4 c16 etc.
539 . * \bla {} vs \bla ;
540 . * mix engraver hacking with music ?
541 . * \once\property KEY = VAL
542 . * \addtranslator, \removetranslator
543 . * junk ^ and _ for scripts
544 . * junk _ for lyrics.
545 . * abstract grammar.
546 . * Figure out semicolons.
547 . * c4 4 4 4 for c4 c4 c4 c4?
558 . * configure pitch_byte
559 . * rest name configurable
564 . * Faulenzer sign (% repeat)
566 . * fix confusing naming in Engraver vs Engraver_group_engraver (context)
568 . * progress when creating MIDI elts.
570 . * A range for context errors (eg. mark both { and }. )
572 . * lyric in staff (sharpsharp in staff, text below)
574 . * half sharps/flats
576 . * write Dynamic_line (to group dynamics horizontally)
578 . * use Real for all y positions.
580 . * half-sharps, half-flats
582 . * adaptive accidental spacing.
584 . * handle EOF graciously in error messages.
586 . * midi esp.: use I32 iso int where 32 bits are needed (or assumed...)
588 . * stafftypes: voice names/ instrument names.
592 . * % toe to bheel four to five
598 (where "to" is a tiny bow)
600 . * auxilliary file for caching info.
607 . * Output data structures of Mudela in XML/SGML.
608 . * create libmudela, or liblily_frontend
609 . * move MIDI stuff (including Quantization) to a ANSI C libmidi library.
610 . * Spacing_request for manually adjusting spacing
611 . * caching breakpoints
612 . * used fixedpoint arithmetic for min. energy.
613 . * move towards incremental algorithms.
614 . * versioning stuff (cvt mudela, mudela, etc.)
615 . * dynamic loading of engravers?
617 Han-Wen Nienhuys <hanwen@cs.uu.nl> writes:
620 > Foo_smob *smob_ptr_;
624 > Foo_class *class_ptr_
627 Usually you can get away without having this interlinked structure.
628 One piece of information you need when exporting objects to scheme is
629 the smob tag for your class. You might store this value (a long) into
630 a class static variable, or a file static variable. I'll use a class
631 static variable in this example.
633 I typically use code that works like this (untested code ahead):
636 static long *Foo_smob_tag;
637 SCM obj; // representation as a scheme object, description comes later
640 // call this once on startup
641 void init_Foo_class {
642 static scm_smobfuns type_rec;
644 type_rec.mark = foo_mark;
645 type_rec.free = foo_free;
646 type_rec.print = foo_display;
648 Foo_class::Foo_smob_tag = new int(scm_new_smob(type_rec));
651 When you want to export an object to scheme, you put a pointer to the
652 object itself in the cdr of the cell, and the tag in the car of the
653 cell. The code looks like this:
659 return(SCM_NIMP(obj) && SCM_CAR(obj) == Foo_class::Foo_smob_tag);
662 // given a Scheme representation, return, a C++ representation
666 return((Foo_class*)SCM_CDR(obj));
669 // the SCM representation of the object is stored inside itself
670 // this will become useful when destructor gets called
672 foo_box(Foo_class *foo)
675 SCM_NEWCELL(foo->obj);
676 SCM_SETCAR(foo->obj, Foo_class::Foo_smob_tag);
677 SCM_SETCDR(foo->obj, (SCM)foo);
682 > C++ determines life time, so what is the strategy?
684 What happens now when the destructor gets called? Lets set the cdr to
685 NULL, and then check for that in all of the primitive functions that
686 use your smob. We'll call this notion 'live'; a scheme object is
687 'live' if the C++ representation still exists, it's dead if the C++
688 object is gone. You can still have references to dead objects in
689 scheme code; it's just an error to use them. This idea is stolen from
690 Emacs's handling of buffers ('buffer-live-p' and friends).
692 Add another function, foo_live_p:
697 return(foo_p(obj) && SCM_CDR(obj) != NULL);
700 In you destructor, you need to do:
704 SCM_CDR(this->obj, NULL);
707 When writing new primitives, now just check foo_live_p().
709 I hope the above helps,
715 (defvar outline-font-lock-keywords
716 '(;; Highlight headings according to the level.
717 ;; must change this to allout node layout
718 ;;("^\\(\\*+\\)[ \t]*\\(.+\\)?[ \t]*$"
719 ("^\\([.]*[ ]*[*]\\)[ \t]*\\(.*\\)$"
720 (1 font-lock-string-face)
721 (2 (let ((len (- (match-end 1) (match-beginning 1))))
722 (or (cdr (assq len '((1 . font-lock-function-name-face)
723 (2 . font-lock-keyword-face)
724 (3 . font-lock-comment-face))))
725 font-lock-variable-name-face))
727 ;; Highlight citations of the form [1] and [Mar94].
728 ("\\[\\([A-Z][A-Za-z]+\\)*[0-9]+\\]" . font-lock-type-face))
729 "Additional expressions to highlight in Outline mode.")
731 (add-hook 'outline-mode-hook
733 (setq font-lock-maximum-decoration t)
734 (setq font-lock-maximum-decoration t)
735 (make-local-variable 'font-lock-defaults)
736 (setq font-lock-defaults '(outline-font-lock-keywords t))
737 (font-lock-mode global-font-lock-mode)