Would this work for you? https://lists.gnu.org/archive/html/lilypond-user/2024-06/msg00138.html
-- Knute Snortum On Tue, Jun 17, 2025 at 4:59 PM Kyle Baldwin <[email protected]> wrote: > Hi all - > > I'm looking at improving my centering of MM rest numbers between staves. I > have come across solutions like this: > https://lists.gnu.org/archive/html/lilypond-user/2012-10/msg00293.html but > the problem seems to be that it will always find the center of the Dynamics > context which, if notes whatever are between the staves, un-centers the MM > rest numbers. > > This is my current thought process. > > - Create an engraver that lives on the piano staff that records the > position of my up and down staves and record Y pos in a context property. > - Set the MM rest number to transparent so that it is not recorded as > taking up space > - Set the MM rest 'after-line-breaking' to read the context property of > the parents and set the numbers centered between the bars. > > Does this sound feasible? Is there an easier way? I remember seeing > something about looking at the gridlines for height, but not 100% sure it > would work for my purposes: > https://lists.gnu.org/archive/html/lilypond-user/2023-05/msg00139.html > > Thanks! > > -Kyle >
