[JW Lua] Determine whether a tuplet has a bracket or not
Jan Angermüller
jan at angermueller.com
Thu Jul 28 13:27:09 CEST 2016
Hi Thomas,
I haven't worked with bracket detection yet, but it sounds reasonable
what you have found.
Maybe the Finale PDK offers something like HasBracket which is not
implemented yet ?
Or Jari could give us a CalcHasBracket() method ?
There are some more conditions missing in your list:
- FCTuplet.Visible needs to be checked
- the notation style needs be checked in FCCurrentStaffSpec (e.g. tuplet
brackets are not visible on slash or empty rest notation)
Is there also any metric information on the tuplets left in the PDK
which is not accessible yet ?
This is on my wish list :-)
Jan
Am 28.07.2016 um 12:59 schrieb Thomas Weber:
> I don't see a simple built-in method to determine whether a bracket is displayed for a tuplet or not.
>
> Obviously, if FCTuplet's ShapeStyle is not set to TUPLETSHAPE_BRACKET, we won't get a bracket and I'm done.
>
> Otherwise, if BracketMode is set to TUPLETBRACKET_ALWAYS, it is displayed and I'm done.
>
> Otherwise, I need to find out whether there is a beam spanning all the notes. However, I don't see a built-in method either for that task, so I think I need to iterate over them and make sure
>
> * neither the first nor the last note are a rest (unless FCMiscDocPrefs' ExtendBeamsOverRests is true)
> * for all but the first entry, BeamBeat is false (for the first entry, it may be either true or false)
>
> If there is no beam spanning all the entries, the bracket is displayed and I'm done.
>
> Otherwise, a bracket is not shown if either
>
> * the tuplet is placed on the same side as the beam
> * BracketMode is set to TUPLETBRACKET_UNBEAMEDONLY
>
> This feels pretty involved for what feels like it should be a pretty trivial check. Therefore I'd be interested to learn whether I'm actually missing something.
>
> Thomas
>
>
> _______________________________________________
> JWLua mailing list
> JWLua at jwmusic.nu
> http://jwmusic.nu/mailman/listinfo/jwlua_jwmusic.nu
>
More information about the JWLua
mailing list