Home Download Buy Blog Forum Support

How to do key stroke filtering

How to do key stroke filtering

Postby oLinkSW0001 on Thu Jun 10, 2010 7:22 pm

Hello;

Is there a way to have every keystroke be passed to a handler/func/filter first, and if such a handler can't handle it, then keys are passed to a default handler?

An example to help with this question: say I want to record every key, without affecting the default Sublime functionality. One approach would be to have a func that is called first, it saves key strokes to a file and then calls the default entry point for Sublime. // I'm not trying to do this, just using this example to clarify my question.

Regards;
oLinkSW0001
 
Posts: 5
Joined: Thu Jun 03, 2010 6:11 am

Re: How to do key stroke filtering

Postby edanm on Fri Jun 11, 2010 6:38 am

In other words, you want to be able to choose to run the next command in the command list for a specific keystroke?
I.e. if I bind my action to "ctrl+d", I could choose from inside my command to call the "next in line" command for ctrl+d. This would allow you to do what you're asking for.

If so, then I've wanted this functionality a few times, and I think it would make a great addition to the api.
edanm
 
Posts: 131
Joined: Thu Mar 04, 2010 11:05 pm

Re: How to do key stroke filtering

Postby jps on Sun Jun 13, 2010 4:44 am

There isn't a way to intercept all keystrokes, no
jps
Site Admin
 
Posts: 3067
Joined: Wed Mar 19, 2008 12:33 pm

Re: How to do key stroke filtering

Postby oLinkSW0001 on Mon Jun 14, 2010 9:58 pm

ok, thanks.
oLinkSW0001
 
Posts: 5
Joined: Thu Jun 03, 2010 6:11 am


Return to Technical Support

Who is online

Users browsing this forum: Exabot [Bot], Yahoo [Bot] and 33 guests