Top Description Fields Constructors Methods
org.eclipse.swt.layout

public final Class RowData

extends Object
Class Inheritance
Imports
org.eclipse.swt.*, org.eclipse.swt.graphics.*

Each control controlled by a RowLayout can have its initial width and height specified by setting a RowData object into the control.

The following code uses a RowData object to change the initial size of a Button in a Shell:

		Display display = new Display();
		Shell shell = new Shell(display);
		shell.setLayout(new RowLayout());
		Button button1 = new Button(shell, SWT.PUSH);
		button1.setText("Button 1");
		button1.setLayoutData(new RowData(50, 40));
See Also
RowLayout, Sample code and further information

Field Summary

Modifier and TypeField and Description
public boolean
exclude

exclude informs the layout to ignore this control when sizing and positioning controls.

public int
height

height specifies the preferred height in points.

public int
width

width specifies the desired width in points.

Constructor Summary

AccessConstructor and Description
public
RowData()

Constructs a new instance of RowData using default values.

public
RowData(int
a minimum width for the control
width
,
int
a minimum height for the control
height
)

Constructs a new instance of RowData according to the parameters.

public
RowData(Point
a point whose x coordinate specifies a minimum width for the control and y coordinate specifies a minimum height for the control
point
)

Constructs a new instance of RowData according to the parameter.

Method Summary

Modifier and TypeMethod and Description
pack-priv String
public String

Returns:

a string representation of the RowData object
toString
()

Overrides java.lang.Object.toString.

Returns a string containing a concise, human-readable description of the receiver.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

excludeback to summary
public boolean exclude

exclude informs the layout to ignore this control when sizing and positioning controls. If this value is true, the size and position of the control will not be managed by the layout. If this value is false, the size and position of the control will be computed and assigned. The default value is false.

Since
3.1
heightback to summary
public int height

height specifies the preferred height in points. This value is the hHint passed into Control.computeSize(int, int, boolean) to determine the preferred size of the control. The default value is SWT.DEFAULT.

See Also
org.eclipse.swt.widgets.Control#computeSize(int, int, boolean)
widthback to summary
public int width

width specifies the desired width in points. This value is the wHint passed into Control.computeSize(int, int, boolean) to determine the preferred size of the control. The default value is SWT.DEFAULT.

See Also
org.eclipse.swt.widgets.Control#computeSize(int, int, boolean)

Constructor Detail

RowDataback to summary
public RowData()

Constructs a new instance of RowData using default values.

RowDataback to summary
public RowData(int width, int height)

Constructs a new instance of RowData according to the parameters. A value of SWT.DEFAULT indicates that no minimum width or no minimum height is specified.

Parameters
width:int

a minimum width for the control

height:int

a minimum height for the control

RowDataback to summary
public RowData(Point point)

Constructs a new instance of RowData according to the parameter. A value of SWT.DEFAULT indicates that no minimum width or no minimum height is specified.

Parameters
point:Point

a point whose x coordinate specifies a minimum width for the control and y coordinate specifies a minimum height for the control

Method Detail

getNameback to summary
pack-priv String getName()
toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Returns a string containing a concise, human-readable description of the receiver.

Returns:String

a string representation of the RowData object

Annotations
@Override