Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 412021 - Bad "Ubuntu" font width (was: Incorrect label for "Make type XY abstract" mouse hover quick fix)
Summary: Bad "Ubuntu" font width (was: Incorrect label for "Make type XY abstract" mou...
Status: CLOSED DUPLICATE of bug 393602
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 4.3   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-SWT-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-07-01 11:06 EDT by Libor Jelinek CLA
Modified: 2013-07-11 10:45 EDT (History)
6 users (show)

See Also:


Attachments
Incorrect label for "Make type XY abstract" mouse hover quick fix (137.17 KB, image/png)
2013-07-01 11:06 EDT, Libor Jelinek CLA
no flags Details
Eclipse Installation Details from About dialog (541.24 KB, text/plain)
2013-07-04 12:11 EDT, Libor Jelinek CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Libor Jelinek CLA 2013-07-01 11:06:16 EDT
Created attachment 232949 [details]
Incorrect label for "Make type XY abstract" mouse hover quick fix

For the following example code

    public interface IResolver {
        public void resolve();
    }

    public class SomeResolver implements IResolver {		
    }

Quick fix assistant complains "The type SomeResolver must implement the inherited abstract method IResolver.resolve()".

It offers two quick fixes on Ctrl-1:
* "Add unimplemented methods"
* "Make type 'SomeResolver' abstract"

But for mouse hovered quick fixes it incorrectly renders text of "Make type 'SomeResolver' abstract" only as ""Make type 'SomeResolver'".

See attached screenshot.

I have this JDT feature installed (Kepler 4.3, About / Installation Details):

  Eclipse Java Development Tools
  3.9.0.v20130605-2000
  org.eclipse.jdt.feature.group
Comment 1 Jay Arthanareeswaran CLA 2013-07-01 11:15:43 EDT
I don't know if it's a problem only in Linux, because I can't reproduce this with Windows. Moving to JDT/UI for investigation.
Comment 2 Noopur Gupta CLA 2013-07-01 13:02:13 EDT
Cannot reproduce it on Windows and Lubuntu 12.04 with Eclipse 4.3.
Please provide your OS and Java version details. 
Also, check for any exceptions in the log on hovering.
Comment 3 Markus Keller CLA 2013-07-04 10:54:09 EDT
Also doesn't reproduce on my Ubuntu 12.04 with "Ubuntu 11" font.

Looks like this is a problem in the Link widget with your specific font.
What's your "Javadoc dialog font" on the "Colors and Fonts" preference page?


The Link controls are created here, but we don't restrict their width:
org.eclipse.jdt.internal.ui.text.java.hover.AbstractAnnotationHover.AnnotationInformationControl#createCompletionProposalLink(Composite, ICompletionProposal, int)
Comment 4 Markus Keller CLA 2013-07-04 10:55:12 EDT
(In reply to comment #3)
> What's your "Javadoc dialog font" on the "Colors and Fonts" preference page?

Sorry, this is about the "Dialog font".
Comment 5 Libor Jelinek CLA 2013-07-04 12:11:36 EDT
Created attachment 233089 [details]
Eclipse Installation Details from About dialog
Comment 6 Libor Jelinek CLA 2013-07-04 12:12:46 EDT
Markus, you were right - if I change dialog font to any other from "Ubuntu", then tooltip quick fix texts are rendered properly.

Ubuntu font is default font (I've never change dialog font before) and also is set to it when you press "Use System Font" button.

I'm running vanilla fresh Ubuntu 13.04 32bit with OpenJDK 1.7.0_21-b02.

$ uname -a
Linux pc-libor 3.8.0-25-generic #37-Ubuntu SMP Thu Jun 6 20:47:30 UTC 2013 i686 
i686 i686 GNU/Linux

$ java -version
java version "1.7.0_21"
OpenJDK Runtime Environment (IcedTea 2.3.9) (7u21-2.3.9-1ubuntu1)
OpenJDK Server VM (build 23.7-b01, mixed mode)

Eclipse installation details from About dialog are attached.
Comment 7 Markus Keller CLA 2013-07-08 06:32:52 EDT
Thanks, so it looks like a general problem with calculating the width of the "Ubuntu" font in Ubuntu 13.04.
Comment 8 Dani Megert CLA 2013-07-11 09:05:18 EDT
*** Bug 412665 has been marked as a duplicate of this bug. ***
Comment 9 Dani Megert CLA 2013-07-11 09:10:44 EDT
Probably the same as bug 393602.
Comment 10 Markus Keller CLA 2013-07-11 10:45:09 EDT
> Probably the same as bug 393602.
Yes.

*** This bug has been marked as a duplicate of bug 393602 ***