lilypond-user
[Top][All Lists]
Advanced

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

Re: Shift up OttavaBracket


From: Paolo Prete
Subject: Re: Shift up OttavaBracket
Date: Mon, 13 Jan 2020 02:17:10 +0100

Unfortunately, with extra-offset I have the disadvantage that all the other objects are not moved automatically (smart repositioning)
Does my example show a bug/missing feature for OttavaBracket?

Thanks,
Paolo

On Mon, Jan 13, 2020 at 1:56 AM Aaron Hill <address@hidden> wrote:
If you want to move the bracket upwards based on its final position
after accounting for other objects such as the slur, then extra-offset
seems the way to go.

Otherwise, you can manually do the work that \offset Y-offset would have
done if you need to use 2.18.2.

%%%%
\version "2.18.2"
test = { \ottava #1 c'''' c'''' c'''' \ottava #0 c'''
          \ottava #1 c''''( c'''' c'''' \ottava #0 c''') }
{
   \test

   % \offset Y-offset 2 Staff.OttavaBracket
   \override Staff.OttavaBracket.Y-offset =
     #(let ((offset (lambda (n) (+ 2 n))))
        (ly:make-unpure-pure-container
          (lambda (grob) (offset
            (ly:side-position-interface::y-aligned-side grob)))
          (lambda (grob start end) (offset
            (ly:side-position-interface::pure-y-aligned-side
               grob start end)))))
   \test
   \revert Staff.OttavaBracket.Y-offset

   \override Staff.OttavaBracket.extra-offset = #'(0 . 2)
   \test
}
%%%%


-- Aaron Hill


reply via email to

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