[JW Lua] FCNoteEntry:CalcStemUp() on rests / Entry metrics on rests

Jan Angermüller jan at angermueller.com
Mon Mar 6 12:15:08 CET 2017


Jari,

when using the note entry metrics from FCEntryMetrics, I always need to 
check first whether it's an upstem or downstem note (via 
FCNoteEntry:CalcStemUp()), because GetStemLeftPosition is either on the 
right side of the notehead (if upstem) or on the left side (if downstem).

Now if I want to calculate the left/right metrics of a rest, the same 
problem exists:
I need to know whether it's "sort of" upstem or downstem.
But: FCNoteEntry:CalcStemUp() seems to always return false on rests.

The problem comes up for example when have measures with two voices or 
two layers.
GetStemLeftPosition returns the left boundary of the rest, if the rest 
is on voice1 and the right boundary on voice2.
Similar, but a bit more difficult to determine when using rests on 
different layers.

It would be great if I could determine this metrics behaviour with 
CalcStemUp() on rests - just as it is possible on notes.
Currently it's a bit of guessing whether GetStemLeftPosition returns the 
left boundary of the right boundary of rests.

Best,
Jan

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://jwmusic.nu/pipermail/jwlua_jwmusic.nu/attachments/20170306/6d47a191/attachment.html>


More information about the JWLua mailing list