[JW Lua] Fwd: Re: Wrong results with FCNote:CalcRightsidePlacement

Jari Williamsson jari.williamsson at mailbox.swipnet.se
Sat Aug 12 23:17:17 CEST 2017


Jan,

Although the entry metrics is rebuilt dynamically in the score 
(depending on what you edit), this bug is indeed in the PDK Framework.

I'll fix this and your FCMusicRegion issue for the upcoming update.


Best regards,

Jari Williamsson


On 2017-08-12 21:50, Jan Angermüller wrote:
> Jari,
> 
> no, unfortunately that doesn't solve it. I had tried the same before.
> 
> Isn't the entry metrics rebuilt anyway when a Finale document is loaded?
> That's why I attached both document files: the defect one and the 
> working one.
> 
> Best,
> Jan
> 
> Am 12.08.2017 um 20:56 schrieb Jari Williamsson:
>> Jan,
>>
>> I guess the layout metrics in Finale requires an update.
>>
>> Call the static metod FCNoteEntry::MarkEntryMetricsForUpdate() before 
>> the call to see if that fixes the issue. Let me know how it goes.
>>
>>
>> Best regards,
>>
>> Jari Williamsson
>>
>>
>> On 2017-08-12 16:47, Jan Angermüller wrote:
>>> Jari,
>>>
>>> FCNote:CalcRightsidePlacement() sometimes returns incorrect results.
>>> I have attached two identical looking first measures with one note on 
>>> the left and on the right side, so I would expect a false and a true 
>>> result when calling CalcRightsidePlacement().
>>>
>>> But it doesn't:
>>> the "OK" document return false / true while the "Error" document 
>>> returns false / false.
>>> The note flags look identical to me. (or did I overlook anything?)
>>> The "OK" document was derived directly from the default document, the 
>>> "Error" document is an excerpt from an orchestra score.
>>>
>>> I don't see a workaround for this at the moment.
>>> If I had direct access to the downstem 2nd and the upstem 2nd flag, I 
>>> could write something.
>>> But currently these flags are not available for reading/writing.
>>>
>>> Code snippet:
>>> local musicregion=finale.FCMusicRegion()
>>> musicregion:SetFullDocument()
>>> for entry in eachentry(musicregion) do
>>>      for note in each(entry) do
>>>          print(note:CalcRightsidePlacement())
>>>      end
>>> end
>>>
>>> Running [Unnamed Script] ======> --OK document
>>> false
>>> true
>>> <======= [Unnamed Script] succeeded (Processing time: 0.005 s).
>>>
>>> Running [Unnamed Script] ======> --Error Document
>>> false
>>> false   --!!wrong!!
>>> <======= [Unnamed Script] succeeded (Processing time: 0.005 s).
>>>
>>> For file size reasons I have attached the files in Fin2012 format. 
>>> They were originally Fin2014.5 files.
>>>
>>> Best,
>>> Jan
>>>
>>>
>>> _______________________________________________
>>> JWLua mailing list
>>> JWLua at jwmusic.nu
>>> http://jwmusic.nu/mailman/listinfo/jwlua_jwmusic.nu
>>>
>>
>>
>>
>> _______________________________________________
>> JWLua mailing list
>> JWLua at jwmusic.nu
>> http://jwmusic.nu/mailman/listinfo/jwlua_jwmusic.nu
> 
> 
> 
> _______________________________________________
> JWLua mailing list
> JWLua at jwmusic.nu
> http://jwmusic.nu/mailman/listinfo/jwlua_jwmusic.nu
> 





More information about the JWLua mailing list