Developer forums (C::B DEVELOPMENT STRICTLY!) > Plugins development
Key Macros plugin
dmoore:
a more general alternative would be to write code to convert UI keystrokes to a squirrel script (assuming there are enough hooks in CB to handle most of the UI in a squirrel script)
Pecan:
I think I'm misunderstanding this loop.
Say: Menu hotkey '{' invokes KeyMacro which pushes '{' and '}' onto the keyboard buffer.
'{' could not possibly ever reach the editor even if the plugin turned off further processing. The OS would eat all '{'s attempting to execute the menu entry.
So allowing a user to use a hotkey that is also in the macroText is futile and should not be allowed.
Am I on the right track now?
However, the loop problem still exists. macroA contains command keys that invoke macroB which contains command key that invokes macroA again.
The loop still lives.
Pecan:
--- Quote from: Pecan on December 11, 2006, 08:58:33 pm ---I think I'm misunderstanding this loop.
...
However, the loop problem still exists. macroA contains command keys that invoke macroB which contains command key that invokes macroA again.
The loop still lives.
--- End quote ---
But the macro editor could handle this.
It knows all the hotkeys and has access to every macro's text.
It could then put up a msg like:
*"Hey bozo, this macro causes a loop and the big kahuna banishes plugins that allow that."
Then trash the macro. Not with standing tears, crys of innocents, and threats of death to the programmer.
Pecan:
Under windows, pressing keyboard Alt+0+1+9+1 will produce a '¿' (reversed question mark).
Does this facility work under Xwindows or Linux?
Edit: 4:52 PM
It appears that Alt-0-anything is ok from the windows FireFox side.
But then when I try to enter the same thing from the andLinux Firefox size, nothing happens.
Makes sense. But I thought maybe Xwindows would get a scan code from the keyboard. Alt-0xxx must work from the opsys, not the keyboard.
Am I getting warm?
I hate to delete this code from Linux cbKeyMacs if I'm wrong.
Pecan:
KeyMacs is a Code::Blocks plugin providing the user an ability to group sequences of keystokes as a macro (KeyMac). The KeyMac can be executed by either the main Plugin menu, a menu command key, or the context menu.
KeyMacs editor:
Wiki article:
KeyMacs_plugin
Download cbKeyMacs03.zip
http://savefile.com/files/416395
Installation:
Unzip cbKeyMacs03.zip to a clean folder.
Compile KeyMacs for MSWindows with KeyMacs.cbp. Then copy KeyMacs.dll to ...\trunk\src\devel\share\CodeBlocks\plugins\KeyMacs.dll. Copy KeyMacs.zip to ...\trunk\src\devel\share\CodeBlocks\KeyMacs.zip
Compile KeyMacs for Linux with KeyMacs(unix).cbp. Then copy KeyMacs.dll to .../trunk/src/devel/share/codeclocks/plugins/KeyMacs.dll. Copy KeyMacs.zip to .../trunk/src/devel/share/codeblocks/KeyMacs.zip
Linux users will need the X11 and Xtst development libraries. Ubuntu Synaptic provided the following libraries when I searched for xtst:
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version