[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[news.eclipse.platform.swt] StyledText maximum visible text area

Hello!

how do I calculate the width of the area in StyledText where the text is painted?

Currently i have something like this:

width = styledText.getBounds().width - styledText.getVerticalBar().getSize().x;

However it is still too large (by about 8-9 pixels under gtk+).
(i do check if vertical bar is not null)

I simply want to draw a rectangle around the text.

Thanks for help!

Jacek