]> git.donarmstrong.com Git - lilypond.git/blob - TODO
release: 1.1.48
[lilypond.git] / TODO
1 -*-outline-layout:(2 (-1 -1 0 :) 0);outline-stylish-prefixes:nil -*-
2
3 * GNU LilyPond TODO
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
7
8 Most of the items are marked in the code as well
9 Grep for TODO and ugh/ugr/urg.  
10
11 .* BUGS
12 . * junk separate mudela versioning. 
13 . * petite-ouverture time sig size. 
14 . * PostScript
15 .  * header for PS enteredby = "bla <bla@bar.com>"
16 .  * ps/lily.ps see comments.
17 . * By the way, I'm not sure the translation of 'C, G, and F clef'
18 > should include Alto, Violin, Bass <clef translated>.
19 [..]
20
21 I understand your point.  It should be changed.
22
23
24
25 > The terms C-clef, G-clef, F-clef stand for the signs, being
26 > mutated forms of a C, a G and an F.
27
28 > The terms Violin Clef etc. stand for the signs being used in
29 > special positions on the staff.
30
31 > The G-clef-sign indicates g' on the line around which the
32 > snake centers. It is a Violin Clef if it is centered around the
33 > second line (from below), and a French Violin Clef if it is
34 > centered around the lowest.
35
36 > The C-clef indicates c' on the line that gets
37 > 'pinched' by it. It is a Soprano, Mezzosoprano (English?), Alto, Tenor
38 > and (don't remember exactly, maybe Baritone) Clef, depending on
39 > the line (from highest to lowest).
40
41 > The F-clef-sign indicates f on the line between
42 > the two dots. If it's on the second line from above, it is called
43 > Bass Clef. If it's on the middle line, it is called (maybe
44 > Baritone) Clef too, because it indicates the same pitches as the
45 > C-Clef on the highest line. So, you could write an Alto Clef by
46 > putting the F-clef sign on the lowest line (but that's _very_
47 > uncommon).
48
49 > Sorry, this is written very messy because I'm in a hurry,
50 > but I hope you understand what I want to say.
51
52 . * didot / big point.
53 . * midi key.
54 . * Repeats
55 .  * input/bugs/rep.ly (moved from test)
56 .  * unfold broken: 
57 .   * without alternatives: repeat unfold 4 { a b c d }
58 .   * count > alternatives: repeat unfold 79 { a b c d } 
59 \alternative { { c c c c } { d d d d } }
60 .  * kind of 'initial property' iso fold/volta(semi)/unfold strings
61 . * fix singleStaffBracket
62 . * declare performers in \midi
63 . * fix MIDI
64 . * \shape 1st dim skipped? 
65 . * turn slope-damping on/off
66 . * tremolo stuff: tremolo over whole note.
67 . * We need feta-din*.mf files for more sizes than 10.
68 . * fix dynamics decently, ie. use kerning & ligatures.  
69 . * dots & rest collisions?
70 . * mudela-book.py
71 .  * fix \mudelafile{} to have decent functionality
72 .  * P.P.S. It can be cool in mudela-book to distinguish in
73 pre,postMudelaExample, whether MudelaExample is epsed or not: ( if
74 this fragment is floating eps, than 1, otherwise 2). say
75 preMudelaExample[eps]{}, and change it in document body sometimes.
76 .  * use less RE's
77 . * slurs colllide with lyrics.
78 . * Is there any reasonable way to do this: I would like to have one file
79 that can generate the same tune in two different modes without having
80 to go through and rewrite all the music in the other mode.
81
82 Lyrics and scripts collide.
83 . * Phrasing:  Indicating the textual underlay of a piece, or
84 otherwise dividing a piece into phrases.
85
86 There are distinct ways of specifying the first two (although at
87 present, they're not properly distinguished) but no distinct way to
88 specify the third.  Should there be?
89 . * rest collision minimum dist.
90 . * a note with a circle after it, meaning:
91
92    note + circle = note + 1/4 of its length
93
94 5   the circle is like a dot that's not filled in.  for example, on
95    page three, the c-sharp on the second line should be a quarter with 
96    a circle, not a quarter tied to a sixteenth.  is this at all
97    possible with lily?
98 . * tuplets that are written as "number : note", for example
99    "3 : [image of a half note here]".  possible?
100 . * repeat engraver, gallina.ly
101
102 . * Matanya's tips: 
103 .  * spacing for prefatory matter
104 .  * accidentals closer to note head
105 .  * to space the staffs/staffgroups contained in the score.  
106 .  * heavier beams?
107
108 .* Cleanups needed
109 . * Beam
110 . * Stem
111 . * Slur
112 . * Rhythmic_grouping
113 . * Duration
114 . * Collision
115 . * Rest_collision
116 . * clef grav prop's 
117 . * parser
118
119 .* TODO before 1.2
120 . * Morally pure LilyPond.
121 .  * Remove mutopia ramblings.
122 .  * Remove non-free software links.
123 .  * Remove meta article LilyPond.
124 . * break priority setting from SCM.
125 . * Gade score
126 .  * remove [] in favour of auto-beamer
127 . * hangOnClef with non-breakable clefs.
128 . * Aha, the problem is the new TeX code generation for changing fonts.
129 > (The explanation below is mostly intended for Han-Wen and Jan)
130 > Before, the font was changed with macros declared separately for 
131 > pure TeX and LaTeX, but now all the fonts are declared directly in
132 > the generated code using the low-level TeX commands. This circumvents
133 > the fontencoding mechanism of LaTeX and is a potential source of
134 > problems also for us users of the Latin-1 character set. 
135 > I think it still works since the inputencoding latin1 is 
136 > declared by ly2dvi, but it still means that e.g. an o with
137 > umlaut is typeset as a combination of the two symbols 'o' and
138 > 'umlaut' instead of as a single character, as would be the case
139 > if fontencoding OT1 had been used. This shouldn't give any 
140 > difference in layout, though. One of the main argument for using
141 > fontencoding OT1 is for the hyphenation mechanism to work, an 
142 > argument that's clearly irrelevant in our application. Yet we
143 > see the problem for August.
144 . * Abstraction for engravers:
145 .  * make "in-between" engraver (Tie, Extender)
146 .  * make wide_spanner_engraver (line_group_spanner, staff_symbol)
147 . * remove Interval dim_ from Dimension_cache and rename the struct.
148 . * do scaled fonts generally 
149 . * The Lilypond accidental symbols are available through the TeX macros, 
150 \textflat, \textsharp and \textnatural defined in the init file
151 lilyponddefs.tex. All the symbols are defined in the files fetaXX.tex
152 where XX corresponds to the size. I don't know where (or even if) they
153 are installed but they are generated in the mf/out/ directory during the
154 compilation.
155 . * make dependencies () a virtual function.
156 . * one big ly2dvi input that includes *all* tests.
157 . * store req -> element, element -> element causes for warnings
158 . * include examples in RPM.
159 . * fix partial measures in meaningful way.
160 . * add scripts to bars eg.  |^"bla" 
161 . * relative mode for mi2mu
162 . * uniformise recent feta contributions.
163 .  * use SCM and Molecules for {accordeon stuff, }
164 .  * bigger and fatter 4/4 C
165 . * sort out directory stuff.
166 .  * --prefix option?
167 .  * -I option per filetype?
168 .  * kpathsea?
169 . * ly2dvi/lilypond logfile.
170 . * fractional chord durs.
171 . * hang Item on Spanner
172 . * do --safe for PS output?
173 . * convert-mudela --output
174 . * Staff_margin (with a partial measure.)
175 . * fix pletvisibility properties:
176 .  * bracket on/off/no-bracket-when-beam
177 .  * num on/off/no-num-when-beam
178 . * fix: standchen.
179 . * junk text{sharp,flat,etc}
180 . * fix convert-mudela manpage
181 . * decimal point in \paper {}
182 . * {  \voiceone <a'4.*2/3  d''4.*2/3 fis''4.*2/3>  [g''8 fis'' e''] d''4 |}
183          and
184          { \voicetwo  d'4 d'2.*2/3 } spacing
185 . * tied notes for MIDI
186 . * sharp / flat on trills (in MIDI ??)
187 . * scm-ify \property values.
188 . * move class Lookup {} into scm
189 . * msgfmt -o check?
190 . * \breathmark TeX macro 
191 . * add new glyphs to font.ly
192 . * formatting of input stuff. 
193 . * \notes{ a \< b \cr } vs \notes{ a \< b \! }
194 . * 'hinterfleisch' before bar (e.g. wtk1-fugue2)?
195 . * Summary of minor spelling irregularities:
196 .  *  capitalization/use of underscores in property names
197 .  * fix SkipBars  -> skipBars
198 . * broken scripts:
199         lbheel = \script { "bheel" 0 0 -1  0 0 }
200         rbheel = \script { "bheel" 0 0 1 0 0 }
201         lbtoe = \script { "btoe" 0 0 -1 0 0 }
202         rbtoe = \script { "btoe" 0 0 1 0 0 }
203         lfheel = \script { "fheel" 0 0 -1  0 0 }
204         rfheel = \script { "fheel" 0 0 1 0 0 }
205         lftoe = \script { "ftoe" 0 0 -1 0 0 }
206         rftoe = \script { "ftoe" 0 0 1 0 0 }
207         and also
208         portato= \script { "portato" 0 -1 0 1 0 }
209 . * ly2dvi
210 .  * bottomnote for ly2dvi
211 .  * deps for ly2dvi
212
213 .* STUFF
214 . * compulsory hshift
215 . * Give # lines in linebreaking.  
216 . * arrows on slurs.
217 . * rewrite context defs using Scheme
218 . * \selectmusic to cut pieces from music. 
219 . * TODO: merge atom & molecule; make  tree from molecule.
220 . * Align_element::padding  ?
221 . * typo checks on property names?
222 . * use streambufs and iostream
223         to provide IO handling for TeX stream, mudela stream, data-file.
224 . * seriously buffer TeX output (do profile of writing .5 mb TeX file.)
225 . * strip EXEs before installing
226 . * zip target for binary windows dist (JBR)
227 . * junking \skip req in lyrics
228 . * mi2mu empty staffs.
229 . * use Fourier transformation for rhythmic quantisation.
230 . * horizontal centering of dynamics 
231 . * $DEPENDENCIES_OUTPUT support
232 . * fix vertical alignment and stafflines
233 . * declaring Performers
234 . * *.yo: fix pod manpage layout legacy
235 . * text-items clash with stems/beams
236 . * --include, -I option for ly2dvi (pass on to lily)
237 . * fix placement of beam-less abbrev
238 . * \meter 3/4;
239         <{\voiceone cis4. cis8 cis4 | cis4 cis cis | r1 }
240          {\voicetwo cis,4 r r | r2. | r1 }> |
241         }
242 . * Musical_pitch (analogous to Duration and Rhythmic_req)
243           think about, analogous to pitch: 
244            * { a4 a16 } c <-- duration of c?
245            * < a4 b8 > c <-- duration of c?
246 . * \tempo 4. = 90;
247 . * fix audio-items (don't use (input) requests, but copy data)
248 . * make sure all ex's have a mudela-version
249 . * do rest-collisions for Multi_measure_rests as well.
250 . * split error/warning in error/warning/non_fatal_error
251 . * add a Duration_convert member to Duration_iter to set parameters.
252         Junk global duration settings. 
253 . * en-,discouraged linebreaking: 
254 .  * handle DISALLOW < penalty > FORCE
255 .  * discourage breaking of slurs
256 . * fix variable define/lookup parser global<->paper
257 . * fix title/instrument placements; see input/test/title.ly
258 . * <\voiceone c4. \voicetwo c4>
259 . * add full cello suites to web site (kom op, Maarten!)
260 . * add mudela-book-doc source to webstie.
261 . * Rethink Time_description
262 \cadenza , \meter, \grouping should all be \properties
263 . * rename
264 .  * measure -> bar
265 .  * abbrev -> tremolo
266 .  * abbreviation-beam -> (measured/unmeasured) tremolo
267 .  * partial -> anacrouse
268 . * robustify Beam (in case of no stems, 32nd notes)
269 . * move paper vars into engraver properties
270 . * check for groff / troff/ nroff et
271 . * more intelligent file searching
272 . * disable spaces in TeX stuff
273 . * handle ^C for tmp/file creation.
274 . * make LilyPond RPM fully relocatable
275 . * dots & rest collisions.
276 . * the warning about the negative slur/tie length appears twice
277 which is irritating.
278 . * better hshift (dots, distance, head dependent)
279 . * clefs (AG): The "8" should appear closer to the actual clef,
280 touching it.
281 . * put errorlevel in Input class
282 . * junk nesting slurs
283 . * integrate midi-elts from mi2mu and lily?
284 . * distinguish between unset and empty properties. 
285
286 .* FONT
287 . * the bracket is ugly (wings are too parabolic, should be more circular)
288 . * versioning for Feta
289 . * rewrite dynamic signs.  They're kind of spaghetti now. 
290 . * The `3' in the meter key is a one or two pixels too thin (at 600dpi)
291         in the middle:
292 . * design macro for penstroke with rounded endings
293 . * timesig C: fat yet less curved.  Check out relations. 
294 . * design decent macro for bulbed endings
295 . * printer dependencies.
296 . * versioning  
297 . * lo-res fixes.
298 . * work out sizes of character fonts.
299 . * more symbols
300 .  * piano pedals: Ped/*
301 .  * maxima notehead
302 .  * coda signs: Segno, O+
303 .  * glissando, arpeggio
304 .  * lengthened trill
305 . * include important spacing dims in fetalog 
306 . * scalability: use blot_diameter everywhere, make font chubbier for
307     small sizes.
308
309 .* 3RD PARTY BUGS
310 . * GNU diff 2.7: diff -rN does not see a new directory with empty file
311 . * check out GCC signatures?
312 . * glibc 2.0:
313           f = fopen ("/dev/null", "r")
314           assert (feof (f))
315
316 . * tetex: mfplain.mem
317 .* 3RD PARTY PROJECTS:
318 . * make GCC warn about ctor that leaves member vars  uninitialised.
319 . * GNU patch 
320 .  * 'double-fix' mode: ignore identical fix, rather than suggest 
321             to revert patch direction when (more or less? exactly) the same 
322             thing is fixed
323 .* PROJECTS
324 . * Scripts:
325 .  * stack scripts in chords:
326           % fingering:        footing:
327             < a-4 c-2 g-1 >   < c-\ltoe e-\lheel >
328 .  * script-spacing
329 .  * slur parts as a script
330 .  * stack parameterised scripts for fingering and footing:
331
332 . * convert-mudela:
333 .  * automatically add  a \version if not present.
334 .  * better parsing
335 .  * make smarter
336 .  * convert-mudela -e empty.ly
337
338 . * emacs mudela-mode
339 .  *  should handle block comments too.
340 .  *  handle lexer modes (\header, \melodic, \lyric) etc.
341 .  *  indentation
342 .  *  notenames?
343 .  *  fontlock: \melodic \melodic
344
345 . * use properties for:
346 .  * default tempo.
347 .  * cadenza mode? 
348
349 . * page handling:
350 .  * PS output
351 .  * optimal pagebreaking.
352
353 . * Unicode support? -> man 7 unicode
354 .  * 16 bit Strings
355 .  * -u switch
356 .  * detect of 16/8 bit files
357 .  * examples to go with it.
358
359 . * \header
360 .  * output header info to MIDI too.
361
362 . * a musical dictionary. See Documentation/vocabulary-*, other
363 languages:
364 .  * explanations
365 .  * italian
366 .  * german
367 .  * dutch
368 .  * swedish
369          .. ?
370
371 . * chords
372 .  * guitar chords (fret diagrams)
373 .  * other chord name styles (american(?) style)
374 .  * basso continuo
375 .  * MIDI output?
376
377 . * Debug logs:
378 .  * derive lily_stream, Dstream, texstream from ostream?
379 .  * indentable stream as baseclass for TeX stream, lily stream, Dstream.
380 .  * use dstream feature in mi2mu
381 .  * integrate IO checking into stream class
382
383 . * input converters
384 .  * NIFF?
385 .  * ABC? 
386 .  * SMDL?
387
388 . * add to MIDI output:
389 .  * tempo change
390 .  * ornaments (and trills?)
391 .  * slurs
392 .  * accents
393 .  * dynamics
394 > Would it be hard to add support for proper dynamics in MIDI output?  I
395 > would really like to have this feature...
396
397 Concretely spoken, for dynamics you have to write a performer
398 (Dynamics_performer), that will take the input requests. If I
399 understand correctly, every MIDI note played must have its dynamic
400 strength set separately.  That means the the Dynamics_performer must
401 set the strength of every Audio_note it finds.  This means that one
402 has to modify existing Audio items.  The best way of doing this is
403 with a broadcast/acknowledge process.
404
405 So the best way of handling this, is
406
407   1 supporting dynamic settings in Audio_note
408
409   2 Write a Dynamics_performer that will modify
410   any notes it finds to set appropriate strengths.
411
412 I'd say that the work involved is not hard, but you have to be fluent
413 with C++ and need some insight into the working of Notation Contexts
414 and friends.  I guess I could do it in a day or so, but if you are not
415 so fluent with the inner workings of LilyPond, it could take you some
416 more time (A few more days?).
417
418 Please note, that I am *not* going to code this myself: my days are
419 valuable, and I think I have more interesting things to do than fixing
420 the MIDI output (I don't even have a soundcard).  But I *do* want to help
421 you or other people with implementing this, so if you need help, don't
422 hesitate to ask.
423 .  * account for rhythmic position in measure
424 .  * etc.
425
426 . * grace notes
427 .  * make separate class for Grace_*_engravers 
428         (which is at Voice_gravs level)
429 .  * make encapsulated spacing problems.
430
431 . * accidentals per Voice_group
432
433 . * Output class, handles : (smallish)
434 .  * help text /(c) notice?
435 .  * version line
436 .  * warning /errors/progress
437 .  * abort on error/warning; exit status
438 .  * quiet/ignore-version options
439 .  * logfile output
440
441 . * PS 
442 .  * speed up PS code.
443 .  * PS lines to .eps files
444 .  * write custom prolog
445
446 . * SGML input
447
448 . * Documentation
449 .  * remove links to non-free SW.
450 .  * internal documentation
451 .  * a general paper. 
452 .  * \properties
453 .   * left/rightbeamcount
454 .   * various other new properties.
455 .  * introduction?
456 .  * info?
457 .  * LaTeX?
458 .  * more manpages?
459 .  * Doc (C) stuff of sheet music
460 .  * a better format?  SGML?  TeX?  Info?
461 .  * a better tutorial
462
463 . * more spanners (smallish)
464 .  * Glissando
465 .  * trill
466
467 . * Rewrite Stem, Beam and Rhythmic_grouping (hairy)
468 .  * [c8. c32 c32]
469 .  * doc on Rhythmic_grouping
470 .  * general shaving on Beam and Stem
471 .  * use plet grouping
472 .  * separate visual from rhythmic info even more
473 .  * beams over bars
474
475 . * lines:
476 .  * Ledger lines, should be separate item: Ledger_lines
477 .  * set different line sizes / thicknesses
478 .  * beam stem showthrough, inter beam sizes (french vs german style)
479
480 . * Collisions
481 .  * left/right note balls should be handled by Collision:
482         < \multi 2; { \stem 1; <b c> } { <f as b> } >
483
484 . * Keys:
485 .  * merge key{item} & localkey{item}?
486 .  * spacing, national styles?
487
488 . * Support for TAB
489 .  * redo Notehead to allow digits as heads
490 .  * add a \tablature {} lexer mode for easy entering
491
492 . * should adjust stemlength for flag number.
493
494 . * breaking:
495 .  * caching breakpoints
496 .  * saving them
497 .  * specify number of lines
498
499 .* INPUTLANGUAGE
500 . * \rhythms 4 16 16 16 16; c c c c c -> c4 c16 etc. 
501 . * Language:
502 .  * \translator -> ?
503 .  * fix \partial 
504 .  * \bla {} vs \bla ; 
505 .  * mix engraver hacking with music ?
506 .  * \once\property  KEY = VAL
507 .  * \addtranslator, \removetranslator
508 .  * junk ^ and _ for scripts
509 .  * junk _ for lyrics.
510 .  * abstract grammar.
511 . * Figure out semicolons.
512 . * c4 4 4 4 for c4 c4 c4 c4?
513 . * <c f a>4 ?
514 . * Viola mode?
515
516                 @c c g e g 
517         for
518                 c g es g, 
519
520                 @A c g e g
521         for
522                 cis gis e gis
523 . * configure pitch_byte
524 . * rest name configurable
525
526
527 .* SMALLISH PROJECTS
528
529 . * Faulenzer sign (% repeat).  Perhaps also use \repeat syntax?
530
531 . * fix confusing naming in Engraver vs Engraver_group_engraver (context)
532
533 . * progress when creating MIDI elts.
534
535 . * A range for context errors (eg. mark both { and }. )
536
537 . * lyric in staff  (sharpsharp in staff, text below)
538
539 . * half sharps/flats
540
541 . * write Dynamic_line (to group dynamics horizontally)
542
543 . * use Real for all y positions.
544
545 . * half-sharps, half-flats
546
547 . * adaptive accidental spacing.
548
549 . * handle EOF graciously in error messages.
550
551 . * midi esp.: use I32 iso int where 32 bits are needed (or assumed...)
552
553 . * stafftypes: voice names/ instrument names.
554
555 . * lily \tempo
556
557 . *   % toe to bheel   four to five
558             %   ^_u            4_5  
559             %     -                           
560             %  --|x--         --|x--
561             %  --|---         --|---
562             %  --|---         --|---
563           (where "to" is a tiny bow)
564
565 . * auxilliary file for caching info.
566
567 . * Text_crescendo
568
569 . * revise calcideal
570
571 .* IDEAS
572 . * Output data structures of Mudela in XML/SGML.
573 . * create libmudela, or liblily_frontend
574 . * move MIDI stuff (including Quantization) to a ANSI C libmidi library.
575 . * Spacing_request for manually adjusting spacing
576 . * caching breakpoints
577 . * used fixedpoint arithmetic for min. energy.
578 . * move towards incremental algorithms.
579 . * versioning stuff (cvt mudela, mudela, etc.)
580 . * dynamic loading of engravers? 
581 .* SMOBS
582 Han-Wen Nienhuys <hanwen@cs.uu.nl> writes:
583
584 >       class Foo_class {
585 >               Foo_smob *smob_ptr_;
586 >       }
587
588 >       struct Foo_smob {
589 >               Foo_class *class_ptr_
590 >       }
591
592 Usually you can get away without having this interlinked structure.
593 One piece of information you need when exporting objects to scheme is
594 the smob tag for your class.  You might store this value (a long) into
595 a class static variable, or a file static variable.  I'll use a class
596 static variable in this example.
597
598 I typically use code that works like this (untested code ahead):
599
600 class Foo_class {
601     static long *Foo_smob_tag;
602     SCM obj; // representation as a scheme object, description comes later
603 }
604
605 // call this once on startup
606 void init_Foo_class {
607     static scm_smobfuns type_rec;
608
609     type_rec.mark = foo_mark;
610     type_rec.free = foo_free;
611     type_rec.print = foo_display;
612     type_rec.equalp = 0;
613     Foo_class::Foo_smob_tag = new int(scm_new_smob(type_rec));
614 }
615
616 When you want to export an object to scheme, you put a pointer to the
617 object itself in the cdr of the cell, and the tag in the car of the
618 cell.  The code looks like this:
619
620 // Is this a Foo?
621 static int
622 foo_p(SCM obj)
623 {
624     return(SCM_NIMP(obj) && SCM_CAR(obj) == Foo_class::Foo_smob_tag);
625 }
626
627 // given a Scheme representation, return, a C++ representation
628 static Foo_class *
629 foo_unbox(SCM obj)
630 {
631     return((Foo_class*)SCM_CDR(obj));
632 }
633
634 // the SCM representation of the object is stored inside itself
635 // this will become useful when destructor gets called
636 static SCM
637 foo_box(Foo_class *foo)
638 {
639     SCM_DEFER_INTS;
640     SCM_NEWCELL(foo->obj);
641     SCM_SETCAR(foo->obj, Foo_class::Foo_smob_tag);
642     SCM_SETCDR(foo->obj, (SCM)foo);
643     SCM_ALLOW_INTS;
644     return foo->obj;
645 }
646
647 > C++ determines life time, so what is the strategy?
648
649 What happens now when the destructor gets called?  Lets set the cdr to
650 NULL, and then check for that in all of the primitive functions that
651 use your smob.  We'll call this notion 'live'; a scheme object is
652 'live' if the C++ representation still exists, it's dead if the C++
653 object is gone.  You can still have references to dead objects in
654 scheme code; it's just an error to use them.  This idea is stolen from
655 Emacs's handling of buffers ('buffer-live-p' and friends).
656
657 Add another function, foo_live_p:
658
659 static int
660 foo_live_p(SCM obj)
661 {
662     return(foo_p(obj) && SCM_CDR(obj) != NULL);
663 }
664
665 In you destructor, you need to do:
666
667 ~Foo_class()
668 {
669     SCM_CDR(this->obj, NULL);
670 }
671
672 When writing new primitives, now just check foo_live_p().
673
674 I hope the above helps,
675
676
677 * OUTLINE SETUP
678 .* .EMACS
679 ;;; from outline.el
680 (defvar outline-font-lock-keywords
681   '(;; Highlight headings according to the level.
682     ;; must change this to allout node layout
683     ;;("^\\(\\*+\\)[ \t]*\\(.+\\)?[ \t]*$"
684     ("^\\([.]*[ ]*[*]\\)[ \t]*\\(.*\\)$"
685      (1 font-lock-string-face)
686      (2 (let ((len (- (match-end 1) (match-beginning 1))))
687           (or (cdr (assq len '((1 . font-lock-function-name-face)
688                                (2 . font-lock-keyword-face)
689                                (3 . font-lock-comment-face))))
690               font-lock-variable-name-face))
691         nil t))
692     ;; Highlight citations of the form [1] and [Mar94].
693     ("\\[\\([A-Z][A-Za-z]+\\)*[0-9]+\\]" . font-lock-type-face))
694   "Additional expressions to highlight in Outline mode.")
695
696 (add-hook 'outline-mode-hook
697           '(lambda ()
698             (setq font-lock-maximum-decoration t)
699             (setq font-lock-maximum-decoration t)
700             (make-local-variable 'font-lock-defaults)
701             (setq font-lock-defaults '(outline-font-lock-keywords t))
702             (font-lock-mode global-font-lock-mode)
703         ))
704  
705 (require 'allout)
706 (outline-init 't)