Page 1 of 1
Let's talk about Scriptable Hotkeys
Posted: 14 May 2007 19:31
by admin
Scriptable hotkeys? ... here are some examples (3 of about 12 (and rising)) directly from the code. Should give you an idea...
Code: Select all
defFunctionSH eF_SH_GoTo, "Go To [...]", _
"Go to specified location"
defFunctionSH eF_SH_Open, "Open [...]", _
"Open specified item."
defFunctionSH eF_SH_OpenWith, "Open With [...]", _
"Open selected item(s) with specified application."
The [...] is the user-configurable part (plus the key combo to trigger it, of course). Maybe "scriptable" is not the best term for it, since it's basically a command with a variable that can be set by the user, like a switch.
The CKS dialog will get an additional input field.
Posted: 14 May 2007 19:52
by serendipity
Wow!! Sounds awesome. hmmm very interesting. [think mode].
Posted: 14 May 2007 20:38
by admin
Just to make sure: of course, you can have any number of instances of any script key type, meaning: 5 different GoTo keys, 12 OpenWith keys etc.
Posted: 14 May 2007 20:40
by admin
FYI, here are the others I compiled so far.
Code: Select all
defFunctionSH eF_SH_Copy, "Copy [...]", _
"Copy specified item to clipboard."
defFunctionSH eF_SH_MoveTo, "Move To [...]", _
"Move selected item(s) to specified location"
defFunctionSH eF_SH_CopyTo, "Copy To [...]", _
"Copy selected item(s) to specified location"
defFunctionSH eF_SH_CopyHere, "Copy [...] Here", _
"Copy the specified item to the current folder."
defFunctionSH eF_SH_CreateNewFolder, "Create New Folder [...]", _
"Create a new folder named as specified in the current folder."
defFunctionSH eF_SH_BackupTo, "Backup To [...]", _
"Backup selected item(s) to specified location"
defFunctionSH eF_SH_RenameBatch, "Batch Rename [...]", _
"Rename selected item(s) based on specified template"
defFunctionSH eF_SH_RenameRegExp, "RegExp Rename [...]", _
"Rename selected item(s) based on specified Regular Expression"
defFunctionSH eF_SH_SelectTab, "Select Tab [...]", _
"Select tab at specified position. Enter '1' for left-most tab, '2' for the next, etc."
defFunctionSH eF_SH_Shell, "Shell [...]", _
"Run specified Shell command"
Posted: 14 May 2007 22:04
by jacky
admin wrote:Just to make sure: of course, you can have any number of instances of any script key type, meaning: 5 different GoTo keys, 12 OpenWith keys etc.
hmm.. will it be possible to have more than one function/command assigned to one key ?
For example, having one "key" to do this:
(RS=Rename Special, I2C=Info to Clipboard)
1/ RS: UrlUnescape
2/ RS: _ to Spaces
3/ RS: RegExp Rename [regexp here]
4/ I2C: Item Names
..would be pretty cool!

Posted: 15 May 2007 00:09
by John Bee
jacky wrote:hmm.. will it be possible to have more than one function/command assigned to one key ?
For example, having one "key" to do this:
(RS=Rename Special, I2C=Info to Clipboard)
1/ RS: UrlUnescape
2/ RS: _ to Spaces
3/ RS: RegExp Rename [regexp here]
4/ I2C: Item Names
..would be pretty cool!

Oh Ya. This would surely bring XY to the next level of Nirvana!

Posted: 15 May 2007 07:13
by admin
jacky wrote:For example, having one "key" to do this:
(RS=Rename Special, I2C=Info to Clipboard)
1/ RS: UrlUnescape
2/ RS: _ to Spaces
3/ RS: RegExp Rename [regexp here]
4/ I2C: Item Names
..would be pretty cool!

Already on the roadmap and called "scriptability".

Those scripts will be stored in the catalog, and then you can assign a KS to the catalog item.
Okay, it will all be the same "scripting language" (which is 90% done in my head), so I could indeed add it right away to the hotkeys. But I rather have one simple thing with a simple interface first, and a more advanced thing later and in another place.
You know, with real free scripting there the problem of syntax errors... lots of checks and validations. However with my "scriptable hotkeys" (a better term is always welcome!) there's no way for the user to do anything wrong. Foolproof, intuitive, quick.

Posted: 06 Jul 2007 07:51
by admin
admin wrote:... However with my "scriptable hotkeys" (a better term is always welcome!) there's no way for the user to do anything wrong. Foolproof, intuitive, quick.

I'll try to get this done before vacation. Need a better term since "scriptable" is just too much for it. All you can do is fill one blank slot with a certain type of information, e.g. fill a path into "Go To [...]".
What about
softkeys !? That would sum up what it is: user-adjustable (=soft) commands that can have keyboard shortcuts.
Posted: 06 Jul 2007 18:23
by jacky
admin wrote:What about softkeys !? That would sum up what it is: user-adjustable (=soft) commands that can have keyboard shortcuts.
I don't know.. doesn't sound quite obvious to me, but that might be me.
Question: will all those "new" commands be added into a new category on CKS interface, eg. a new one after Misc. ?
If so, why not forget about the "key" part and focus about the "customizable" part of the
commands. So more along the lines of "customizable commands"... ?
I think that would make sense, and be more "obvious" as what it is/does.
Plus, such names would also make perfect sense the for other use in the future, like the customizable toolbar buttons

Posted: 06 Jul 2007 18:50
by admin
jacky wrote:admin wrote:What about softkeys !? That would sum up what it is: user-adjustable (=soft) commands that can have keyboard shortcuts.
I don't know.. doesn't sound quite obvious to me, but that might be me.
Question: will all those "new" commands be added into a new category on CKS interface, eg. a new one after Misc. ?
If so, why not forget about the "key" part and focus about the "customizable" part of the
commands. So more along the lines of "customizable commands"... ?
I think that would make sense, and be more "obvious" as what it is/does.
Plus, such names would also make perfect sense the for other use in the future, like the customizable toolbar buttons

"customizable commands"... yes, only that they are a bit hard to trigger without a key -- that's why I wanted the "key" in it. Also they will be stored in ks.dat. From the technical point of view they are key combos with a variable parameter.
But OTOH: we have that new "Close & Trigger" thing, and I'm thinking about adding a new menu (!) in the main window which will make the "customizable commands" reachable via mouse.
"customizable commands" is a bit long, especially for a menu name. What about "Custom commands" or "User commands" and then simply "User" as the menu name (would be located between "Tools" and "Window" I think).
Posted: 06 Jul 2007 19:26
by jacky
admin wrote:"customizable commands"... yes, only that they are a bit hard to trigger without a key -- that's why I wanted the "key" in it.
Yeah... for now
admin wrote:But OTOH: we have that new "Close & Trigger" thing, and I'm thinking about adding a new menu (!) in the main window which will make the "customizable commands" reachable via mouse.
"customizable commands" is a bit long, especially for a menu name. What about "Custom commands" or "User commands" and then simply "User" as the menu name (would be located between "Tools" and "Window" I think).
hmm... only those commands, not the Misc ones too? You could even have under "Tools" itself, (or a new menu "Extras"), two submenus:
- Miscellaneous commands
- Custom commands
Posted: 06 Jul 2007 21:11
by admin
jacky wrote: You could even have under "Tools" itself, (or a new menu "Extras"), two submenus:
- Miscellaneous commands
- Custom commands
Now you're talking!

Posted: 07 Jul 2007 04:58
by j_c_hallgren
If I followed this discussion correctly, I think I agree with new Extra menu, as it appears there may be some new commonds that aren't easily "mouseable", and while I like/use some CKS, there are others that I only use occasionally so having them available via mouse is definitely needed! (Since I'd likley have forgotten what obscure key combo I'd used

)