I'm testing out Aptana Studio to do some javascript development I want to know if there is a shortcut to delete a whole line. Or if there is a way to create some kind of macro to do it.
I am running windows, and I know that I can click Ctrl+Shift+Del but that doesn't actually do what I want it to do. In VS when you click Shift+Del it doesn't matter where the cursor is on the line it will delete the whole line.
To do the same in Aptana I need to:
Click Home to get me to the beginning of the line
Click Ctrl+Shift+Del to delete the content of the line
Click Ctrl+Shift+Del to delete the line
This may seem small, but I do this action all the time in VS and I've grown accustomed to it.
Anyone have any ideas to help me out?
I just figured it out:
It's quite simple: Ctrl+D
Also if you want to change the key binding you can
Go to menu Window -> Preferences
Go to General -> Keys
Find Command 'Delete Line' and then bind it to your desired key combo(like Shift+Delete)
Related
One of the more annoying aspects of IntelliJ for me is how the default way to delete a portion of text I highlight with my mouse is to press shift+delete, rather than simply delete. I'm aware that I can go to Preferences --> Keymap to customize controls like this, but I'm not sure exactly which function to change and how to set it to the delete key.
I'm using the 2016.1.3 Community Edition for OS X.
I figured out what was going on — I had rather absentmindedly installed the IdeaVIM plugin, which adds weird (vim-like) keybindings, one of which is that you need to press shift+delete to delete a highlighted portion.
I'm big on not using the mouse, especially while writing code. I've noticed in IntelliJ IDEA 2016.1 that when I'm navigating in the project window, hitting Enter while a particular file is selected opens the file in an editor, but it doesn't place the cursor in the editor. Interestingly, if I double-click on the file in the project window, the cursor is placed in the editor.
How do I configure IntelliJ to place the cursor in the editor after opening the file via Enter from the project window?
To the best of my knowledge, I do not believe there is a way to configure what you are looking for. A search for focus in the settings didn't turn up anything.
That said, hitting Esc when in the project view will return you to the editor. So you would need to do Enter, Esc. If having to type two keys in a row bothers you, you could always record a macro (Edit > Macros) to do that key sequence and map it to a shortcut.
In IntelliJ IDEA, one of the more helpful commands I've found is 'Shift-Enter' - it effectively moves the cursor to the end of the line, and starts a new line, thus not affecting the text on the current line.
I'd like to re-create this in Atom, but I can't seem to figure out how one would go about doing so. It doesn't look like you can have multiple editor actions for a given key combination, and I'm not sure if I simply can't find the esoteric editor command I'm looking for.
How can I recreate the behavior of shift-enter in IntelliJ for Atom?
As it so happens, I stumbled across the shortcut: You can use cmd-enter to do the same action. I'm not sure what the underlying command is, but I hope this is helpful to other people!
You can recreate this behaviour by adding this to your keymap:
'atom-workspace atom-text-editor:not([mini])':
'shift-enter': 'editor:newline-below'
Detailed answer;
Freshly open atom editor
Open Keymap option
Copy this and paste this;
'atom-workspace atom-text-editor:not([mini])':
'shift-enter': 'editor:newline-below'
Click save and close the file
Press Shift and enter, Now you'll be able to form a new line below the line you currently in are regardless of the place you are typing in.
what are shotcut keys in vs2012 ,which to copy a line of code then move down or up,and cut a line of code then move down or up??
the copy version:
printf("hello world");// press a shotcut key ,then ..
printf("hello world");// this line of code automaticly appear here.
the cut version:
printf("hello you");//press a shotcut key ,then this line **will be cut**,and then ..
printf("hello you");//this line of code automaticly appear here.
is there any shotcut key exists likes them?
Shift-Alt-T moves the line with the cursor down one line, I'm still trying to figure out how to move it up.
So after a little bit of googling it doesn't seem that VS has a keyboard shortcut to move a line up, which is quite baffling since the do have the above mentioned shortcut to move a line down. Anyway, you're definitely not the only one who wants this functionality and there are a few suggestions to this.
Either install this extension (free):
MoveLine extension
Or you could install ReSharper which is really, really nice in my opinion:
ReSharper
You should try this explanation below:
http://www.herrodius.com/blog/52
The Visual Studio Productivity Power Tools extension adds support for this. It's the "Move Line Up/Down Commands" feature.
With this feature enabled Alt+↑ and Alt+↓ move the current line (or multi-line selection) up or down.
Usually the first thing I do when set up visual studio is install this extension, then turn off all the other rubbish it adds (weird document tabs, scrollbar etc) just for the move up and down
I'm Using resharper 6 nighty builds and VB.net. I've a big medium project with multiple files that don't follow the code style conventions of my company.
I've configured resharper with my own convenctions and It suggest to me the right name for each variable (perfect!).
But I can't find any automagic way to make the current name to be replaced with the suggested name.
Are there any way to do it? If not ... did you know ane fearure of coderush Xpress to achieve it?
Thanks.
If you've configured ReSharper with your naming conventions, then it should show a warning (blue squiggly underline) under any identifiers that don't comply. If you put the text cursor on one of those misnamed identifiers, you should see a pyramid icon appear near the left margin. Then you can press Alt+Enter (or click the pyramid icon) to drop down a quick-fix menu. There should be an option in the menu to "Rename to '_myField'". Usually it's the first item in the list, so you can just press Enter again to do the rename.
If you want to do this on everything in a source file, you can use the ReSharper > Inspect > Next Issue in File command (or its keyboard shortcut -- F12 in the IDEA keymap) to move the cursor to the next warning in the file. Then, if it's another name warning, you can use Alt+Enter, Enter again to fix it.
Unfortunately, there isn't a way to automatically fix every instance of a warning at once (though it's been requested; please feel free to vote for RSRP-126551 in their issue tracker).