Laying out text

Paul Hibbert paul at livecode.org
Mon Feb 23 10:30:40 EST 2015


Nothing should cause LC to crash, so that should be reported as a bug, if you prefer not to or don't have enough time to report it just let me know and I would be happy to.

By default the templateField doesn't have the text properties set for textFont or textSize, however, I found that it can work if you set the font/size first, as far as I can see, you only need to set the font/size once provided you don't issue a reset command.

You could also use 'this card' or 'this stack', which doesn't crash LC if that helps.

put measureText("testText”,this card) into theTextWidth

Regards,

Paul

> On Feb 23, 2015, at 3:16 AM, Terence Heaford <t.heaford at icloud.com> wrote:
> 
> Tried it as:
> 
> put measureText("testText”,templateField) into theTextWidth
> 
> Wasn’t expecting it to work and it didn’t but should it have crashed LC?
> 
> Would it be a good idea for it to work with the templateField?
> 
> All the best
> 
> Terry
> 
> 
>> On 23 Feb 2015, at 07:35, Terence Heaford <t.heaford at icloud.com> wrote:
>> 
>> Can it work in some way with the templateField. In that way a field would not have to exist?
> 
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode





More information about the use-livecode mailing list