Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 134504 - custom draw of item: how to get inner border?
Summary: custom draw of item: how to get inner border?
Status: RESOLVED DUPLICATE of bug 178008
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 3.2   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Steve Northover CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-04-03 09:42 EDT by Dani Megert CLA
Modified: 2007-05-07 06:33 EDT (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dani Megert CLA 2006-04-03 09:42:23 EDT
3.2 M6

I looked at the new custom drawing support.
When drawing the text myself I need to add +2 to the x and y location to make the text appear at the exact same location as when no custom rendering is used. The '2' seems to be the inner border. The snippets, e.g. snippet 228:
  gc.drawText(text, event.x+2, event.y+offset, true);
also seem to hard-code this inner border value.

In order to do this right we need API to get the inner border (i.e. the '2'), or is this something which is already there and I missed it?
Comment 1 Steve Northover CLA 2006-04-04 11:45:30 EDT
Obviously, "2" isn't right.  We need to fix this for 3.2.
Comment 2 Martin Aeschlimann CLA 2007-04-05 09:04:42 EDT

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