-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 We had a similar discussion already last August, but this question was not raised back then:
There are ways to move dynamics to the left/right, let it fall down towards the staff, once it has left the skyline of the note, or even move the dynamic inside the staff (with the drawback that the part of the dynamic that is still outside the staff will NOT count towards the skyline). The 2.10 version is at the LSR http://lsr.dsi.unimi.it/LSR/Item?id=469 and the 2.12 version is attached. Now, my problems with these solutions are that - -) The y-extent is set to an invalid value in dynamicsAllInside (so it basically has 0 height and is ignored). Unfortunately, this causes a warning: Programmierfehler: cannot align on self: empty element Fortsetzung, die Daumen drücken - -) All shifting is done by offsets from the final position. My main problem is connected to the last one: I have a large score, where I need to move about every dynamic sign slightly inside the staff. I want them to align properly vertically, i.e. all dynamic signs should start between the topmost and the second staff line. Is there any way to move the dynamic sign to an explicit position? I.e. the last two dynamics in the attached file show this problem: The correct offset has to be different for every note, since each note has a different skyline and causes a different vertical position for the dynamic. Both final \f in the attached score use the same vertical offset, but of course they are placed at different positions relative to the staff. Is there any way to position a dynamic sign at an explicit staff-relative (not note-relative) vertical position? Thanks, Reinhold - -- - ------------------------------------------------------------------ Reinhold Kainhofer, reinh...@kainhofer.com, http://reinhold.kainhofer.com/ * Financial & Actuarial Math., Vienna Univ. of Technology, Austria * http://www.fam.tuwien.ac.at/, DVR: 0005886 * LilyPond, Music typesetting, http://www.lilypond.org -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) iD8DBQFJ7OUZTqjEwhXvPN0RAmaWAKDGAlnW5BMSdQribIIv+Ejo8HpiwwCdFday nEeFHnHCaR1SHKzkeJwkUJk= =wC5+ -----END PGP SIGNATURE-----
\paper { ragged-right = ##f } dynamicsX = #(define-music-function (parser location offset) (number?) #{ \once \override DynamicText #'X-offset = $offset \once \override DynamicLineSpanner #'Y-offset = #0 #}) dynamicsXY = #(define-music-function (parser location offsetX offsetY) (number? number?) #{ \once \override DynamicText #'X-offset = $offsetX \once \override DynamicLineSpanner #'Y-offset = $offsetY #}) dynamicsInside = #(define-music-function (parser location offsetX shiftY height) (number? number? number?) #{ \once \override DynamicText #'X-offset = $offsetX \once \override DynamicLineSpanner #'Y-offset = #0 \once \override DynamicText #'Y-extent = #(cons $shiftY $height ) \once \override DynamicLineSpanner #'Y-extent = #(cons $shiftY $height ) \once \override DynamicText #'extra-offset = #(cons 0 $shiftY ) #}) dynamicsAllInside = #(define-music-function (parser location offsetX shiftY) (number? number?) #{ \once \override DynamicText #'X-offset = $offsetX % \once \override DynamicLineSpanner #'Y-offset = #0 \once \override DynamicText #'Y-extent = #(cons 1 -1) \once \override DynamicLineSpanner #'Y-extent = #(cons 1 -1) \once \override DynamicText #'extra-offset = #(cons 0 $shiftY ) #}) { \dynamicUp b''2\f \dynamicsX #-3 b''2\f \dynamicsXY #-3 #-16 b''2\f b''2 \break b''2\f \dynamicsInside #-3 #-4 #-2 b''2\f % I want to vertically place the following two \f at the same vertical staff % position, i.e. they should start between the topmost and the second % staff line. Using offsets, this doesn't work, as each note requires a % different offset! \dynamicsAllInside #-3.5 #-2.75 b''2\f \dynamicsAllInside #-3.5 #-2.75 g''2\f \break } #(ly:set-option 'debug-skylines #t)
dyn.pdf
Description: Adobe PDF document
_______________________________________________ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user