|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--org.eclipse.swt.widgets.Widget
|
+--org.eclipse.swt.widgets.Control
|
+--org.eclipse.swt.widgets.Scrollable
|
+--org.eclipse.swt.widgets.Composite
Instances of this class are controls being capable of containing other controls.
Note: The NO_BACKGROUND, NO_FOCUS, NO_MERGE_PAINTS,
and NO_REDRAW_RESIZE styles are intended for use with Canvas.
They can be used with Composite if you are drawing your own, but their
behavior is undefined if they are used with subclasses of Composite other
than Canvas.
This class may be subclassed by custom control implementors who are building controls that are constructed from aggregates of other controls.
Canvas| Field Summary |
| Fields inherited from class org.eclipse.swt.widgets.Widget |
h, INCMD_DISPOSE, INCMD_EXTKEY, INCMD_KEY, INCMD_LDOWN, INCMD_LUP, INCMD_MENU, INCMD_POS, UPDATEITEM_ENABLED, UPDATEITEM_NAME, w, x, y |
| Constructor Summary | |
protected |
Composite()
Prevents uninitialized instances from being created outside the package. |
|
Composite(Composite composite,
int style)
Constructs a new instance of this class. |
| Method Summary | |
Control[] |
getChildren()
Returns an array containing the receiver's children. |
void |
pack(boolean changed)
Causes the receiver to be resized to its preferred size. |
void |
setLayout(Layout layout)
Sets the layout which is associated with the receiver to be the argument which may be null. |
| Methods inherited from class org.eclipse.swt.widgets.Scrollable |
getClientArea |
| Methods inherited from class org.eclipse.swt.widgets.Control |
computeSize, computeSize, getLayoutData, isFocusControl, pack, setBackground, setBounds, setFocus, setLayoutData, setSize, setSize, update |
| Methods inherited from class org.eclipse.swt.widgets.Widget |
addListener, dispose, focusState, getBorderWidth, getDisplayArea, getSelection, getStyle, getText, isDisposed, removeListener, setBounds, setCursor, stop |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, toString |
| Methods inherited from interface org.eclipse.swt.graphics.Drawable |
drawLine, drawRect, drawText, setColor |
| Methods inherited from interface java.lang.Runnable |
run |
| Constructor Detail |
protected Composite()
public Composite(Composite composite,
int style)
The style value is either one of the style constants defined in
class SWT which is applicable to instances of this
class, or must be built by bitwise OR'ing together
(that is, using the int "|" operator) two or more
of those SWT style constants. The class description
lists the style constants that are applicable to the class.
Style bits are also inherited from superclasses.
composite - a widget being the parent of the new instance (cannot be null)
IllegalArgumentException - SWTException - SWT#NO_BACKGROUND,
SWT#NO_FOCUS,
SWT#NO_MERGE_PAINTS,
SWT#NO_REDRAW_RESIZE,
SWT.NO_RADIO_GROUP,
Widget.getStyle()| Method Detail |
public Control[] getChildren()
Note: This is not the actual structure used by the receiver to maintain its list of children, so modifying the array will not affect the receiver.
SWTException - public void setLayout(Layout layout)
layout - the receiver's new layout or null
SWTException - public void pack(boolean changed)
Control
If the changed flag is true, it indicates that the receiver's
contents have changed, therefore any caches that a layout manager
containing the control may have been keeping need to be flushed. When the
control is resized, the changed flag will be false, so layout
manager caches can be retained.
pack in class ControlControl.computeSize(int, int)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||