[Top][All Lists]

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

Re: centering of instrument names

From: Neil Puttock
Subject: Re: centering of instrument names
Date: Wed, 15 Jul 2009 22:07:35 +0100

2009/5/30 Joe Neeman <address@hidden>:

> The sanest behaviour IMO is the behaviour of your current patch, but
> with a different meaning for 'padding. I can see two ways to do this:
> the quick&dirty way to get this is to replace
> instrument-name::calc-combined-delimiters-offset with
> instrument-name::calc-min-distance-to-support, which goes through all
> the instrument names and finds the minimum distance necessary between
> any instrument name and any grob in its support. The nicer way to get
> the same effect would be to create an InstrumentNameColumn grob that is
> the X-parent of all the InstrumentNames and do the instrument name
> positioning in ly:instrument-name-column::calc-positioning-done.

I had a stab at creating an InstrumentNameColumn, which acknowledges
InstrumentNames, but it doesn't work properly because InstrumentName
grobs appear to be static unless there's a name change, meaning they
only get acknowledged once.  I placed the new engraver in the Score
context, but it missed all but the first system's InstrumentNames;
setting a new shortInstrumentName before the next system resulted in
only that grob being acknowledged.

Following your comments about keeping the positioning out of the
stencil code, I've reworked my original patch completely in Scheme,
removing the X- and Y-positioning to X-offset/Y-offset callbacks.
I've posted the new patch set to Rietveld here:


reply via email to

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