I'm LilyPonding a piece which requires a "Notation Key". The recipient
of this notation key will be doing a bit of further manipulation of the
output. What I need to provide is, at her preference, a PNG closely
cropped so that she can then position this graphic under some
introductory text about the piece. I have been unsuccessful at finding
information about this in the docs. I've checked the command-line
options section and elsewhere but have not found any reference to
controlling the cropping.
The notation key follows at the end here if anyone wants to see how I've
done this. I'm not 100% pleased with the spacing but haven't yet tried
to adjust it yet. Suggestions for cropping the output are mostly what
I'm after, but suggestions for a better way to make the notation key are
also welcome.
A couple of ideas that I haven't yet explored involve trying
lilypond-book or OpenOffice with LilyPondTool.
-David
%%%%% BEGIN LILYPOND CODE %%%%%
\version "2.11.56"
grad = {
\override Glissando #'bound-details #'right #'arrow = ##t
\override Glissando #'arrow-length = #1
\override Glissando #'arrow-width = #0.25
}
darg = {
\revert Glissando #'bound-details
\revert Glissando #'arrow-length
\revert Glissando #'arrow-width
}
mask = {
\hideNotes
\override Staff.BarLine #'transparent = ##t
\override Staff.TimeSignature #'transparent = ##t
\override Staff.Clef #'transparent = ##t
\override Staff.StaffSymbol #'transparent = ##t
}
wa = \relative c'' {
\mask
c^"wa"
\once\override Staff.TextScript #'extra-offset = #'(0 . -0.75)
s4^\markup{"quick close to open, creating 'wa' sound"}
}
closed = \relative c'' {
\mask
c^"+"
s4^\markup{"closed position"}
}
opened = \relative c'' {
\mask
c^\markup{\musicglyph #"scripts.open"}
s4^\markup{"open position"}
}
openClose = \relative c'' {
\mask
\grad
\override Staff.Glissando #'extra-offset = #'(0 . 2.25)
c^\markup{ \musicglyph #"scripts.open" } \glissando c^+
\once\override Staff.TextScript #'extra-offset = #'(0 . -1)
s4^\markup{"gradually move from open to closed"}
}
closeOpen = \relative c'' {
\mask
\grad
\override Staff.Glissando #'extra-offset = #'(0 . 2.25)
c^+ \glissando c^\markup{ \musicglyph #"scripts.open" }
\once\override Staff.TextScript #'extra-offset = #'(0 . -1)
s4^\markup{"gradually move from closed to open"}
}
ww = \relative c'' {
\mask
\unHideNotes
c8(^"wa" c8^"wa" c8^"wa" c8^"wa")
\once\override Staff.TextScript #'extra-offset = #'(0 . -2)
s4^\markup{"'wa' legato, no tongue when on same pitch"}
}
sung = \relative c'' {
\mask
\unHideNotes
\override Staff.Stem #'transparent = ##t
\override Voice.NoteHead #'style = #'harmonic-mixed
\override Staff.TextScript #'extra-offset = #'(0 . -2.5)
c4 s4^"sung note"
}
aw = \relative c''{
\mask
c4^\markup{\musicglyph #"scripts.open" \musicglyph #"scripts.stopped"}
\once\override Staff.TextScript #'extra-offset = #'(0 . -1)
s4^\markup{"Very quick open-close effect ('bell tones')"}
}
mmm = \relative c'' {
\mask
\override TrillSpanner #'bound-details #'left #'text = " "
s4 \startTrillSpan s s s4 \stopTrillSpan
\once\override Staff.TextScript #'extra-offset = #'(0 . -1)
s4^\markup{ "'wa' vibrato on long, held-out note"}
}
\score {
\wa
\layout {
\context {
\Score
\override SpacingSpanner
#'base-shortest-duration = #(ly:make-moment 1 32)
}
}
}
\score {
\closed
\layout {
\context {
\Score
\override SpacingSpanner
#'base-shortest-duration = #(ly:make-moment 1 32)
}
}
}
\score {
\opened
\layout {
\context {
\Score
\override SpacingSpanner
#'base-shortest-duration = #(ly:make-moment 1 32)
}
}
}
\score {
\closeOpen
\layout {
\context {
\Score
\override SpacingSpanner
#'base-shortest-duration = #(ly:make-moment 1 32)
}
}
}
\score {
\openClose
\layout {
\context {
\Score
\override SpacingSpanner
#'base-shortest-duration = #(ly:make-moment 1 32)
}
}
}
\score {
\ww
\layout {
%
\context {
\Score
\override SpacingSpanner
#'base-shortest-duration = #(ly:make-moment 1 16)
}
%}
}
}
\score {
\sung
\layout {
\context {
\Score
\override SpacingSpanner
#'base-shortest-duration = #(ly:make-moment 1 32)
}
}
}
\score {
\aw
\layout {
\context {
\Score
\override SpacingSpanner
#'base-shortest-duration = #(ly:make-moment 1 32)
}
}
}
\score {
\mmm
\layout {
\context {
\Score
\override SpacingSpanner
#'base-shortest-duration = #(ly:make-moment 1 32)
}
}
}
\header {
title = "Notation Key"
}
\paper {
between-system-space = 0.5\cm
between-system-padding = #0.1
%ragged-bottom=##f
%ragged-last-bottom=##f
}
%%%%% END LILYPOND CODE %%%%%
_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user