Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » Offset of last visible character in a StyledText control
Offset of last visible character in a StyledText control [message #1005602] Sun, 27 January 2013 10:21
Kevin Albrecht is currently offline Kevin AlbrechtFriend
Messages: 2
Registered: July 2009
Junior Member
How can I get the integer offset of the last visible character in a StyledText control?

I have tried the following:

Rectangle rect = styledText.getClientArea();
Point p = new Point(rect.width, rect.height);
int offset = styledText.getOffsetAtLocation(p);


But this causes an IllegalArgumentException.

Thanks,
Kevin
Previous Topic:swt, xulrunner 10, and Javascript XPCOM calls
Next Topic:SWT, XULrunner, OS X and hover events not working
Goto Forum:
  


Current Time: Fri Dec 19 10:56:10 GMT 2014

Powered by FUDForum. Page generated in 0.03242 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software