git.lucas.co / hou-control
git clone https://git.lucas.co/hou-control.git

commitd7e36de6407cd9c30f226736540fabbac52c983e
parent0a5ce15550
authorLucas Galante <[email protected]>
date2026-04-17 10:07
keycam: allow Shift+k to coexist globally and inside the state for translation

 hc_hotkeys.json                 | 1 +
 python3.11libs/hc/hcbindings.py | 6 ++++++
 2 files changed, 7 insertions(+)

diff --git a/hc_hotkeys.json b/hc_hotkeys.json
index 27e492f..21409b2 100644
--- a/hc_hotkeys.json
+++ b/hc_hotkeys.json
@@ -7,6 +7,7 @@
         "h.hc_session_toggletabs":                "alt+t",
         "h.hc_session_newtabdialog":              "alt+shift+t",
         "h.hc_session_togglemainmenu":            "alt+m",
+        "h.pane.gview.state.obj.keycam.trans_up": "shift+k",
         "h.pane.nexttab":                         "ctrl+tab",
         "h.pane.prevtab":                         "ctrl+shift+tab",
         "h.pane.gview.refplane":                  "shift+g",
diff --git a/python3.11libs/hc/hcbindings.py b/python3.11libs/hc/hcbindings.py
index 3026676..71d5ceb 100644
--- a/python3.11libs/hc/hcbindings.py
+++ b/python3.11libs/hc/hcbindings.py
@@ -47,6 +47,12 @@ class HCBindings:
                 conflict_ctx, conflict_sym = context, entry
             if conflict_sym == symbol:
                 continue
+            
+            # Allow Shift+k to exist globally as the entry point 
+            # even if it is also used inside the keycam state.
+            if conflict_sym == 'h.hc_session_keycam' and symbol.endswith('.trans_up'):
+                continue
+
             ok = hou.hotkeys.removeAssignment(conflict_ctx, conflict_sym, key)
             if ok:
                 print(f"[HCBindings] unbound {key!r} from conflicting {conflict_sym!r}")