Focus on Option button

Anything beyond the basics in using the LiveCode language. Share your handlers, functions and magic here.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
alemrantareq
Posts: 203
Joined: Wed Jul 23, 2008 8:46 am

Focus on Option button

Post by alemrantareq » Thu Feb 25, 2010 1:02 pm

Hi everybody, I just want to know how to focus on option button with the Tab button so that it can be controlled by the keyboard? Thanks in advance...

BvG
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 1239
Joined: Sat Apr 08, 2006 1:10 pm
Contact:

Re: Focus on Option button

Post by BvG » Thu Feb 25, 2010 3:16 pm

For windows, make sure that "traversalOn" is true both for the button and all the groups it is in. This is the default setting, so most likely you set it to false.

For Mac OS, you need to either script your own solution, or tell your users to change their system accessibiliy settings to allow keyboard navigation trough forms.
Various teststacks and stuff:
http://bjoernke.com

Chat with other RunRev developers:
chat.freenode.net:6666 #livecode

alemrantareq
Posts: 203
Joined: Wed Jul 23, 2008 8:46 am

Re: Focus on Option button

Post by alemrantareq » Fri Feb 26, 2010 12:53 pm

The traversalOn property works fine for me, but still I face a problem. After the application open, I press the tab key to select the option btn and then press down arrow to see the dropdown list; but it doesn't show the list until I keep the mouse pointer on this btn. I don't know others faced this problem before or not. I use revolution enterprise 4.0. Pls, get me out of this problem.........

BvG
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 1239
Joined: Sat Apr 08, 2006 1:10 pm
Contact:

Re: Focus on Option button

Post by BvG » Fri Feb 26, 2010 1:50 pm

the rev version is one important information, the other is the os you're tying this on. every os behaves differently, and every os expects different things to happen.

And of course you could always script the behaviour that you want, if it's not the default behaviour of your os. For that you'd need the focusedobject property and the rawkeydown message.
Various teststacks and stuff:
http://bjoernke.com

Chat with other RunRev developers:
chat.freenode.net:6666 #livecode

alemrantareq
Posts: 203
Joined: Wed Jul 23, 2008 8:46 am

Re: Focus on Option button

Post by alemrantareq » Fri Feb 26, 2010 3:50 pm

Hi BvG, thanks for your replying. I've found the main problem. And that is, after the app open, if I click in the empty space of the card, press tab key to focus the btn and then press down arrow key, it works fine. Why it doesn't work after the app open and waits for my clicking? Pls give me clear solution. I'm using win XP sp3.

BvG
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 1239
Joined: Sat Apr 08, 2006 1:10 pm
Contact:

Re: Focus on Option button

Post by BvG » Sat Feb 27, 2010 12:08 am

in that case you can script it yourself, and file a bugreport.
Various teststacks and stuff:
http://bjoernke.com

Chat with other RunRev developers:
chat.freenode.net:6666 #livecode

Post Reply