10.04.2013 Views

in Snippets - LilyPond

in Snippets - LilyPond

in Snippets - LilyPond

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Rhythms 60<br />

(cha<strong>in</strong>-assoc-get 'box-padd<strong>in</strong>g props 0.2)))<br />

(m (<strong>in</strong>terpret-markup layout props arg)))<br />

(NWS-box-stencil m th pad)))<br />

% Test it:<br />

\relative c' {<br />

c1^\markup { \NWS-box ABCD }<br />

c1^\markup { \NWS-box \note #"4" #1.0 }<br />

}<br />

<br />

ABCD<br />

<br />

<br />

Time signature pr<strong>in</strong>t<strong>in</strong>g only the numerator as a number<br />

(<strong>in</strong>stead of the fraction)<br />

Sometimes, a time signature should not pr<strong>in</strong>t the whole fraction (e.g. 7/4), but only the numerator<br />

(7 <strong>in</strong> this case). This can be easily done by us<strong>in</strong>g \override Staff.TimeSignature #'style<br />

= #'s<strong>in</strong>gle-digit to change the style permanently. By us<strong>in</strong>g \revert Staff.TimeSignature<br />

#'style, this sett<strong>in</strong>g can be reversed. To apply the s<strong>in</strong>gle-digit style to only one time signature,<br />

use the \override command and prefix it with a \once.<br />

\relative c'' {<br />

\time 3/4<br />

c4 c c<br />

% Change the style permanently<br />

\override Staff.TimeSignature #'style = #'s<strong>in</strong>gle-digit<br />

\time 2/4<br />

c4 c<br />

\time 3/4<br />

c4 c c<br />

% Revert to default style:<br />

\revert Staff.TimeSignature #'style<br />

\time 2/4<br />

c4 c<br />

% s<strong>in</strong>gle-digit style only for the next time signature<br />

\once \override Staff.TimeSignature #'style = #'s<strong>in</strong>gle-digit<br />

\time 5/4<br />

c4 c c c c<br />

\time 2/4<br />

c4 c<br />

}<br />

5 <br />

4 2 2<br />

<br />

4 2<br />

<br />

4 3 3 <br />

Tweak<strong>in</strong>g grace layout with<strong>in</strong> music<br />

The layout of grace expressions can be changed throughout the music us<strong>in</strong>g the functions<br />

add-grace-property and remove-grace-property. The follow<strong>in</strong>g example undef<strong>in</strong>es the Stem

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!