Keyboard shortcuts in WPF

One way is to add your shortcut keys to the commands themselves them as InputGestures. Commands are implemented as RoutedCommands. This enables the shortcut keys to work even if they’re not hooked up to any controls. And since menu items understand keyboard gestures, they’ll automatically display your shortcut key in the menu items text, if … Read more

How to switch between terminals in Visual Studio Code?

Go to File → Preferences → Keyboard Shortcuts or just press Ctrl + k + Ctrl + s. Then click the icon in upper right corner, it opens keybindings.json file: Try adding the following two entries to this file: { “key”: “ctrl+pagedown”, “command”: “workbench.action.terminal.focusNext”, “when”: “terminalFocus” }, { “key”: “ctrl+pageup”, “command”: “workbench.action.terminal.focusPrevious”, “when”: “terminalFocus” } … Read more

Any way (or shortcut) to auto import the classes in IntelliJ IDEA like in Eclipse?

IntelliJ IDEA does not have an action to add imports. Rather it has the ability to do such as you type. If you enable the “Add unambiguous imports on the fly” in Settings > Editor > General > Auto Import, IntelliJ IDEA will add them as you type without the need for any shortcuts. You … Read more

Sublime 3 – Set Key map for function Goto Definition

For anyone else who wants to set Eclipse style goto definition, you need to create .sublime-mousemap file in Sublime User folder. Windows – create Default (Windows).sublime-mousemap in %appdata%\Sublime Text 3\Packages\User Linux – create Default (Linux).sublime-mousemap in ~/.config/sublime-text-3/Packages/User Mac – create Default (OSX).sublime-mousemap in ~/Library/Application Support/Sublime Text 3/Packages/User Now open that file and put the following … Read more

Xcode duplicate line

Go to this folder which contains dark side of the force: Xcode 4.2 or prior: /Developer/Library/PrivateFrameworks/IDEKit.framework/Resources Xcode 4.3 or later: /Applications/Xcode.app/Contents/Frameworks/IDEKit.framework/Resources. Open IDETextKeyBindingSet.plist. Add a new dictionary and a new command item as the screenshot below (name them what you want): That’s: selectLine:, copy:, moveToEndOfLine:, insertNewline:, paste:, deleteBackward: Restart Xcode and go to Preferences – … Read more

Make Visual Studio understand CamelCase when hitting Ctrl and cursor keys

Thanks to those who suggested Resharper. This gives me another reason to love it even more. Just to be specific about where this lives – JetBrains call it CamelHumps (cute) and you can switch it on using the menu: Resharper -> Options -> Environment -> Editor -> Editor Behavior -> Use CamelHumps … in older … Read more

Is there a keyboard shortcut (hotkey) to open Terminal in macOS?

I tested the following procedure under macOS Mojave 10.14.6 (18G3020). Launch Automator. Create a document of type “Quick Action”: (In older versions of macOS, use the “Service” template.) In the new Automator document, add a “Run AppleScript” action. (You can type “run applescript” into the search field at the top of the action list to … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)