Page 2 of 2
Re: Error on 'put "My text" into the selection' (Solved)
Posted: Thu Jun 20, 2019 10:32 pm
by FourthWorld
Klaus wrote: ↑Thu Jun 20, 2019 6:39 pm
Just tested with LC 9.04 on macOS 10.14.5, and yes traversalon or not, it works as advertized.
Looks like they have changed this in a former version, but this did definitively not work a long time ago.
Here on Ubuntu, v9.0.4 works as Raney and Waddingham have always described it: traversalOn shifts focus to the button, causing any selected text to become unselected.
Searching the v9.0.4 Release Notes for "text", "selection", "traversalOn", and "focus" all turned up empty.
Have you seen any indication from the team that the change you see in macOS is intentional?
Re: Error on 'put "My text" into the selection' (Solved)
Posted: Fri Jun 21, 2019 9:46 am
by Klaus
FourthWorld wrote: ↑Thu Jun 20, 2019 10:32 pm
...
Have you seen any indication from the team that the change you see in macOS is intentional?
No, that was just an assumption, since this has been the case on the Mac, too, at least a long time ago. Therefore I did not try this again until yesterday and was really surprised to see it actually work.
Re: Error on 'put "My text" into the selection'
Posted: Fri Jun 21, 2019 5:46 pm
by FourthWorld
The change may not be intentional, and may have implications for managing focus that could be undesirable in some contexts.
You might want to submit it as a bug report, and see how the team responds.
Re: Error on 'put "My text" into the selection'
Posted: Fri Jun 21, 2019 6:02 pm
by LCMark
The dictionary for traversalOn does describe the observed behavior (well, the language is a bit out of date, but if you read between the lines...):
----
Setting a field's traversalOn to true enables the user to tab into or click in the field for editing (if the field's lockText property is false). If a field's traversalOn and lockText properties are both set to true, the user can select text, but not change it, and can scroll within the field using the keyboard. If the traversalOn is true and the lockText is false, the field can be edited. If the lockText is true and the traversalOn is false, the user can neither select nor edit the field's text.
If the object is a group, setting its traversalOn to true causes tabbing into the group to set the focus to the first control in the group.
If the object is a control other than a group or field, if its traversalOn is true, and if the lookAndFeel is set to "Motif" or "Windows 95", the user can tab to the control, then press Return or Enter to send a mouseUp message to the object.
If the lookAndFeel is set to "Motif", "Macintosh", or "Appearance Manager", the active is outlined, and the control receives any keystrokes and the messages associated with them. (The outline can be turned off by setting the field's showFocusBorder property to false.) If the lookAndFeel is set to "Windows 95", the appearance of a focused field does not change, but it receives keystroke messages.
---
Essentially on macOS buttons never take focus, so traversalOn has no effect. On Windows and Linux they can take focus, so traversalOn does take effect.
The behavior here is tied to the lookAndFeel - so if you set the lookAndFeel to "motif" on mac (which does still work) your buttons will respond to traversalOn.
Re: Error on 'put "My text" into the selection'
Posted: Sat Jun 22, 2019 1:44 pm
by Klaus
Hi Mark,
LCMark wrote: ↑Fri Jun 21, 2019 6:02 pm
...so if you set the lookAndFeel to "motif" on mac (which does still work) your buttons will respond to traversalOn.
yeah, and look butt-ugly!
Thank you very much for the clarification!
Best
Klaus