Page 1 of 1

Overriding the 'don't wrap' text option

Posted: Thu Nov 05, 2020 2:22 pm
by glenn9
Hi everyone,

Just wanted to check if it was possible to have a field wrap text as well as at the same time having a list behaviour?

From what I've tried so far they seem to be mutually exclusive, ie if list behaviour is set in a card's properties, it doesn't seem possible to uncheck the 'don't wrap' option. I've tried to override this in script but the script seems to get ignored.

Many thanks,

Glenn

Re: Overriding the 'don't wrap' text option

Posted: Thu Nov 05, 2020 2:32 pm
by Klaus
Hi Glenn,

I'm afraid you canonly have listfield AND dontwrap or die! :D

But here is a workaround:
Uncheck "listfield" and "downtwrap" in the inspector for your listfield and just add this script to your now EX-listfield:

Code: Select all

on mouseUp 
   select the mouseline  
   ## do something with -> the selectedtext of me 
   ## answer the selectedtext of me
end mouseUp
The user will not be able to tell the difference! 8)

Best

Klaus

Re: Overriding the 'don't wrap' text option

Posted: Thu Nov 05, 2020 2:38 pm
by Klaus
P.S.
This will however require to script the use of arrowkeys in that field!
But -> the selectedline
will give you something like -> line 2 of fld 1
So scripting is not too difficult, drop a line if you need help with this.

Re: Overriding the 'don't wrap' text option

Posted: Thu Nov 05, 2020 2:52 pm
by glenn9
Thanks Klaus, the mouseLine function works a treat.

I've not needed to use arrowkeys as yet but thank you for your offer of advice.

Kind regards,

Glenn