When Alt-Enter is pressed, or the mouse is clicked on the hint lightbulb, a hint appears. At the same time, the tip that relates to the problem is shown. This is annoying and unnecessary. When a hint is displayed, the tip should not be shown.
I am a bit confused - do you mean the tooltip that contains the error/warning description? Should that be disabled when the fix list is shown? Then the users will not know the error/warning message the fixes relate to?
Created attachment 112115 [details]
"Convert to switch" looks horrible with hint and tooltip!
I think the context of the hint is normally obvious. The tooltip is normally not very helpful and takes up space. Also not something I see in IntelliJ and in Eclipse, simply because it is not necessary and takes up space.
Created attachment 112116 [details]
"Convert to multicatch" looks horrible with hint and tooltip!
I agree that in this case it does not seem great - the question is whether the problem should not be rephrased to "The warning texts produced by some hints are not good." (which is true anyway, and a well written warnings texts would be very welcome).
But, I can of course easily disable the tooltip, either for all errors/warnings or only for warnings. I am only afraid that we (well, me in this case, maybe reassigning to you?) will be buried under a pile of complaints when I do. Please specify exactly what should I do.
OK, thanks for the open response. Personally, I think that we should always hide a tooltip if a hint is shown. But maybe I will blog about it and ask the community what they think. If you know of specific scenarios where the tooltip is useful when there is a hint, please tell me.
Created attachment 112117 [details]
A case where the error description tooltip is useful (IMO)
A case where I think the tooltip is quite useful. In fact, it is the simplest way I know of to get the error message, well formatted, only by using keyboard.
I don't understand why that tooltip is useful. The hint is clear that "undefined" needs to be defined.
Nice solution, thanks very much.
Integrated into 'main-golden'
User: Jan Lahoda <firstname.lastname@example.org>
Log: #203810: disabling error tooltip when the fixes are being shown.
Created attachment 112275 [details]
Example of why this may be a bad idea
Can you guess from the screenshot what the error message here is? Note that Mode is successfully imported from a valid dependency.
Answer: "not a statement", but now you need the mouse to find this out (or run a build or guess).
Then that hint shouldn't be displayed. Or, if there is no way to not display it, the user can hover the mouse over the error annotation to see what the reason is for the problem.
(In reply to comment #13)
> Then that hint shouldn't be displayed.
Perhaps. Are you going to check through hundreds of hints in the IDE and third-party extensions to verify that they are all appropriate in every case and that the warning/error can be clearly inferred from the hint text?
> the user can hover the mouse over the error annotation
Not if you are a keyboard user. This is a serious A11Y regression.
Created attachment 112379 [details]
Another even worse example
Here the warning tooltip is several lines long:
Required children missing from element "head".
Otherwise: ... exactly one is a 'title' element.
Not only does the hint "Disable..." not give you any clue as to the nature of the warning, it is not a hint you would usually want to accept; better in most cases (not this one as it happens) would be to add the <title>.
I think this change has to be reverted. Some better GUI for displaying warnings in combination with hints in the same popup may be possible, but just suppressing the warning is not workable.
Could we solve this by reverting the way the option works? I.e., by default, use the same way as always, i.e., by default always show the tooltip. But, if the option has been set (i.e., you need to explicitly make this choice), the tooltip is always hidden?
A configurable option is the last resort if no real solution seems feasible. The cases you originally reported do indeed look better with the tooltip hidden. What is needed is some new UI which works reasonably for all the cases. Some ideas (not necessarily exclusive):
1. Allow the hint provider to declare that a given warning message is superseded by one or more of the fix texts, so the UI can safely suppress it when the fixes are displayed.
2. Show the warning message physically as part of the list of hints, rather than in a separate popup. Would eliminate the ugly gap in the original screenshots and avoid hiding code above the selected line.
3. Show warning messages some other way than in a tool tip, such as in the status line - possibly just by navigating into the line or line part with a warning, i.e. no Alt-ENTER required. (TBD how lines with multiple warnings should be handled.)
See screenshot attached to bug #209850 - the missing warning is very confusing. I am inclining to reverting to pre-7.1 way - it worked mostly OK for many years, and it is really very unpleasant for me at least to work in an IDE without it. As for the suggestions above, "1" is conceptually implementable, but I would say that we would have trouble to find a group of warnings that would want the warning tooltip disabled (it all depends on the context, there may be several warnings on one line). "2" is an idea, but not a design. "3" is something we should probably do, but does not really solve the problem, as not all the warning text may fit into the limited size of the status line (and some compilation errors are multi-line).
If you revert, please make sure to include some kind of switch to disable it. Whenever I do a demo with NetBeans IDE and the meaningless tips show up that duplicates exactly what the hint already displays, I get questions about UI design in NetBeans IDE, i.e., someone then always asks: "Does NetBeans not have a UI design team? It doesn't seem like it with the tips & hints displaying the same info, at least it should be possible to switch those hints off."
FYI: I have implemented #3 in:
Lets see how that works out.
Integrated into 'main-golden', will be available in build *201203230400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
User: Jan Lahoda <email@example.com>
Log: #203810: show the message(s) of the error(s)/warning(s) currently under caret in the status line.
(In reply to comment #20)
> Lets see how that works out.
Seems to work for most cases. Not sure if it is enough or not.
*** Bug 62959 has been marked as a duplicate of this bug. ***