Usually, IntelliJ displays a special globe icon with actions for URL when a request handling method is declared, as shown in this pic.
But below my intellij doesn't show the 'Actions for URL' toolbox for some reason, and I don't see any special icon either. Does anyone know why? Thanks!
I'm also following the same tutorial and researched about it. It seems like that you are also using Community Edition. That feature only exists in the Ultimate edition of IntelliJ.
Integrated developer tools comparison
Source:
https://www.jetbrains.com/products/compare/?product=idea&product=idea-ce
Suppose you're using the Ultimate version and you don't have a globe icon. In that case, You can disable the icon under Settings/Preferences -> Editor -> -> Inlay Hints -> Java: check the 'Show hints' box for the 'URL path inlay' option.
Also note that the globe icons is now different from the IntelliJ IDEA image you shared. See screen shot below:
The icon is now on the left, next to the line number of the method header.
I hope this helps.
Related
I am using IntelliJ Ide 2021.3 (ultimate edition) to learn spring boot. My issue is that the color scheme for all code "except keywords" appears grayed out by using the default text color. despite checking and unchecking all the inherit values from "checkbox" in language defaults and in java and changing the color scheme and editor theme multiple times this issue persists. What's confusing is that whenever I hover on a line of code it appears to be perfectly colored in the tooltip according to the color scheme that I chose. Am new to Intellij Ide and I could really use your help here. I reverted To the Dragula theme and color scheme to display the issue in a more simplified setup. grayed out code correctly colored in tooltip grayed out code correctly colored in tooltip. Thank you for your help and have a nice day.
Looks like the problem is not with color scheme but with Content Roots:
Try to open Maven tool window and click on Reload All Maven Projects:
or mark the sources/test roots manually by right clicking on main/java and test/java and selecting the appropriate option under Mark Directory As.
I have just installed the 2020-12 version of Eclipse IDE, and I simply cannot get the Ctrl+Space suggestions to work. Every time I try to use them I get an empty suggestion box.
I've already searched for this of course, and I've found many who suggest how to fix it.
https://superuser.com/questions/209752/eclipse-doesnt-autocomplete-and-find-references-anymore
Eclipse - CTRL+Space autocompletion does not work any more for Java
https://mkyong.com/java/content-assist-ctrl-space-is-not-working-eclipse/
No Default Proposals in Eclipse Juno
Eclipse/Java code completion not working
Most of these say I need the Other Java Proposals in the settings, but if you look at the image you see that that option doesn't even exist! In the image the default settings are applied but I've also tried to check every single one of those boxes and still get an empty suggestion box when I press Ctrl+Space at the end of Combi (also in the image).
Image of the issue and my settings: https://imgur.com/a/CVRRgC0
The autocomplete of eclipse is not working now and I searched for hours but I couldn't find an answer to solve it. I haven't used it for long time then the first thing after opening it was to install SWT and windows builder even though I had swing installed. What I mean is, it is may possibly be because of some conflict caused by swt and swing(I read something about a conflict but I don't if this is possible).
Strange thing is it doesn't show anything when I press ctrl+space but when I go Edit-> Content Assist -> Default(it says Ctrl+Space nearby it), it shows things needed to be shown/works as desired.
public class Dsada {
String sssss;
public Dsada(){
sss //pressing ctrl+space is not working,Edit->ContentAssist->Default works fine
}
}
The solution is not to tick/untick some stuff under Windows->Preferences->...->Content Assist-> Advanced. I checked if "ctrl+space" is hijacked by some other thing which is not and checked keyboard language which is English(Those are suggested in mkyong).
I read something about a bug but I couldn't understand. I tried to delete eclipse and re-install again but I guess some settings just stayed in the machine so that it didn't work.
This is recurring for me. I'm using Eclipse 2019-03 in Windows 10.
The steps below work for my case, and does not require a restart.
Window->Preferences->Java->Editor->Content Assist->Advanced
The following options are de-selected, and when I set them the autocomplete worked as before. No restart needed.
1. Java Non-Type Proposals
2. Java Proposals
3. Java Type Proposals
4. Java Proposals (Task-focused)
I don't know what's triggering this but it only happens after I've created a new project. Usually doesn't. It simply doesn't happen often enough for me to notice a pattern to follow up on more.
Clearly this problem occurs with a variety of causes, so review the other answers to see if they match your case.
The hot key combination ctrl+space might be conflict with other settings in system if you are using windows.
Try modify this combination like alt+/, i always use this one since the first time i knew eclipse. It works well.
Hope it works for you.
Window->Preferences->Java->Editor->Content Assist->Advanced
The following options have to be selected, then the autocomplete worked . No restart is required.
Java Proposals (must be selected, not sure the follows)
Java Non-Type Proposals
Java Type Proposals
Java Proposals (Task-focused)
I was facing the same issue. If you use OS X Eclipse Ctrl+Space shortcut can be interfering with OS X system's "Selecting previous input source" using Ctrl+Space shortcut as default.
It is necessary to
edit System Preferencies/Keyboard/Shortcuts/Input Source and uncheck the "Selecting previous input source" or change the shortcut on something else. Eclipse should work after that even without restart.
I faced hot key problem with use Ctrl+Space. I tried to fix the issue first by Windows->Preferences->...->Content Assist-> Advanced and selected
Select the proposal kinds contained in the 'default' content assist list:
Other Java Proposals,
List item
SWT Template Proposals
Template Proposals
Type Proposals
but didn't help.
Therefore, I tried another solution. There would be multiple languages on your computer which could be eating up your Ctrl command. To solve this Go to Control Panel -> Region and Language -> Keyboards and Languages (tab) and then Change Keyboards.
You’ll see a list of languages installed – remove any that you don’t want (click the language and then click the Remove button) until you only have the ones you want left. That fixed it for me, but you can also check the Advanced Key Settings tab to make sure that none of the keyboard short-cuts that are set include Ctrl-Space.
Once you’ve done that, Ctrl-Space should work nicely!!!!
I had the same Problem on Ubuntu 14.04. The problem for me was that ibus used Ctrl+Space as a shortcut. I solved it by starting the program ibus-setup and chaning the shortcut to something else than Ctrl+Space.
Go to Windows >> Preferences » Java » Editor » Content Assist. Then Check the Auto activation triggers for java, Add this in the text box .abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ
Recently, I also faced this issue. When I install neon version eclipse.
By (1) deleting respective class, (2) restoring defaults appearance and (3) restarting eclipse, solved the problem for me.
Hope it will help someone.
Go to Preferences » Java » Editor » Content Assist » Advanced. Make sure Other Java Proposals is ticked/checked.
I checked windows has no conflict of ctrl+space (of eclipse autosuggestion) with windows.
This is mere configuration issue of eclipse. reinstallation would fix it.
Thanks.
I select all the parameters in Preferences -> Java -> Editor -> Content Assist -> Advanced.
It help me and resolve the my problem.
Cltr+space work using this step.
Saving my work and restarting Eclipse solved this for me. I hadn't shut down Eclipse in a while, maybe weeks.
I had the same problem (MacOS Monterey, Eclipse 06-2022). Turned out it works with pressed fn button.
For Mac user, you can try : Preferences -> Java > Editor > Content Assist and then :
tick the field "Enable auto activation"
in the field Auto activation trigger for Java, you can input the text alphabet ".abcdefghijklmnopqrstuvwxyz"
I started to learn swing and downloaded netbeans to work through the tutorials. Unfortunately, when I create a JFrame design view hangs instead of loading and the Navigator and Inspector panes just show up empty.
System details:
Linux Mint Maya
Netbeans version 7.0.1
java 1.6.0_24
Any ideas would be greatly appreciated.
In whatever editor/designer you choose, consider the approach shown here, in which the top-level container is created manually and one or more content panels are maintained in the designer.
look in the Netbeans View menu and choose "IDE log"
There may be an error message / exception there, that might give you a clue.
Reinstalling the nb-javac plugin fixed this issue for me.
I followed the steps here and it resolved my problem.
For me, this was caused by a "FormGuardedBlockError", because at one point in my project I copied all of the source out into Notepad++ and used that to replace the .java file, thereby stripping all of the //GEN-BEGIN and related directives.
You can close NetBeans, open the .java file in a plaintext editor and put these directives back by hand, but it may be easier to merge with an earlier version of your code (if you have one).
For more details, check out http://wiki.netbeans.org/FormGuardedBlockError
Menu->view->show edit toolbar fixed this for me , of course the file you select to edit must have jframe, added to it I think for design tab to appear.
Go to Menu -> Option -> Select "Java" from option windows tool
then Active
This question already has answers here:
IntelliJ show JavaDocs tooltip on mouse over
(21 answers)
Closed 5 years ago.
I just switched from Eclipse to IntelliJ. IntelliJ lacks one feature from Eclipse - when you put your mouse over a method, Eclipse shows javadoc info. I think the way to show it is to use a shortcut - command+J, but when I click it, I get something wrong as on the screen shot below. Please advise me on how I can quickly get javadoc information. I need to at least know what type a method returns.
Use View | Quick Documentation or the corresponding keyboard shortcut (by default: Ctrl+Q on Windows/Linux and Ctrl+J on macOS or F1 in the recent IDE versions). See the documentation for more information.
It's also possible to enable automatic JavaDoc popup on explicit (invoked by a shortcut) code completion in Settings | Editor | General | Code completion (Autopopup documentation):
Yet another way to see the quick doc is on mouse move:
Alternatively you can position your cursor on the item and show JavaDoc using
CTRL+Q
which is the default shortcut.
Edit: As Methical mentioned on Mac the shortcut is
CTRL+j (^+j not ⌘+j)
Go to File/Settings, Editor, click on General.
Scroll down, then ✔ Show quick documentation on mouse move.
There is nice feature which shows quick documentation when your mouse is over element.
IntelliJ 14
Editor / General -> Show quick documentation on mouse move
Older versions
Add the following line to idea.properties file:
auto.show.quick.doc=true
Configuration for IntelliJ IDEA CE 2016.3.4 to enable JavaDocs on mouse hover. I am running IntelliJ IDEA on Mac OS but believe that Linux/Windows should have similar options.
Autopopup docs:
IntelliJ IDEA > Preferences > Editor > General > Code Completion
Documentation on mouse move:
IntelliJ IDEA > Preferences > Editor > General
NOTE: Please hit Apply button to apply these settings
To best mirror Eclipses functionality, enable the following settings:
IDE Settings/Editor -> Other.Show quick doc on mouse move
IDE Settings/Editor/Code Completion -> Autopopup Documentation
To see the javadoc in the autocomplete menu, hit '.' to get the popup, then hover over the object you are working with, once you get the javadoc popup, you can select an item in the popup to switch the javadoc over. Not ideal... But its something.
As another note. The search functionality of the options menu is very useful. Just type in 'doc' and you will see all the options for doc.
Also, searching for "autopopup doc" will not only find each of the options, but it will also highlight them in the menu. Pretty awesome!
Edit:
Going beyond the initial question, this might be useful for people who just want quick and easy access to the docs.
After using this for a few more days, it seems just getting used to using the hotkey is the most efficient way. It will pop up the documentation for anything at the spot of where your text input marker is so you never have to touch the mouse. This works in the intellisense popup as well and will stay up while navigating up and down.
Personally, Ctrl+Q on windows was not ideal so I remapped it to Alt+D. Remaping can be done under IDE Settings/Keymap. Once in the keymap menu, just search for Quick Documentation.
For me, it wasn't just getting the javadoc window to open, but also getting the complete javadoc to present. You may still get a sparse javadoc that is based solely on the method signature if you are importing libraries from a Maven repository and do not tell Idea to include the javadocs in the download. Be sure to tick the "JavaDocs" option in the "Download Library From Maven Repository" dialog, which can be found under Project Structure -> Projtect Settings -> Libraries.
Go to Settings -> Editor -> General then enable Show quick documentation on mouse move
IntelliJ IDEA 15 added this feature
Now it is available as EAP.
As you can see in the picture below, the caret position doesn't influence the cursor position:
This feature was implemented in IntelliJ IDEA 15 142.4675.3 Release Notes.
The closest to Eclipse will be Ctrl+Button2 Click (Scroll click)
It's called Quick Doc in IntelliJ, I wish guys from JetBrains one day add quick doc like Eclipse with Ctrl+Mouse Move it's so much better.
In my case only with only mouse move is a bit annoying, so if you search in Preferences/Settings --> Keymap for "quick documentation" you will find:
Win-Linux: "Ctrl+Q" and "Ctrl+Button2 Click" (Scroll click)
Mac: "Ctrl+J" and "Ctrl+Button2 Click" (Scroll click)
I have noticed that selecting the method name and pressing F2(Quick Documentation) dispalys it's JavaDoc.
I am using Intellij 2016, and Eclipse Keymap