I'm used to the keyboard shortcut Ctrl DOWN in many editors that will jump the caret (cursor) to the next blank line in the code. This allows for quick navigation of the code.
Perhaps I completely missed it, but the action of "move caret to next blank line" or something like that is not in the Keymap list for the editor.
Do you know if such an option is there, and if not, can you recommend a good way to navigate the code? "Move Caret to Code Block Start" is not very intuitive to me when I'm moving about the code and the simple page-up, page-down are too coarse.
Edit: As #CrazyCoder says, this feature does not appear to be available. I've added a ticket for it on YouTrack. If you are also interested in this feature, please vote it up.
There is no such feature in PhpStorm (and in IntelliJ IDEA platform that it's based on) and surprisingly no one has requested it yet. Feel free to add your feature request.
If you are looking for the list of the most common navigation shortcuts, refer to the Default Keymap Reference that you can open from the Welcome screen, print, fold into a pyramid and put on your desk.
Since the 10/09/2015, there is the functions move caret backward a paragraph and move caret forward a paragraph (source).
Related
I'm looking at various laptops for one to program on while traveling and I found this one: the Asus Flip Chromebook:
It's already hard to find sub-15" laptops with a Del/PgUp/PgDn/End row which I use religiously while coding but most laptops have at least an "Fn" key to acquire most of this functionality from the arrow keys. But this laptop doesn't even have that.
I understand that this laptop is a Chromebook and isn't targeted at programmers but if someone wanted to use a laptop like this for programming, how can an environment and IDE be setup to account for these missing keys?
For example, to to select the current line I type Shift+Home if I'm at the end, Home+Shift+End if I'm below, etc.
What solutions and different workflows are available for this kind of keyboard?
Official Chromebook Shortcuts
It looks like Google may have you covered here, with their list of Chromebook-specific keyboard shortcuts. They do include shortcuts that work as Home, End, Page Up, Down, Delete.
Editor-specific shortcuts
If you're finding these shortcuts aren't working for your purposes, you can also check to see if the specific cloud IDE has keyboard shortcuts available, such as these for Repl.it. You might want to search up to see if there are keyboard shortcuts available for your preferred editor.
Personal Recommendations if the above options don't help
Some combinations I've noticed work:
Alt+left arrow to replace Home
Alt+right arrow to replace End
You can also add in the shift key here to highlight to the beginning and the end of the line respectively.
Page Up and Down are tricky but if you're using them to go to the top of the doc, you can make use of Ctrl+A which highlights everything. Then you can use the arrow keys to go to the left or right of the total selection:
Ctrl+A then left arrow to go to the top
Ctrl+A then right arrow to go to the bottom
If you're wanting to highlight a selection from the current cursor position to the top or bottom, you could try just holding shift and an up or down arrow key.
Note: With any navigation shortcuts you find, you can try to throw in shift when pressing them to also highlight at the same time, though, there will likely be some trial and error.
To use the Home, Page up, Page down, and End functions hold down the Fn key and press the corresponding arrow key.
Combination Function
Fn key with Left arrow Home
Fn key with Up arrow Page up
Fn key with Down arrow Page down
Fn key with Right arrow End
I'm using Kdevelop 5.1.2 on Kubuntu 17.10.
When I move the mouse pointer in the editor to a line of code, there constantly appear huge tool-tips with info I usually do not want to see, hiding the code and making it difficult to move the mouse pointer to the intended code position.
Especially annoying is that when there is a compile error in the line the tool tip will not disappear when I move the mouse pointer away.
Is there a way to switch off this behaviour, i.e. so that no tool tips appear, or at least the delay can be increased?
Unfortunately there is no way to turn off only the tooltips.
You could either:
Go to settings->plugins and uncheck the "code browser".
Open the "code browser" panel and reduce it to minimum dimensions, this way the tooltip content will appear inside the panel, not in the editor.
Eclipse highlights the closing parenthesis when I place my caret after the opening one. Is there a way to change this to highlight the closing parenthesis when I place my cursor before the opening parenthesis instead of after?
I think this is a bug in Eclipse for a couple of reasons:
If you go to Windows -> Preferences -> C/C++ -> Editor and click the ? button in the bottom right corner the help documentation states that if Highlight matching brackets is checked (which it is by default) then When the cursor is beside a bracket, the matching bracket is highlighted. It doesn't say anything about the cursor having to be to the right of the bracket for this to work.
Also, note that the matching bracket is highlighted in Java regardless of whether the cursor (caret) is to the left or right of the opening bracket, and it seems very unlikely that this behavior is deliberately different in Java vs. C/C++.
Feel free to raise a bug report if you agree.
There is an alternative approach which doesn't do exactly what you want, but might be acceptable:
Install the Bracketeer for C/C++ (CDT) plugin: http://marketplace.eclipse.org/content/bracketeer-cc-cdt
Positioning the cursor to the left of a bracket still doesn't work!
However, if you hover over the caret left bracket, or to the left of it, the plugin will highlight the matching closing bracket. Ironically, if you hover to the right of the caret it doesn't work. Here's sample screen shot after hovering to the left of an opening bracket:
Note that this behavior is totally independent of the cursor position. In the screen shot above you can see that the cursor is on line 25.
Bracketeer comes with a lot of configurable options (Windows -> Preferences -> General -> Editors -> Bracketeer -> Bracket Highlighting / Hints), so it might be worth a look:
How do I select multiple instances of text? Such as selecting all the "li" tags by highlighting one and pressing a shortcut to select the next instance and so on.
Thanks
Well, you cannot. I think you're talking about the multiple cursors that are present in Sublime Text 2. But, if your text is aligned, then you can change it using the ALT + CLICK and dragging that.
You can vote for this feature as lena mentions.
UPDATE
This feature is now supported in Webstorm 8. If you press the ALT key and click on a different location, you will get a separate cursor there. Before, you could only drag and create cursors in the same line, however, now you can place your cursor wherever you want to.
Keyboard Shortcut
Ctrl then Ctrl+Arrow Up
Please take a look at this video to learn more.
Now you can do it in WebStorm 8 EAP (and later builds) with Select Next Occurrence (Ctrl+G on Mac and Alt+J on Windows) - See more at: http://blog.jetbrains.com/webstorm/2014/02/webstorm-8-eap-build-134-1361-multiple-selection
You can use this plugin for a similar effect.
http://plugins.jetbrains.com/plugin/7147?pr=idea
I'm looking for a basic text editor or a plugin for an existing editor that can highlight the entire current column or vertical location of the cursor similar to the common option to highlight the entire currently selected row or line.
I think it would be very useful for indented code.
Does anyone know where I can find something like this?
I understand exactly what you're looking for and want it myself. I use Notepad++ (based on Scintilla) but there doesn't seem to be a "highlight current column" option the way they do provide for "highlight current line".
I looked at the plugin architecture and demo plugin package. I whipped up a proof of concept - very basic, surely buggy, that uses the long lines edge column indicator as the "highlight" for current cursor column. Not the best solution since if you're using the edge indicator, you "lose" it.
Source code on GitHub:
https://github.com/vinsworldcom/nppColHighlight
Notepad++
It's based on the Scintilla library which implements exactly that feature you're describing, basically highlighting a rectangular area.
To do so, hold Alt + Left Mouse or Alt + Shift + Arrow Keys to select.
If you still haven't found such an editor, PSPad editor has the feature.
Link: https://www.pspad.com/
Please see the attached screenshot (don't worry about the editor language in my screenshot, English (and several other languages) are also available).
PSPad editor with vertical line showing the current cursor position