|
From: | Simon Albrecht |
Subject: | Re: ClefModifier tweaks conditional on clef |
Date: | Wed, 10 May 2017 00:03:48 +0200 |
Am 09.05.2017 um 23:39 schrieb Kieren MacMillan:
Hi Joram,does it only handle the x-offset? Try-and-error told me that the first number is the X-offset for _8 and the second for ^8. But can I affect the y position?Ah! I look forward to seeing the answer. It would be great (actually, kind of essential) if it did.
Perhaps needless to mention, and I’m sure the following implementation isn’t to be taken serious, but of course you could write a callback:
%%%%%%%%%%%%%%% \version "2.19.58" #(define (adapt-to-clef-glyph grob) (let* ((clef-glyph (ly:grob-property (ly:grob-parent grob 1) 'glyph-name "")) (F-clef (string-any #\F clef-glyph))) (if F-clef 10 0))) \layout { \context { \Staff \override ClefModifier.Y-offset = #adapt-to-clef-glyph } } { \clef "treble_8" 1 \clef "bass_8" c,1 } %%%%%%%%%%%%%% Best, Simon
[Prev in Thread] | Current Thread | [Next in Thread] |