I don't know what the hotkey I accidentally clicked, but this Ǧ looking sign appeared on every line of code, and there are grey dots instead of spaces in the code.
How can I get rid of those characters?
Assuming this is SQL Developer, go to Tools->Preferences (or on Mac, find that under the SQL Developer menu). Expand the Code Editor section and click on Display. Untick "Show whitespace characters" (second checkbox in the list).
You can check for defined shortcuts under Preferences, in the Shortcut Keys section. On Mac there isn't one for this, but Windows has it as Control+Shift+W, which will also toggle them off if you don't want to go through the preference pane.
Related
I want to change the key binding set in Xcode 11 some are editable bur some are greyed which I cannot edit, how to unlock it.
Because they are similar to other editable shortcuts thus are treated as something like dependent variables.
In the File Menu section for example, the Close Tab (CMD+W) shortcut is editable. Meanwhile, the similar shortcuts (Close Other Tabs (Option+CMD+W), Close Window (Shift+CMD+W), Close Other Windows (Control+Option+CMD+W), Close All Windows (Option+Shift+CMD+W)) are not editable (greyed).
But when I change Close Tab from (CMD+W) to (CMD+M), the W in the keys of all those similar shortcuts will be changed accordingly to M.
You can verify this on your computer.
To be clear, you cannot edit key bindings that are grayed out. They are generated based on the preceding setting. For example, if the preceding settings is ⌘2 then the grayed out setting below may add ⌥ to become ⌘⌥2.
If you're astonished at how poor this design is, then rest assured that your understanding is correct.
As a workaround, I use BetterTouchTool to remap my shortcuts. For example to "close other tabs" I remap ⌘⇧W (my preferred shortcut) to ⌥⌘W (Xcode's default) and have it only apply to the Xcode app.
A recent update to Visual Studio has introduced a new or updated shortcut key that on my non-English keyboard allowed me to create closing curly braces (AltGr+shift+*). This shortcut still works as expected outside of VS (e.g. in notepad) but in VS it is now associated to some text selection command (like select text from the cursor position to the bottom of the file).
How can I find the offending shortcut key command among the hundreds in VS? I remembered the existence of a VS add-in that allowed printing out all currently set shortcut keys to attempt generating a list I could quickly search through but I failed at finding it.
This has been driving me crazy for the last week. I tried to disable ReSharper, to reset the keybindings, to repair Visual Studio, all to no avail, I haven't been able to type closing curly braces since then. It never occurred to me that a new shortcut could have been introduced hijacking the keypress until reading your question.
To check if there's a rogue shortcut hijacking your keypresses, open the keyboard options screen using the Tools → Options → Environment → Keyboard menus and click inside the "Press shortcut keys" field (it doesn't matter which command is selected):
Then press the affected keys combination, the combination will appear in the "Press shortcut keys" field and the associated commands - if any is - will be listed in the "Shortcut currently used by" drop-down:
To remove the shortcuts you need to search for every entry listed in the drop-down by typing the command name in the "Show command containing" field, selecting the entry in the filtered list, and removing every entry listed in the "Shortcuts for the selected commands" drop-down by clicking the "Remove" button.
A recent update to Visual Studio has introduced a new or updated shortcut key that on my non-English keyboard allowed me to create closing curly braces (AltGr+shift+*). This shortcut still works as expected outside of VS (e.g. in notepad) but in VS it is now associated to some text selection command (like select text from the cursor position to the bottom of the file).
How can I find the offending shortcut key command among the hundreds in VS? I remembered the existence of a VS add-in that allowed printing out all currently set shortcut keys to attempt generating a list I could quickly search through but I failed at finding it.
This has been driving me crazy for the last week. I tried to disable ReSharper, to reset the keybindings, to repair Visual Studio, all to no avail, I haven't been able to type closing curly braces since then. It never occurred to me that a new shortcut could have been introduced hijacking the keypress until reading your question.
To check if there's a rogue shortcut hijacking your keypresses, open the keyboard options screen using the Tools → Options → Environment → Keyboard menus and click inside the "Press shortcut keys" field (it doesn't matter which command is selected):
Then press the affected keys combination, the combination will appear in the "Press shortcut keys" field and the associated commands - if any is - will be listed in the "Shortcut currently used by" drop-down:
To remove the shortcuts you need to search for every entry listed in the drop-down by typing the command name in the "Show command containing" field, selecting the entry in the filtered list, and removing every entry listed in the "Shortcuts for the selected commands" drop-down by clicking the "Remove" button.
I am using a notebook without a mouse.
After typing prop and pressing tab, Visual Studio will automatically give me a property template. Pressing tab will move the cursor between type and propertyname placeholders.
I want to move the cursor to a new line after completing the property template.
Is there a shortcut to do so?
Press the Enter key twice.
I tried to post this answer 3 times before I left the comment. It wouldn't let me, too short. That's why I'm typing this otherwise useless verbiage.
It's not specific to snippets, but you can press Ctrl+Shift+Enter to start a new line below where the cursor currently is.
To insert a new line above where the cursor currently is, use Ctrl+Enter.
Both of these work anywhere in the editor. Both of these are handy because they work no matter where you are horizontally on your current line.
Update: Productivity PowerTools for VS2010 (Woot! 2012 too) provides the keyboard shortcut Tools.AddEndTokenAtEnd. (Thanks Ben.)
For some reason, magically, my VS2010 does this with Shift-Enter (which I prefer from my experience with TextMate.) Looking at my keyboard bindings (Tools > Customize > Keyboard) I see that this shortcut is assigned to the command Tools.AddEndTokenAtTheEnd. So if that command appears in your list of commands, assigning a keyboard shortcut to it should work. I have Productivity Power Tools, PowerCommands for Visual Studio 2010, and ReSharper installed. But I can't find any setting from the first two that would be responsible, and, in my experience, all of ReSharper's commands contain its name, so I don't think it added the command. Ooo, and I just discovered that the reason it is named that is because the command also ensures there's a semicolon at the end of the initial line before moving the cursor down; just like the useful keyboard shortcut in Textmate.
I'm interested, but baffled by the 2x-Enter solution. When I press enter twice I get two line breaks followed by whatever code was after the cursor on the first line. Can anyone explain how that shortcut/key-combination works? Is it time-sensitive so that the two enters must be pressed in rapid succession? What if the user wants to quickly insert some lines above some code and hits Return multiple times!?
Ok, maybe they're system shortcuts. I've googled (just a bit) and couldn't find an answer. Maybe there isn't any :) Still..
I love keyboard and I use quite a few in TextMate but just realise I still use the mouse for 2 of the most common actions:
How do I press search and replace after the S/R dialog box is up? - if you press enter it just takes you to the next occurrence of the search string
when I close a file that I don't want to save, how can I choose don't save without touching the mouse?
To select Don't Save from the keyboard, you can use the keyboard shortcut ⌘+D. (This works in most OS X apps, not just TextMate.)
The search and replace (actually it's called "Replace & Find") shortcut is alt-cmd-f and works both inside the Find dialog and without it. With using other shortcuts like cmd-f, shift-cmd-f, cmd-G you can perform most of the search/replace actions without even opening the dialog. For example, if you want to perform the substitution, you press alt-cmd-f, then another is highlighted and if you want to skip it, it's cmd-G, which finds yet another, and so on.
As for the second question, I think it's a general Mac OS X issue -- the message boxes buttons don't have keyboard shortcuts in other apps, too. When I first switched from Windows, this annoyed me but I got used to it by now.
I recently built a web site to store lists of shortcut keys and there is a great list of TextMate Shortcut Keys for Mac on there.
If you know any more you can add them yourself too!
Here's the link http://shortcutkeys.org/software-shortcuts/mac/textmate
If you want to choose the answer for any dialog with the keyboard, go to "System Preferences" > "Keyboard" > "Keyboard Shortcuts". On the bottom of that page there are two radio buttons. Activate "All controls". Now you can switch options of a dialog box with the tab key in every proper OS X application. Note that this is a secondary option, thus you can hit the enter key for the default behaviour or space to trigger your secondary option. Most often it's set to the opposite of the default behaviour, i.e. "Don't save" in a file save dialog and "no" or "cancel" in many many other applications.
I think thats a great feature. Due to the secondary option I always hit either enter or space, depending which option I wanted.