[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: \fromproperty return problem.
From: |
Nicolas Sceaux |
Subject: |
Re: \fromproperty return problem. |
Date: |
Thu, 21 Feb 2008 21:08:58 +0100 |
Le 21 févr. 08 à 14:57, Gilles THIBAULT a écrit :
I just try the version "2.11.40" and his new markup command :
\underline.
I am very happy with it but i have a problem using it with the
\fromproperty
command.
In the score above, there is no title defined in the score header
but you can see a line above
the note :
{ c'1^\markup { \underline \fromproperty #'header:title } }
It seems that \fromproperty doesn't return an empty stencil, even if
the property given in the argument is empty.
It becomes a problem in a book with several scores, if you defines
a scoreTitleMarkup for example in a way like that
\paper {
scoreTitleMarkup = \markup {
printallheaders=##t
................
....\underline \fromproperty #'header:subsubtitle
................
}
}
}
because if a score has no subsubtitle, you'll get a (under)line !
Is there a workaround for that ?
I use a \when-property markup command to handle that:
#(define-markup-command (when-property layout props symbol markp)
(symbol? markup?)
(if (chain-assoc-get symbol props)
(interpret-markup layout props markp)
(ly:make-stencil '() '(1 . -1) '(1 . -1))))
\when-property #'header:title \underline \fromproperty #'header:title