lilypond-user
[Top][All Lists]
Advanced

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

Re: \offset and mutable properties


From: David Nalesnik
Subject: Re: \offset and mutable properties
Date: Tue, 21 Jul 2015 19:16:09 -0500

Hi Simon,

On Tue, Jul 21, 2015 at 6:25 PM, Simon Albrecht <address@hidden> wrote:
And I forgot to mention: Unfortunately, your offIIb.ly file doesn’t place the dynamics in the middle of the staff symbol as they should be – probably because of outside-staff-priority?


No, the Y-offset callback will return the same values whether outside-staff-priority is its usual value or ##f.  \offset takes the result of this Y-offset callback and offsets against it.

This is probably not what you want, but there's a tricky way to offset against a user value, involving a combination of override and tweak:

 \relative {
  \hideNotes
  \dynamicUp
  \override DynamicLineSpanner.outside-staff-priority = ##f
  \override DynamicLineSpanner.Y-offset = 0 % try other values
  b'2
  -\offset DynamicLineSpanner.Y-offset 2
  \< 2\f\>
  2 2\f\<
  2\f
}

Here, of course, we could simply do the following :)

\relative {
  \hideNotes
  \dynamicUp
  \override DynamicLineSpanner.outside-staff-priority = ##f
  \override DynamicLineSpanner.Y-offset = 2
  b'2\< 2\f\>
  2 2\f\<
  2\f
}

--David

reply via email to

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