Save This Page
Home » Eclipse-SWT-3.5.1 » org.eclipse.swt.widgets » [javadoc | source]
org.eclipse.swt.widgets
abstract public class: Control [javadoc | source]
java.lang.Object
   org.eclipse.swt.widgets.Widget
      org.eclipse.swt.widgets.Control

All Implemented Interfaces:
    Drawable

Control is the abstract superclass of all windowed user interface classes.

Styles:
BORDER
LEFT_TO_RIGHT, RIGHT_TO_LEFT
Events:
DragDetect, FocusIn, FocusOut, Help, KeyDown, KeyUp, MenuDetect, MouseDoubleClick, MouseDown, MouseEnter, MouseExit, MouseHover, MouseUp, MouseMove, Move, Paint, Resize, Traverse

Only one of LEFT_TO_RIGHT or RIGHT_TO_LEFT may be specified.

IMPORTANT: This class is intended to be subclassed only within the SWT implementation.

Field Summary
public  int handle    the handle to the OS resource (Warning: This field is platform dependent)

IMPORTANT: This field is not part of the SWT public API. It is marked public only so that it can be shared within the packages provided by SWT. It is not available on all platforms and should never be accessed from application code.

 
 Composite parent     
 Cursor cursor     
 Menu menu     
 String toolTipText     
 Object layoutData     
 Accessible accessible     
 Image backgroundImage     
 Region region     
 Font font     
 int drawCount     
 int foreground     
 int background     
Fields inherited from org.eclipse.swt.widgets.Widget:
style,  state,  display,  eventTable,  data,  DISPOSED,  CANVAS,  KEYED_DATA,  DISABLED,  HIDDEN,  LAYOUT_NEEDED,  LAYOUT_CHANGED,  LAYOUT_CHILD,  THEME_BACKGROUND,  DRAW_BACKGROUND,  PARENT_BACKGROUND,  RELEASED,  DISPOSE_SENT,  TRACK_MOUSE,  FOREIGN_HANDLE,  DRAG_DETECT,  MOVE_OCCURRED,  MOVE_DEFERRED,  RESIZE_OCCURRED,  RESIZE_DEFERRED,  IGNORE_WM_CHANGEUISTATE,  DEFAULT_WIDTH,  DEFAULT_HEIGHT,  MAJOR,  MINOR
Constructor:
 Control() 
 public Control(Composite parent,
    int style) 
    Constructs a new instance of this class given its parent and a style value describing its behavior and appearance.

    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.

    Parameters:
    parent - a composite control which will be the parent of the new instance (cannot be null)
    style - the style of control to construct
    Throws:
    IllegalArgumentException -
    • ERROR_NULL_ARGUMENT - if the parent is null

    SWTException -
    • ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the parent
    • ERROR_INVALID_SUBCLASS - if this class is not an allowed subclass

    Also see:
    SWT#BORDER
    SWT#LEFT_TO_RIGHT
    SWT#RIGHT_TO_LEFT
    Widget#checkSubclass
    Widget#getStyle
    exception: IllegalArgumentException -
    • ERROR_NULL_ARGUMENT - if the parent is null

    exception: SWTException -
    • ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the parent
    • ERROR_INVALID_SUBCLASS - if this class is not an allowed subclass

Method from org.eclipse.swt.widgets.Control Summary:
WM_ACTIVATE,   WM_CAPTURECHANGED,   WM_CHANGEUISTATE,   WM_CHAR,   WM_CLEAR,   WM_CLOSE,   WM_COMMAND,   WM_CONTEXTMENU,   WM_CTLCOLOR,   WM_CUT,   WM_DESTROY,   WM_DRAWITEM,   WM_ENDSESSION,   WM_ENTERIDLE,   WM_ERASEBKGND,   WM_GETDLGCODE,   WM_GETFONT,   WM_GETMINMAXINFO,   WM_GETOBJECT,   WM_HELP,   WM_HOTKEY,   WM_HSCROLL,   WM_IME_CHAR,   WM_IME_COMPOSITION,   WM_IME_COMPOSITION_START,   WM_IME_ENDCOMPOSITION,   WM_INITMENUPOPUP,   WM_INPUTLANGCHANGE,   WM_KEYDOWN,   WM_KEYUP,   WM_KILLFOCUS,   WM_LBUTTONDBLCLK,   WM_LBUTTONDOWN,   WM_LBUTTONUP,   WM_MBUTTONDBLCLK,   WM_MBUTTONDOWN,   WM_MBUTTONUP,   WM_MEASUREITEM,   WM_MENUCHAR,   WM_MENUSELECT,   WM_MOUSEACTIVATE,   WM_MOUSEHOVER,   WM_MOUSELEAVE,   WM_MOUSEMOVE,   WM_MOUSEWHEEL,   WM_MOVE,   WM_NCACTIVATE,   WM_NCCALCSIZE,   WM_NCHITTEST,   WM_NCLBUTTONDOWN,   WM_NCPAINT,   WM_NOTIFY,   WM_PAINT,   WM_PALETTECHANGED,   WM_PARENTNOTIFY,   WM_PASTE,   WM_PRINT,   WM_PRINTCLIENT,   WM_QUERYENDSESSION,   WM_QUERYNEWPALETTE,   WM_QUERYOPEN,   WM_RBUTTONDBLCLK,   WM_RBUTTONDOWN,   WM_RBUTTONUP,   WM_SETCURSOR,   WM_SETFOCUS,   WM_SETFONT,   WM_SETREDRAW,   WM_SETTINGCHANGE,   WM_SHOWWINDOW,   WM_SIZE,   WM_SYSCHAR,   WM_SYSCOLORCHANGE,   WM_SYSCOMMAND,   WM_SYSKEYDOWN,   WM_SYSKEYUP,   WM_TIMER,   WM_UNDO,   WM_UPDATEUISTATE,   WM_VSCROLL,   WM_WINDOWPOSCHANGED,   WM_WINDOWPOSCHANGING,   WM_XBUTTONDBLCLK,   WM_XBUTTONDOWN,   WM_XBUTTONUP,   addControlListener,   addDragDetectListener,   addFocusListener,   addHelpListener,   addKeyListener,   addMenuDetectListener,   addMouseListener,   addMouseMoveListener,   addMouseTrackListener,   addMouseWheelListener,   addPaintListener,   addTraverseListener,   borderHandle,   checkBackground,   checkBorder,   checkBuffered,   checkComposited,   checkHandle,   checkMirrored,   computeSize,   computeSize,   computeTabGroup,   computeTabList,   computeTabRoot,   createHandle,   createWidget,   defaultBackground,   defaultFont,   defaultForeground,   deregister,   destroyWidget,   dragDetect,   dragDetect,   dragDetect,   drawBackground,   drawBackground,   drawBackground,   drawImageBackground,   drawThemeBackground,   enableDrag,   enableWidget,   fillBackground,   fillImageBackground,   fillThemeBackground,   findBackgroundControl,   findBrush,   findCursor,   findImageControl,   findMenus,   findMnemonic,   findThemeControl,   fixChildren,   fixFocus,   forceFocus,   forceResize,   getAccessible,   getBackground,   getBackgroundImage,   getBackgroundPixel,   getBorderWidth,   getBounds,   getClipboardText,   getCodePage,   getCursor,   getDragDetect,   getDrawing,   getEnabled,   getFont,   getForeground,   getForegroundPixel,   getLayoutData,   getLocation,   getMenu,   getMonitor,   getParent,   getPath,   getRegion,   getShell,   getSize,   getToolTipText,   getVisible,   hasCursor,   hasFocus,   internal_dispose_GC,   internal_new_GC,   isActive,   isEnabled,   isFocusAncestor,   isFocusControl,   isReparentable,   isShowing,   isTabGroup,   isTabItem,   isVisible,   mapEvent,   markLayout,   menuShell,   mnemonicHit,   mnemonicMatch,   moveAbove,   moveBelow,   new_Accessible,   new_GC,   pack,   pack,   print,   printWidget,   redraw,   redraw,   redraw,   redrawChildren,   register,   releaseHandle,   releaseParent,   releaseWidget,   removeControlListener,   removeDragDetectListener,   removeFocusListener,   removeHelpListener,   removeKeyListener,   removeMenuDetectListener,   removeMouseListener,   removeMouseMoveListener,   removeMouseTrackListener,   removeMouseWheelListener,   removePaintListener,   removeTraverseListener,   sendFocusEvent,   sendMove,   sendResize,   setBackground,   setBackground,   setBackgroundImage,   setBackgroundImage,   setBackgroundPixel,   setBounds,   setBounds,   setBounds,   setBounds,   setCapture,   setCursor,   setCursor,   setDefaultFont,   setDragDetect,   setEnabled,   setFixedFocus,   setFocus,   setFont,   setForeground,   setForegroundPixel,   setLayoutData,   setLocation,   setLocation,   setMenu,   setParent,   setRadioFocus,   setRadioSelection,   setRedraw,   setRegion,   setSavedFocus,   setSize,   setSize,   setTabItemFocus,   setToolTipText,   setToolTipText,   setVisible,   showWidget,   sort,   subclass,   toControl,   toControl,   toDisplay,   toDisplay,   topHandle,   translateAccelerator,   translateMnemonic,   translateMnemonic,   translateTraversal,   traverse,   traverse,   traverseEscape,   traverseGroup,   traverseItem,   traverseMnemonic,   traversePage,   traverseReturn,   unsubclass,   update,   update,   updateBackgroundColor,   updateBackgroundImage,   updateBackgroundMode,   updateFont,   updateImages,   updateLayout,   widgetCreateStruct,   widgetExtStyle,   widgetParent,   widgetStyle,   windowClass,   windowProc,   windowProc,   wmColorChild,   wmCommandChild,   wmDrawChild,   wmMeasureChild,   wmNotify,   wmNotifyChild,   wmScrollChild
Methods from org.eclipse.swt.widgets.Widget:
DeferWindowPos,   SetWindowPos,   _addListener,   addDisposeListener,   addListener,   callWindowProc,   checkBits,   checkOpened,   checkOrientation,   checkParent,   checkSubclass,   checkWidget,   destroyWidget,   dispose,   dragDetect,   error,   filters,   findItem,   fixMnemonic,   fixMnemonic,   getData,   getData,   getDisplay,   getListeners,   getMenu,   getName,   getNameText,   getStyle,   hooks,   isDisposed,   isListening,   isValidSubclass,   isValidThread,   mapEvent,   new_GC,   notifyListeners,   postEvent,   postEvent,   release,   releaseChildren,   releaseHandle,   releaseParent,   releaseWidget,   removeDisposeListener,   removeListener,   removeListener,   sendDragEvent,   sendDragEvent,   sendEvent,   sendEvent,   sendEvent,   sendEvent,   sendFocusEvent,   sendKeyEvent,   sendKeyEvent,   sendMouseEvent,   sendMouseEvent,   setData,   setData,   setInputState,   setKeyState,   setTabGroupFocus,   setTabItemFocus,   showMenu,   toString,   wmCaptureChanged,   wmChar,   wmContextMenu,   wmIMEChar,   wmKeyDown,   wmKeyUp,   wmKillFocus,   wmLButtonDblClk,   wmLButtonDown,   wmLButtonUp,   wmMButtonDblClk,   wmMButtonDown,   wmMButtonUp,   wmMouseHover,   wmMouseLeave,   wmMouseMove,   wmMouseWheel,   wmNCPaint,   wmPaint,   wmPrint,   wmRButtonDblClk,   wmRButtonDown,   wmRButtonUp,   wmSetFocus,   wmSysChar,   wmSysKeyDown,   wmSysKeyUp,   wmXButtonDblClk,   wmXButtonDown,   wmXButtonUp
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.eclipse.swt.widgets.Control Detail:
 LRESULT WM_ACTIVATE(int wParam,
    int lParam) 
 LRESULT WM_CAPTURECHANGED(int wParam,
    int lParam) 
 LRESULT WM_CHANGEUISTATE(int wParam,
    int lParam) 
 LRESULT WM_CHAR(int wParam,
    int lParam) 
 LRESULT WM_CLEAR(int wParam,
    int lParam) 
 LRESULT WM_CLOSE(int wParam,
    int lParam) 
 LRESULT WM_COMMAND(int wParam,
    int lParam) 
 LRESULT WM_CONTEXTMENU(int wParam,
    int lParam) 
 LRESULT WM_CTLCOLOR(int wParam,
    int lParam) 
 LRESULT WM_CUT(int wParam,
    int lParam) 
 LRESULT WM_DESTROY(int wParam,
    int lParam) 
 LRESULT WM_DRAWITEM(int wParam,
    int lParam) 
 LRESULT WM_ENDSESSION(int wParam,
    int lParam) 
 LRESULT WM_ENTERIDLE(int wParam,
    int lParam) 
 LRESULT WM_ERASEBKGND(int wParam,
    int lParam) 
 LRESULT WM_GETDLGCODE(int wParam,
    int lParam) 
 LRESULT WM_GETFONT(int wParam,
    int lParam) 
 LRESULT WM_GETMINMAXINFO(int wParam,
    int lParam) 
 LRESULT WM_GETOBJECT(int wParam,
    int lParam) 
 LRESULT WM_HELP(int wParam,
    int lParam) 
 LRESULT WM_HOTKEY(int wParam,
    int lParam) 
 LRESULT WM_HSCROLL(int wParam,
    int lParam) 
 LRESULT WM_IME_CHAR(int wParam,
    int lParam) 
 LRESULT WM_IME_COMPOSITION(int wParam,
    int lParam) 
 LRESULT WM_IME_COMPOSITION_START(int wParam,
    int lParam) 
 LRESULT WM_IME_ENDCOMPOSITION(int wParam,
    int lParam) 
 LRESULT WM_INITMENUPOPUP(int wParam,
    int lParam) 
 LRESULT WM_INPUTLANGCHANGE(int wParam,
    int lParam) 
 LRESULT WM_KEYDOWN(int wParam,
    int lParam) 
 LRESULT WM_KEYUP(int wParam,
    int lParam) 
 LRESULT WM_KILLFOCUS(int wParam,
    int lParam) 
 LRESULT WM_LBUTTONDBLCLK(int wParam,
    int lParam) 
 LRESULT WM_LBUTTONDOWN(int wParam,
    int lParam) 
 LRESULT WM_LBUTTONUP(int wParam,
    int lParam) 
 LRESULT WM_MBUTTONDBLCLK(int wParam,
    int lParam) 
 LRESULT WM_MBUTTONDOWN(int wParam,
    int lParam) 
 LRESULT WM_MBUTTONUP(int wParam,
    int lParam) 
 LRESULT WM_MEASUREITEM(int wParam,
    int lParam) 
 LRESULT WM_MENUCHAR(int wParam,
    int lParam) 
 LRESULT WM_MENUSELECT(int wParam,
    int lParam) 
 LRESULT WM_MOUSEACTIVATE(int wParam,
    int lParam) 
 LRESULT WM_MOUSEHOVER(int wParam,
    int lParam) 
 LRESULT WM_MOUSELEAVE(int wParam,
    int lParam) 
 LRESULT WM_MOUSEMOVE(int wParam,
    int lParam) 
 LRESULT WM_MOUSEWHEEL(int wParam,
    int lParam) 
 LRESULT WM_MOVE(int wParam,
    int lParam) 
 LRESULT WM_NCACTIVATE(int wParam,
    int lParam) 
 LRESULT WM_NCCALCSIZE(int wParam,
    int lParam) 
 LRESULT WM_NCHITTEST(int wParam,
    int lParam) 
 LRESULT WM_NCLBUTTONDOWN(int wParam,
    int lParam) 
 LRESULT WM_NCPAINT(int wParam,
    int lParam) 
 LRESULT WM_NOTIFY(int wParam,
    int lParam) 
 LRESULT WM_PAINT(int wParam,
    int lParam) 
 LRESULT WM_PALETTECHANGED(int wParam,
    int lParam) 
 LRESULT WM_PARENTNOTIFY(int wParam,
    int lParam) 
 LRESULT WM_PASTE(int wParam,
    int lParam) 
 LRESULT WM_PRINT(int wParam,
    int lParam) 
 LRESULT WM_PRINTCLIENT(int wParam,
    int lParam) 
 LRESULT WM_QUERYENDSESSION(int wParam,
    int lParam) 
 LRESULT WM_QUERYNEWPALETTE(int wParam,
    int lParam) 
 LRESULT WM_QUERYOPEN(int wParam,
    int lParam) 
 LRESULT WM_RBUTTONDBLCLK(int wParam,
    int lParam) 
 LRESULT WM_RBUTTONDOWN(int wParam,
    int lParam) 
 LRESULT WM_RBUTTONUP(int wParam,
    int lParam) 
 LRESULT WM_SETCURSOR(int wParam,
    int lParam) 
 LRESULT WM_SETFOCUS(int wParam,
    int lParam) 
 LRESULT WM_SETFONT(int wParam,
    int lParam) 
 LRESULT WM_SETREDRAW(int wParam,
    int lParam) 
 LRESULT WM_SETTINGCHANGE(int wParam,
    int lParam) 
 LRESULT WM_SHOWWINDOW(int wParam,
    int lParam) 
 LRESULT WM_SIZE(int wParam,
    int lParam) 
 LRESULT WM_SYSCHAR(int wParam,
    int lParam) 
 LRESULT WM_SYSCOLORCHANGE(int wParam,
    int lParam) 
 LRESULT WM_SYSCOMMAND(int wParam,
    int lParam) 
 LRESULT WM_SYSKEYDOWN(int wParam,
    int lParam) 
 LRESULT WM_SYSKEYUP(int wParam,
    int lParam) 
 LRESULT WM_TIMER(int wParam,
    int lParam) 
 LRESULT WM_UNDO(int wParam,
    int lParam) 
 LRESULT WM_UPDATEUISTATE(int wParam,
    int lParam) 
 LRESULT WM_VSCROLL(int wParam,
    int lParam) 
 LRESULT WM_WINDOWPOSCHANGED(int wParam,
    int lParam) 
 LRESULT WM_WINDOWPOSCHANGING(int wParam,
    int lParam) 
 LRESULT WM_XBUTTONDBLCLK(int wParam,
    int lParam) 
 LRESULT WM_XBUTTONDOWN(int wParam,
    int lParam) 
 LRESULT WM_XBUTTONUP(int wParam,
    int lParam) 
 public  void addControlListener(ControlListener listener) 
    Adds the listener to the collection of listeners who will be notified when the control is moved or resized, by sending it one of the messages defined in the ControlListener interface.
 public  void addDragDetectListener(DragDetectListener listener) 
    Adds the listener to the collection of listeners who will be notified when a drag gesture occurs, by sending it one of the messages defined in the DragDetectListener interface.
 public  void addFocusListener(FocusListener listener) 
    Adds the listener to the collection of listeners who will be notified when the control gains or loses focus, by sending it one of the messages defined in the FocusListener interface.
 public  void addHelpListener(HelpListener listener) 
    Adds the listener to the collection of listeners who will be notified when help events are generated for the control, by sending it one of the messages defined in the HelpListener interface.
 public  void addKeyListener(KeyListener listener) 
    Adds the listener to the collection of listeners who will be notified when keys are pressed and released on the system keyboard, by sending it one of the messages defined in the KeyListener interface.

    When a key listener is added to a control, the control will take part in widget traversal. By default, all traversal keys (such as the tab key and so on) are delivered to the control. In order for a control to take part in traversal, it should listen for traversal events. Otherwise, the user can traverse into a control but not out. Note that native controls such as table and tree implement key traversal in the operating system. It is not necessary to add traversal listeners for these controls, unless you want to override the default traversal.

 public  void addMenuDetectListener(MenuDetectListener listener) 
    Adds the listener to the collection of listeners who will be notified when the platform-specific context menu trigger has occurred, by sending it one of the messages defined in the MenuDetectListener interface.
 public  void addMouseListener(MouseListener listener) 
    Adds the listener to the collection of listeners who will be notified when mouse buttons are pressed and released, by sending it one of the messages defined in the MouseListener interface.
 public  void addMouseMoveListener(MouseMoveListener listener) 
    Adds the listener to the collection of listeners who will be notified when the mouse moves, by sending it one of the messages defined in the MouseMoveListener interface.
 public  void addMouseTrackListener(MouseTrackListener listener) 
    Adds the listener to the collection of listeners who will be notified when the mouse passes or hovers over controls, by sending it one of the messages defined in the MouseTrackListener interface.
 public  void addMouseWheelListener(MouseWheelListener listener) 
    Adds the listener to the collection of listeners who will be notified when the mouse wheel is scrolled, by sending it one of the messages defined in the MouseWheelListener interface.
 public  void addPaintListener(PaintListener listener) 
    Adds the listener to the collection of listeners who will be notified when the receiver needs to be painted, by sending it one of the messages defined in the PaintListener interface.
 public  void addTraverseListener(TraverseListener listener) 
    Adds the listener to the collection of listeners who will be notified when traversal events occur, by sending it one of the messages defined in the TraverseListener interface.
 int borderHandle() 
  void checkBackground() 
  void checkBorder() 
  void checkBuffered() 
  void checkComposited() 
 boolean checkHandle(int hwnd) 
  void checkMirrored() 
 public Point computeSize(int wHint,
    int hHint) 
    Returns the preferred size of the receiver.

    The preferred size of a control is the size that it would best be displayed at. The width hint and height hint arguments allow the caller to ask a control questions such as "Given a particular width, how high does the control need to be to show all of the contents?" To indicate that the caller does not wish to constrain a particular dimension, the constant SWT.DEFAULT is passed for the hint.

 public Point computeSize(int wHint,
    int hHint,
    boolean changed) 
    Returns the preferred size of the receiver.

    The preferred size of a control is the size that it would best be displayed at. The width hint and height hint arguments allow the caller to ask a control questions such as "Given a particular width, how high does the control need to be to show all of the contents?" To indicate that the caller does not wish to constrain a particular dimension, the constant SWT.DEFAULT is passed for the hint.

    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.

 Widget computeTabGroup() 
 Widget[] computeTabList() 
 Control computeTabRoot() 
  void createHandle() 
  void createWidget() 
 int defaultBackground() 
 int defaultFont() 
 int defaultForeground() 
  void deregister() 
  void destroyWidget() 
 public boolean dragDetect(Event event) 
    Detects a drag and drop gesture. This method is used to detect a drag gesture when called from within a mouse down listener.

    By default, a drag is detected when the gesture occurs anywhere within the client area of a control. Some controls, such as tables and trees, override this behavior. In addition to the operating system specific drag gesture, they require the mouse to be inside an item. Custom widget writers can use setDragDetect to disable the default detection, listen for mouse down, and then call dragDetect() from within the listener to conditionally detect a drag.

 public boolean dragDetect(MouseEvent event) 
    Detects a drag and drop gesture. This method is used to detect a drag gesture when called from within a mouse down listener.

    By default, a drag is detected when the gesture occurs anywhere within the client area of a control. Some controls, such as tables and trees, override this behavior. In addition to the operating system specific drag gesture, they require the mouse to be inside an item. Custom widget writers can use setDragDetect to disable the default detection, listen for mouse down, and then call dragDetect() from within the listener to conditionally detect a drag.

 boolean dragDetect(int button,
    int count,
    int stateMask,
    int x,
    int y) 
  void drawBackground(int hDC) 
  void drawBackground(int hDC,
    RECT rect) 
  void drawBackground(int hDC,
    RECT rect,
    int pixel) 
  void drawImageBackground(int hDC,
    int hwnd,
    int hBitmap,
    RECT rect) 
  void drawThemeBackground(int hDC,
    int hwnd,
    RECT rect) 
  void enableDrag(boolean enabled) 
  void enableWidget(boolean enabled) 
  void fillBackground(int hDC,
    int pixel,
    RECT rect) 
  void fillImageBackground(int hDC,
    Control control,
    RECT rect) 
  void fillThemeBackground(int hDC,
    Control control,
    RECT rect) 
 Control findBackgroundControl() 
 int findBrush(int value,
    int lbStyle) 
 Cursor findCursor() 
 Control findImageControl() 
 Menu[] findMenus(Control control) 
 char findMnemonic(String string) 
 Control findThemeControl() 
  void fixChildren(Shell newShell,
    Shell oldShell,
    Decorations newDecorations,
    Decorations oldDecorations,
    Menu[] menus) 
  void fixFocus(Control focusControl) 
 public boolean forceFocus() 
    Forces the receiver to have the keyboard focus, causing all keyboard events to be delivered to it.
  void forceResize() 
 public Accessible getAccessible() 
    Returns the accessible object for the receiver. If this is the first time this object is requested, then the object is created and returned.
 public Color getBackground() 
    Returns the receiver's background color.

    Note: This operation is a hint and may be overridden by the platform. For example, on some versions of Windows the background of a TabFolder, is a gradient rather than a solid color.

 public Image getBackgroundImage() 
    Returns the receiver's background image.
 int getBackgroundPixel() 
 public int getBorderWidth() 
    Returns the receiver's border width.
 public Rectangle getBounds() 
    Returns a rectangle describing the receiver's size and location relative to its parent (or its display if its parent is null), unless the receiver is a shell. In this case, the location is relative to the display.
 String getClipboardText() 
 int getCodePage() 
 public Cursor getCursor() 
    Returns the receiver's cursor, or null if it has not been set.

    When the mouse pointer passes over a control its appearance is changed to match the control's cursor.

 public boolean getDragDetect() 
    Returns true if the receiver is detecting drag gestures, and false otherwise.
 boolean getDrawing() 
 public boolean getEnabled() 
    Returns true if the receiver is enabled, and false otherwise. A disabled control is typically not selectable from the user interface and draws with an inactive or "grayed" look.
 public Font getFont() 
    Returns the font that the receiver will use to paint textual information.
 public Color getForeground() 
    Returns the foreground color that the receiver will use to draw.
 int getForegroundPixel() 
 public Object getLayoutData() 
    Returns layout data which is associated with the receiver.
 public Point getLocation() 
    Returns a point describing the receiver's location relative to its parent (or its display if its parent is null), unless the receiver is a shell. In this case, the point is relative to the display.
 public Menu getMenu() 
    Returns the receiver's pop up menu if it has one, or null if it does not. All controls may optionally have a pop up menu that is displayed when the user requests one for the control. The sequence of key strokes, button presses and/or button releases that are used to request a pop up menu is platform specific.
 public Monitor getMonitor() 
    Returns the receiver's monitor.
 public Composite getParent() 
    Returns the receiver's parent, which must be a Composite or null when the receiver is a shell that was created with null or a display for a parent.
 Control[] getPath() 
 public Region getRegion() 
    Returns the region that defines the shape of the control, or null if the control has the default shape.
 public Shell getShell() 
    Returns the receiver's shell. For all controls other than shells, this simply returns the control's nearest ancestor shell. Shells return themselves, even if they are children of other shells.
 public Point getSize() 
    Returns a point describing the receiver's size. The x coordinate of the result is the width of the receiver. The y coordinate of the result is the height of the receiver.
 public String getToolTipText() 
    Returns the receiver's tool tip text, or null if it has not been set.
 public boolean getVisible() 
    Returns true if the receiver is visible, and false otherwise.

    If one of the receiver's ancestors is not visible or some other condition makes the receiver not visible, this method may still indicate that it is considered visible even though it may not actually be showing.

 boolean hasCursor() 
 boolean hasFocus() 
 public  void internal_dispose_GC(int hDC,
    GCData data) 
    Invokes platform specific functionality to dispose a GC handle.

    IMPORTANT: This method is not part of the public API for Control. It is marked public only so that it can be shared within the packages provided by SWT. It is not available on all platforms, and should never be called from application code.

 public int internal_new_GC(GCData data) 
    Invokes platform specific functionality to allocate a new GC handle.

    IMPORTANT: This method is not part of the public API for Control. It is marked public only so that it can be shared within the packages provided by SWT. It is not available on all platforms, and should never be called from application code.

 boolean isActive() 
 public boolean isEnabled() 
    Returns true if the receiver is enabled and all ancestors up to and including the receiver's nearest ancestor shell are enabled. Otherwise, false is returned. A disabled control is typically not selectable from the user interface and draws with an inactive or "grayed" look.
 boolean isFocusAncestor(Control control) 
 public boolean isFocusControl() 
    Returns true if the receiver has the user-interface focus, and false otherwise.
 public boolean isReparentable() 
    Returns true if the underlying operating system supports this reparenting, otherwise false
 boolean isShowing() 
 boolean isTabGroup() 
 boolean isTabItem() 
 public boolean isVisible() 
    Returns true if the receiver is visible and all ancestors up to and including the receiver's nearest ancestor shell are visible. Otherwise, false is returned.
  void mapEvent(int hwnd,
    Event event) 
  void markLayout(boolean changed,
    boolean all) 
 Decorations menuShell() 
 boolean mnemonicHit(char key) 
 boolean mnemonicMatch(char key) 
 public  void moveAbove(Control control) 
    Moves the receiver above the specified control in the drawing order. If the argument is null, then the receiver is moved to the top of the drawing order. The control at the top of the drawing order will not be covered by other controls even if they occupy intersecting areas.
 public  void moveBelow(Control control) 
    Moves the receiver below the specified control in the drawing order. If the argument is null, then the receiver is moved to the bottom of the drawing order. The control at the bottom of the drawing order will be covered by all other controls which occupy intersecting areas.
 Accessible new_Accessible(Control control) 
 GC new_GC(GCData data) 
 public  void pack() 
    Causes the receiver to be resized to its preferred size. For a composite, this involves computing the preferred size from its layout, if there is one.
 public  void pack(boolean changed) 
    Causes the receiver to be resized to its preferred size. For a composite, this involves computing the preferred size from its layout, if there is one.

    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.

 public boolean print(GC gc) 
    Prints the receiver and all children.
  void printWidget(int hwnd,
    int hdc,
    GC gc) 
 public  void redraw() 
    Causes the entire bounds of the receiver to be marked as needing to be redrawn. The next time a paint request is processed, the control will be completely painted, including the background.
  void redraw(boolean all) 
 public  void redraw(int x,
    int y,
    int width,
    int height,
    boolean all) 
    Causes the rectangular area of the receiver specified by the arguments to be marked as needing to be redrawn. The next time a paint request is processed, that area of the receiver will be painted, including the background. If the all flag is true, any children of the receiver which intersect with the specified area will also paint their intersecting areas. If the all flag is false, the children will not be painted.
 boolean redrawChildren() 
  void register() 
  void releaseHandle() 
  void releaseParent() 
  void releaseWidget() 
 public  void removeControlListener(ControlListener listener) 
    Removes the listener from the collection of listeners who will be notified when the control is moved or resized.
 public  void removeDragDetectListener(DragDetectListener listener) 
    Removes the listener from the collection of listeners who will be notified when a drag gesture occurs.
 public  void removeFocusListener(FocusListener listener) 
    Removes the listener from the collection of listeners who will be notified when the control gains or loses focus.
 public  void removeHelpListener(HelpListener listener) 
    Removes the listener from the collection of listeners who will be notified when the help events are generated for the control.
 public  void removeKeyListener(KeyListener listener) 
    Removes the listener from the collection of listeners who will be notified when keys are pressed and released on the system keyboard.
 public  void removeMenuDetectListener(MenuDetectListener listener) 
    Removes the listener from the collection of listeners who will be notified when the platform-specific context menu trigger has occurred.
 public  void removeMouseListener(MouseListener listener) 
    Removes the listener from the collection of listeners who will be notified when mouse buttons are pressed and released.
 public  void removeMouseMoveListener(MouseMoveListener listener) 
    Removes the listener from the collection of listeners who will be notified when the mouse moves.
 public  void removeMouseTrackListener(MouseTrackListener listener) 
    Removes the listener from the collection of listeners who will be notified when the mouse passes or hovers over controls.
 public  void removeMouseWheelListener(MouseWheelListener listener) 
    Removes the listener from the collection of listeners who will be notified when the mouse wheel is scrolled.
 public  void removePaintListener(PaintListener listener) 
    Removes the listener from the collection of listeners who will be notified when the receiver needs to be painted.
 public  void removeTraverseListener(TraverseListener listener) 
    Removes the listener from the collection of listeners who will be notified when traversal events occur.
 boolean sendFocusEvent(int type) 
  void sendMove() 
  void sendResize() 
  void setBackground() 
 public  void setBackground(Color color) 
    Sets the receiver's background color to the color specified by the argument, or to the default system color for the control if the argument is null.

    Note: This operation is a hint and may be overridden by the platform. For example, on Windows the background of a Button cannot be changed.

 public  void setBackgroundImage(Image image) 
    Sets the receiver's background image to the image specified by the argument, or to the default system color for the control if the argument is null. The background image is tiled to fill the available space.

    Note: This operation is a hint and may be overridden by the platform. For example, on Windows the background of a Button cannot be changed.

  void setBackgroundImage(int hBitmap) 
  void setBackgroundPixel(int pixel) 
 public  void setBounds(Rectangle rect) 
    Sets the receiver's size and location to the rectangular area specified by the argument. The x and y fields of the rectangle are relative to the receiver's parent (or its display if its parent is null).

    Note: Attempting to set the width or height of the receiver to a negative number will cause that value to be set to zero instead.

 public  void setBounds(int x,
    int y,
    int width,
    int height) 
    Sets the receiver's size and location to the rectangular area specified by the arguments. The x and y arguments are relative to the receiver's parent (or its display if its parent is null), unless the receiver is a shell. In this case, the x and y arguments are relative to the display.

    Note: Attempting to set the width or height of the receiver to a negative number will cause that value to be set to zero instead.

  void setBounds(int x,
    int y,
    int width,
    int height,
    int flags) 
  void setBounds(int x,
    int y,
    int width,
    int height,
    int flags,
    boolean defer) 
 public  void setCapture(boolean capture) 
    If the argument is true, causes the receiver to have all mouse events delivered to it until the method is called with false as the argument. Note that on some platforms, a mouse button must currently be down for capture to be assigned.
  void setCursor() 
 public  void setCursor(Cursor cursor) 
    Sets the receiver's cursor to the cursor specified by the argument, or to the default cursor for that kind of control if the argument is null.

    When the mouse pointer passes over a control its appearance is changed to match the control's cursor.

  void setDefaultFont() 
 public  void setDragDetect(boolean dragDetect) 
    Sets the receiver's drag detect state. If the argument is true, the receiver will detect drag gestures, otherwise these gestures will be ignored.
 public  void setEnabled(boolean enabled) 
    Enables the receiver if the argument is true, and disables it otherwise. A disabled control is typically not selectable from the user interface and draws with an inactive or "grayed" look.
 boolean setFixedFocus() 
 public boolean setFocus() 
    Causes the receiver to have the keyboard focus, such that all keyboard events will be delivered to it. Focus reassignment will respect applicable platform constraints.
 public  void setFont(Font font) 
    Sets the font that the receiver will use to paint textual information to the font specified by the argument, or to the default font for that kind of control if the argument is null.
 public  void setForeground(Color color) 
    Sets the receiver's foreground color to the color specified by the argument, or to the default system color for the control if the argument is null.

    Note: This operation is a hint and may be overridden by the platform.

  void setForegroundPixel(int pixel) 
 public  void setLayoutData(Object layoutData) 
    Sets the layout data associated with the receiver to the argument.
 public  void setLocation(Point location) 
    Sets the receiver's location to the point specified by the arguments which are relative to the receiver's parent (or its display if its parent is null), unless the receiver is a shell. In this case, the point is relative to the display.
 public  void setLocation(int x,
    int y) 
    Sets the receiver's location to the point specified by the arguments which are relative to the receiver's parent (or its display if its parent is null), unless the receiver is a shell. In this case, the point is relative to the display.
 public  void setMenu(Menu menu) 
    Sets the receiver's pop up menu to the argument. All controls may optionally have a pop up menu that is displayed when the user requests one for the control. The sequence of key strokes, button presses and/or button releases that are used to request a pop up menu is platform specific.

    Note: Disposing of a control that has a pop up menu will dispose of the menu. To avoid this behavior, set the menu to null before the control is disposed.

 public boolean setParent(Composite parent) 
    Changes the parent of the widget to be the one provided if the underlying operating system supports this feature. Returns true if the parent is successfully changed.
 boolean setRadioFocus(boolean tabbing) 
 boolean setRadioSelection(boolean value) 
 public  void setRedraw(boolean redraw) 
    If the argument is false, causes subsequent drawing operations in the receiver to be ignored. No drawing of any kind can occur in the receiver until the flag is set to true. Graphics operations that occurred while the flag was false are lost. When the flag is set to true, the entire widget is marked as needing to be redrawn. Nested calls to this method are stacked.

    Note: This operation is a hint and may not be supported on some platforms or for some widgets.

 public  void setRegion(Region region) 
    Sets the shape of the control to the region specified by the argument. When the argument is null, the default shape of the control is restored.
 boolean setSavedFocus() 
 public  void setSize(Point size) 
    Sets the receiver's size to the point specified by the argument.

    Note: Attempting to set the width or height of the receiver to a negative number will cause them to be set to zero instead.

 public  void setSize(int width,
    int height) 
    Sets the receiver's size to the point specified by the arguments.

    Note: Attempting to set the width or height of the receiver to a negative number will cause that value to be set to zero instead.

 boolean setTabItemFocus() 
 public  void setToolTipText(String string) 
    Sets the receiver's tool tip text to the argument, which may be null indicating that the default tool tip for the control will be shown. For a control that has a default tool tip, such as the Tree control on Windows, setting the tool tip text to an empty string replaces the default, causing no tool tip text to be shown.

    The mnemonic indicator (character '&') is not displayed in a tool tip. To display a single '&' in the tool tip, the character '&' can be escaped by doubling it in the string.

  void setToolTipText(Shell shell,
    String string) 
 public  void setVisible(boolean visible) 
    Marks the receiver as visible if the argument is true, and marks it invisible otherwise.

    If one of the receiver's ancestors is not visible or some other condition makes the receiver not visible, marking it visible may not actually cause it to be displayed.

  void showWidget(boolean visible) 
  void sort(int[] items) 
  void subclass() 
 public Point toControl(Point point) 
    Returns a point which is the result of converting the argument, which is specified in display relative coordinates, to coordinates relative to the receiver.

 public Point toControl(int x,
    int y) 
    Returns a point which is the result of converting the argument, which is specified in display relative coordinates, to coordinates relative to the receiver.

 public Point toDisplay(Point point) 
    Returns a point which is the result of converting the argument, which is specified in coordinates relative to the receiver, to display relative coordinates.

 public Point toDisplay(int x,
    int y) 
    Returns a point which is the result of converting the argument, which is specified in coordinates relative to the receiver, to display relative coordinates.

 int topHandle() 
 boolean translateAccelerator(MSG msg) 
 boolean translateMnemonic(MSG msg) 
 boolean translateMnemonic(Event event,
    Control control) 
 boolean translateTraversal(MSG msg) 
 boolean traverse(Event event) 
 public boolean traverse(int traversal) 
    Based on the argument, perform one of the expected platform traversal action. The argument should be one of the constants: SWT.TRAVERSE_ESCAPE, SWT.TRAVERSE_RETURN, SWT.TRAVERSE_TAB_NEXT, SWT.TRAVERSE_TAB_PREVIOUS, SWT.TRAVERSE_ARROW_NEXT and SWT.TRAVERSE_ARROW_PREVIOUS.
 boolean traverseEscape() 
 boolean traverseGroup(boolean next) 
 boolean traverseItem(boolean next) 
 boolean traverseMnemonic(char key) 
 boolean traversePage(boolean next) 
 boolean traverseReturn() 
  void unsubclass() 
 public  void update() 
    Forces all outstanding paint requests for the widget to be processed before this method returns. If there are no outstanding paint request, this method does nothing.

    Note: This method does not cause a redraw.

  void update(boolean all) 
  void updateBackgroundColor() 
  void updateBackgroundImage() 
  void updateBackgroundMode() 
  void updateFont(Font oldFont,
    Font newFont) 
  void updateImages() 
  void updateLayout(boolean resize,
    boolean all) 
 CREATESTRUCT widgetCreateStruct() 
 int widgetExtStyle() 
 int widgetParent() 
 int widgetStyle() 
 abstract TCHAR windowClass()
 abstract int windowProc()
 int windowProc(int hwnd,
    int msg,
    int wParam,
    int lParam) 
 LRESULT wmColorChild(int wParam,
    int lParam) 
 LRESULT wmCommandChild(int wParam,
    int lParam) 
 LRESULT wmDrawChild(int wParam,
    int lParam) 
 LRESULT wmMeasureChild(int wParam,
    int lParam) 
 LRESULT wmNotify(NMHDR hdr,
    int wParam,
    int lParam) 
 LRESULT wmNotifyChild(NMHDR hdr,
    int wParam,
    int lParam) 
 LRESULT wmScrollChild(int wParam,
    int lParam)