Skip to content

Instantly share code, notes, and snippets.

@twidi
Created August 9, 2012 14:59
Show Gist options
  • Save twidi/3304937 to your computer and use it in GitHub Desktop.
Save twidi/3304937 to your computer and use it in GitHub Desktop.
One key to toggle sidebar AND miniap in sublime-text-2
A simple way to toggle the display of the sidebar AND the minimap, with only one key binding.
Put "toggle_sidebar_and_minimap.py" in ~/.config/sublime-text-2/Packages/
and the content of "keymap" in your "Key bindings - User" file.
{ "keys": ["f2"], "command": "toggle_sidebar_and_minimap" }
import sublime, sublime_plugin
class ToggleSidebarAndMinimapCommand(sublime_plugin.WindowCommand):
def run(self):
self.window.run_command("toggle_side_bar")
self.window.run_command("toggle_minimap")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment