How can I disable a single key binding such as ctrl-alt-= in Atom?
I'm using the QWERTZ keyboard layout, so that I execute pane:increase-size when I type a '\'.
Open settings with File > Settings
Click Keybindings
Filter the list by typing ctrl-alt-= in the search box.
Click the clipboard icon next to the shortcut. This will copy the shortcut definition to your clipboard.
Click the hyperlinked text your keymap file.
Paste in the contents of the clipboard.
Replace 'pane:increase-size' with the value 'unset!'
Now ctrl-alt-= will not do anything.
EDIT: 'unset!' was previously null, see this atom discussion for details.
EDIT2: To fix issues with many non-QWERTY keyboard layouts, check out the keyboard-localization package for Atom.
Fix from #Monkey worked, here's the code from my keymap.cson for fixing backslash.
'atom-workspace atom-text-editor:not([mini])':
'ctrl-alt-[': 'unset!'
EDIT:
I'm using the QWERTZ keyboard layout.
Related
I develop a package, which allows user to use Home button to toggle cursor position in soft-wrapped lines, as it is in Komodo Edit editor.
In my toggle() function I try to get active text editor from Atom Workspace using getActiveTextEditor function and then I do my logic.
atom.workspace.getActiveTextEditor()
I bind a Home key with a selector atom-text-editor.editor, and it mainly works fine until triggered inside Search&Replace pane or Command Palette.
"atom-text-editor.editor": {
"home": "toggle-home:toggle"
}
In this case, getActiveTextEditor returns always a currently edited file's text editor. It leads to a situation, when a cursor is moved inside an edited file's pane, but not inside focused field. When I use a Home inside a text field in Settings pane, Atom throws an exception, as it can't find any active text editor.
I did a research through Atom Docs, Atom API, even community packages, but all I found, was adding 'mini' to my event selector, to narrow event scope a bit.
"atom-text-editor.editor:not([mini])": {
"home": "toggle-home:toggle"
}
Nevertheless it still causes exception or misbehaviour in text fields without 'mini' (ie. textarea of Git/GitHub package).
What I want to achieve is:
1) to find a proper keybinding selector, that would fire only inside currently edited file pane;
OR
2) to find a method to get focused instance (Search&Replace, Command Palette or any other field) for further processing.
Solution
As DamnedScholar mentioned here:
the selector atom-workspace-axis.vertical atom-pane-container atom-text-editor:not([mini]) will do it.
Already tested, works fine.
Is there a way to mark a cell in the ipython/jupyter notebook readonly using the json format in the ipynb file? (E.g., a cell attribute "readonly":false or some such.) If not, is there a jquery hack to find suppress the double click event in the cell?
#Richard Ackon's answer requires adjustments for JupyterLab:
Open the Property Inspector.
Focus the cell you want to lock.
Add the following lines to the Cell Metadata:
{
"trusted": true,
"editable": false,
"deletable": false
}
Click on the tick to save the metadata... Tadah!, your cell can't be modified or deleted.
The Property Inspector comes built-in since JupyterLab 2.0 (note it was moved to the right sidebar by default in JupyterLab 3.0). For older JupyterLab versions you would need to modify the notebook file manually.
Unfortunately, the outputs can still be cleared by intentionally selecting that option in the menu bar (Edit > Clear Ouputs). Of course that can only happen if you DO WANT to clear the outputs and not just update them by running the cell.
Source
Yes, Use the steps below:
Select view on the menubar
Point to Cell Toolbar and select Edit Metadata
An "Edit Metadata" button will appear at the top-right corner of the cell.
Click on that button and edit the json that pops up. Set the editable key to true or false to get the desired effect.
The JSON will look something like this:
{
"deletable": false,
"editable": false,
"scrolled": true,
"trusted": true
}
There is an extension for IPython that is supposed to that:
Read Only Cell extension.
Getting it to work is something else, but it is there.
Can it be turned off ? If yes: how ?
For instance it keeps changing "refactor" to "refractor".
When i correct it - Xcode changes it back (oO).
Look in System Preferences, Languages and text, Text tab, there is a checkbox for auto-correction.
I used to work with a developer who, selects a text in aspx page and applies a keyboard shortcut to enclose it in double quotes.
Eg: runat=server. when i select server and press ctrl+somekey, it should be runat="server"
Could someone tell me what is the keyboard shortcut, i tried googling a lot, but couldnt find one..
Currently we are overhauling a page, and need this badly...
Thanks in advance.
As far as I know this is a setting in Visual Studio which enables you to immediatelly place quotes when you type attribute and press equals sign or if you type a few letter and press CTRL+Space. This will autocomplete the attribute and place quotes. In order to enable the quotes click on Tools then Options. If it is not checked, check Show all settings. Expand Text Editor, then HTML and click on Formatting. On the right side enable Insert attribute values quote when typing and Insert attribute value quotes when formatting
Format selection: ctrl+k, ctrl+f
I also have Tools > Options > HTML > Formatting > Insert attribute value quotes when formatting checked.
I think you should try this with the replace function
search : runat=server
replace: runat="server"
The developer may have been using a refactoring tool such as CodeRush or Resharper. Have a look at this link for how you may be able to do something similar without extra tools.
The felx builder (on eclipse) next/previous word command, usually bound to CTRL-RIGHTARROW on OPTION-RIGHTARROW on the mac, doesn't stop for ":" and "." and in a few other cases.
It's clearly a wrong behaviour for action script development!
How can I change it?
Here is the fix:
http://www.visible-form.com/blog/mac-eclipse-word-boundary-issue-fix/
"Go to System Preferences > Language & Text > Text, and set the ‘Word Break’ dropdown to ‘English, United States (Computer)’."
Remember Quit Flex Builder and restart it. If this doesn't work, try restarting the OS.
This option is missing in Mavericks… you can fix it with:
defaults write .GlobalPreferences AppleTextBreakLocale en_US_POSIX