keymapping

Atom/Sublime like Multiple selections in Jupyter

前提是你 提交于 2019-12-21 07:38:50
问题 How can I select matching keywords in a Jupyter notebook via a keyboard shortcut? For example, in the Atom/Sublime editor I can hit cmd + D on a mac (or Ctrl + d on Windows) while the cursor is over 'var' and each time I do that the next 'var' will be highlighted. I can then type the new variable name and 'var' is replaced with whatever I typed. var = "hello" print(var) print(var) Is there an equivalent in a Jupyter notebook? 回答1: Add custom.js to C:\Users\username\.jupyter\custom # for

Does IntelliJ have a `Ctrl` + `K`,`Ctrl` + `D` Sublime equivalent? How do I skip a match when using Alt+J for multiple selections in Android Studio?

丶灬走出姿态 提交于 2019-12-21 06:46:58
问题 I want to have the 'Ctrl'+'K','Ctrl'+'D' functionality of Sublime in Android Studio, how do I do it? Perfectly similar to this question, but with respect to Android Studio. How do I skip a match when using Ctrl+D for multiple selections in Sublime Text 2? I use Ctrl+D to add to selection (discrete multiple select) the next occurrence of the string (or substring) highlighted. And to skip adding next immediate selection to selection but the one after it, I use Ctrl+K, Ctrl+D . How do I do the

Change the mapping of F5 on the basis of specific file type

≯℡__Kan透↙ 提交于 2019-12-21 02:41:18
问题 The current mapping of my F5 key is: imap <F5> <esc>:w\|!python %<CR> Now I want that if I'm editing any python file (it will be better if it also recognizes file other than standard .py format like .pyd etc) then this mapping works as it is. But, if I edit a Java file it is mapped to something like: imap <F5> <esc>:w\|!javac %<CR> And when I'm editing any .c or .cpp file then F5 is mapped to this: imap <F5> <esc>:w\|!make %<CR> I have no idea how to proceed. 回答1: There are problems with both

Insert a newline without entering in insert mode, vim

匆匆过客 提交于 2019-12-20 09:33:26
问题 I want insert newlines in normal mode in vim using Shift-Enter and Ctrl-Enter . I try some solutions and mixing solutions from Vim Wikia - Insert newline without entering insert mode but Shift-Enter and Ctrl-Enter didn't respond: " put a new line before or after to this line nnoremap <S-CR> m`o<Esc>`` nnoremap <C-CR> m`O<Esc>`` " reverse J command nnoremap <C-J> vaW<Esc>Bi<CR><Esc>k:s/\s\+$//<CR>$ 回答1: My alternative is using oo (resp. OO ) to insert a new line under (resp. over) the current

How to configure IntelliJ (also Android Studio) redo shortcut to CTRL+Y instead of CTRL+SHIFT+Z?

不羁的心 提交于 2019-12-20 08:11:48
问题 The default IntelliJ / Android Studio "Redo" action shortcut is CTRL + Shift + Z and this is a common problem for Windows users. A bigger problem is CTRL + Y is mapped to the "Delete line" action - and this causes the undo stack to be lost. To solve this issue, how can the "Redo" shortcut be changed to CTRL + Y in IntelliJ? 回答1: Open Settings (press CTRL + ALT + S ) Click Keymap on the left list. There is a combobox that contains keymaps. Select one of them (default means IntelliJ of course.

Advanced Usage of Ranges with Vim Keymappings

南笙酒味 提交于 2019-12-20 05:52:08
问题 I have a mapping in my vimrc that downwardly comments out regions of c code: nmap comc :normal! I//<ESC> Since the 'normal' ex command implicitly converts input such as "Ncomc" to ".,.+N-1 comc", I can range comments downwardly without many keystrokes and without leaving normal mode. This is, however, a very limited subset of what vim ranges can do. If I'm willing to be verbose, I can achieve upward ranging comments like so: .,.-5 normal comc While editing text, I would much prefer to type

What is the “When” and “Command” for ctrl-P panels?

柔情痞子 提交于 2019-12-19 11:30:10
问题 I'm trying to create my own key shortcut to act as the arrow keys in Visual Studio Code. When I hit "ctrl-p" it pops up a window that I can navigate. However, when I use my special keybinding, which I've set as { "key": "alt+i", "command": "cursorUp", "when": "textInputFocus" } it does not move up to the next option like pressing the up arrow does. I'm guessing this is due to having either the wrong command or the wrong "when" for getting the keymap to trigger when that window is open.

multiple “commands” in a single Sublime Text 2 user keymap shortcut

China☆狼群 提交于 2019-12-18 11:53:09
问题 Is there a way to have multiple "commands" associated with one shortcut? I have these two shortcuts. First shortcut makes the window on the left larger than the right one (in a 2 column view) and the next shortcut puts the focus on the first window. I tend to forget one or the other shortcut when coding quickly. { "keys": ["super+alt+left"], "command": "set_layout", "args": { "cols": [0.0, 0.66, 1.0], "rows": [0.0, 1.0], "cells": [[0, 0, 1, 1], [1, 0, 2, 1]] } }, { "keys": ["ctrl+alt+left"],

Visual Studio ReSharper Keymap for IntelliJ IDEA

左心房为你撑大大i 提交于 2019-12-18 10:08:45
问题 I primarily use Visual Studio and ReSharper (R#) for development and have excellent working knowledge of R#. I want to leverage that knowledge in IntelliJ IDEA (with my personal Java adventures) without having to learn the IDEA keymap scheme. IDEA has a Visual Studio keymap but that mainly updates such key bindings as Find (Ctrl + F) and Replace (Ctrl + H) etc. Because Visual Studio doesn't have built-in capabilities like "Inspect This..." etc. (the kinda stuff provided by R#), those IntelliJ

Rebind emacs “C-d” to delete word

泄露秘密 提交于 2019-12-12 13:28:39
问题 I have tried several different ways of doing this, and none have been successful. I want to switch the M-d and C-d functionality (delete word, delete char) respectively while working in c++ files. Can someone please lend me a hand? 回答1: (add-hook 'c-initialization-hook (lambda () (define-key c++-mode-map "\C-d" 'kill-word) (define-key c++-mode-map "\M-d" 'c-electric-delete-forward))) From CC Hooks - CC Mode Manulal: Variable: c-initialization-hook Hook run only once per Emacs session, when CC