[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Centered Paragraphs
From: |
Jay Anderson |
Subject: |
Centered Paragraphs |
Date: |
Tue, 10 Jun 2014 20:00:31 -0700 |
My main goal is to have some simple indented paragraphs which don't
take the full width and are centered horizontally. With a syntax
something like this:
\markuplist
{
\paragraph
{
Some text
}
\vspace #0.6
\paragraph
{
Some more text
}
}
Any idea how to cause the paragraph command (from here:
http://www.lilypond.org/doc/v2.18/Documentation/extending/new-markup-list-command-definition)
to center the paragraph?
I can make it more narrow:
#(define-markup-list-command (paragraph layout props args) (markup-list?)
#:properties ((par-indent 2))
(interpret-markup-list layout props
#{
\markuplist \override-lines #'(line-width . 80)
\justified-lines
{
\hspace #par-indent #args
}
#}))
But this keeps the text on the left edge of the page. All of my
attempts have failed. The mismatch between markuplist and markup
commands is my biggest difficulty.
I tried switching to a markup command:
#(define-markup-command (paragraph layout props args) (markup?)
#:properties ((par-indent 2))
(interpret-markup layout props
#{
\markup
\fill-line
{
\override #'(line-width . 80)
\justify { \hspace #par-indent #args }
}
#}))
But this resulted in each word being on its own line.
Thanks for the help.
-----Jay
- Centered Paragraphs,
Jay Anderson <=