positiveman
positiveman

Reputation: 63

How to set height of SWT Tree?

Now the height of the tree depends on the number of elements of the first level. The tree is very large and watch it in a small frame, very uncomfortable.

swt tree swt tree full

Upvotes: 0

Views: 597

Answers (1)

greg-449
greg-449

Reputation: 111142

For RowLayout you can use a RowData layout data object to specify the height of a row:

RowData layoutData = new RowData(SWT.DEFAULT, height);

tree.setLayoutData(layoutData);

Upvotes: 1

Related Questions