]> git.donarmstrong.com Git - lilypond.git/commitdiff
release: 1.5.48 origin/tarball/master release/1.5.48 tarball/HEAD
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Tue, 26 Mar 2002 23:27:21 +0000 (00:27 +0100)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Tue, 26 Mar 2002 23:27:21 +0000 (00:27 +0100)
36 files changed:
ChangeLog
VERSION
input/mozart-hrn-3.ly [new file with mode: 0644]
input/mozart-hrn3-allegro.ly [new file with mode: 0644]
input/mozart-hrn3-romanze.ly [new file with mode: 0644]
input/mozart-hrn3-rondo.ly [new file with mode: 0644]
lily/bar-line.cc
lily/beam.cc
lily/custos.cc
lily/dynamic-engraver.cc
lily/include/lookup.hh
lily/include/multi-measure-rest.hh
lily/include/note-head.hh
lily/lookup.cc
lily/multi-measure-rest.cc
lily/note-head.cc
lily/porrectus.cc
lily/slur.cc
lily/staff-symbol-referencer.cc
lily/voice-devnull-engraver.cc
lilypond-font-lock.el
ly/grace-init.ly
ly/params-init.ly
ly/spanners-init.ly
make/out/lilypond.lsm
make/out/lilypond.mandrake.spec
make/out/lilypond.redhat.spec
make/out/lilypond.suse.spec
mf/feta-eindelijk.mf
scm/ascii-script.scm
scm/grob-description.scm
scm/pdf.scm
scm/pdftex.scm
scm/ps.scm
scm/tex.scm
tex/lilyponddefs.tex

index 363e38739586a9016d7f59ad980a3d9c83f6b47a..8ffd169bb727bd64ce45f64920e57ad11275a107 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,46 @@
+2002-03-27  Han-Wen  <hanwen@cs.uu.nl>
+
+       * lily/multi-measure-rest.cc (symbol_molecule): split off from
+       brew_molecule()
+       (set_spacing_rods): Use symbol_molecule() to determine minimum
+       width
+       (church_rest): split off from brew_molecule()
+       (big_rest): split off from brew_molecule(). Construct using
+       variable shape.
+       
+       * mf/feta-eindelijk.mf: junk multi measure rest.
+
+2002-03-26  Han-Wen  <hanwen@cs.uu.nl>
+
+       * lily/multi-measure-rest.cc (add_column): remove columns property.
+
+       * lily/dynamic-engraver.cc (process_music): add more verbose warning
+
+       * input/mozart-hrn3-romanze.ly (romanze): add mozart horn concerto
+       3 as test piece.
+
+2002-03-26  Heikki Junes <hjunes@cc.hut.fi>
+
+       * lilypond-font-lock.el (LilyPond-font-lock-keywords): most new
+       keywords covered, dropped some non-keywords, include R- and 128-notes
+
+2002-03-25 Juergen Reuter <reuter@ipd.uka.de>
+
+       * Code clean-up: Junk multiple implementations of ledger line
+       creation in note_head, custos, and porrectus.  This is important
+       since there soon will be some more applications of ledger lines to
+       come (e.g. ambitus engraver).
+
+       * Make thickness of ledger lines adjustable.  This is essential
+       for mensural notation.
+
+       * Fix some bugs in the current ledger_line implementation, most
+       notably that of the horizontal extent of ledger lines which equals
+       at least the extent of the metafont ledger_line character, and
+       which grows(!) if the desired extent shrinks below this limit.
+
+       * roundfilledbox: variable blotdiameter
+
 2002-03-24  Han-Wen  <hanwen@cs.uu.nl>
 
        * VERSION: 1.5.47 released
diff --git a/VERSION b/VERSION
index e6d9e5925e9018554490bfba153904d001edac32..322e260b3dd5f6bca2ee8f6a6868f576e8ab7135 100644 (file)
--- a/VERSION
+++ b/VERSION
@@ -1,7 +1,7 @@
 PACKAGE_NAME=LilyPond
 MAJOR_VERSION=1
 MINOR_VERSION=5
-PATCH_LEVEL=47
+PATCH_LEVEL=48
 MY_PATCH_LEVEL=
 
 
diff --git a/input/mozart-hrn-3.ly b/input/mozart-hrn-3.ly
new file mode 100644 (file)
index 0000000..9c2fc28
--- /dev/null
@@ -0,0 +1,58 @@
+\header{
+  title =       "Konzert Nr. 3 Es dur"
+  subtitle = "f\\\"ur Horn und Orchester"
+  composer =    "Wolfgang Amadeus Mozart (1756-1792)"
+  enteredby =   "HWN"
+  opus = "K.V. 447"
+
+  copyright = "public domain"
+  instrument = "Horn in F"
+  editor = "Henri Kling"
+  mutopiatitle = "Horn Concerto 3"
+  mutopiacomposer = "W.A.Mozart"
+  mutopiaopus = "KV447"
+  style = "classical"
+  maintainer = "hanwen@cs.uu.nl"
+  maintainerEmail = "hanwen@cs.uu.nl"
+  maintainerWeb = "http://www.cs.uu.nl/~hanwen/"       
+  lastupdated = "2002/March/26"
+  source = "Edition Breitkopf 2563"
+
+  tagline =  "\\parbox{\hsize}{\\thefooter\\quad\\small This music is part of the Mutopia project, \\texttt{http://sca.uwaterloo.ca/Mutopia/}. It has been typeset and placed in the public domain by " + \maintainer + ". Unrestricted modification and redistribution is permitted and encouraged---copy this music and share it!}"
+
+}
+%{
+
+This is the Mozart 3 for horn.  It's from an Edition Breitkopf EB
+2563, edited by Henri Kling. Henri Kling (1842-1918) was a horn
+virtuoso that taught in Geneva. 
+
+%}
+
+
+#(set! point-and-click line-column-location)
+
+longgrace = \property Voice.Stem \override #'flag-style = #'()
+endlonggrace = \property Voice.Stem \revert #'flag-style
+ritenuto = \textscript #'(italic  "rit.")
+
+\version "1.5.47"
+
+\paper{
+ \translator { \ScoreContext
+       skipBars = ##t
+       midiInstrument = #"french horn"
+       RehearsalMark \override #'font-series = #'bold
+  }
+ \translator { \StaffContext
+              MinimumVerticalExtent = #'(-4.5 . 4.5)
+              }
+  indent = 10. \mm
+  linewidth = 189. \mm
+}
+
+\include "mozart-hrn3-allegro.ly"
+\include "mozart-hrn3-romanze.ly"
+\include "mozart-hrn3-rondo.ly"
+
+
diff --git a/input/mozart-hrn3-allegro.ly b/input/mozart-hrn3-allegro.ly
new file mode 100644 (file)
index 0000000..c81bb95
--- /dev/null
@@ -0,0 +1,160 @@
+\version "1.3.146"
+
+allegro =
+       \notes
+       \relative c'
+{
+       \time 4/4
+       \key c \major
+       \property Score . measurePosition = #(make-moment 3 4)
+       r4 
+       |
+       R1*4
+       c'2^"Tutti" g
+       c, r
+       R1*1
+       r8 [g' g g] [g g e c]
+       g'4 g, r2
+       R1*18
+       r2 r4 g'4^"Solo" |
+       e'4. () c8 [f (d c )b ]
+       [b()c] g4 r8 [g-. c-. e-.]
+       g2. ( [g16-.( f e ))f]
+       dis4 () e4-- r8 [c8-. c-. c-.]
+       c4.( [d16 e]  f4 ) e
+       a,( d g,) c
+       d-. d-. \grace e16( [)d8. c16 d8. e16]
+       c4 r r2
+       R1*3
+       c,2 ~ [c8 e( g )c]
+       [c () b ] b4-. r2
+       [c,8 () e g c] [e()g e c]
+       [c()b] b4-- r2
+       c4.( g8 e'4.) c8
+       [g'()d ] d4-- r4 d
+       [d8 () c] c4.( [d16 e] [d8 )c]
+       [c8(-\trill )b] b4 r2 |
+       d2( ~  [d8 e16 d] [c8 )b] |
+       [b()a-.] a4-> r8 [a-. a-. a-.]
+       a4( cis e )g
+       \grace { \longgrace g16( \endlonggrace }
+       [ )fis8( e16 )d] d4-. r2 | 
+       \mark "B"
+       R1*3
+       r2 r4 [d8(_#'(italic "con espressione") )b ]
+       [a( )g d'( )b] [a( )g e'( )c ]
+       [b8( )a] a4 r4 [a8-. a-.]
+       [a( \< b c \!cis\> ]  d4 \! )c
+       [ais8() b] r8 b [b()c] r c
+       [cis ()d] r4 r2
+       g,1 ~ g2 ~ [g8 a16 b] [c()d e c]
+       f4-. d-. b-. g-.
+       r1
+       \emptyText
+       c,2\p e4 g c \cresc e g4. e8 |
+       d4. [e16 fis] [g () fis e d] [c() b a g]
+       \endcresc
+       < a1(-\trill
+         { s2. \grace{ [g16 a] } } >
+       )g4 r r2
+       R1*15
+       \mark "D"
+       bes2-\mf d4 f
+       g,2~ [g8 g'( es )c]|
+       bes4( )a4. [c8 d es]
+       cis4()d r8 [bes (c )d]
+       es2 () d4 r
+       es2\p () d4 r
+       [c8(\mf g' es )c] bes4()c-.
+       c4.( cis8 )d4 r
+       R1*2
+       es1~es1|
+       e!
+       d
+       c
+       c,
+       e'
+       e,
+       c'2 [b8( a gis )a]
+       [gis8 e gis b ] e4 r |
+       r8 [e, a c] dis4 r
+       r8 [e, a c] dis4 r
+       r8 [e, g b] e4 r
+       r8 [fis, b dis] fis4 r
+       r8 [gis, b d] f4 r
+       r8 [g, b d_\ritenuto ] f4 r
+       \mark  "E"
+       R1*8
+       r2 r8 [g,-. g-. g-.]
+       e'4.() c8 [f( d c )b]
+       [b()c] g4 r8 [g c e] |
+       g2. ( [g16( f e ))f]
+       dis4()e r8 [c-. c-. c-.]
+       c4.( [d16 e] f4 )e
+       a, ( d g, )c
+       d d 
+           \grace { e8( }
+          [)d8. c16 d8. e16] 
+       c4 r r2
+       \mark "F"
+       R1*3
+       c,2~[c8( e g )c]
+       [c8()b] b4 r2
+       [c,8 e g c ] [e ()g e c]
+       [c()b] b4 r2
+       c2 (bes )a [a8(b c )cis]
+       d2( ~ [d8 e16 d] \grace { \longgrace d16( \endlonggrace } [)c8 b16 )c]
+       \grace { \longgrace c16 \endlonggrace }[ b8( a16 )g] g4 r2 |
+       R1*3
+       r2 r4 [g'8()e]
+       \mark "G"
+       [d()c g'()e] [d()c a'()f]
+       [e()d] d4 r [d8 d]
+       d4(~ [d16 e d )e] [g8() f e d] |
+       c4 r r2
+       r1
+       c1 ~
+       c |
+       [c8-. c-.] r c-. [cis()d] r d-. |
+       [dis()e] r e-. [e()f] r f-. |
+       g4-.-\f e-. c-. bes-. |
+       g-.\ff e-. c-. r |
+       a'2 ~ [a8_#'((font-shape . italic) "sempre " (dynamic "f")) b16 c] [d( e d )e]%TODO
+
+       f4. () d8 [f8 ()d f d]
+       [c (e] )g2 \grace  { \longgrace f16(  \endlonggrace }  [)e8( d16 )c]
+
+       < d1-\trill (
+         { s2. \grace { [c16 d] } } >
+       
+       ) c4 r r2
+       r1 |
+       \mark "H"
+       \times 2/3 { [ c8 ()b a ] }     \times 2/3 { [ g a b] } \times 2/3 { [ c d e] } \times 2/3 { [ f()e d] } |
+       \times 2/3 { [ c () b a ] } \times 2/3 { [ g a b] } \times 2/3 { [ c d e] } \times 2/3 { [ f()e d] }|
+       c4 \times 2/3 {  r8 [g'()e]} c4 \times 2/3 {  r8 [e () c]} |
+       g4 \times 2/3 {  r8 [c8() g] } \times 2/3 { [ e ()g e-. ] } \times 2/3 { [c () e c-.] }|
+       g4 r8 g'\f [a b c d]|
+
+       < d1(-\trill
+         { s2. \grace { [c16 d] } }  >
+       )c4 r r2
+       R1*3
+
+       c4._"Cadenza ad lib." () d8 d4.-\trill ( [c16 )d] 
+       c4 r r2
+       R1*8
+       r4 [c8.^"tutti"-\f c16] c4 c
+       c [c,8. c16] c4 c|
+       c2 r2 \bar "|."
+       
+}
+
+
+\score
+{
+       \notes { \transpose bes \allegro }
+       \paper{ }
+       \header { piece = "allegro" opus = "" } 
+       \midi{ \tempo 4=90 }
+}
diff --git a/input/mozart-hrn3-romanze.ly b/input/mozart-hrn3-romanze.ly
new file mode 100644 (file)
index 0000000..020d1a9
--- /dev/null
@@ -0,0 +1,87 @@
+
+\version "1.3.146"
+
+romanze = \notes \relative c' {
+       \key f \major
+       \time 2/2
+
+       c'4.( _#'(italic (dynamic "p") " con molto espressione") 
+               )f8 a,4 a
+       [bes8( c d bes] )g4 r8 g
+       a r bes r c r [d()bes]
+       a2( [)g8 a( bes )b]
+       c4. () f8 a,4 a |
+       % 6 
+       [bes8 (c d) bes] g4 r8 c,-.
+       [c8( e g )bes] [a( c f ) d]
+       c r e r f r r4
+       \mark "A"
+       R1*8
+       g4. ()f8  [e( d c) bes]
+       % 18
+       [bes( a d )c] c4 r
+       R1*2
+       g'4.() f8 [e( d c) bes]
+       [bes (a d ) c] c4 r
+       r1
+       % 25
+       [c16\mf ( d c )d] [e ( f e )f] [g()e c-. c-.] [f()d b-. b-.]
+       [c16\p () d c )d] [e ( f e )f] [g()e c-. c-.] [f()d b-. b-.]
+       [c8 \< c, c c] [c c c \! c ]
+       \mark "B"
+       c1\f
+       R1*9
+       f'4.(\p )d8 b4 r8 g
+       g'4.() e8 c4 r8 cis |
+       % 39
+       d4(~ [d16 e d )e] [f8 () d f() d]
+       c2()b4 r
+       R1*4
+       e4. ()g8 c,4 ()cis
+       [d8( e f )d] b4 r8 g
+       [c ()e g g] [g( f e )d]
+       c4(
+       \grace { e16 }
+       [d8. )c16] [c8 c--( c-- )c--]
+       \mark "C"
+       des1\sfp
+       g,1\sfp 
+       c\sfp   
+       c,\sfp  
+       R1*3
+       r8 [c-\p c c] c2~
+       [c8 c' c c] c2~
+       [c8 \< e( g f] [e \! d \> c bes]
+       \mark "D"
+       \! )a4 r r2
+       R1*3
+       c4.-\p () f8 a,4 a |
+       [bes8 (c d) bes] g4 r8 c,-.
+       [c8( e g )bes] [a( c f ) d]
+       c-. r e-. r f4 r4
+       R1*3
+       r2 r4 r8 c,8
+       [c8( e g )bes] [a( c f ) d]
+       c-. r e-. r f4 r4       
+       g,1\pp
+       c,2~c4. c8
+       [c8( e g )bes] [a( c f ) d]
+       c r e r f4 r4                   % -. ? 
+
+       r1
+       c8-.   r e-. r f4 r4
+
+       % Finish with F if played separately 
+       c8-.(   r c,-. r ) c4 r4| 
+       \bar "|."
+}
+
+
+
+\score
+{
+    \notes { \transpose bes \romanze }
+       \header { piece = "romanze" opus = "" } 
+       \midi{ \tempo 4 = 70  }
+       \paper{}
+}
diff --git a/input/mozart-hrn3-rondo.ly b/input/mozart-hrn3-rondo.ly
new file mode 100644 (file)
index 0000000..aab198e
--- /dev/null
@@ -0,0 +1,179 @@
+\version "1.3.146"
+
+rondotheme = \notes \relative c' {
+       [c'8 c c] [c c c]
+       c4( cis8 )d r g,
+       [d'8 d d] [d d d]
+       d4( dis8 )e r c |
+       [c()d e] [f g a]
+       [g ()e c] c4 d8
+       e4()d8 e4()f8
+       e4.()d8 r r |
+}
+
+lipbreaker = \notes \relative c'
+{
+       r8 [g'-. g-.] [c()e g,-.]
+       [c()e g,-.] [c()e g,-.]
+       [c c, c] [c c c]
+       [c c c] [c c c]
+}
+
+rightsixteenth = { \property Voice.stemLeftBeamCount = 1
+  \property Voice.stemRightBeamCount = 2 }
+leftsixteenth = { \property Voice.stemLeftBeamCount = 2
+  \property Voice.stemRightBeamCount = 1 }
+bothsixteenth = { \property Voice.stemLeftBeamCount = 2
+  \property Voice.stemRightBeamCount = 2 }
+
+rondo = \notes         \relative c'
+{
+       \partial 8
+       \time 6/8
+       \key c \major
+       
+       g'8-\p |
+       
+       \rondotheme
+       
+       R2.*13 |
+       r8 r-\fermata d [d e f]
+       [g ()e c-.] [d()e d-.]
+       c4 c8 [d e f]
+       [g()e c-.] [d()e d-.]
+       c4 r8 r4 r8 |
+       R2.*7
+       \mark  "A"
+       c4.\p \grace { e16( } [)d8 c d]
+       c4 r8 r4 r8
+       e4. \grace g16( [)f8 e f]
+       e4 r8 r4 r8
+       g4. e4 c8
+       g2.~
+       [g8 a b] [c d e ]
+       e4.()d8 r r
+       R2.*4
+       e2.~ |
+       [e8 d c] [c b a]
+       d2.~
+       [d8 c b] [b a g]
+       g'4()e8 b4()cis8
+       \mark "B"
+       d4 r8 r4 r8
+       R2.*3 |
+       r8 [d-. d-.] [d()g d-.]
+       [d()g d-.] [d d d]
+       [d()g] r r4 r8
+       R2.*1
+       \lipbreaker
+       c4 r8 [c' d e]
+       d4()g8 [c, d e]
+       d4 r8 r4 r8
+       R2. |
+       r4 r8 [c-. d-. e-.]
+       d4()g8 [c, d e]
+       [d()g fis] [e d c]
+       [b () e d] [c b a]
+       \mark "C"
+       g4 r8 r4 r8
+       r2. |
+       %
+       r8 [g g] [g( )b b]
+       [b()d d-.] [d()g g-.]
+       g2.~
+       [g8 a g] [f e d]
+       < \rondotheme
+         { s8-\p } >
+         
+       R2.*12
+       r4 r8 r4 c8
+       \mark "D"
+       c4 f8 c4 a8
+       a4.~a4 a8
+       bes4 c8 d4 bes8
+       g4. ~ g8 r r
+       R2.*3
+       r4 r8 r4 c8
+       a4. c
+       f ~ [f8. \rightsixteenth e16(  \bothsixteenth d )c]
+       bes4 g8 e4 g8
+       c,4. ~ c8 r r
+       R2.*3| 
+       r4 r8 r4 c'8
+       b4()c8 b4()c8
+       bes4. ~ bes4 g8
+       a4 c8 [f () d b]
+       d4. () c8 r r
+       \mark "E"
+       R2.*9  |
+       \lipbreaker 
+       [c8 c' c] c4.~
+       [c8 c d] [e e fis] 
+       g4 r8 r4 r8
+       r2.
+       r8 [g, g] [g g g] |
+       es'4. ~ [es8 d c]
+       b4 r8 r4 r8
+       r2. |
+       r8 [g g] [g g g]
+       es'4. ~ [es8 d c]
+       \cresc b4.  c4. d4. e4.
+       \mark "F"
+       \endcresc
+       
+       f2.\f ~ |
+       f4 r8 r4 r8
+       r8 [g,\> g] [g g g]
+       [fis  g gis] % Edition breitkopf says a-flat (silly!)
+                [a bes \! b]
+       < \rondotheme
+         { s8-\p } >
+       R2.*7
+       \mark "G"
+       R2.*4
+       c,4.\mf c4 c8
+       c4. e4 c8
+       g'4. g4 g8
+       g4. g,4 g8
+       c4 r8 r4 r8
+       r4 r8 r4 g'8
+       [c ()e g,-.]    [c ()e g,-.]
+       [c ()e g,-.]    [c ()e g,-.]
+       \mark "H"
+       \cresc g'2.  bes,2.
+       a4. [b16 c d e f g]
+       a4. f4 d8
+       [c8\f g' e] [c g e]
+       [\stemUp c \stemDown e' c] \stemBoth [g e c]
+       g4 r8 [g''8 e c]
+
+       
+       < d2.(-\trill
+         { s2  \grace {  [c16 d] } } >
+       
+       \endcresc
+       
+       )c4 r8 r4 r8
+       R2.*5
+       r8 r8-\fermata d8\p [d e f]
+       [g ()e c] [d()e d]
+       \cresc [c  c c] [d e f]
+       [g()e c] [d()e d]
+       \endcresc c4\f  r8 r4 r8
+       R2.*5
+       [c8\f c, c] [c c c]
+       c4 r8 c4 r8
+       c4 r8 r4 \bar "|."              % B&H do another r8.
+}
+
+
+
+
+\score
+{
+    \notes { \transpose bes    \rondo }
+       \header { piece = "rondo" opus = "" }
+       \midi{ \tempo 4 = 100 }
+       \paper { }
+}
index e1bd060ccc9fbc9969a5566f728a73a8ec354a6b..d4228dcc25e4c6c434969b8f716c8904b53ce37f 100644 (file)
@@ -54,8 +54,6 @@ Bar_line::compound_barline (Grob*me, String str, Real h)
 
   Real staffline = me->paper_l ()->get_var ("stafflinethickness");
   Real staff_space = Staff_symbol_referencer::staff_space (me);
-  Real staffspace = me->paper_l ()->get_var ("staffspace")
-    * staff_space;
 
   kern *= staffline;
   thinkern *= staffline;
@@ -67,7 +65,7 @@ Bar_line::compound_barline (Grob*me, String str, Real h)
   Molecule colon;
   Molecule dot = Font_interface::get_default_font (me)->find_by_name ("dots-dot");
   Real dist = ( Staff_symbol_referencer::line_count (me) & 1 ? 1 :
-               staff_space<2 ? 2 : .5 ) * staffspace;
+               (staff_space<2 ? 2 : .5) ) * staff_space;
   dot.translate_axis(dist/2,Y_AXIS);
   colon.add_molecule(dot);
   dot.translate_axis(-dist,Y_AXIS);
index 98b674ce8439e6a40449925138347d2ab4ab3e46..23bd41dbaa7330061f38004a0c7bd8f9069a57d1 100644 (file)
@@ -1341,6 +1341,19 @@ ADD_INTERFACE (Beam, "beam-interface",
   "A beam.
 
 #'thickness= weight of beams, in staffspace
-  ",
+
+
+We take the least squares line through the ideal-length stems, and
+then damp that using
+
+       damped = tanh (slope)
+
+this gives an unquantized left and right position for the beam end.
+Then we take all combinations of quantings near these left and right
+positions, and give them a score (according to how close they are to
+the ideal slope, how close the result is to the ideal stems, etc.). We
+take the best scoring combination.
+
+",
   "concaveness-threshold dir-function quant-score auto-knee-gap gap chord-tremolo beamed-stem-shorten shorten least-squares-dy direction damping flag-width-function neutral-direction positions thickness");
 
index 5fc7266b18023bc998dc3b8c04ac7d04fff8f454..608f0c03795b504be69f413b9c2902b7ac0ecaa7 100644 (file)
 #include "font-interface.hh"
 #include "math.h" // rint
 
-/*
-   This function is a patched and hopefully much more understandable
-   rewrite of Note_head::ledger_line ().  It still has some
-   bugs/limitations:
- *
- (1) The term thick/2 probably should be thick*2 (probably a bug,
-   see the code below).
- *
- (2) The minimal width of the resulting ledger line equals the width
-   of the noteheads-ledgerending symbol (a limitation):
- *
- (---- left ledger ending
-     ----) right ledger ending
- (---) resulting ledger line (just ok)
- *
-   If x_extent ("xwid" in Note_head) is less than the width of the
-   ledger ending, the width of the total ledger line is even *greater*
-   than the width of a ledger ending (I would call this a bug).  In
-   the below code, the condition "if (x_extent.length () >
-   slice_x_extent.length ())" avoids outputting the left ending in such
-   cases (rather a silly workaround, but better than nothing).
- *
- (---- left ledger ending
-     ----)   right ledger ending
- (-)   desired ledger line
-     ------- resulting ledger line (too long)
-     ----)   resulting ledger line with additional "if" (still too long)
- *
-   The algorithm works properly only for a desired ledger line width
-   greater than the width of the ledger ending:
- *
- (----    left ledger ending
-        ----) right ledger ending
- (------) desired ledger line
- (------) resulting ledger line (ok)
- *
- * (3) The thickness of the ledger line is fixed (limitation).
- */
-Molecule
-Custos::create_ledger_line (Interval x_extent, Grob *me) 
-{
-  Molecule line;
-  Molecule slice = Font_interface::get_default_font (me)->find_by_name ("noteheads-ledgerending");
-  Interval slice_x_extent = slice.extent (X_AXIS);
-  Interval slice_y_extent = slice.extent (Y_AXIS);
-
-  // Create left ending of ledger line.
-  Molecule left_ending = slice;
-  left_ending.translate_axis (x_extent[LEFT] - slice_x_extent[LEFT], X_AXIS);
-  if (x_extent.length () > slice_x_extent.length ())
-    line.add_molecule (left_ending);
-
-  // Create right ending of ledger line.
-  Molecule right_ending = slice;
-  right_ending.translate_axis (x_extent[RIGHT] - slice_x_extent[RIGHT],
-                              X_AXIS);
-  line.add_molecule (right_ending);
-
-  // Fill out space between left and right ending of ledger line by
-  // lining up a series of slices in a row between them.
-  Molecule fill_out_slice = left_ending;
-  Real thick = slice_y_extent.length ();
-  Real delta_x = slice_x_extent.length () - thick;
-  Real xpos = x_extent [LEFT] + 2*delta_x + thick/2; // TODO: check: thick*2?
-  while (xpos <= x_extent[RIGHT])
-    {
-      fill_out_slice.translate_axis (delta_x, X_AXIS);
-      line.add_molecule (fill_out_slice);
-      xpos += delta_x;
-    }
-
-  return line;
-}
-
-void
-Custos::add_streepjes (Grob* me,
-                  int pos,
-                  int interspaces,
-                  Molecule* custos_p_)
-{
-  // TODO: This is (almost) duplicated code (see
-  // Note_head::brew_molecule).  Junk me.
-  Real inter_f = Staff_symbol_referencer::staff_space (me)/2;
-  int streepjes_i = abs (pos) < interspaces
-    ? 0
-    : (abs (pos) - interspaces) /2;
-  if (streepjes_i) 
-    {
-      Direction dir = (Direction)sign (pos);
-      Molecule ledger_line (create_ledger_line (custos_p_->extent (X_AXIS),
-                                               me));
-      ledger_line.set_empty (true);
-      Real offs = (Staff_symbol_referencer::on_staffline (me))
-       ? 0.0
-       : -dir * inter_f;
-      for (int i = 0; i < streepjes_i; i++)
-       {
-         Molecule streep (ledger_line);
-         streep.translate_axis (-dir * inter_f * i * 2 + offs,
-                                Y_AXIS);
-         custos_p_->add_molecule (streep);
-       }
-    }
-}
-
 MAKE_SCHEME_CALLBACK (Custos,brew_molecule,1);
 SCM
 Custos::brew_molecule (SCM smob)
@@ -147,9 +42,9 @@ Custos::brew_molecule (SCM smob)
       String style = ly_scm2string (scm_symbol_to_string (scm_style));
 
       /*
-       DOCME:
-       
-       Why would we want it differently? What's the meaning of adjust ?
+       * Shall we use a common custos font character regardless if on
+       * staffline or not, or shall we use individual font characters
+       * for both cases?
        */
       bool adjust =
        to_boolean (me->get_grob_property ("adjust-if-on-staffline"));
@@ -199,8 +94,17 @@ Custos::brew_molecule (SCM smob)
        }
       else
         {
-         add_streepjes (me, (int)pos, sz, &molecule);
-         return  molecule.smobbed_copy ();
+         // add ledger lines
+         int pos = (int)rint (Staff_symbol_referencer::position_f (me));
+         int interspaces = Staff_symbol_referencer::line_count (me)-1;
+         if (abs (pos) - interspaces > 1)
+           {
+             Molecule ledger_lines =
+               Note_head::brew_ledger_lines (me, pos, interspaces,
+                                             molecule.extent (X_AXIS), true);
+             molecule.add_molecule (ledger_lines);
+           }
+         return molecule.smobbed_copy ();
        }
     }
   else
@@ -213,7 +117,6 @@ Custos::has_interface (Grob*m)
   return m && m->has_interface (ly_symbol2scm ("custos-interface"));
 }
 
-
 ADD_INTERFACE (Custos, "custos-interface",
   "A custos is a staff context symbol that appears at the end of a
   staff line with monophonic musical contents (i.e. with a single
index 7ddff09e1f470555d4c6dcf701124f68226dc280..05c5a04ba7b395d42b493034b1c77ba6267b300f 100644 (file)
@@ -215,6 +215,8 @@ Dynamic_engraver::process_music ()
  (current_cresc_req_->get_span_dir () == 1
             ? _ ("already have a crescendo")
             : _ ("already have a decrescendo"));
+
+         current_cresc_req_->origin ()->warning (_("Cresc started here"));
        }
       else
        {
index 447d0e4eca136637bee867dc583aedbdf8ba01de..fca7ccea693ff45fbe48d5ff38e89830b1436556 100644 (file)
@@ -21,14 +21,15 @@ struct Lookup
   static Molecule bracket (Axis a, Interval iv, Direction d, Real thick, Real protude);
   static Molecule accordion (SCM arg, Real interline_f, Font_metric*fm);
   static Molecule frame (Box b, Real thick);
-  static Molecule slur (Bezier controls, Real cthick, Real thick) ;
-  static Molecule bezier_sandwich (Bezier, Bezier);
-  static Molecule horizontal_slope (Real, Real, Real);
-  static Molecule beam (Real, Real, Real) ;
-  static Molecule dashed_slur (Bezier, Real thick, Real dash) ;
-  static Molecule blank (Box b) ;
-  static Molecule filledbox (Box b) ;
-  static Molecule repeat_slash( Real w, Real slope, Real th);
+  static Molecule slur (Bezier controls, Real cthick, Real thick);
+  static Molecule bezier_sandwich (Bezier top_curve, Bezier bottom_curve);
+  static Molecule horizontal_slope (Real width, Real slope, Real height);
+  static Molecule beam (Real slope, Real width, Real thick);
+  static Molecule dashed_slur (Bezier, Real thick, Real dash);
+  static Molecule blank (Box b);
+  static Molecule filledbox (Box b);
+  static Molecule roundfilledbox (Box b, Real blotdiameter);
+  static Molecule repeat_slash (Real w, Real slope, Real th);
 };
 
 #endif // LOOKUP_HH
index c6f7c9443267d7eebbc709db9bcc7b0d58419fea..0d46900ec7264eedacc564a33f31b749e5dcfe25 100644 (file)
@@ -23,6 +23,10 @@ public:
   DECLARE_SCHEME_CALLBACK (percent, (SCM));
   static  void add_column (Grob*,Item*);
   DECLARE_SCHEME_CALLBACK (set_spacing_rods, (SCM ));
+
+  static Molecule big_rest (Grob*,Real);
+  static Molecule symbol_molecule (Grob*);  
+  static Molecule church_rest (Font_metric*, int,Real, Real);
 };
 
 #endif /* MULTI_MEASURE_REST_HH */
index e60679d67b6ab7007b6a34bb1f3fb4bd98149489..55a9aa0b5aaef3e8ee9e2e19f9899001342ae79a 100644 (file)
@@ -21,9 +21,9 @@ class Note_head
 {
 public:
   DECLARE_SCHEME_CALLBACK (brew_molecule, (SCM ));
-  static Interval head_extent (Grob*,Axis);
-  static Molecule ledger_lines (Grob*, bool, int,Direction,Interval);
-  static Molecule ledger_line ( Grob*, Interval);
+  static Interval head_extent (Grob*, Axis);
+  static Molecule brew_ledger_lines (Grob *me, int pos, int interspaces,
+                                    Interval x_extent, bool take_space);
   DECLARE_SCHEME_CALLBACK (brew_ez_molecule, (SCM ));
   static bool has_interface (Grob*);
   static Real stem_attachment_coordinate (Grob *, Axis a);
index 1a2c793082c3276da9d0c99c2e05492a8e80230b..f25983e47ca7c4a4ea4dd56bcc5ab2f345c860af 100644 (file)
@@ -45,7 +45,6 @@ Lookup::beam (Real slope, Real width, Real thick)
   return Molecule (b, at);
 }
 
-
 Molecule
 Lookup::dashed_slur (Bezier b, Real thick, Real dash)
 {
@@ -72,7 +71,6 @@ Lookup::blank (Box b)
   return Molecule (b, SCM_EOL);
 }
 
-
 Molecule
 Lookup::filledbox (Box b) 
 {
@@ -86,6 +84,46 @@ Lookup::filledbox (Box b)
   return Molecule (b,at);
 }
 
+/*
+ * round filled box:
+ *
+ *   __________________________
+ *  /     \  ^           /     \
+ * |         |blot              |
+ * |   +   | |dia       |   +---|------
+ * |         |meter             |     ^
+ * |\ _ _ /  v           \ _ _ /|     |
+ * |                            |     |
+ * |                            |     | Box
+ * |                    <------>|     | extent
+ * |                      blot  |     | (Y_AXIS)
+ * |                    diameter|     |
+ * |                            |     |
+ * |  _ _                  _ _  |     |
+ * |/     \              /     \|     |
+ * | (0,0)                      |     v
+ * |   x   |            |   +---|------
+ * |   |                    |   |
+ *  \__|__/______________\__|__/
+ *     |                    |
+ *     |                    |
+ *     |                    |
+ *     |<------------------>|
+ *       Box extent(X_AXIS)
+ */
+Molecule
+Lookup::roundfilledbox (Box b, Real blotdiameter)
+{
+  SCM at = (scm_list_n (ly_symbol2scm ("roundfilledbox"),
+                       gh_double2scm (-b[X_AXIS][LEFT]),
+                       gh_double2scm (b[X_AXIS][RIGHT]),
+                       gh_double2scm (-b[Y_AXIS][DOWN]),
+                       gh_double2scm (b[Y_AXIS][UP]),
+                       gh_double2scm (blotdiameter),
+                       SCM_UNDEFINED));
+
+  return Molecule (b,at);
+}
 
 Molecule
 Lookup::frame (Box b, Real thick)
@@ -112,7 +150,6 @@ Lookup::frame (Box b, Real thick)
   
 }
 
-
 /*
   Make a smooth curve along the points 
  */
@@ -460,8 +497,6 @@ Lookup::repeat_slash (Real w, Real s, Real t)
   return Molecule (b, slashnodot); //  http://slashnodot.org
 }
 
-
-
 Molecule
 Lookup::bracket (Axis a, Interval iv, Direction d, Real thick, Real protude)
 {
index d7f6f04144397dbb704fa7a5379d61fe5114298c..8353e19812d10d45215075ca2bb6f2b3bb65407d 100644 (file)
 #include "rest.hh"
 #include "molecule.hh"
 #include "misc.hh"
-#include "group-interface.hh"
 #include "spanner.hh"
 #include "staff-symbol-referencer.hh"
 #include "text-item.hh"
 #include "percent-repeat-item.hh"
+#include "lookup.hh"
 
 bool
 Multi_measure_rest::has_interface (Grob*me)
@@ -31,7 +31,6 @@ MAKE_SCHEME_CALLBACK (Multi_measure_rest,percent,1);
 SCM
 Multi_measure_rest::percent (SCM smob)
 {
-  
   Grob *me = unsmob_grob (smob);
   Spanner *sp = dynamic_cast<Spanner*> (me);
   
@@ -80,26 +79,10 @@ SCM
 Multi_measure_rest::brew_molecule (SCM smob) 
 {
   Grob *me = unsmob_grob (smob);
-  if (to_boolean (me->get_grob_property ("skip-timestep")))
-    {
-      me->set_grob_property ("skip-timestep", SCM_EOL);
-      return SCM_EOL;
-    }
-  
   Spanner * sp = dynamic_cast<Spanner*> (me);
 
   SCM alist_chain = Font_interface::font_alist_chain (me);
 
-  
-  SCM style_chain =
-    Font_interface::add_style (me, ly_symbol2scm ("mmrest-symbol"),
-                              alist_chain);
-
-  Font_metric *musfont
-    = Font_interface::get_font (me,style_chain);
-                       
-  Real staff_space = Staff_symbol_referencer::staff_space (me);
-
   Interval sp_iv;
   Direction d = LEFT;
   do
@@ -126,7 +109,41 @@ Multi_measure_rest::brew_molecule (SCM smob)
    */
   x_off += sp_iv.length ()/ 2;
 
-  
+  mol.add_molecule (symbol_molecule (me));
+
+  int measures = 0;
+  SCM m (me->get_grob_property ("measure-count"));
+  if (gh_number_p (m))
+    {
+      measures = gh_scm2int (m);
+    }
+
+  if (measures > 1)
+    {
+      Molecule s = Text_item::text2molecule (me,
+                                            ly_str02scm (to_str (measures).ch_C ()),
+                                            alist_chain);
+      s.align_to (X_AXIS, CENTER);
+      s.translate_axis (3.0, Y_AXIS);
+      mol.add_molecule (s);
+    }
+  mol.translate_axis (x_off, X_AXIS);
+  return mol.smobbed_copy ();
+}
+
+
+Molecule
+Multi_measure_rest::symbol_molecule (Grob *me)
+{
+  SCM alist_chain = Font_interface::font_alist_chain (me);
+
+  SCM style_chain =
+    Font_interface::add_style (me, ly_symbol2scm ("mmrest-symbol"),
+                              alist_chain);
+
+  Real staff_space = Staff_symbol_referencer::staff_space (me);
+  Font_metric *musfont
+    = Font_interface::get_font (me,style_chain);
   Molecule s;
 
   int measures = 0;
@@ -139,7 +156,7 @@ Multi_measure_rest::brew_molecule (SCM smob)
 
   SCM limit = me->get_grob_property ("expand-limit");
   if (measures <= 0)
-    return SCM_EOL;
+    return s;
   if (measures == 1)
     {
       s = musfont->find_by_name (Rest::glyph_name (me, 0, ""));
@@ -148,66 +165,87 @@ Multi_measure_rest::brew_molecule (SCM smob)
        ugh.
        */
       if (Staff_symbol_referencer::position_f (me) == 0.0)
-       s.translate_axis (Staff_symbol_referencer::staff_space (me), Y_AXIS);
+       s.translate_axis (staff_space, Y_AXIS);
     }
   else if (measures <= gh_scm2int (limit))
     {
-      /*
-       Build a rest from smaller parts. Distances inbetween are
-       really variable, see Wanske pp. 125 */
-
-      int l = measures;
-      while (l)
-       {
-         int k;
-         if (l >= 4)
-           {
-             l-=4;
-             k = -2;
-           }
-         else if (l>= 2)
-           {
-             l -= 2;
-             k = -1;
-           }
-         else
-           {
-             k = 0;
-             l --;
-           }
-
-         Real pad = s.empty_b ()
-           ? 0.0 : gh_scm2double (me->get_grob_property ("padding")) * staff_space;
-
-         Molecule r (musfont->find_by_name ("rests-" + to_str (k)));
-         if (k == 0)
-           r.translate_axis (staff_space, Y_AXIS);
-         
-         s.add_at_edge (X_AXIS, RIGHT, r, pad);
-       }
-
-
-      s.align_to (X_AXIS, CENTER);
+      Real pad = gh_scm2double (me->get_grob_property ("padding")) * staff_space;
+      s = church_rest (musfont, measures, staff_space, pad);
     }
   else 
     {
-      String idx = ("rests-") + to_str (-4);
-      s = musfont->find_by_name (idx);
+      Real w = gh_scm2double (me->get_grob_property ("width"));
+      s = big_rest (me, w);
     }
+  return s;
+}
+
+Molecule
+Multi_measure_rest::big_rest (Grob *me, Real width)
+{
+  Real thick = gh_scm2double (me->get_grob_property ("thickness"));
+  Real ss = Staff_symbol_referencer::staff_space (me);
+  
+  Real slt = me->paper_l ()->get_var ("stafflinethickness");
+  Real y = slt * thick/2 * ss;
+  Box b(Interval (0, width), Interval (-y, y));
+  Real ythick = slt * ss;
   
-  mol.add_molecule (s);
+  Molecule m =  Lookup::filledbox (b);
+  Molecule yb = Lookup::filledbox (Box (Interval (-ythick, ythick), Interval (-ss, ss)));
 
-  if (measures > 1)
+  m.add_at_edge (X_AXIS, RIGHT, yb, -ythick);
+  m.add_at_edge (X_AXIS, LEFT, yb, -ythick);
+
+  m.align_to (X_AXIS, CENTER);
+  
+  return m;
+}
+
+/*
+  Kirchenpause (?)
+  
+ */
+Molecule
+Multi_measure_rest::church_rest (Font_metric *musfont, int measures,
+                                Real staff_space, Real padding)
+{
+  Molecule s;
+ /*
+       Build a rest from smaller parts. Distances inbetween are
+       really variable, see Wanske pp. 125 */
+   
+  int l = measures;
+  while (l)
     {
-      Molecule s = Text_item::text2molecule (me,
-                                            ly_str02scm (to_str (measures).ch_C ()),
-                                            alist_chain);
-      s.align_to (X_AXIS, CENTER);
-      s.translate_axis (3.0 * staff_space, Y_AXIS);
-      mol.add_molecule (s);
+      int k;
+      if (l >= 4)
+       {
+         l-=4;
+         k = -2;
+       }
+      else if (l>= 2)
+       {
+         l -= 2;
+         k = -1;
+       }
+      else
+       {
+         k = 0;
+         l --;
+       }
+
+      Real pad = s.empty_b () ? 0.0 : padding;
+
+      Molecule r (musfont->find_by_name ("rests-" + to_str (k)));
+      if (k == 0)
+       r.translate_axis (staff_space, Y_AXIS);
+         
+      s.add_at_edge (X_AXIS, RIGHT, r, pad);
     }
-  mol.translate_axis (x_off, X_AXIS);
-  return mol.smobbed_copy ();
+
+  s.align_to (X_AXIS, CENTER);
+  return s;
 }
 
 /*
@@ -216,8 +254,6 @@ Multi_measure_rest::brew_molecule (SCM smob)
 void
 Multi_measure_rest::add_column (Grob*me,Item* c)
 {
-  Pointer_group_interface::add_grob (me, ly_symbol2scm ("columns"),c);
-
   add_bound_item (dynamic_cast<Spanner*> (me),c);
 }
 
@@ -255,11 +291,13 @@ Multi_measure_rest::set_spacing_rods (SCM smob)
       rod.item_l_drul_[LEFT] = l;
       rod.item_l_drul_[RIGHT] = r;
 
-       /*
-         should do something more advanced.
-        */
+      /*
+       should do something more advanced.
+      */
+      Molecule m = symbol_molecule(me);
+      
       rod.distance_f_ = l->extent (l, X_AXIS)[BIGGER] - r->extent (r, X_AXIS)[SMALLER]
-       + gh_scm2double (me->get_grob_property ("minimum-width")) * staff_space;
+       + m.extent (X_AXIS).length () + 2.5*staff_space;
   
       rod.add_to_cols ();
     }
@@ -275,4 +313,4 @@ numbers, fields from font-interface may be used.
 padding is the space between number and rest. Measured in staffspace.
 
 ",
-  "columns measure-count expand-limit minimum-width padding");
+  "thickness measure-count expand-limit padding");
index b66b61d77c472d48fd962352fc2801489dd05fca..08b7c057c6176fe8f58e39a1b104d83e0129846a 100644 (file)
@@ -16,6 +16,9 @@
 #include "molecule.hh"
 #include "musical-request.hh"
 #include "rhythmic-head.hh"
+#include "staff-symbol-referencer.hh"
+#include "lookup.hh"
+#include "paper-def.hh"
 
 /*
   Note_head contains the code for printing note heads.
 
 */
 
-#include "staff-symbol-referencer.hh"
-
-/*
-  build a ledger line for small pieces.
- */
-Molecule
-Note_head::ledger_line (Grob *me, Interval xwid) 
-{
-  Drul_array<Molecule> endings;
-  endings[LEFT] = Font_interface::get_default_font (me)->find_by_name ("noteheads-ledgerending");
-  Molecule *e = &endings[LEFT];
-  endings[RIGHT] = *e;
-  
-  Real thick = e->extent (Y_AXIS).length ();
-  Real len = e->extent (X_AXIS).length () - thick;
-
-  Molecule total;
-  Direction d = LEFT;
-  do {
-    endings[d].translate_axis (xwid[d] - endings[d].extent (X_AXIS)[d], X_AXIS);
-    total.add_molecule (endings[d]);    
-  } while ((flip (&d)) != LEFT);
-
-  Real xpos = xwid [LEFT] + len;
-
-  while (xpos + len + thick /2 <= xwid[RIGHT])
-    {
-      e->translate_axis (len, X_AXIS);
-      total.add_molecule (*e);
-      xpos += len;
-    }
-
-  return total;
-}
-
-
 Molecule
-Note_head::ledger_lines (Grob*me,
-                        bool take_space,
-                        int count, Direction dir, Interval idw)
+Note_head::brew_ledger_lines (Grob *me,
+                              int pos,
+                              int interspaces,
+                              Interval x_extent,
+                              bool take_space)
 {
   Real inter_f = Staff_symbol_referencer::staff_space (me)/2;
+  int lines_i = abs (pos) < interspaces
+    ? 0
+    : (abs (pos) - interspaces) / 2;
+  Molecule molecule = Molecule();
 
-  /*
-    idw ?
-
-    (who's that ?  :-)
-
-
-    --hwn 
-   */
-  Molecule ledger (ledger_line (me, idw));
-
-  if (!take_space)
-    ledger.set_empty (true);
-  
-  Real offs = (Staff_symbol_referencer::on_staffline (me))
-    ? 0.0
-    : -dir * inter_f;
-
-  Molecule legs;
-  for (int i=0; i < count; i++)
+  if (lines_i)
     {
-      Molecule s (ledger);
-      s.translate_axis (-dir * inter_f * i*2 + offs,
-                       Y_AXIS);
-      legs.add_molecule (s);
+      Real ledgerlinethickness =
+       (me->paper_l ()->get_var ("ledgerlinethickness"));
+      Real blotdiameter = ledgerlinethickness;
+      //       (me->paper_l ()->get_var ("blotdiameter"));
+      Interval y_extent =
+       Interval (-0.5*(ledgerlinethickness - blotdiameter),
+                 +0.5*(ledgerlinethickness - blotdiameter));
+      Box ledger_line (x_extent, y_extent);
+
+      // FIXME: Currently need blotdiameter factor 2.0 to compensate
+      // for error somewhere else.  (Maybe draw_box confuses radius
+      // and diameter?)
+#if 1
+       Molecule proto_ledger_line =
+         Lookup::roundfilledbox (ledger_line, ledgerlinethickness );
+#else
+      Molecule proto_ledger_line = // if you like it the old way
+       Lookup::filledbox (ledger_line);
+#endif
+      
+      if (!take_space)
+        proto_ledger_line.set_empty (true);
+
+      Direction dir = (Direction)sign (pos);
+      Real offs = (Staff_symbol_referencer::on_staffline (me, pos))
+        ? 0.0
+        : -dir * inter_f;
+      for (int i = 0; i < lines_i; i++)
+        {
+          Molecule ledger_line (proto_ledger_line);
+          ledger_line.translate_axis (-dir * inter_f * i * 2 + offs, Y_AXIS);
+          molecule.add_molecule (ledger_line);
+        }
     }
 
-  return legs;
+  return molecule;
 }
 
 Molecule
 internal_brew_molecule (Grob *me,  bool ledger_take_space)
 {
-  int sz = Staff_symbol_referencer::line_count (me)-1;
-  int p = (int)  rint (Staff_symbol_referencer::position_f (me));
-  int streepjes_i = abs (p) < sz 
-    ? 0
-    : (abs (p) - sz) /2;
-
   SCM style  = me->get_grob_property ("style");
   if (!gh_symbol_p (style))
     {
@@ -153,9 +131,10 @@ internal_brew_molecule (Grob *me,  bool ledger_take_space)
   String name = "noteheads-" + ly_scm2string (scm_primitive_eval (exp));
   Molecule out = Font_interface::get_default_font (me)->find_by_name (name);
 
-  if (streepjes_i) 
+  int interspaces = Staff_symbol_referencer::line_count (me)-1;
+  int pos = (int)rint (Staff_symbol_referencer::position_f (me));
+  if (abs (pos) - interspaces > 1)
     {
-      Direction dir = (Direction)sign (p);
       Interval hd = out.extent (X_AXIS);
       Real left_ledger_protusion = hd.length ()/4;
       Real right_ledger_protusion = left_ledger_protusion;
@@ -175,8 +154,9 @@ internal_brew_molecule (Grob *me,  bool ledger_take_space)
 
       Interval l_extents = Interval (hd[LEFT] - left_ledger_protusion,
                                     hd[RIGHT] + right_ledger_protusion);
-      out.add_molecule (Note_head::ledger_lines (me, ledger_take_space,
-                                                streepjes_i, dir, l_extents));
+      out.add_molecule (Note_head::brew_ledger_lines (me, pos, interspaces,
+                                                     l_extents,
+                                                     ledger_take_space));
     }
   return out;
 }
@@ -237,23 +217,17 @@ Note_head::brew_ez_molecule (SCM smob)
                       SCM_UNDEFINED);
   Box bx (Interval (0, 1.0), Interval (-0.5, 0.5));
   Molecule m (bx, at);
-  int p = (int)  rint (Staff_symbol_referencer::position_f (me));
-
-  int sz = Staff_symbol_referencer::line_count (me)-1;
-  int streepjes_i = abs (p) < sz 
-    ? 0
-    : (abs (p) - sz) /2;
 
- if (streepjes_i)
-   {
-      Direction dir = (Direction)sign (p);
+  int pos = (int)rint (Staff_symbol_referencer::position_f (me));
+  int interspaces = Staff_symbol_referencer::line_count (me)-1;
+  if (abs (pos) - interspaces > 1)
+    {
       Interval hd = m.extent (X_AXIS);
       Real hw = hd.length ()/4;
-      m.add_molecule (ledger_lines (me, false, streepjes_i, dir,
-                                   Interval (hd[LEFT] - hw,
-                                               hd[RIGHT] + hw)));
+      Interval extent = Interval (hd[LEFT] - hw, hd[RIGHT] + hw);
+      m.add_molecule (brew_ledger_lines (me, pos, interspaces, extent, false));
     }
-  
+
   return m.smobbed_copy ();
 }
 
@@ -280,4 +254,3 @@ Note_head::stem_attachment_coordinate (Grob *me, Axis a)
 ADD_INTERFACE (Note_head,"note-head-interface",
   "Note head",
   "accidentals-grob style stem-attachment-function");
-
index d811c380c3665b77eea00481e6deb12d8c905cc8..405a567d17f78dc87581bd0a0e9c0c7d6f765ee5 100644 (file)
@@ -20,6 +20,7 @@
 #include "bezier.hh"
 #include "font-interface.hh"
 #include "paper-def.hh"
+#include "note-head.hh"
 #include "math.h" // rint
 
 void
@@ -82,75 +83,6 @@ Porrectus::get_right_head (Grob *me)
     }
 }
 
-// Uugh.  The following two functions are almost duplicated code from
-// custos.cc, which itself is similar to code in note-head.cc.  Maybe
-// this should be moved to staff-symbol-referencer.cc?
-Molecule
-Porrectus::create_ledger_line (Interval x_extent, Grob *me) 
-{
-  Molecule line;
-  Molecule slice = Font_interface::get_default_font (me)->find_by_name ("noteheads-ledgerending");
-  Interval slice_x_extent = slice.extent (X_AXIS);
-  Interval slice_y_extent = slice.extent (Y_AXIS);
-
-  // Create left ending of ledger line.
-  Molecule left_ending = slice;
-  left_ending.translate_axis (x_extent[LEFT] - slice_x_extent[LEFT], X_AXIS);
-  if (x_extent.length () > slice_x_extent.length ())
-    line.add_molecule (left_ending);
-
-  // Create right ending of ledger line.
-  Molecule right_ending = slice;
-  right_ending.translate_axis (x_extent[RIGHT] - slice_x_extent[RIGHT],
-                              X_AXIS);
-  line.add_molecule (right_ending);
-
-  // Fill out space between left and right ending of ledger line by
-  // lining up a series of slices in a row between them.
-  Molecule fill_out_slice = left_ending;
-  Real thick = slice_y_extent.length ();
-  Real delta_x = slice_x_extent.length () - thick;
-  Real xpos = x_extent [LEFT] + 2*delta_x + thick/2; // TODO: check: thick*2?
-  while (xpos <= x_extent[RIGHT])
-    {
-      fill_out_slice.translate_axis (delta_x, X_AXIS);
-      line.add_molecule (fill_out_slice);
-      xpos += delta_x;
-    }
-
-  return line;
-}
-
-Molecule
-Porrectus::create_streepjes (Grob *me,
-                            int pos,
-                            int interspaces,
-                            Interval extent)
-{
-  Real inter_f = Staff_symbol_referencer::staff_space (me)/2;
-  int streepjes_i = abs (pos) < interspaces
-    ? 0
-    : (abs (pos) - interspaces) /2;
-  Molecule molecule = Molecule();
-  if (streepjes_i) 
-    {
-      Direction dir = (Direction)sign (pos);
-      Molecule ledger_line (create_ledger_line (extent, me));
-      ledger_line.set_empty (true);
-      Real offs = (Staff_symbol_referencer::on_staffline (me, pos))
-       ? 0.0
-       : -dir * inter_f;
-      for (int i = 0; i < streepjes_i; i++)
-       {
-         Molecule streep (ledger_line);
-         streep.translate_axis (-dir * inter_f * i * 2 + offs,
-                                Y_AXIS);
-         molecule.add_molecule (streep);
-       }
-    }
-  return molecule;
-}
-
 MAKE_SCHEME_CALLBACK (Porrectus,brew_molecule,1);
 SCM 
 Porrectus::brew_molecule (SCM smob)
@@ -179,11 +111,9 @@ Porrectus::brew_molecule (SCM smob)
   bool add_stem = to_boolean (me->get_grob_property ("add-stem"));
 
   /*
-
-  TODO:
-
-  ugr. why not  called direction?
-    
+   * This property is called stem-direction (rather than direction)
+   * since it only refers to this grob's stem (or, more precisely, its
+   * "cauda"), but not the grob as a whole.
    */
   SCM stem_direction_scm = me->get_grob_property ("direction");
   Direction stem_direction =
@@ -191,7 +121,6 @@ Porrectus::brew_molecule (SCM smob)
   if (!stem_direction)
     stem_direction = DOWN;
 
-
   /*
     TODO: revise name.
    */
@@ -285,15 +214,25 @@ Porrectus::brew_molecule (SCM smob)
 
   molecule.translate_axis (left_position_f * space/2, Y_AXIS);
 
-  Molecule left_head_streepjes =
-    create_streepjes (me, (int)rint (left_position_f), interspaces, extent);
-  left_head_streepjes.translate_axis (left_position_f * space/2, Y_AXIS);
-  molecule.add_molecule (left_head_streepjes);
+  int left_pos = (int)rint (left_position_f);
+  if (abs (left_pos) - interspaces > 1)
+    {
+      Molecule left_head_ledger_lines =
+       Note_head::brew_ledger_lines (me, left_pos, interspaces, extent, true);
+      left_head_ledger_lines.translate_axis (left_position_f * space/2,
+                                            Y_AXIS);
+      molecule.add_molecule (left_head_ledger_lines);
+    }
 
-  Molecule right_head_streepjes =
-    create_streepjes (me, (int)rint (right_position_f), interspaces, extent);
-  right_head_streepjes.translate_axis (right_position_f * space/2, Y_AXIS);
-  molecule.add_molecule (right_head_streepjes);
+  int right_pos = (int)rint (right_position_f);
+  if (abs (right_pos) - interspaces > 1)
+    {
+      Molecule right_head_ledger_lines =
+       Note_head::brew_ledger_lines (me, right_pos, interspaces, extent, true);
+      right_head_ledger_lines.translate_axis (right_position_f * space/2,
+                                             Y_AXIS);
+      molecule.add_molecule (right_head_ledger_lines);
+    }
 
   return molecule.smobbed_copy();
 }
@@ -496,4 +435,3 @@ Porrectus::brew_mensural_molecule (Item *me,
 ADD_INTERFACE (Porrectus,"porrectus-interface",
   "A porrectus ligature, joining two note heads into a single grob.",
   "left-head right-head width add-stem auto-properties solid direction");
-
index 2e0e9b57f7c4b20ffb1a3a4eb72dac4d37a258a2..dcdea460abac9b9b24c6fa45590d161aa52a6d93 100644 (file)
@@ -50,7 +50,7 @@ void
 Slur::add_column (Grob*me, Grob*n)
 {
   if (!gh_pair_p (n->get_grob_property ("note-heads")))
-    me->warning (_ ("Putting slur over rest.  Ignoring."));
+    me->warning (_ ("Putting slur over rest.  Ignoring rest."));
   else
     {
       Pointer_group_interface::add_grob (me, ly_symbol2scm ("note-columns"), n);
index 7e1b0838834bd0cf95c5f71953442b43ea552a89..abb66fa954cb6a1100bb17a6af73d6c5aa00af9f 100644 (file)
@@ -53,11 +53,9 @@ Staff_symbol_referencer::staff_space (Grob*me)
   if (st)
     return Staff_symbol::staff_space (st);
 
-  
   return 1.0;
 }
 
-
 Real
 Staff_symbol_referencer::position_f (Grob*me) 
 {
index 5fbcbe171ef9cfa4035455a3c234ca7918876cdd..d580a91b2fdb46067f6edea91900004cfc3612fd 100644 (file)
@@ -97,13 +97,6 @@ Voice_devnull_engraver::acknowledge_grob (Grob_info i)
     for (char const **p = junk_interfaces; *p; p++)
       if (i.grob_l_->has_interface (ly_symbol2scm (*p)))
        {
-#if 0
-         /* Ugh: virtual mmrest::suicide () ? */
-         if (i.grob_l_->has_interface (ly_symbol2scm ("multi-measure-rest-interface")))
-           i.grob_l_->set_grob_property ("skip-timestep", SCM_BOOL_T);
-         else
-           ;
-#endif   
          /* Ugh, we can suicide them, but they remain living */
          i.grob_l_->suicide ();
          return;
index a678a121fdbc9586efb06f3d82766cc15ae27151..4b5d20b3812823b4ddbd73887cd071b7d3ba4fe8 100644 (file)
@@ -9,8 +9,8 @@
 ;; Author: 1995-1996 Barry A. Warsaw
 ;;         1992-1994 Tim Peters
 ;; Created:       Feb 1992
-;; Version:       0.0
-;; Last Modified: 14SEP2001
+;; Version:       1.5.47
+;; Last Modified: 26MAR2002
 ;; Keywords: lilypond languages music notation
 
 ;; This software is provided as-is, without express or implied
   (let* ((keywords '( ; need special order due to over[lapping] of words
 
 ;; all letters are lowercase
-"accepts" "accompany" "addlyrics" "aeolian" "alias" "alternative"
-"apply" "arpeggio" "autochange" "bar" "break" "breathe" "breve"
-"beamintervals" "broken" "blend" "bcincipit" "char" "ch" "cg"
-"chord\\(s\\|stest\\|chordmodifiers\\)?"
-"clef \\(bass\\|treble\\|violin\\|tenor\\)?"
-"clipping" "cm" "coda" "complex" "commandspanrequest" "consists\\(end\\)?"
-"context" "contrabasso" "decr" "default" "denies" "different" "dirs"
-"down\\(bow\\|prall\\)?" "dorian" "duration" "dynamicscript"
-"eccentric" "eg" "embeddedps" "endincipit" "elementdescriptions"
-"ex\\(treme\\)?" "fermata" "f+" "font" "flageolet" "fp" "fragment" "fz"
-"gliss\\(ando\\)?" "global" "gg" "gmsus" "grace" "gr\\(and\\)?staff"
-"header" "hsize" "in\\(clude\\|versions\\|visible\\)?" "ionian"
-"key\\(s\\(ignature\\)?\\)?" "lag" "lheel" "line\\(break\\|prall\\)"
-"locrian" "longa" "lower" "ltoe" "lydian" "lyrics"
-"maintainer" "mark" "maxima" "mel\\(isma\\|ody\\)?" "midi" "major"
-"minor" "mixolydian" "mordent" "monstrous" "multipart" "music"
-"musicalpitch" "m\\(p\\|f\\|m\\)?" "name" "newpage" "noise\\(beat\\)?"
+"accent" "accepts" "accompany" "\\(add\\)?lyrics" 
+"\\(aeol\\|dor\\|ion\\|locr\\|\\(mixo\\)?lyd\\|phryg\\)ian" 
+"alias" "\\(altern\\|rel\\)ative" "apply" "arpeggio" "autochange" "bar" "break"
+"breathe" "breve" "beamintervals" "broken" "blend" "\\(bc\\|end\\)incipit" 
+"ch\\(ar\\)?" "cg" "chord\\(s\\|stest\\|chordmodifiers\\)?"
+"clef[ \t]*\\(F\\|G\\|alto\\|baritone\\|bass\\|\\(mezzo\\)?soprano\\|treble\\|violin\\|tenor\\)?"
+"clipping" "cm" "coda" "complex" 
+"\\(command\\)?spanrequest" "consists\\(end\\)?"
+"context" "contrabasso" "\\(de\\)?cr" "default" "denies" "different" "dirs"
+"down\\(bow\\|prall\\)?" "duration" "\\(dynamic\\)?script"
+"eccentric" "eg" "embeddedps" "elementdescriptions"
+"ex\\(treme\\)?" "fermata" "f+" "figures" "font" "flageolet" "fp" "fragment" 
+"fz" "gliss\\(ando\\)?" "gg" "gmsus" "grace" "gr\\(and\\)?staff"
+"header" "\\(h\\|v\\)size" "in\\(clude\\|versions\\|visible\\)?" 
+"key\\(s\\(ignature\\)?\\)?" "lag" "\\(l\\|r\\)heel" "line\\(break\\|prall\\)"
+"longa" "lower" "\\(l\\|r\\)toe"
+"mark" "marcato" "maxima" "mel\\(isma\\|ody\\)?" "midi" "m\\(aj\\|in\\)or"
+"\\(up\\|down\\)?mordent" "monstrous" "multipart" "music"
+"\\(musical\\)?pitch" "m\\(p\\|f\\|m\\)?" "name" "newpage" "noise\\(beat\\)?"
 "normal\\(key\\|size\\)" "note\\(name\\)?s" "nt?"
-"one\\(staff\\)?" "open" "outputproperty" "over\\(ride\\)?"
-"paper" "partcombine" "partial" "penalty" "phrygian" "pitch" "p+"
-"property" "pt" "prall\\(mordent\\|prall\\|up\\)?" "quickmeasure"
-"relative" "remove" "repeat" "rever\\(t\\|seturn\\)" "rf" "rheel" "rhythm"
-"right" "rtoe" "scales?" "scheme" "score" "scpaper" "script" "scscore" "sd"
+"one\\(staff\\)?" "open" "\\(output\\)?property" "over\\(ride\\)?"
+"part\\(combine\\|ial\\)" "penalty" "p+" "pt" 
+"prall\\(down\\|mordent\\|prall\\|up\\)?" "quickmeasure" "rc\\(ed\\)?" "remove"
+"repeat[ \t]*\\(\\(un\\)?fold\\|percent\\|\\|tremolo\\|volta\\)?" "rest"
+"revert" "\\(reverse\\)?turn" "rf\\(z\\)?" "rhythm"
+"right" "scales?" "scheme" "\\(sc\\)?paper" "\\(sc\\)?score" "sd"
 "segno" "sequential" "set\\(tings\\)?" "sf\\(f\\|z\\)?" "shortlong"
-"simultaneous" "singlepart" "skip" "small" "smarttranspose" "spanrequest"
-"staccato" "staff\\(height\\|space\\)" "start" "stop\\(ped\\)?"
+"simultaneous" "singlepart" "skip" "small" "\\(smart\\)?transpose"
+"sp\\(p\\)?" "staccat\\(issim\\)?o" "staff\\(height\\|space\\)" "start" 
+"stop\\(ped\\)?"
 "st\\(paper\\|score\\)" "stuff" "stylesheet" "su" "tab" "tempo" "tenuto" 
 "textscript" "thenotes" "thrd" "threevoice" "thumb" "tilt\\(down\\|up\\)" 
-"timb" "times?" "timpani" "tiny" "toeters" "touch" "trans\\(lator\\|pose\\)
-"trill" "trombe" "turn" "type" "t\\(wo\\(voice\\(steminvert\\)?\\)?\\)?" 
+"timb" "times?" "tiny" "toeters" "touch" "translator
+"trill" "type" "t\\(wo\\(voice\\(steminvert\\)?\\)?\\)?" 
 "un\\(der\\|set\\)" "up\\(bow\\|per\\|prall\\)?" "version" 
-"viol\\(a\\|in\\(incipit\\)?\\|oncello\\)" "visible" "voicedefault" "vsize"
-"x" "zagers?" "z\\(eu\\|o\\)ger"
+"visible" "voicedefault" "x"
 
                      ))
 
   (identifiers '( 
 
 ;; in principle, have one or more uppercase letters
-"\\(\\(BarNumbering\\|Choir\\|Grand\\|HaraKiri\\|OrchestralPart\\|Piano\\|Rhythmic\\)Staff\\|\\(Cue\\|Lyrics\\)?Voice\\|\\(Orchestral\\)?Score\\|ChordNames\\|Grace\\|Lyrics\\|StaffGroup\\|Thread\\)Context" ; *Context
+"\\(\\(BarNumbering\\|Choir\\|Grand\\|HaraKiri\\|OrchestralPart\\|Piano\\|Rhythmic\\)?Staff\\|\\(Cue\\|Lyrics\\)?Voice\\|\\(Orchestral\\)?Score\\|ChordNames\\|Grace\\|Lyrics\\|Staff\\(Group\\)?\\|Thread\\)Context" ; *Context
 "\\(script\\|dots\\|dynamic\\|slur\\|stem\\|sustain\\|sostenuto\\|unaCorda\\|treCorde\\|tie\\|tuplet\\)\\(Both\\|Down\\|Up\\)" ; *(Both/Down/Up)
 "\\(slur\\|tie\\)\\(Dotted\\|Solid\\)" ; *(Dotted/Solid)
 "\\(autoBeam\\|cadenza\\|impro\\|turn\\)\\(Off\\|On\\)" ; *(On/Off)
 "voice\\(One\\|Two\\|Three\\|Four\\|B\\|C\\|D\\|E\\)" ; voice*
 "paper\\(Eleven\\|Sixteen\\|Thirteen\\|TwentySix\\)" ; paper*
 "\\(lower\\|upper\\)\\(Octave\\|One\\)" ; (lower/upper)*
-"hairyChord"
-"\\(Piano\\|Rhythmic\\)\\(Staff\\)?"
+"hairyChord" "\\(Piano\\|Rhythmic\\)\\(Staff\\)?"
 "\\(clarinetti\\|fagotti\\|flauti\\|melodic\\|oboi\\|\\(quite\\|rather\\|somewhat\\)LongLyrics\\|violinoII?\\)?\\(Staff\\)?" ; *Staff
 "\\(archi\\|bassi\\|legni\\|ottoni\\|timpani\\|viole\\|violini\\)\\(Group\\)" ; *Group
 "melisma\\(End\\)?" "staff\\(One\\|Two\\)?" "rests\\(II\\)?" "specialKey"
 "noBreak" "paperTwentysix" "endHorizScript" "FontBody" "text(I)+"
+"\\(modern\\|forget\\)Accidentals" ; *Accidentals
+"noResetKey" "modern\\(Voice\\)?Cautionaries" "unaCorda" "treCorde"
 
                       ))
 
 
 ;; Other words which look nicer when colored
 "Accidentals" "autoBeamSettings" "BarLine" "Beam"
-"ChordName\\([s]?\\|s.[a-zA-Z]*\\)" "Grace\\(.[a-zA-Z]*\\)?"
-"\\(Grand\\|Piano\\)Staff" "Lyrics\\(.[a-zA-Z]*\\)?" "NoteHead" 
-"Score\\(.[a-zA-Z]*\\)" "Stem" "Staff\\(Symbol\\)?" "TextScript" 
-"TimeSignature" "Voice\\(.[a-zA-Z]*\\)?"
+"ChordName\\([s]?\\|s.[a-zA-Z]*\\)" "DynamicText"
+"FiguredBass" "Hairpin" "\\(Grand\\|Piano\\)Staff"
+"Slur" "Stem" "SpacingSpanner" "System\\(StartDelimiter\\)?"
+"\\(Grace\\|Lyrics\\|Note\\(Head\\|Names\\)\\|Score\\|\\(Rhythmic\\)?Staff\\(Symbol\\)?\\|Thread\\|Voice\\)\\(.[a-zA-Z]*\\)?" ; combine below, if possible
+"\\(Grace\\|Lyrics\\|Note\\(Head\\|Names\\)\\|Score\\|\\(Rhythmic\\)?Staff\\(Symbol\\)?\\|Thread\\|Voice\\)[ \t]*\\(.[ \t]*[a-zA-Z]*\\)?" 
+"TextScript" "TimeSignature" "VerticalAlignment"
 
                      ))
 
 ;; font-lock- comment / string / keyword / builtin / function-name / 
 ;;            variable-name / type / constant / warning -face
 
-      '("\\([_^]?\\\\[a-zA-Z][a-zA-Z]*\\)" 1 font-lock-constant-face)
-      '("\\(\\(#'\\)?[a-zA-Z][_a-zA-Z.\-]*[ \t]*=[ \t]*#\\)" 1 font-lock-variable-name-face)
+      '("\\([_^-]?\\\\[a-zA-Z][a-zA-Z]*\\)" 1 font-lock-constant-face)
+      '("\\(\\(#'\\)?[a-zA-Z][_a-zA-Z.\-]*[ \t]*=[ \t]*#\\(#f\\|#t\\)\\)" 1 font-lock-variable-name-face)
       '("\\([a-zA-Z][_a-zA-Z.\-]*\\)[ \t]*=[ \t]*" 1 font-lock-variable-name-face)
       '("[ \t]*=[ \t]*\\([a-zA-Z][_a-zA-Z]*\\)" 1 font-lock-variable-name-face)
 
       (cons (concat "\\(" rwregex "\\)") 'font-lock-variable-name-face)
 
 ;; highlight note names; separate notes from (other than ')'-type) brackets
-      '("[ <\{[~()\t]\\(\\(\\(\\(do\\|re\\|mi\\|fa\\|sol\\|la\\|si\\)\\(bb?\\|dd?\\|ss?\\)?\\)\\|\\([a-hsr]\\(flat\\(flat\\)?\\|sharp\\(sharp\\)?\\|ff?\\|ss?\\|is\\(siss\\|s\\|is\\)?\\|es\\(sess\\|s\\|es\\)?\\)?\\)\\|\\(as\\(as\\|es\\)?\\)\\|\\(es\\(es\\)?\\)\\|\\(bb\\)\\)[,']*\\(64\\|32\\|16\\|8\\|4\\|2\\|1\\)?[.]*\\)" 1 font-lock-type-face)
+      '("[ <\{[~()\t]\\(\\(\\(\\(do\\|re\\|mi\\|fa\\|sol\\|la\\|si\\)\\(bb?\\|dd?\\|ss?\\)?\\)\\|\\([a-hsrR]\\(flat\\(flat\\)?\\|sharp\\(sharp\\)?\\|ff?\\|ss?\\|is\\(siss\\|s\\|is\\)?\\|es\\(sess\\|s\\|es\\)?\\)?\\)\\|\\(as\\(as\\|es\\)?\\)\\|\\(es\\(es\\)?\\)\\|\\(bb\\)\\)[,']*\\(128\\|64\\|32\\|16\\|8\\|4\\|2\\|1\\)?[.]*\\)" 1 font-lock-type-face)
 
 ;; highlight identifiers
-      (cons (concat "\\([_^]?\\(" iregex "\\)\\)+\\($\\|[] \t(~{}>\\\\]\\)") '(0 font-lock-function-name-face t))
+      (cons (concat "\\([_^-]?\\(" iregex "\\)\\)+\\($\\|[] \t(~{}>\\\\]\\)") '(0 font-lock-function-name-face t))
 
 ;; highlight keywords
-      (cons (concat "\\([_^]?\\(" kwregex "\\)\\)+\\($\\|[] \t(~{}>\\\\]\\)") '(0 font-lock-keyword-face t))
+      (cons (concat "\\([_^-]?\\(" kwregex "\\)\\)+\\($\\|[] \t(~{}>\\\\]\\)") '(0 font-lock-keyword-face t))
 
 ;; highlight bracketing constructs
       '("\\([][}{]\\)" 0 font-lock-warning-face t)
index c03ea803d421a182205bca33853e8acc3dadd68b..858e4d005793ad48ec5c9e0e864d03bf4f662f53 100644 (file)
@@ -10,7 +10,6 @@ startGraceMusic = {
         #(map (lambda (x) (* 0.8 x)) '(0.0 1.5 1.25 1.0))
     \property Voice.Stem \override #'no-stem-extend = ##t
     \property Voice.Stem \override #'flag-style  = #"grace"
-
     \property Voice.Beam \override #'thickness = #0.384
     
     % Can't use Staff.fontSize, since time sigs, keys sigs, etc. will
@@ -18,9 +17,11 @@ startGraceMusic = {
 
     \property Voice.fontSize = #-2
     \property Staff.Accidentals \override #'font-relative-size = #-2
+    \property Voice.Slur \override #'direction = #-1
 }
 
 stopGraceMusic = {
+    \property Voice.Slur \revert #'direction
     \property Staff.Accidentals \revert #'font-relative-size
     \property Voice.Beam \revert #'thickness
 
index 29dd3cd10d3050076906d1469c21885d57e9d40d..69c2ea699e5ef2297c5b8475856e09a24b9d9daf 100644 (file)
@@ -22,6 +22,9 @@ unit = "mm"
 staffspace = \staffheight / 4.0
 stafflinethickness = \staffspace / 10.0
 outputscale = \staffheight / 4.0
+ledgerlinethickness = 2.0 * \stafflinethickness
+
+
 
 % blotdiameter = 0.4 \pt
 blotdiameter = 0.04 \pt
index 3fdf1b7b31029418cd342e23185742ba26ac361c..d2f5457236ac48b2996248c01f722a2609b9a7d8 100644 (file)
@@ -7,7 +7,7 @@ rced = \spanrequest \stop "decrescendo"
 
 cresc = \notes {
   \commandspanrequest \start "crescendo" 
-  \property Voice.crescendoText = #"cresc."
+  \property Voice.crescendoText = #'((font-shape . italic) "cresc.")
   \property Voice.crescendoSpanner = #'dashed-line
 }
 
index 86b88a954dbe42f0301d425cd3800ca81b5ffebf..1ff31de79dfd0de210153936bcb39c083e2612a2 100644 (file)
@@ -1,15 +1,15 @@
 Begin3
 Title: LilyPond
-Version: 1.5.47
-Entered-date: 24MRT02
+Version: 1.5.48
+Entered-date: 27MRT02
 Description: @BLURB@
 Keywords: music notation typesetting midi fonts engraving
 Author: hanwen@cs.uu.nl (Han-Wen Nienhuys)
        janneke@gnu.org (Jan Nieuwenhuizen)
 Maintained-by: hanwen@stack.nl (Han-Wen Nienhuys)
 Primary-site: sunsite.unc.edu /pub/Linux/apps/sound/convert
-       1000k lilypond-1.5.47.tar.gz 
+       1000k lilypond-1.5.48.tar.gz 
 Original-site: ftp.cs.uu.nl /pub/GNU/LilyPond/development/
-       1000k lilypond-1.5.47.tar.gz 
+       1000k lilypond-1.5.48.tar.gz 
 Copying-policy: GPL
 End
index 74d6cdf91601a854a5e956d1132fee1213eb5a5c..10b3c82b45fa636185c0a61116f79a592f6eb9d8 100644 (file)
@@ -1,5 +1,5 @@
 %define name lilypond
-%define version 1.5.47
+%define version 1.5.48
 %define release 1mdk
 
 Name: %{name}
index 67e41d113e72f446f23396369b49706be9ac56bf..f17159888ba17ca230784dce7bbd3252602704fc 100644 (file)
@@ -3,11 +3,11 @@
 %define info yes
 
 Name: lilypond
-Version: 1.5.47
+Version: 1.5.48
 Release: 1
 License: GPL
 Group: Applications/Publishing
-Source0: ftp.cs.uu.nl:/pub/GNU/LilyPond/development/lilypond-1.5.47.tar.gz
+Source0: ftp.cs.uu.nl:/pub/GNU/LilyPond/development/lilypond-1.5.48.tar.gz
 Summary: Create and print music notation 
 URL: http://www.lilypond.org/
 BuildRoot: /tmp/lilypond-install
index b170b23015fa1d9a1952acb0a988d926400e552c..7335263cd935035d36e67ef9f7ff04a034d918f9 100644 (file)
 
 Distribution: SuSE Linux 7.0 (i386)
 Name: lilypond
-Version: 1.5.47
+Version: 1.5.48
 Release: 2
 Copyright:    GPL
 Group: Applications/Publishing
-Source0: ftp.cs.uu.nl:/pub/GNU/LilyPond/development/lilypond-1.5.47.tar.gz
+Source0: ftp.cs.uu.nl:/pub/GNU/LilyPond/development/lilypond-1.5.48.tar.gz
 # music notation software for.. ?
 Summary: A program for printing sheet music.
 URL: http://www.lilypond.org/
index 5192fe3a7f4d9efa261b46bf4401c89e41a871cb..2a3bb4fa776c89df7064299bcdd155e59282ee5c 100644 (file)
@@ -92,8 +92,6 @@ save breve_rest_y, breve_rest_x;
 
 breve_rest_y# =  staff_space#;
 breve_rest_x# = 3/5 staff_space#;
-multi_rest_x# = 4 staff_space#;
-multi_beam_height# = 1/3 staff_space#;
 
 define_pixels(breve_rest_y, breve_rest_x, multi_rest_x, multi_beam_height);
 
@@ -109,17 +107,6 @@ fet_endchar;
 
 tracingvariables := 1;
 
-fet_beginchar("multi rest", "-4", "multirest");
-       set_char_box(multi_rest_x#, multi_rest_x#,
-                    breve_rest_y#, breve_rest_y#);
-       draw_block ((- b, - multi_beam_height),
-                  (w, multi_beam_height));
-       draw_block ((- b,-breve_rest_y),
-                  (rthin - b, breve_rest_y));
-       draw_block ((w - rthin,-breve_rest_y),
-                  (w, breve_rest_y));
-fet_endchar;
-
 fet_beginchar("Quarter rest","2","quartrest");
 %      draw_staff (-2, 2, 0.0);        
        save alpha, yshift, height;
index 25255e3f2886171b41417498a05da2e240822ed0..dc8f8f1d2075ad427b8d2c0a4879b971b414bc25 100644 (file)
                (if (<= dy 1) "-" "="))
          (func "h-line" dx))))))
 
+(define (roundfilledbox breapth width depth height)
+  (filledbox breapth width depth height))
+
 (define (font-load-command name-mag command)
   ;; (display "name-mag: ")
   ;; (write name-mag)
index f28a50c4bc4f17ff9e7ae6efd9fbcb2ee80c51ad..d35e4ac032e8f6a3a9f40b9a4ee28ff1bb707815 100644 (file)
        (Y-offset-callbacks . (,Staff_symbol_referencer::callback))
        (staff-position . 0)
        (expand-limit . 10)
-       (padding . 2.0) ; staffspace
-       (minimum-width . 12.5) ; staffspace
+       (width . 5.5)
+       (thickness . 6.6)
+       (padding . 1.5) ; staffspace
        (font-family . number)
        (font-relative-size . 1)
        (meta . ((interfaces . (multi-measure-rest-interface rest-interface font-interface staff-symbol-referencer-interface))))
index 5f022652c79213d763753105bb091db1e327af27..a47e67f4f88d4a70ff21e93e9a0ba9a1f1446f93 100644 (file)
                   (ly-number->string (+ depth height))
                   " re f "))
 
+;; TODO:
+;;
+;;(define (dot x y diam)
+;;  (let (radius (/ diam 2))
+;;    (string-append (ly-number->string (x))
+;;                  (ly-number->string (y))
+;;                  (ly-number->string (radius))
+;;                  " ??? "))) ;; how to draw a circle in PDF?
+;;
+;;(define (roundfilledbox x width y height blotdiam)
+;;  (string-append " "
+;;    (dot x y blotdiam)
+;;    (dot (+ x width) y blotdiam)
+;;    (dot (+ x width) (+ y height) blotdiam)
+;;    (dot x (+ y height) blotdiam)
+;;    (filledbox (+ x (/ blotdiam 2)) (+ width (/ blotdiam 2)) y height)
+;;    (filledbox x width (+ y (/ blotdiam 2)) (+ height (/ blotdiam 2)))))
+;;
+;;
+;; WORKAROUND:
+;;
+  (define (roundfilledbox breadth width depth height) 
+    (filledbox breadth width depth height))
+;;
+
   (define (font-def i s) "")
 
   (define (font-switch i) "")
            (define end-output ,end-output)
            (define experimental-on ,experimental-on)
            (define filledbox ,filledbox)
+           (define roundfilledbox ,roundfilledbox)
            (define font-def ,font-def)
            (define font-switch ,font-switch)
            (define header-end ,header-end)
        ((eq? action-name 'experimental-on) experimental-on)
        ((eq? action-name 'ez-ball) ez-ball)    
        ((eq? action-name 'filledbox) filledbox)
+       ((eq? action-name 'roundfilledbox) roundfilledbox)
        ((eq? action-name 'repeat-slash) repeat-slash)
        ((eq? action-name 'select-font) select-font)
        ((eq? action-name 'volta) volta)
index 6fccc24420a24fd98a4083a19c5a9a6e5df3f7a1..a40e208669ece44734e8ae389dbe1eaa714ceb93 100644 (file)
      "depth " (number->dim depth)
      "height " (number->dim height) " "))
 
+  (define (roundfilledbox x width y height blotdiam)
+    (embedded-pdf ((pdf-scm 'roundfilledbox) x width y height blotdiam)))
+
   (define (text s)
     (string-append "\\hbox{" (output-tex-string s) "}"))
   
index dbc58a79c29611015a3c1bdb4fcb15f0a2448a35..75cf347d89fa1cd3e89c7098e761c72f619b1b39 100644 (file)
   (string-append (numbers->string (list breapth width depth height))
                 " draw_box" ))
 
+(define (dot x y radius)
+    (string-append " "
+     (numbers->string
+      (list x y radius)) " draw_dot"))
+
+(define (roundfilledbox x width y height blotdiam)
+   (string-append " "
+      (dot (- 0 x) (- 0 y) (/ blotdiam 2))
+      (dot width (- 0 y) (/ blotdiam 2))
+      (dot width height (/ blotdiam 2))
+      (dot (- 0 x) height (/ blotdiam 2))
+      (filledbox (+ x (/ blotdiam 2)) (+ width (/ blotdiam 2)) y height)
+      (filledbox x width (+ y (/ blotdiam 2)) (+ height (/ blotdiam 2)))))
+
 ;; obsolete?
 (define (font-def i s)
   (string-append
 
                                        ; TODO: use HEIGHT argument
 
-  
-(define (start-line height)
+  (define (start-line height)
   (string-append
    "\n"
    (ly-number->string height)
index 2769db1cd20a963e6129039d021e713b2c794c2f..9f0e65d857b11a3a8448d0005241dd4ca3c0bba1 100644 (file)
        "depth " (number->dim depth)
        "height " (number->dim height) " ")))
 
+(define (roundfilledbox x y width height blotdiam)
+  (embedded-ps (list 'roundfilledbox  x y width height blotdiam)))
+
 (define (text s)
   (string-append "\\hbox{" (output-tex-string s) "}"))
 
index 3ad96eaec792fda234c262db08cce2a80ea974be..1b16819e35d496ab7569b4c92fac4ca3bdf6d681 100644 (file)
 \def\leftalign#1{\hbox to 0pt{#1\hss}}
 
 % Attempt to keep lilypiecetitle together with the piece:
-\def\myfilbreak{\par\vfil\penalty200\vfilneg}
+
+%
+% TODO: figure this out.
+%
+
+\def\myfilbreak{} %\par\vfil\penalty200\vfilneg}
 
 
 \ifundefined{lilypondpaperinterscorelinefill}