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 05:21
Kevin Albrecht is currently offline Kevin Albrecht
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: Wed Aug 27 19:25:25 EDT 2014

Powered by FUDForum. Page generated in 0.01534 seconds