[EMAIL PROTECTED] writes:
> * Han-Wen Nienhuys
> 
> > > -> So dou you know how to get the information whether there's
> > > a lyrics-staff *below* the current staff (at the time when a dynamic
> > > symbol is prepared e.g. in Dynamic_engraver::do_process_requests()) ?
> > 
> > That would be difficult.
> 
> Coming to think of it, it shouldn't be.
>

I know it shouldn't, but unfortunately, it is; that is, I can't see
how to solve it cleanly.  One could hardcode in C++ to look for a
context called Lyric, and hope that it contains a engraver for the
syllable, find that engraver and do all sorts of wonderful things.

A cleaner solution would be to have a sort of superstaff that catches
notes and syllables and somehow couples them. 

> setting the default dynamicdir to "up" for vocal music).  Later, it

That's easy 


        Staff = \translator {
                \type "Engraver_group_engraver";
                defaultclef = violin;


                dynamicdir = "1"1;

                \consists "Bar_engraver";
                \consists "Clef_engraver";

                        :
                        :

> could allow automatic placement of beams to follow the rythm of the
> lyrics, e.g. if I enter

I fear not.  Automatic placement of beams is hairy as it is: we can't
do it without the complications of Lyrics, let alone with those.
> 
> Another way of accomplishing the same thing would be to make a special
> kind of staff for vocal music, somewhat like this:
> 
>     Vocal_staff = \translator {
>       \type "Engraver_group_engraver";
>       defaultclef = "g";
>       dynamicdir = 1 ; % or "up", for readability?
> 
>       \consists "Bar_engraver";
>       \consists "Clef_engraver";
>       \consists "Key_engraver";
>       \consists "Local_key_engraver";
>       \consists "Staff_sym_engraver";
>       \consists "Collision_engraver";
>       \consists "Rest_collision_engraver";
>       \consists "Staff_margin_engraver";
>       \consists "Separating_line_group_engraver";
>       \consists "Vertical_align_engraver";  % do we need this?


no, it is for aligning (stacking)  staffs and staff groups vertically.

>       \consists "Line_group_engraver";      % or this?

yes;  It makes the symbols in the staff behave as a group.

>       % \consists "Vocal_beam_engraver";    % Some day the beams
>                                             % may follow the lyrics
>                                             % automagically.


yep.  But the code for Vocal_beam_engraver?

>       \accepts "Voice";
>       \accepts "Lyrics";

That won't work: the lyrics and notes would be printed in overstrike
mode

> 
> Both ways, Lilypond would know she's dealing with vocal music, and she
> could be told to act accordingly in numerous ways[1].  I guess the
> second form is way cleaner, but that's my guess.

I fear that the following FAQ entry applies here


Q: Could you implement feature XXXX? It is really easy, just extend
the syntax to allow YYYY!


A: If it is reasonable, I'll add XXXX to the TODO list. In general
finding a cute syntax (such as YYYY) isn't very hard. The complicated
issue how to adapt the internals to do XXXX. The parser is really a
simple front end to the complicated internals.

> [1] karaoke output, anyone? ;-)

MIDI output actually works like Karaoke.  You just need a good MIDI player.

-- 

Han-Wen Nienhuys, [EMAIL PROTECTED] ** GNU LilyPond - The Music Typesetter 
      http://www.cs.uu.nl/people/hanwen/lilypond/index.html 

Reply via email to