Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 330844 - [Text] computeSize returns smaller width for text with styles SWT.MULTI | SWT.BORDER
Summary: [Text] computeSize returns smaller width for text with styles SWT.MULTI | SWT...
Status: RESOLVED FIXED
Alias: None
Product: RAP
Classification: RT
Component: RWT (show other bugs)
Version: 1.4   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 1.4 M4   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-11-22 14:03 EST by Ivan Furnadjiev CLA
Modified: 2010-12-07 04:50 EST (History)
0 users

See Also:


Attachments
Screenshot (13.50 KB, image/png)
2010-11-22 14:15 EST, Ivan Furnadjiev CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ivan Furnadjiev CLA 2010-11-22 14:03:22 EST
Steps to reproduce:
1. Start Controls Demo -> Text Tab
2. Check MULTI and BORDER
3. There is a horizontal scrollbar and the text is not visible at all.
Adding 1px to compute size width solves the problems, but we need to find why this 1px is needed.
Reproducible with default and classic theme.
Comment 1 Ivan Furnadjiev CLA 2010-11-22 14:06:16 EST
This is only a FF issue - tested with FF 3.6.12.
Comment 2 Ivan Furnadjiev CLA 2010-11-22 14:15:19 EST
Created attachment 183595 [details]
Screenshot
Comment 3 Ivan Furnadjiev CLA 2010-12-07 04:50:33 EST
Due to bug 253644, the padding for MULTI text is hard coded in AppearanceBase.js. There, if BORDER style is set, additional pixel is added to the left padding (increase from 3 to 4). I don't remember why this was needed, but with the current CVS HEAD this special treatment of BORDER is not needed. Tested with FF, IE, Chrome and Safari.