Summary: | Printing Labels results in the label's text being bigger than shown in UI. | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | [Tools] GEF | Reporter: | Craig <craighewetson> | ||||||
Component: | GEF-Legacy Draw2d | Assignee: | gef-inbox <gef-inbox> | ||||||
Status: | NEW --- | QA Contact: | |||||||
Severity: | major | ||||||||
Priority: | P3 | CC: | aboyko, ahunter.eclipse, thomas.thuem | ||||||
Version: | unspecified | ||||||||
Target Milestone: | --- | ||||||||
Hardware: | PC | ||||||||
OS: | Linux | ||||||||
Whiteboard: | |||||||||
Attachments: |
|
Description
Craig
2010-04-28 08:27:40 EDT
Created attachment 166311 [details]
PrintExample
Run this code to illustrate the problem. Note you don't have to print to paper you can also print to file and the same problem occurs.
I occured the same problem on a Windows PC. It looks that this is actually not a problem specific to printing, instead also when zooming is enabled the font-size does not match exactly and the last letters may disappear (partly). This is such a show stopper for my company, that I might have to fix it myself if the community doesn't. Heaven help :| I can duplicate this problem with GMF Printing and GMF export to image file which uses the same GEF constructs: Take a GMF Geoshapes diagram example. Create a few shapes with different font sizes. I used Times New Roman and Arial, 10, 24 and 72 points Print or export to image as a PNG file. The fonts are chopped both on the top and bottom. I am using the Helios M7 downloads. well if GMF is built on top of draw2d then it makes sense. It seems that the problem lies in draw2d (In reply to comment #4) > I am using the Helios M7 downloads. The bug occurs back to Ganymede, I raised Bug 312723 for GMF. Craig, do you use antialias setting on the Graphics/GC to paint the text? Created attachment 168436 [details]
printExample output
Well if you see the PrintExample, there is no text anti-aliasing specified. I've attached the output of this example when you print to pdf.
BTW: This has been tested on windows with the same results.
Alex, does the PrintExample.java show the text 100% if you print it, using the print button on the example? No, unlikely 100%. There is a scaling factor calculated for the graphics by PrintFigureOperation, which is based on printer DPI. So far I only tried this Win 7 and this example is not working on Win 7, just clips most of the figures for some reason. I'll try this on Win XP next week. It is possible that the problem is with the example. I've tested it on Windows XP and the example prints 100%. It seems to be a problem on Ubuntu (gtk), Windows 7 (from what you have told me) and Windows Vista. Win 7 and Vista issues seem to be an SWT Win 7/Vista printing issue: Bug 313357 The symptoms of the Win 7/Vista bug different from this one. Craig, do you mind trying to write a small SWT snippet for printing a label drawn on the canvas? I have SLED 10 Linux, but no Ubuntu. If I can't reproduce it with SLED 10, you'd have to try reproducing this in pure SWT on Ubuntu (see snippet for 313357) and if successful, raise a defect against SWT. |