Insertion point problems
J. Landman Gay
jacque at hyperactivesw.com
Wed Jun 24 12:15:43 EDT 2015
I don't think traversal is the problem here. When I tested, my button did not have traversalOn set to true (that was the first thing I checked.) The anomaly is that the selectedChunk works fine if the selection contains text, it only fails if the selection is a simple insertion point.
Both instances should work identically.
On June 24, 2015 10:27:04 AM CDT, Richard Gaskin <ambassador at fourthworld.com> wrote:
>Yes, the traversalOn property is the key here.
>Only one object can have focus at any given time, so when traversing
>among controls with the keyboard any field selection will be cleared.
>But by turning off the traversalOn property for buttons you want to be
>able to act on text, the focus remains in the field and things work as
>easily as you'd expect with LiveCode.
> Richard Gaskin
> Fourth World Systems
> Software Design and Development for the Desktop, Mobile, and the Web
> Ambassador at FourthWorld.com http://www.FourthWorld.com
>Peter Brigham wrote:
>> What I do for this is store the selectedchunk in a customprop or a
>> local on mouseEnter in the button script that will be doing the
>> That way if the mousedown removes the current selection you already
>> the info you need. BTW, if you set the traversalon to false for the
>> the current selection should be preserved, which will obviate the
>> this workaround.
>> -- Peter
>> Peter M. Brigham
>> pmbrig at gmail.com
>> On Tue, Jun 23, 2015 at 7:35 PM, Bob Sneidar <bobsneidar at
>>> On a Mac, I opened two stacks, one with a button, one with a field.
>>> palletized the first stack, then set the insertion point in the
>>> the second one. Clicking the button in the palletized stack still
>>> the field on the second stack to lose focus.
>>> I don’t think there is a way to change this behavior. The workaround
>>> comes to my mind is to have an exitField handler in the field which
>>> the selection in a property or global variable that the palette
>>> access. Alternatively you could have an exitField handler inserted
>>> front script when the palette opens, so that the selection can be
>>> That is how I would go about this.
>>> Bob S
>use-livecode mailing list
>use-livecode at lists.runrev.com
>Please visit this url to subscribe, unsubscribe and manage your
Jacqueline Landman Gay | jacque at hyperactivesw.com
HyperActive Software | http://www.hyperactivesw.com
More information about the Use-livecode