[JW Lua] TextBlock width & hight, measure attached textblocks

Jari Williamsson jari.williamsson at mailbox.swipnet.se
Mon Feb 2 18:28:44 CET 2015


Bart,

The Width and Height has been implemented since the last public beta. 
However, when the next beta becomes available, please note that these 
methods are in the FCTextBlock object for the measure/page-attached text.

If my change log is correct, the following sample code should work in 
the current available beta as well (for creating a measure-attached text 
block in measure 4 of staff ID 1, and position it at the 2nd quarter 
note at 100 EVPUs).
---
local textblock = finale.FCMeasureText()
local cell = finale.FCCell(4, 1)
textblock:ConnectCell(cell)
textblock:SaveNew()
local str = finale.FCString()
str.LuaString = "^font(Times New Roman)^size(16)^nfx(1)test"
textblock:SaveNewTextBlock(str)
textblock.MeasurePos = 1024 -- In EDUs
textblock.VerticalPos = 100 -- In EVPUs
textblock:Save()

local meas = finale.FCMeasure()
meas:Load(4)
meas.TextFlag = true
meas:Save()
---

Best regards,

Jari Williamsson

On 2015-01-31 21:11, Bart Visser wrote:
> Hi Jari,
>
> Is it possible to hook up the Textblock width and hight methods? If I'm correct they do not work yet with JW Lua.
>
> Also: I would like to create measure-attached TextBlocks (attaching it to a measure-number, and position it). If I'm correct, at the moment you can only create one, but aren't able to set those properties.
>
> Thanks,
>
>
> Bart Visser
>
>
> Verstuurd vanaf mijn iPad
> _______________________________________________
> JWLua mailing list
> JWLua at jwmusic.nu
> http://jwmusic.nu/mailman/listinfo/jwlua_jwmusic.nu
>
>






More information about the JWLua mailing list