I've been starting to mess around with PowerPro (http://www.windowspowerpro.com) the free and *very* powerful shell add-on.
Would it be possible to write a ppro addin for Console that could provide access to Console functions? Things like copy, paste, select config, change background image(?), reload settings, etc.
My idea is this - provide that addin and then you could configure a PPro bar that would appear on (or around) your Console windows and could then provide buttons to access those functions, and the bar and buttons could then be skinned. (Which could be cool - and you wouldn't have to add skinning support to Console.)
You could have a row of buttons along the top to show/hide console, edit config, exit. Buttons for each configuration XML you want to switch between.
Only problem I can see is in the proposed addin code itself - how to determine which console window to use? Console would need some kind of IPC (COM object perhaps). Or the addin could send specific windows messages to all console windows - and only those configured to listen would be affected (add another attribute "listen to IPC commands").
With that code, you could also make a command-line tool to issue those same windows messages (or whatever IPC method is chosen) and then you could write batch files (and more) to control the Console windows. And that might provide a way to integrate with other shells like Litestep.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I don't think writing a PP plugin is necessary. You could use PP's window.sendmessage command to send WM_COMMAND messages to Console to emulate popup menu selections (I can document the parameters for WM_COMMAND)
You can also make a PP bar that will stick to a specified window (PP has that feature if I remember correctly)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
WM_COMMAND handler already exists, since menu commands send WM_COMMAND messages. A nice side-effect is that you have an external interface :)
I will document WM_COMMAND parameters in the readme file. Until then, try this:
*Window SendMessage WM_COMMAND 40004 0 <Console window title in quotes>
This command will reload the settings for the specified Console window.
These are commands currently defined:
ID_ABOUT 40001
ID_HIDE_CONSOLE 40002
ID_EXIT_CONSOLE 40003
ID_RELOAD_SETTINGS 40004
ID_EDIT_CONFIG_FILE 40005
ID_COPY 40006
ID_PASTE 40007
ID_TOGGLE_ONTOP 40008
ID_SEL_CONFIG_FILE 40009
ID_SHOW_README_FILE 40011
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Great! Now I can get busy getting PPro to control Console. (I already have it so I can hit Ctrl-D and have PPro send "exit<enter>" - nothing difficult, but now when I automatically hit Ctrl-D like I'm used to doing to close a console window, it will!)
- hmm, for the ID_SEL_CONFIG_FILE, it'd be nice if there were a parameter/flag that could be passed to it to say "don't prompt for reload". That way if I make a button or keystroke in PPro to tell console to switch to configuration X, it won't pop up the dialog (yes, that I asked for :-) and then PPro can send the ID_RELOAD_SETTINGS message to do the reload all in one command.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
...and now I have a bar with buttons to edit the xml, show about... all the commands, and even to launch IE straight into sourceforge.net/console to enter more comments and ideas!
Did notice that if I have multiple console windows open, each responds to the message (unfortunately I can't see a way around that at the moment).
Post a shot of my console window with the bar in action:
<http://users.adelphia.net/~rob.davenport/console-withbar.jpg> (warning it's 174K, the bar's sort of small so I left the shot big).
Rob
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I've been starting to mess around with PowerPro (http://www.windowspowerpro.com) the free and *very* powerful shell add-on.
Would it be possible to write a ppro addin for Console that could provide access to Console functions? Things like copy, paste, select config, change background image(?), reload settings, etc.
My idea is this - provide that addin and then you could configure a PPro bar that would appear on (or around) your Console windows and could then provide buttons to access those functions, and the bar and buttons could then be skinned. (Which could be cool - and you wouldn't have to add skinning support to Console.)
You could have a row of buttons along the top to show/hide console, edit config, exit. Buttons for each configuration XML you want to switch between.
Only problem I can see is in the proposed addin code itself - how to determine which console window to use? Console would need some kind of IPC (COM object perhaps). Or the addin could send specific windows messages to all console windows - and only those configured to listen would be affected (add another attribute "listen to IPC commands").
With that code, you could also make a command-line tool to issue those same windows messages (or whatever IPC method is chosen) and then you could write batch files (and more) to control the Console windows. And that might provide a way to integrate with other shells like Litestep.
I'm a long time PPro user myself :-)
I don't think writing a PP plugin is necessary. You could use PP's window.sendmessage command to send WM_COMMAND messages to Console to emulate popup menu selections (I can document the parameters for WM_COMMAND)
You can also make a PP bar that will stick to a specified window (PP has that feature if I remember correctly)
(You turned me on to PPro, and I like you sysmeter skin, Marko!)
So you'll think about adding WM_COMMAND handlers for Console functions?
That'll force me to learn more about PPro scripting to implement the integration. If I get it working, I'll post it.
And I've tried the PPro bar tied to a window - works pretty well.
WM_COMMAND handler already exists, since menu commands send WM_COMMAND messages. A nice side-effect is that you have an external interface :)
I will document WM_COMMAND parameters in the readme file. Until then, try this:
*Window SendMessage WM_COMMAND 40004 0 <Console window title in quotes>
This command will reload the settings for the specified Console window.
These are commands currently defined:
ID_ABOUT 40001
ID_HIDE_CONSOLE 40002
ID_EXIT_CONSOLE 40003
ID_RELOAD_SETTINGS 40004
ID_EDIT_CONFIG_FILE 40005
ID_COPY 40006
ID_PASTE 40007
ID_TOGGLE_ONTOP 40008
ID_SEL_CONFIG_FILE 40009
ID_SHOW_README_FILE 40011
(D'oh! Forgot that the messages already exist.)
Great! Now I can get busy getting PPro to control Console. (I already have it so I can hit Ctrl-D and have PPro send "exit<enter>" - nothing difficult, but now when I automatically hit Ctrl-D like I'm used to doing to close a console window, it will!)
- hmm, for the ID_SEL_CONFIG_FILE, it'd be nice if there were a parameter/flag that could be passed to it to say "don't prompt for reload". That way if I make a button or keystroke in PPro to tell console to switch to configuration X, it won't pop up the dialog (yes, that I asked for :-) and then PPro can send the ID_RELOAD_SETTINGS message to do the reload all in one command.
I have added a new command-line and config file options for controlling new config autoload (yes, no, prompt)
Check out the latest build.
Very nice - now I can switch and reload quickly or prompt if needed. Thanks!
Woot! I now have a bar with two buttons - one that sends the edit xml command and one that sends the about command, and they work!
Way cool! Thanks for the help!
Rob
...and now I have a bar with buttons to edit the xml, show about... all the commands, and even to launch IE straight into sourceforge.net/console to enter more comments and ideas!
Did notice that if I have multiple console windows open, each responds to the message (unfortunately I can't see a way around that at the moment).
Post a shot of my console window with the bar in action:
<http://users.adelphia.net/~rob.davenport/console-withbar.jpg> (warning it's 174K, the bar's sort of small so I left the shot big).
Rob