| Summary: | ControlDecoration uses the wrong GC method to render text | ||
|---|---|---|---|
| Product: | [Eclipse Project] Platform | Reporter: | Dejan Glozic <dejan> |
| Component: | UI | Assignee: | Boris Bokowski <bokowski> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | Kevin_McGuire |
| Version: | 3.3 | ||
| Target Milestone: | 3.3 M5 | ||
| Hardware: | PC | ||
| OS: | Windows XP | ||
| Whiteboard: | |||
Fix released >20070117. . |
The constructor of the Hover in ControlDecoration: hoverShell.addPaintListener(new PaintListener() { public void paintControl(PaintEvent pe) { pe.gc.drawString(text, hm, hm); if (!CARBON) { pe.gc.drawPolygon(getPolygon(true)); } } }); The size of the hover is correctly performed when there are carriage returns in the text. However, the text is painted as String. This causes only the first line to be painted and the rest of the hover is empty. The fix is to use GC.drawText' instead.