On Jan 29, 2012, at 11:48 PM, Thomas Morley wrote:
>
>
> 2012/1/29 Joey Di Nardo <[email protected]>
> Looking to do something like this:
>
> <Screen Shot 2012-01-29 at 5.34.51 PM.png>
>
> If anyone knows the best way, I'd appreciate the insight.
>
> Thank you,
> Joey
>
> ???
>
> There is no code, image or sth else.
>
> Harm
I see an attachment w/ a system brace between two staves.
It's not easy. I can give you pointers for what to fiddle with but as for the
fiddling, I won't be able to be of much help.
You can create a TextScript using a glyph from the feta-braces font combined
with a boxed markup. Set the Y-extent property of the text script to a pair
representing the height of this stencil (you can get this height directly from
the stencil).
Then, for the stencil, use the actual stencil but translate it by a certain
amount. The amount is what's difficult to glean. You'll have to get the
VerticalAxisGroup of the staff above the staff with the TextScript. You can
(probably) find the distance between the text script and the vertical axis
group above by finding the height of the lower of the two skylines in the
vertical-skyline pair via ly:skyline::get-height at the script's X coordinate.
Something like:
(ly:skyline-height (ly:skyline-pair::skyline (ly:grob-property grob
'vertical-skylines) DOWN) x-pos)
Where grob is the VerticalAxisGroup of the above staff and x-pos is the x
position of the text script.
To get said VerticalAxisGroup, get the root vertical alignment of the score by
find the Y parent of the grob until you hit a grob w/ no more Y-parents. This
is the vertical alignment. Then, get the 'elements object. The
VerticalAxisGroup you want will be in this list (likey before the
VerticalAxisGroup to which the TextScript belongs).
If this reads like Sanskrit, it is because I am tired and unfortunately don't
have time to create a code example. I may be able to in the next couple days.
Cheers,
MS
_______________________________________________
lilypond-user mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/lilypond-user