]> git.donarmstrong.com Git - lilypond.git/commitdiff
* lily/lexer.ll: add empty markup signature.
authorhanwen <hanwen>
Fri, 16 Jan 2004 14:35:38 +0000 (14:35 +0000)
committerhanwen <hanwen>
Fri, 16 Jan 2004 14:35:38 +0000 (14:35 +0000)
* scm/new-markup.scm (markup-functions-and-signatures): reinstate
strut markup

* lily/parser.yy (markup): MARKUP_HEAD_EMPTY

* scm/define-translator-properties.scm: update melismata property
doco.

ChangeLog
input/regression/ottava-broken.ly
lily/lexer.ll
lily/parser.yy
scm/define-grobs.scm
scm/define-translator-properties.scm
scm/new-markup.scm

index a4aa798f51a441e505c29d813a70e351c4a429d6..a37fe0ef303d67736a127521381b4b0f588e8423 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,15 @@
 2004-01-16  Han-Wen Nienhuys   <hanwen@xs4all.nl>
 
+       * lily/lexer.ll: add empty markup signature. 
+
+       * scm/new-markup.scm (markup-functions-and-signatures): reinstate
+       strut markup
+
+       * lily/parser.yy (markup): MARKUP_HEAD_EMPTY
+
+       * scm/define-translator-properties.scm: update melismata property
+       doco.
+
        * lily/system.cc (output_lines): revert uniquify_list() patch,
        strange side effects seen.
        
index 7ce44e8ef16ddfd49223d0dbbeaa4b5e0fc0c3a5..1b6b12afe56554cec15b7a024aae3a08a7e877dd 100644 (file)
@@ -16,9 +16,10 @@ line, and the horizontal line doesn't stick out."
   \notes\relative c''' \notes {
   a2 b
   #(set-octavation 1)
-  a2 b \break c a
+  a2 b \break c''1 \break
+  a
   #(set-octavation 0)
-  a b c a 
+  g,,2 b c a 
 }
 }
 
index cd6d8403290266b695550e1e76e6f0142b24b48b..e419aaaeed08648f14fbdc1dee7f6f25b954d89f 100644 (file)
@@ -484,6 +484,8 @@ HYPHEN              --
                        SCM tag = gh_cdr(s);
                        if (tag == ly_symbol2scm("markup0"))
                                return MARKUP_HEAD_MARKUP0;
+                       if (tag == ly_symbol2scm("empty"))
+                               return MARKUP_HEAD_EMPTY;
                        else if (tag == ly_symbol2scm ("markup0-markup1"))
                                return MARKUP_HEAD_MARKUP0_MARKUP1;
                        else if (tag == ly_symbol2scm ("markup-list0"))
index 077578e4b3b607aed92063c15fa4be00967d7f89..86a1dbf40be75fd56b8f55fea4268a828cfbac5d 100644 (file)
@@ -344,6 +344,7 @@ yylex (YYSTYPE *s,  void * v)
 
 %token MARKUP
 %token <scm> MARKUP_HEAD_MARKUP0
+%token <scm> MARKUP_HEAD_EMPTY
 %token <scm> MARKUP_HEAD_MARKUP0_MARKUP1
 %token <scm> MARKUP_HEAD_SCM0
 %token <scm> MARKUP_HEAD_SCM0_MARKUP1
@@ -2222,6 +2223,9 @@ markup:
        STRING {
                $$ = make_simple_markup ($1);
        }
+       | MARKUP_HEAD_EMPTY {
+               $$ = scm_list_n ($1, SCM_UNDEFINED);
+       }
        | MARKUP_HEAD_MARKUP0 markup {
                $$ = scm_list_n ($1, $2, SCM_UNDEFINED);
        }
index 2055fcbaec0c6fac0e13559afff03ae5f5c7fe1e..cf45e539146d5409a85a228b59b2738caecf0f44 100644 (file)
        (text-repeat-if-broken . #t)
        (shorten-pair . (0.0 . -0.6))
        (staff-padding . 1.0)
+       (padding  . 1.0)
        (enclose-bounds . #t)
        (width-correct . 0.0)
        (style . dashed-line)
index 852be930a2596dee77d51ba0e90f5c0f70350363..1f46f5df736298e59d65234e9051c42244de9dc6 100644 (file)
@@ -116,7 +116,7 @@ true then reset measurePosition when finding a barcheck. Turn off when
 using barchecks in polyphonic music.")
 (translator-property-description 'barNumberVisibility procedure? "Procedure that takes an int and returns whether the corresponding bar number should be printed")
 (translator-property-description 'bassFigureFormatFunction procedure? "DOCME")
-(translator-property-description 'beamMelismaBusy boolean? "Signal if a beam is set when automaticMelismata is set")
+(translator-property-description 'beamMelismaBusy boolean? "Signal if a beam is present.")
 (translator-property-description 'beatLength ly:moment? "The length of one beat in this time signature.")
 (translator-property-description 'beatGrouping list?
                                 "List of beatgroups. Eg. in 5/8 time #(list 2 3).")
@@ -315,8 +315,14 @@ the start of the music.
 whether a melisma is active. This can be used to signal melismas on
 top of those automatically detected. ")
 (translator-property-description 'melismaBusyProperties list?
-                                "List of  properties (symbols) to
-determine whether a melisma  is playing.")
+                                "List of properties (symbols) to
+determine whether a melisma is playing.  Setting this property will
+influence how lyrics are aligned to notes.  For example, if set to
+@code{#'(melismaBusy beamMelismaBusy)}, only manual melismata
+(i.e. setting @code{melismaBusy} to @code{#t}) and manual beams are
+considered. Possible values include @code{melismaBusy},
+@code{slurMelismaBusy}, @code{tieMelismaBusy}, and
+@code{beamMelismaBusy}")
 
 
 (translator-property-description 'metronomeMarkFormatter procedure?
@@ -390,7 +396,7 @@ r1 r1*3 R1*3  \\\\property Score.skipBars= ##t r1*3 R1*3
                                 "When true, all no typesetting is done at
 this moment, causing  the interpretation phase to go a lot faster. This can
 help with debugging large scores.")
-(translator-property-description 'slurMelismaBusy boolean? "Signal a slur if automaticMelismata is set.")
+(translator-property-description 'slurMelismaBusy boolean? "Signal if a slur is present.")
 (translator-property-description 'solo boolean? "set if solo is detected by the part combiner.")
 (translator-property-description 'soloADue boolean? "set Solo/A due texts in the part combiner?.")
 (translator-property-description 'soloIIText string? "text for begin of solo for voice ``two'' when part-combining.")
@@ -419,9 +425,11 @@ positions - by only drawing one beam over the beat.")
                                 "Function formatting a tab notehead; it takes
 a string number, a list of string tunings and Pitch object. It returns the text as a string.")
 
-(translator-property-description 'tieMelismaBusy boolean? "Signal ties when automaticMelismata is set.")
-(translator-property-description 'timeSignatureFraction number-pair? "
-pair of numbers,  signifying the time signature. For example #'(4 . 4) is a 4/4time signature.")
+(translator-property-description 'tieMelismaBusy boolean? "Signal whether a tie is present.")
+(translator-property-description 'timeSignatureFraction number-pair?
+"pair of numbers, signifying the time signature. For example #'(4 . 4)
+is a 4/4 time signature.")
+
 (translator-property-description 'timing boolean? " Keep administration of measure length, position, bar number, etc?
 Switch off for cadenzas.")
 (translator-property-description 'tonic ly:pitch?
index 3c2c55b4a8b5b730d905838338b9d9172fbf8dfa..ff0dce12537964c19438c6854c4d92e9d1ee48e4 100644 (file)
@@ -452,7 +452,6 @@ any sort of property supported by @ref{font-interface} and
   ))
 
 
-;; TODO: fix this .
 (define-public (strut-markup paper props . rest)
   "Syntax: \\strut
 
@@ -462,7 +461,7 @@ any sort of property supported by @ref{font-interface} and
   (let*
       ((m (Text_item::interpret_markup paper props " ")))
 
-    (ly:molecule-set-extent! m 0 '(1000 . -1000))
+    (ly:molecule-set-extent! m X '(1000 . -1000))
     m))
 
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
@@ -470,43 +469,40 @@ any sort of property supported by @ref{font-interface} and
 
 (define (markup-signature-to-keyword sig)
   " (A B C) -> a0-b1-c2 "
-  
-  (let* ((count  0))
-    (string->symbol (string-join
-     
-     (map
-     (lambda (func)
-       (set! count (+ count 1))
-       (string-append
-
-       ;; for reasons I don't get,
-       ;; (case func ((markup?) .. )
-       ;; doesn't work.
-       (cond 
-         ((eq? func markup?) "markup")
-         ((eq? func markup-list?) "markup-list")
-         (else "scheme")
-         )
-       (number->string (- count 1))
-       ))
-     
-     sig)
-     "-"))
-
-  ))
+  (if (equal? sig '())
+      'empty
+      (let* ((count  0))
+       (string->symbol (string-join
+                        
+                        (map
+                         (lambda (func)
+                           (set! count (+ count 1))
+                           (string-append
+
+                            ;; for reasons I don't get,
+                            ;; (case func ((markup?) .. )
+                            ;; doesn't work.
+                            (cond 
+                             ((eq? func markup?) "markup")
+                             ((eq? func markup-list?) "markup-list")
+                             (else "scheme")
+                             )
+                            (number->string (- count 1))
+                            ))
+                         
+                         sig)
+                        "-"))
 
+       )))
 
 (define (markup-function? x)
-  (object-property x 'markup-signature)
-  )
+  (object-property x 'markup-signature) )
 
 (define (markup-list? arg)
   (define (markup-list-inner? l)
     (if (null? l)
        #t
-       (and (markup? (car l)) (markup-list-inner? (cdr l)))
-    )
-  )
+       (and (markup? (car l)) (markup-list-inner? (cdr l))) ) )
   (and (list? arg) (markup-list-inner? arg)))
 
 (define (markup-argument-list? signature arguments)
@@ -637,6 +633,7 @@ any sort of property supported by @ref{font-interface} and
    (cons fontsize-markup (list number? markup?))
 
    (cons box-markup  (list markup?))
+   (cons strut-markup '())
    ))