lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re:


From: Thomas Morley
Subject: Re:
Date: Sat, 11 May 2013 23:40:20 +0200

2013/5/11  <address@hidden>:

> Thanks a lot, this seems to work indeed!  Actually I was dreaming of
> something like \hfill\break in TeX, so that I could either do
>
> notes \bar "|." \hfill \break
>
> or
>
> notes \hfill \bar "|." \break
>
> for example, but your solution is already very good.

Well, you could do the following, although it might be not be the same
as \hfill in Tex.
Please note: I improved the function concerning BarLine #'space-alist.

\version "2.14.2"

spaceRight =
#(define-music-function (parser location space)(number?)
  (let* ((amount (+ space 0.5))
         (space-right `(extra-space . ,amount)))
  #{
     %% Maybe additional layout-objects must be affected!?
     \once \override Score.BarLine #'space-alist #'right-edge =
#`(extra-space . ,$space)
     \once \override Score.KeySignature #'space-alist #'right-edge =
$space-right
     \once \override Score.KeyCancellation #'space-alist #'right-edge
= $space-right
     \once \override Score.TimeSignature #'space-alist #'right-edge =
$space-right
  #}))


hfill = \spaceRight #20

{
   %\spaceRight #30
   %\key d\major
   a4\( b c d~(
   %\breathe
   \hfill\break
   %\time 8/8
   %\clef alto
   %\key cis\major
   d4 b) c\) d \bar "|."
   \hfill
}

-Harm



reply via email to

[Prev in Thread] Current Thread [Next in Thread]