yes it is. File->Setup, page Application/Key Bindings. Choose the item for which you want to install a shortcut, enter the desired key into the shortcut box right to the item list and hit "Ok".
Can a key be bound to a chain of singlet commands, short of
"macro-izing", by some syntax (like command;command )?
I also recall there was a particular binding which was "hard"
while others were "soft" (user can change). Don't remember
which, why or why I cared at one point. My question (#3)
there is, is that still so or is everything up for grabs.
OK, #4 - is there a facility for saving out and reading back
(onstartup, by klayoutrc?) a customized bindkey definition
file?
Hi Matthias, the "Customize Menu" tool is an awesome feature. Is there an option for switching the type of ruler? Ideally I could assign a different shortcut/hotkey for Ruler, Cross, Box, etc.
Ruler and annotation currently does not have a shortcut setting avaliable in the customize menu page,
but we can always acess the menu items by macro and bind the macro to a hotkey like my previous comment.
For example we use edit_menu.mode_menu.ruler.ruler_template_{i} to set current ruler type (Ruler, Box, measure..., I starts from 1 to customized ruler template counts)
After set and template, call with @toolbar.ruler to trigger measure function.
In following example, the 2nd ruler template is setted as active ruler, in my case is a diagnal measurement, it'll not always be the same accross different machine.
Paset following codes and change the 2 number in last line and bind the macro to keys, repeat this until you got all the template/key~~~~ set.
def activateRuler(i = 1):
menu = pya.Application.instance().main_window().instance().menu()
menu.action(f"edit_menu.mode_menu.ruler.ruler_template_{i}").trigger()
menu.action("@toolbar.ruler").trigger()
activateRuler(2)
# ^
# change this number and bind the script to different hot key
# repeat this to map keys to different ruler type
Instead of triggering a specific action, you can also use the canonical ways - i.e. "set_config" and "switch_mode". This may be a slightly more portable:
Comments
Hi Shirly,
yes it is. File->Setup, page Application/Key Bindings. Choose the item for which you want to install a shortcut, enter the desired key into the shortcut box right to the item list and hit "Ok".
Matthias
"Key Bindings" no longer exists as of 2023, using version 0.28.7

what is the new location?
Hi nmz787_intel

In newer version, the kotkey can be set in customiz menu tab
... and it is called "Customize Menu" now since you can turn off menu entries
I have a question about key-bindings. Maybe two.
"macro-izing", by some syntax (like command;command )?
I also recall there was a particular binding which was "hard"
while others were "soft" (user can change). Don't remember
which, why or why I cared at one point. My question (#3)
there is, is that still so or is everything up for grabs.
OK, #4 - is there a facility for saving out and reading back
(onstartup, by klayoutrc?) a customized bindkey definition
file?
Hi dick_freebird
macro can be bind to hot key throuth macro properties setting page (wrench icon).

key bind can be set at
default key short cut
optionFor change hot key binding using a script that bind to a hot key,
here's an example of saving hot key and load back
Exactly
Thanks @RawrRanger!
Matthias
Hi Matthias, the "Customize Menu" tool is an awesome feature. Is there an option for switching the type of ruler? Ideally I could assign a different shortcut/hotkey for Ruler, Cross, Box, etc.
HI 14darcia,
Ruler and annotation currently does not have a shortcut setting avaliable in the customize menu page,
but we can always acess the menu items by macro and bind the macro to a hotkey like my previous comment.
For example we use
edit_menu.mode_menu.ruler.ruler_template_{i}
to set current ruler type (Ruler, Box, measure..., I starts from 1 to customized ruler template counts)After set and template, call with
@toolbar.ruler
to trigger measure function.In following example, the 2nd ruler template is setted as active ruler, in my case is a diagnal measurement, it'll not always be the same accross different machine.
Paset following codes and change the
2
number in last line and bind the macro to keys, repeat this until you got all the template/key~~~~ set.Very good, thanks @RawRanger!
Instead of triggering a specific action, you can also use the canonical ways - i.e. "set_config" and "switch_mode". This may be a slightly more portable:
Best regards,
Matthias