Canvas to receive TAB key

Got an idea for enhancing PureBasic? New command(s) you'd like to see?
said
Enthusiast
Enthusiast
Posts: 342
Joined: Thu Apr 14, 2011 6:07 pm

Canvas to receive TAB key

Post by said »

Hi,

Perhaps the times are now for fixing bugs with the new 5.4 ... but it would be really nice to optionally allow canvas gadgets to receive the TAB key (in #PB_EventType_KeyDown for example); Right now pressing a tab over a canvas will move the focus to the next gadget and we have no chance to process tab keys inside the canvas gadget; This is badly needed when using canvas to create custom gadgets with user input

Thanks


Oops! I posted this in the wrong section :!: This is supposed to be in the Features Requests :oops: Can a moderator pls move this to the right section ?
davido
Addict
Addict
Posts: 1890
Joined: Fri Nov 09, 2012 11:04 pm
Location: Uttoxeter, UK

Re: Canvas to receive TAB key

Post by davido »

+1
DE AA EB
Trond
Always Here
Always Here
Posts: 7446
Joined: Mon Sep 22, 2003 6:45 pm
Location: Norway

Re: Canvas to receive TAB key

Post by Trond »

Have you tried AddKeyboardShortcut(Tab) every time the gadget receives keyboard focus, and RemoveKeyboardShortcut(Tab) every time it loses focus?
said
Enthusiast
Enthusiast
Posts: 342
Joined: Thu Apr 14, 2011 6:07 pm

Re: Canvas to receive TAB key

Post by said »

Trond wrote:Have you tried AddKeyboardShortcut(Tab) every time the gadget receives keyboard focus, and RemoveKeyboardShortcut(Tab) every time it loses focus?
Yes this is the only native work around that i could use but the issue is that once you call RemoveKeyboardShortcut(Tab) when exiting the canvas, then the tab key is no longer acting as expected in that window :? :( Would be enough if we can at least restore initial function of the TAB key on exiting the canvas .... i could not find a way on how this can be done :!: If you/anyone have/has an idea, it would be appreciated :D
Trond
Always Here
Always Here
Posts: 7446
Joined: Mon Sep 22, 2003 6:45 pm
Location: Norway

Re: Canvas to receive TAB key

Post by Trond »

That must be a bug. It should be removable.
Post Reply