Code::Blocks
September 02, 2010, 09:53:09 pm *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: New release 10.05 is ready. Grab it while it's hot!!!
 
   Home   Help Search Login Register  :: WebsiteWiki  
Pages: [1]
  Send this topic  |  Print  
Author Topic: Keyboard Macros plugin  (Read 2536 times)
LonelySTar
Advanced newcomer
*
Posts: 30


« on: October 06, 2007, 12:13:58 am »

Hello,

I wrote a plugin for C::B to record and playback Keyboard Macros. I tried the KeyMacs plugin but it did not fullfill my needs.
But my plugin only works under Linux/X11 with the record extension enabled.

What the plugin can do, and I was missing in KeyMacs:
- The AltGr key is recorded (I believe US Keyboard do not have this key, but my german keyboard has).
- Using dialogs like the find dialog can be done in a macro.
- It does not wait for you to release all keys before playback.
- A key macro can be bound to a char event. I for Example like to have the courser movements bound to the emacs shortcuts. If I press Ctrl+f, the courser moves to the right. If you would bind this macro to a normal keybinding, the movement is not repeated when holding down Ctrl+f.

What the plugin can not do:
- Does only work under Linux/X11
- You can not edit a recorded macro

I do not know if people are interested in this plugin and did not create a wiki entry for it.
I use the record extension for recording key events and XSendEvent for playback.
If people are interested, I would look into porting this to windows.
Anyone knows what a good way of recording and playing key events under windows?

How to enabled the record extensions:
Add this to the "Module" section of  your X config file:
Code:
     Load         "record"

Link to download the plugin: http://www.savefile.com/files/1103151

Greetings,
Nathan
Logged
kfmfe04
Advanced newcomer
*
Posts: 27


« Reply #1 on: June 27, 2009, 09:57:04 am »

The link appears to be broken...   Sad

I'm actually looking for any solutions which will allow me to edit using the keyboard-only (no mouse).  Specifically, rather than arrow keys, I need to map directions to other keys like emacs-bindings, so I don't need to take my fingers off home row. 

I tried the Keyboard Shortcuts plug-in, but that only seems to map to pre-existing menu items...

Any suggestions would be greatly appreciated.

- Ken
« Last Edit: June 27, 2009, 10:04:55 am by kfmfe04 » Logged
LonelySTar
Advanced newcomer
*
Posts: 30


« Reply #2 on: June 27, 2009, 11:10:47 am »

The link appears to be broken...   Sad

I'm actually looking for any solutions which will allow me to edit using the keyboard-only (no mouse).  Specifically, rather than arrow keys, I need to map directions to other keys like emacs-bindings, so I don't need to take my fingers off home row. 

I tried the Keyboard Shortcuts plug-in, but that only seems to map to pre-existing menu items...

Any suggestions would be greatly appreciated.

- Ken


Well, that  was a long time ago.
I had the same needs as you (I wanted emacs keybindings). The KeyboardMacros where a good Idea, but it did not really work as I remember. I gave up on codeblocks for that reason.

Here is the old project: http://lonely-star.org/KeyboardMacros.tar.gz
I don't know, if it is any use, but you can try.

Regards,
Nathan

Logged
kfmfe04
Advanced newcomer
*
Posts: 27


« Reply #3 on: June 27, 2009, 12:14:45 pm »

Thanks, I will take a look.

Too bad they didn't just add the following to MenuBar>Edit>Special commands>Movement:

Character left
Character right
Line up
Line down

That's all I need - it's probably a 5 minute change in the code for someone who knows that chunk...

BTW, what environment/IDE do you use instead?  Emacs?  XEmacs?  Or something else?

- K
Logged
LonelySTar
Advanced newcomer
*
Posts: 30


« Reply #4 on: June 27, 2009, 12:18:57 pm »

BTW, what environment/IDE do you use instead?  Emacs?  XEmacs?  Or something else?

- K


emacs, together with cedet. It's doing OK. But sometimes I miss the features of a real IDE like C::B ...
Logged
Pages: [1]
  Send this topic  |  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC Valid XHTML 1.0! Valid CSS!