How to draw "Find" result bar with keyboard shortcut in Sublime Text? - sublimetext

When you type in ⌘ + F in Sublime Text, you enter the "Find" mode, with the search result bar shows up on the bottom of the screen. However, I would like to return to the original form only with keyboard and not like to do mouseover to the X-mark on the result bar and then tap the x-mark to remove the search bar, which is quite a lot of work.
So is it feasible to return to the pre-search mode only with keyboard? I use Sublime Text 3 on my OS X 10.9.2.

Escape will close the find menu.

Related

Deactivate menu opening when pressing Alt in sublime

I use alt + ijkl as arrow keys to move my cursor when I am coding. However in Sublime text when you press alt, it opens the upper left menu, and it sometimes messes up my shortcuts. Is there any way to deactivate that ? Haven't found it in "preferences -> keybinds"
This is possible, but not in Sublime Text 3; only Sublime Text 4, which introduces the following setting (shown here with default value):
// When false, disables alt-tapping revealing the menu when hidden on Linux
// and Windows. Does not affect auto hiding or toggling the menu through
// the command palette.
"reveal_menu": true,

Is there a way to do multiline editing a-la Visual Studio in Sublime?

Visual Studio allows selecting a vertical piece of text, and then editing it. One has to hold Shift + Alt and move the cursor up-down left-right to make the selection.
I know there is Ctrl + D multi-cursor thing in Sublime, but it's not quite the same.
So is there a way to do the multi-line editing a-la Visual Studio in Sublime?
Move cursor where you want, hold ctrl + shift press ↓ a few times.
Press tab, then ← twice, type "Hello World,",
Press esc to leave multi-line mode.
You also can perform "square selection" using your mouse middle button.
Answer: Standard way: Ctrl + Alt + Cursor (which flips the screen orientation on my laptop). The way that works: Keyboard Column Selection for Sublime Text 2 on Windows

How to turn the blue placement text in Xcode to text?

Is there a way to turn the blue placement text in Xcode to actual text? It is quite tedious to have to type it out when I have a block.
From the caret position you show, doesn't:
Tab then Return
do what you want?
With the blue replacement text selected, hit return.
Press Tab key, when the blue text is selected, press Enter.
Select using tab or mouse click
press Enter or Return
That will insert the text

is there a VisualStudio keyboard shortcut to hide Find Results windw?

After I do a find, I have to use the mouse to hide the Find Results window.
Is there a keyboard shortcut?
Shift+Escape works for me for closing the Find results window.
I figured out how to make hide the find or replace window. here's how:
Dock the find or replace results window
Right-click its title bar, and select "auto hide".
Now, whenever you find or replace, it pops up in its docked position, and shows you the result,
and when you press , it disappears.

Textmate-like Keyboard Navigation for the Command Line?

How do I better navigate the command line? In TextMate, I can do:
CMD + ALT + ARROW to switch tabs
CMD + SHIFT + ARROW to highlight lines of text
ALT + SHIFT + ARROW to highlight words
ALT + ARROW to jump words, etc.
How do I do this kind of stuff in the terminal?
Here's a slightly more complete mapping from Mac text navigation to the default Readline keys:
I set this up in the Keys pane of my iTerm2 preferences, but you should be able to make the same mappings in Terminal.app (Edit: Everything except the first two. Terminal.app only lets you pick from a few different keys)
In MacOS' Terminal app, you can change your keyboard bindings; go to Terminal Preferences (shortcut Cmd + ,) and navigate to the 'Keyboard' tab:
Key => Action
control cursor left => \033b
control cursor right => \033f
etc. You can do the same thing with other emacs-style bindings. As far as switching tabs, that's a System Preferences > Keyboard > Keyboard Shortcuts setting; click 'Application Shortcuts' on the left side, and then click + on the right to add a new shortcut. Use your desired keyboard combo and pair it with the exact menu name, which in Terminal for moving forward/backward through tabs is 'Select Next Tab' and 'Select Previous Tab' (via the Window menu in Terminal), respectively.
Does that help?
This is a pointer for anyone landing here looking for the equivalent tips for iTerm (as opposed to the default terminal).
To do the same in iTerm, go to menu "Bookmarks", "Manage Profiles", "Keyboard profiles", "Global".
Then add all of the shortcuts you see in the other answers here, but instead of sending text "\033..." when creating a mapping, you simply select the action "send character sequence" and the character for the escape sequence!.
"\033b" becomes b
"\033f" becomes f
and so on.
Escape sequence example
Some things can be done by editing the readline bindings (see bind -p / man bash) but for some of the mac keyboard keys you can (or need to?) set extras up in Terminal.app's preferences.
For word navigation try this:
Terminal preferences -> settings -> keyboard
add the following:
option cursor left \033b (escape b) (backwards word)
option cursor right \033f (escape f) (forward word)
option forward delete \033d (escape d) (kill word)
Word boundaries behave a little differently, but it's better than single character or whole line navigation, and doesn't require trading your option key for a meta key and learning a bunch of new key combos.

Resources