Is it possible to enable text wrapping in Intellij Idea JavaDoc tooltip? - intellij-idea

Intellij Idea show horizontal scroll for wide JavaDoc method declaration (preserving original text formatting on new line) in yellow documentation help tooltip while NetBeans IDE wrap both text and declaration to fit tooltip width.
It is annoying instead of just using Up/Down mouse scroll also move horizontal scrollbar to see hidden method arguments.
Note that today IDE practice is to extract JavaDoc from sources package and preserving text formatting by Intellij Idea is not smart, at least inconvenient...

I've submitted this problem to YouTrack, feel free to vote:
IDEA-169414 Method signature is not wrapped in JavaDoc

Related

How to implement a non-intrusive UI element in Intellij editor

I would like to implement something similar to breakpoint or lightbulb notifications in my IntelliJ plugin. Up until now I've been using Inlay which is great but they shift the text next to them. I need something similar that doesn't impact text layout and can still receive user clicks.
It would also be great if I can place such content in the gutter area like real breakpoints.
Unfortunately these things are very hard to search for as the common keywords popup up and cloud the search results.
It seems that what I was looking for are gutter icons: https://intellij-support.jetbrains.com/hc/en-us/community/posts/360000164564-Insert-Gutter-icon

How to make IntelliJ display the Javadoc of autocompletion suggestions?

IntelliJ display Java code auto-completion suggestions in a drop-down menu after pressing CtrlSpace. All other IDEs manage to display the corresponding Javadoc if available. How to get IntelliJ to do that?
How to see JavaDoc in IntelliJ IDEA? refers to displaying it on a mouse hover event whereas I'm missing the Javadoc from code-completion suggestions.
Once you put a dot and the suggestions appear, press F1 (which is the default shortcut for "Quick Documentation" in most keymaps). The documentation for the currently selected method then appears as a card as show in the image. Then you can either use the up/down arrow keys or start typing the method name to select it. The documentation card will reflect accordingly.
You can also click on the pin icon on top right of the documentation card to expand it if required.

Intellij IDEA inline documentation doesn't highlight {#code } blocks as monospace

I use IDEA 2016.3 (but the problem existed in previous versions too):
When I call inline documentation (Ctrl+J on Mac, Ctrl+Q on Win) for Java methods it opens Documentation for window, and it is pretty good formatted according to JavaDoc guides, except {#code XXX} blocks have the same style as normal text. See the attached example for java.util.HashMap#get method and compare it with the reference from Oracle site:
The root of the problem, probably, that the documentation is already monospaced. So, maybe there is a way to highlight the code blocks with a background? Or to make the default documentation text in non-monospaced font?
UPDATE:
the same issue on Windows with Segoe UI default font (non-monospace):
As far as I know the quick documentation window does not have a monospaced font by default in IntelliJ IDEA. To revert the documentation back to a proportional font:
Invoke Find Action... Ctrl/CmdShiftA and type Registry Enter. Disable the documentation.component.editor.font option in the Registry dialog that appears. Be careful with the other configuration options, because it is possible to break your IntelliJ IDEA installation with an incorrect setting.

Multiple "right margins" or guides in PHPStorm

PHPStorm has a vertical line on what they call the "right margin" which is set by default to 120 characters or columns...
Given that PSR standards state There MUST NOT be a hard limit on line length; the soft limit MUST be 120 characters; lines SHOULD be 80 characters or less., it'd be nice if I could get another visual indicator at the 80 character mark...
I'm well aware that it says what line/column you're on in the status bar, but I typically hide most panels (status bar included) while coding.
Therefore, is there a way (feature or plugin) that would allow me to add a 2nd vertical line to indicate the 80th column?
It is not currently possible .. and no plugin comes into my mind.
https://youtrack.jetbrains.com/issue/IDEA-99875 -- star/vote/comment to get notified on progress.
P.S. Considering that this is rather PHP/Python specific (other languages do not care about this) .. I would not expect JB to have it implemented in nearest future...
I suggest the following workaround, it works for me on PhpStorm 9.0:
Open Settings page (usually Ctrl+Alt+S), go to Plugins -> Browse Repositories
Find and install BackgroundImage plugin
Restart IDE, it may output an error, something like "unknown protocol d" - don't worry, go forth
Make an image with height=1px, and width=(desired width of additional margin). Give it, say, white background and paint one rightmost pixel to say, black. I took a screenshot of an editor and cropped it in PS, to avoid annoying search and adjustment of the image width. Every change of background image requires to restart PhpStorm.
Open Settings again, goto Other settings -> BackgroundImage
Set Enabled checkbox, browse your created image, and check the FileSystem radio button
Restart IDE again and change the margin and you will get two margins
The image is left-aligned, so when you resize an editor on x-axis (move the splitter between Editor and Project View or File System View, etc.), the margin will remain truthy.
Some side-effects - it appears also on console window, event log, perhaps somewhere else.
If the plugin doesn't work, check out this page (there said that most JetBrains plugins should work on all products on IntelliJ Platform, and some workaround if they does not): http://www.jetbrains.org/intellij/sdk/docs/basics/getting_started/plugin_compatibility.html
ADDED: Doesn't work with scaling an editor (Ctrl + MouseWheel) - the scale of the image (fake margin), remains the same and the margin becomes not truthy.
In the latest PHPStorm, this is now possible. This would be PHPStorm 2017.3. The instructions on the ticket mentioned in the accepted answer explains it quite well:
Will be available in the next EAP build. You can set it up at
Settings|Editor|Code Style|Visual guides for all languages or on
"Wrapping and Braces" tab for a specific language ("Other" tab for
XML/HTML). You can change the visual indent guide color at
Settings|Editor|Color Scheme|General|Guides|Visual guides. Please
submit separate reports if you find any problems.
I personally found the setting in Settings|Editor|Code Style|PHP|Wrapping and Braces|Visual guides. It should be there for every language.

How to programmatically add Tooltip for InlineEditBox in dojo 1.8

I'm using dojo 1.8.1 and have two inline editors, one for a Textarea, and one for an Editor. I would like to provide flyover tips to help explain how they should be used. Ideally, I'd like to seed the inline editor's textarea / editor with a hint if there is no content, and have this disappear when they click to edit the missing content (the underlines with the writer icon didn't do it for me -- if I can replace that span that would be okay too). However, as a start it would be nice to have a tooltip show when mousing over the entry area.
There is a parameter in the constructor for the InlineEditBox called noValueIndicator where you can put the hint for content when none has been supplied and it disappears when the editor has focus for entry. Too simple -- horses, not zebras...