From 8cccc72565f5a293e796765176d2db3ee03290a8 Mon Sep 17 00:00:00 2001 From: Jan Nieuwenhuizen Date: Tue, 27 Mar 2001 22:56:36 +0200 Subject: [PATCH] patch::: 1.3.143.jcn3 1.3.143.jcn3 ============ * LilyPond-mode: show what's going on (font building) in *view* buffer. --- CHANGES | 5 ++++ Documentation/regression-test.tely | 2 ++ VERSION | 2 +- input/regression/lyric-phrasing.ly | 41 ++++++++++++++++++++++++++++++ lily/lyric-phrasing-engraver.cc | 17 ++++++++++++- lily/syllable-group.cc | 5 +++- lilypond-mode.el | 12 +++++++-- mutopia/F.Schubert/standchen.ly | 15 +++++------ scripts/lilypond-book.py | 1 + 9 files changed, 87 insertions(+), 13 deletions(-) create mode 100644 input/regression/lyric-phrasing.ly diff --git a/CHANGES b/CHANGES index 74a6a0dd35..ecaaf2c40b 100644 --- a/CHANGES +++ b/CHANGES @@ -1,3 +1,8 @@ +1.3.143.jcn3 +============ + +* LilyPond-mode: show what's going on (font building) in *view* buffer. + 1.3.143.jcn2 ============ diff --git a/Documentation/regression-test.tely b/Documentation/regression-test.tely index 8125c6cf66..1a15cc7735 100644 --- a/Documentation/regression-test.tely +++ b/Documentation/regression-test.tely @@ -158,6 +158,8 @@ and documenting bugfixes. @lilypondfile[printfilename]{lyrics-multi-stanza.ly} +@lilypondfile[printfilename]{lyric-phrasing.ly} + @section Multiple notes diff --git a/VERSION b/VERSION index ad508afa16..2e0a72bbfa 100644 --- a/VERSION +++ b/VERSION @@ -2,7 +2,7 @@ PACKAGE_NAME=LilyPond MAJOR_VERSION=1 MINOR_VERSION=3 PATCH_LEVEL=143 -MY_PATCH_LEVEL=jcn2 +MY_PATCH_LEVEL=jcn3 # use the above to send patches: MY_PATCH_LEVEL is always empty for a # released version. diff --git a/input/regression/lyric-phrasing.ly b/input/regression/lyric-phrasing.ly new file mode 100644 index 0000000000..ffa791cbdd --- /dev/null +++ b/input/regression/lyric-phrasing.ly @@ -0,0 +1,41 @@ +\header{ + texidoc="Lyric phrasing + + We find start and end of phrases, and align lyrics of multiple stanzas + accordingly. + + Also, lyrics at start of melismata should be left aligned. + (is that only lyrics that are followed by `__'? Because + that seems to be the case now -- jcn) + +@example + | | | | | + x| x| x| x| x| + + 1: Start sentence melisma end. + 2: x x x______ x +@end example + + Only lyrics that are followed by '__' while there's a melisma, + are left-aligned, in this case the third x."; +} + +\paper { linewidth = -1.; } +\score { + \addlyrics + \context Voice = "v" \notes \relative c'' { + \property Staff.automaticMelismata = ##t + \autoBeamOff + a a a8()a a4 + } + \context Lyrics < + \context LyricsVoice = "v-1" \lyrics { + \property LyricsVoice . stanza = "1:" + Start sentence melisma end. + } + \context LyricsVoice = "v-2" \lyrics { + \property LyricsVoice . stanza = "2:" + x x x __ x + } + > +} diff --git a/lily/lyric-phrasing-engraver.cc b/lily/lyric-phrasing-engraver.cc index e24f7642c3..b23e2d786e 100644 --- a/lily/lyric-phrasing-engraver.cc +++ b/lily/lyric-phrasing-engraver.cc @@ -39,9 +39,24 @@ ADD_THIS_TRANSLATOR (Lyric_phrasing_engraver); */ /* - We find start and end of phrases, and align lyrics accordingly. + We find start and end of phrases, and align lyrics of multiple stanzas + accordingly. + Also, lyrics at start of melismata should be left aligned. + (is that only lyrics that are followed by `__'? Because + that seems to be the case now -- jcn) + + + | | | | | + x| x| x| x| x| + 1: Start sentence melisma end. + 2: x x x_____ x + + Only lyrics that are followed by '__' while there's a melisma, + are left-aligned, in this case the third x. + + Alignment and melismata I've taken [a different] approach: diff --git a/lily/syllable-group.cc b/lily/syllable-group.cc index afe3ad1078..119acd03df 100644 --- a/lily/syllable-group.cc +++ b/lily/syllable-group.cc @@ -175,7 +175,10 @@ Syllable_group::appropriate_alignment (const char *punc) lastchar = lyric_str[lyric_str.length_i ()-1]; /* If it doesn't end in punctuation then it ain't an end of phrase */ if (! strchr (punc, lastchar)) { - /* Special case: trailing space. Here examine the previous character and reverse the + /* + FIXME: Document this. + + Special case: trailing space. Here examine the previous character and reverse the sense of the test (i.e. trailing space makes a break without punctuation, or suppresses a break with punctuation). This behaviour can be suppressed by including a space in the diff --git a/lilypond-mode.el b/lilypond-mode.el index a72f32a034..177004d096 100644 --- a/lilypond-mode.el +++ b/lilypond-mode.el @@ -295,6 +295,14 @@ Must be the car of an entry in `LilyPond-command-alist'." file)) string))) +(defun LilyPond-shell-process (name buffer command) + (let ((old (current-buffer))) + (switch-to-buffer-other-window buffer) + (goto-char (point-max)) + (start-process-shell-command name buffer command) + (switch-to-buffer-other-window old))) + + (defun LilyPond-command (name file) "Run command NAME on the file you get by calling FILE. @@ -316,8 +324,8 @@ command." ;; Don't open new xdvi window, but force redisplay ;; We could make this an option. (signal-process (process-id process-xdvi) 'SIGUSR1) - (start-process-shell-command name buffer-xdvi command))) - (start-process-shell-command name buffer-xdvi command))) + (LilyPond-shell-process name buffer-xdvi command))) + (LilyPond-shell-process name buffer-xdvi command))) (progn (setq LilyPond-command-default name) (LilyPond-compile-file command name))))))) diff --git a/mutopia/F.Schubert/standchen.ly b/mutopia/F.Schubert/standchen.ly index c9a0b1f6aa..69561d89b3 100644 --- a/mutopia/F.Schubert/standchen.ly +++ b/mutopia/F.Schubert/standchen.ly @@ -1,4 +1,6 @@ +#(set! point-and-click line-column-location) + instrument = "Piano" \header { @@ -98,7 +100,7 @@ vocalThrough = \notes\relative c{ } lyricVerseOne = \lyrics{ - Lei- se fleh- en mei- ne Lie- der + Lei- se fleh- en mei- ne Lie- der Durch die Nacht zu dir; In den stil- len Hain her- nie- der Lieb- chen, komm zu mir! @@ -345,17 +347,17 @@ global = \notes{ \bar "|."; } -allLyrics = \lyrics { +allLyrics = \lyrics { \lyricVerseOne \lyricVerseTwo \lyricThrough } -lyricStaff = \context Lyrics = lyric< +lyricStaff = \context Lyrics { \allLyrics -> +} -vocals = \notes{ +vocals = \context Voice { \clef treble; % certainly no auto-beaming for vocals \property Voice.noAutoBeaming = ##t @@ -389,7 +391,6 @@ trebleStaff = \context Staff = treble< \global \treble > - bass = { \clef bass; \bassIntro @@ -425,8 +426,6 @@ grandStaff = \context PianoStaff < %} \addlyrics - %\context Staff=vocal \vocalStaff - %\context Lyrics=lyric \lyricStaff \vocalStaff \lyricStaff \grandStaff diff --git a/scripts/lilypond-book.py b/scripts/lilypond-book.py index e4bb7ffef3..acfec670af 100644 --- a/scripts/lilypond-book.py +++ b/scripts/lilypond-book.py @@ -50,6 +50,7 @@ if program_version == '@' + 'TOPLEVEL_VERSION' + '@': # setups. Maybe we should check if kpsewhich can find # feta16.{afm,mf,tex,tfm}, and only set env upon failure. # +datadir = '@datadir@' environment = { 'MFINPUTS' : datadir + '/mf:', 'TEXINPUTS': datadir + '/tex:' + datadir + '/ps:.:', -- 2.39.5