Am Montag, 19. Mai 2008 schrieb Nicolas Sceaux:
> Le 19 mai 08 à 18:05, Reinhold Kainhofer a écrit :
> > The problem with that approach is that it will really leave no space
> > between
> > subsequent markups, so there will not be any pixel space between the
> > headline / title and between each of the columns...
> > Instead, there will be several lines of space at the bottom of the
> > page :-(
>
> You need to use a command that adds space around the
> subsequent lines of text, such as \column-lines.
>
> \markuplines \column-lines {
>    \line { titi }
>    \line { toto }
>    \line { tutu }
> }

Unfortunately, my problems remain, because this does not work after a line 
with multiple columns, as the attached file shows. Plus, before the columns 
there is way too much space...
Or am I doing something wrong in the code?

Cheers,
Reinhold

-- 
------------------------------------------------------------------
Reinhold Kainhofer, Vienna University of Technology, Austria
email: [EMAIL PROTECTED], http://reinhold.kainhofer.com/
 * Financial and Actuarial Mathematics, TU Wien, http://www.fam.tuwien.ac.at/
 * K Desktop Environment, http://www.kde.org, KOrganizer maintainer
 * Chorvereinigung "Jung-Wien", http://www.jung-wien.at/
\version "2.11.46"

%%%% Distribute line width evenly to all columns:
%%%% Solution by Nicolas Sceaux
#(define-markup-command (columns layout props args) (markup-list?)
   (let ((line-width (/ (chain-assoc-get 'line-width props
                         (ly:output-def-lookup layout 'line-width))
                        (max (length args) 1))))
     (interpret-markup layout props
       (make-line-markup (map (lambda (line)
                                (markup #:pad-to-box `(0 . ,line-width) '(0 . 0)
                                  #:override `(line-width . ,line-width)
                                  line))
                               args)))))

\markuplines { \column-lines {
  \line {\bold {Text der Messe / Text of the Mass}}

  \line {\bold "Kyrie eleison" }
  \column-lines {\columns{
    \column { "line 1"  "line 2" "line 3" }
    \column { "line 1"  "line 2" "line 3" }
    \column { "line 1"  "line 2" "line 3" }
  }}

  \line {\bold "Gloria in excelsis Deo" }
  \column-lines {\columns{
    \column { "line 1"  "line 2" "line 3" }
    \column { "line 1"  "line 2" "line 3" }
    \column { "line 1"  "line 2" "line 3" }
  }}

  \line {\bold "Credo in unum Deum" }
  \column-lines {\columns{
    \column { "line 1"  "line 2" "line 3" }
    \column { "line 1"  "line 2" "line 3" }
    \column { "line 1"  "line 2" "line 3" }
  }}
}}

Attachment: markuplines_spacing.pdf
Description: Adobe PDF document

_______________________________________________
lilypond-user mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to