Sublime Forum

Hide sidebar command not working?

#1

In 2175, I just tried to hide the sidebar (something I have done in the past) with command-K, command-B.

I get “no build system” dialog. I can hide and show it from the menu though. Why is this?

0 Likes

#2

Well, because those hotkeys are bound to different commands (command-B is to build the current file, which gave you the “no build system” dialog you saw).

What I did was go to Preferences -> Key Bindings - User, and set my hotkey, something like this:

{ "keys": "ctrl+\\"], "command": "toggle_side_bar" }

]

0 Likes

#3

It works by default, check you don’t have anything bound to Cmd+K

0 Likes

#4

This doesn’t seem to work for me either. I get the same message regarding the build system. If I look in Preferences > Key Bindings > Default (I haven’t touched anything in here, I use the User file) I see the following mappings which are related to the same keystrokes:

//Line 17
{ “keys”: “super+k”, “super+b”], “command”: “toggle_side_bar” },

// Line 230
{ “keys”: “super+b”], “command”: “build” },

// Lines 509 - 515
{ “keys”: “super+k”, “super+u”], “command”: “upper_case” },
{ “keys”: “super+k”, “super+l”], “command”: “lower_case” },
{ “keys”: “super+k”, “super+space”], “command”: “set_mark” },
{ “keys”: “super+k”, “super+a”], “command”: “select_to_mark” },
{ “keys”: “super+k”, “super+w”], “command”: “delete_to_mark” },
{ “keys”: “super+k”, “super+x”], “command”: “swap_with_mark” },
{ “keys”: “super+k”, “super+g”], “command”: “clear_bookmarks”, “args”: {“name”: “mark”} },

These look like they clash. Is this what everyone else has in their Default Key Bindings? If so why are their clashing commands?

0 Likes

#5

Yeah I am seeing this too, it’s weird… so many super+k bindings by default. Surely this can’t be right? As a (brand new) user of SublimeText, I would prefer to learn the default keybindings, rather than set up custom ones. But obviously the default keybindings are broken on mac! Anyone able to look into this for us?

0 Likes

#6

The default key bindings are not broken.

A key binding like “super+k”, “super+b”] specifies a key sequence.
So you’d press Super+K, release the keys, then press Super+B to hide the sidebar.
Key sequences are a very common thing that both Emacs and Microsoft Visual Studio make heavy use of.

The key sequence implementation in Sublime Text has a certain timeout.
If you press Super+K, wait 3 seconds, then press Super+B, it will not recognize the
sequence but invoke the key binding for Build, which is bound to Super+B alone.

1 Like