Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » SWT TableItem and TreeItem(TableItem is not displaying whole text)
SWT TableItem and TreeItem [message #657280] Wed, 02 March 2011 10:28 Go to next message
Purush  is currently offline Purush Friend
Messages: 1
Registered: March 2011
Junior Member
Hi,
SWT TableItem and TreeItem is not displaying text properly if assigned character length is more than 200 or so. Wrap will not support by Tree and Table. Below is sample code,

Any workaround?

Thanks in advance.

final Display display = new Display ();
final Shell shell = new Shell (display);
shell.setLayout (new FillLayout ());
final Table table = new Table (shell, SWT.BORDER);

for (int i = 0; i < 20; i++) {
TableItem item = new TableItem (table, SWT.NONE);
item.setText("SWT is an open source widget toolkit for Java designed to provide efficient, portable access to the user-interface facilities of the operating systems on which it is implemented."
+ "SWT includes many rich features, but a basic knowledge of the system's core - widgets, layouts, and events - is all that is needed to implement useful and robust applications.");
}
table.pack();
shell.pack ();
shell.open();
while (!shell.isDisposed()) {
if (!display.readAndDispatch())
display.sleep();
}
display.dispose();
Re: SWT TableItem and TreeItem [message #657309 is a reply to message #657280] Wed, 02 March 2011 11:45 Go to previous message
Daniel Krügler is currently offline Daniel KrüglerFriend
Messages: 853
Registered: July 2009
Senior Member
On 2011-03-02 11:29, Purush wrote:
> Hi, SWT TableItem and TreeItem is not displaying text properly if
> assigned character length is more than 200 or so. Wrap will not support
> by Tree and Table. Below is sample code,

This is due to OS-limitations, see

https://bugs.eclipse.org/bugs/show_bug.cgi?id=251379

> Any workaround?

Not one that I'm aware of.

HTH & Greetings from Bremen,

Daniel Krügler
Previous Topic:SWT Binary and Source
Next Topic:Aligning TableEditor on Linux
Goto Forum:
  


Current Time: Thu Apr 02 23:41:56 GMT 2020

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

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

Back to the top