On 2013/04/16 13:03:25, dak wrote:
On 2013/04/16 12:50:47, david.nalesnik wrote: > Here I kept the same pattern as \alterBroken and \shape, > as they have been revised by David Kastrup. I agree that > the syntax is a little awkward, and that > it would be nice if the pattern you give were workable. > However, IIRC, this syntax is the only one currently feasible. > I'm not an expert here, though.
For \alterBroken and \shape, the syntax is actually \shape ... item where item is either music (which is then tweaked) _or_ a grob (which then gets an override). The syntax is only due to this double-function.
If \offset does not have the same characteristic (nor intends to have
it), then
one should be able to make do with a single specification.
I have not reviewed this so far, so I can't tell.
I've always thought that the syntax of \shape was done this way because there was no "property" argument (as it always concerned control-points) - in other words, \shape's syntax is \shape value grobname-or-music because we need to keep the number and order of arguments quite constant. The alternative (specifying grobname before value) would be bad because then we'd have \shape grobname-or-nothing value nothing-or-musc and there's too many "or-nothing"s there (i suppose that the biggest problem is an optional argument followed by non-optional one ("value")). However, in case of \offset, we can have either a \shape-like syntax \offset property value grobname-or-music or \offset grobwithproperty-or-property value nothing-or-music since the first argument is not optional (i.e there's always at least the property to specify), i guess that it should be easier to do? best, Janek https://codereview.appspot.com/8647044/ _______________________________________________ lilypond-devel mailing list lilypond-devel@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-devel