[JW Lua] Repeat Brackets Hide Mysteriously - still unsolved

Jan Angermüller jan at angermueller.com
Thu Oct 20 11:29:08 CEST 2022


Robert,

do you have any ideas on this old issue?
It popped up again in another document.
Is the "Show/Hide" property somehow available for FCEndingRepeat?

Jan

On 03.07.2019 / 12:31 Jan Angermüller wrote:

I have found out that when you copy (Save as...) the repeat bracket to a 
new measure, the new repeat bracket will behave correctly and not hide 
when calling sep:AssureStaffPlacement(1) .
So there seems be some measure cell flag that says that the repeat 
bracket should hide. But I can't access it.
When I now delete the old repeat bracket in measure 5 and run the script 
again to copy back from measure 6 to measure 5, the new repeat bracket 
will again behave false and hide. So the "Hide" flag is not reset by 
deleting the repeat bracket, but still seems to be active in the background.

The result:
- the first repeat bracket is again hidden
- but the copied repeat bracket is fine


Here is the new test code (applied to the document from the email 2/7/2019):

local endrep=finale.FCEndingRepeat()
if endrep:Load(5) then   --i.e. load bracket in measure 5
     endrep.IndividualPositioning=true --not really required here as it 
is already true in the document, just for better understanding
     local sep=endrep:CreateSeparatePlacements()
     local s=sep:AssureStaffPlacement(1)    -- i.e. create separate 
placement element for staff 1 -> this leads to the hiding

     --Now save to measure 6 and see what happens
     endrep:SaveAs(6)
     local meas=finale.FCMeasure()
     meas:Load(6)
     meas.RepeatBracketFlag=true --make the new repeat bracket active
     meas:Save()
     local sep=endrep:CreateSeparatePlacements()
     local s=sep:AssureStaffPlacement(1) --DOES NOT hide the second 
repeat bracket

     --try again with loading
     local endrep=finale.FCEndingRepeat()
     if endrep:Load(6) then
         endrep.IndividualPositioning=true
         local sep=endrep:CreateSeparatePlacements()
         local s=sep:AssureStaffPlacement(1)   --DOES NOT hide the 
second repeat bracket
     end
end

Anyone any ideas?

Jan


-------- Weitergeleitete Nachricht --------
Betreff: 	[JW Lua] Repeat Brackets Hide Mysteriously
Datum: 	Tue, 2 Jul 2019 13:08:50 +0200
Von: 	Jan Angermüller <jan at angermueller.com>
Antwort an: 	The JW Lua script plug-in. <jwlua at jwmusic.nu>

	



Jari et al,

I have a problem with an ending repeat bracket. Attached is an excerpt 
from an orchestra score.
When I want to add a "separate placement" (i.e. a change of the bracket 
offsets only for this staff), the repeat bracket always hides. The 
following code is the excerpt which leads to the hiding in the attached 
document:

local endrep=finale.FCEndingRepeat()
if endrep:Load(5) then   --i.e. load bracket in measure 5
     endrep.IndividualPositioning=true --not really required here as it 
is already true in the document, just for better understanding
     local sep=endrep:CreateSeparatePlacements()
     local s=sep:AssureStaffPlacement(1)    -- i.e. create separate 
placement element for staff 1 -> this leads to the hiding
     --... here follows the part which sets the offsets, but it's not 
required for this problem, the staff becomes hidden
end

Can anyone explain this?
Or in other words: each bracket in Finale has a show/hide property. How 
can I address show/hide of brackets in JW Lua?
FCSeparatePlacement only has offset values, but no visibility 
properties. Same for FCEndingRepeat.
(Of course, you can also handle this over staff lists, but I assume they 
don't have anything to do with show/hide property)

Jan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://jwmusic.nu/pipermail/jwlua_jwmusic.nu/attachments/20221020/b4517e5e/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 6e0GhmXnHUBsIZ5M.png
Type: image/png
Size: 4312 bytes
Desc: not available
URL: <http://jwmusic.nu/pipermail/jwlua_jwmusic.nu/attachments/20221020/b4517e5e/attachment-0001.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: repeatbracket test.mus
Type: application/octet-stream
Size: 50282 bytes
Desc: not available
URL: <http://jwmusic.nu/pipermail/jwlua_jwmusic.nu/attachments/20221020/b4517e5e/attachment-0001.obj>


More information about the JWLua mailing list