lilypond-user
[Top][All Lists]
Advanced

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

Re: Grouping grobs


From: lilypond
Subject: Re: Grouping grobs
Date: Tue, 16 Aug 2022 19:14:24 +0000

Of course, happy to give more context. I primarily write graphic scores (but with western notation symbols). The score isn't always static, so I want to be able to manipulate fragments of music after generation.

In the past I have used my own program to place glyphs programmatically, which requires that I create my own notation<>glyph mappings and to have the engraving font installed/available to whoever views it.

When I saw that Lilypond produces shapes in SVG output, not glyphs, I was intrigued--and leveraging Lilypond's input over my own mapping is appealing as well.

I suppose one answer is keep my current system and outline the glyphs like Lilypond may be doing under the hood. Another is to make and group selections based on position, not an id attribute, from the current Lilypond output.

Hi,

I'm new to Lilypond and am trying to generate SVG output for use elsewhere. In general I'd like to create fragments of music and add ids to each group. So far I've seen that each grob is output as its own <g>--is there a way to group at a higher level, say markup, staff, etc.?

John
\version "2.22.2"
\markup {
    % with SVG output this is two <g>: notehead and dot
    % \override NoteHead.output-attributes.id = 123
    \note {4.} #0
}

There isn’t a simple way to do this. I wonder what leads you to this question, though. Could you explain the purpose for which you would like this type of output? There may be a different way to solve your problem. See also: https://en.m.wikipedia.org/wiki/XY_problem


reply via email to

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