Community
Participate
Working Groups
I20050509-2010 (MacOS X and Windows XP) Hovering over a type declaration with an 'unimplemented method' error shows the type hover when hovering over the right border of the type name. I would expect the error hover to completely hide the type hover.
Created attachment 20962 [details] Screenshot of type hover That is, when using a large font.
I've debugged this: ICodeAssist.codeSelect(...) returns a type even if the offset is pointing to the space after the type
*** Bug 81129 has been marked as a duplicate of this bug. ***
This makes hyperlinking look ugly, especially when using upcoming builds (>N20060425-0010) where we fixed some text measuring issues. I assume the fix is quite simple. Could this be addressed for 3.2? Test Case using N20060426-0010 or newer: 1. select a large Java editor font (e.g. 20pt) 2. add a CU with only the following text: /** String */ 3. Ctrl+Move the mouse from the right side towards the 'String' ==> we get the hand cursor one offset too early.
The fix seems easy. I just need to replace 'scanner.startPosition <= selectionStart && selectionStart <= scanner.currentPosition' by 'scanner.startPosition <= selectionStart && selectionStart < scanner.currentPosition' in SelectionEngine#checkSelection(...) But if i do that the following test case will not work 1) class X implements Runnable {} 2) put the caret just after Runnable 'class X implements Runnable| {}' 3) do F3 Currently code select return the Runnable element. But if i apply the fix, code select will return nothing in this case. It's not possible two have both behaviors in JDT/Core (unless we add a new API). Daniel - Do you think it is possible to have both behaviors by changing something on your side ?
Feels like a contract change in our layer if we do what is asked here.
Discussed with David: we mention this case in the Javadoc (improve it) and leave codeSelect(...) as is. Now that we know the contract we can adjust the UI where appropriate.
I will update the Javadoc to describe this contract. I entered a bug for that (bug 138432) Move to JDT/Text
Just a corner case: ABC DEF (one space in between) Is the hover going to show info for DEF as soon as escaping from ABC ? (when hovering in space area)
>Is the hover going to show info for DEF as soon as escaping from ABC ? (when >hovering in space area) No, it should dismiss the hover.
Fixed hovering and hyperlinking in HEAD. Available in builds > N20060425-0010.
Verified in 3.2RC3