Checkbox and non-checkbox items in a SWT tree [message #448688] |
Thu, 13 January 2005 08:30 |
Eclipse User |
|
|
|
Originally posted by: mathieu.watel.axlog.fr
Hi,
I want to know how to create a SWT tree where you can both have checkbox
item nodes and non checkbox items. Now, i have the code below that will
just put checkboxes at each node :
Tree myTree = new Tree(parent, SWT.SINGLE | SWT.CHECK);
TreeItem myItem = new TreeItem(myTree, SWT.NONE);
myItem.setText("item 1");
myItem = new TreeItem(myItem, SWT.NONE);
myItem.setText("subitem 1");
If I only want to have a checkbox on the subitem, what is the procedure ?
Moreover, I don't understand why we must give a style parameter to the
constructor of TreeItem as it doesn't change anything. In the
documentation it is said that there aren't any style for this kind of
object...
Thanks in advance for your help !
|
|
|
|
Powered by
FUDForum. Page generated in 0.02789 seconds