java.lang.Object | +--org.eclipse.swt.widgets.Widget | +--org.eclipse.swt.widgets.Control | +--org.eclipse.swt.widgets.Scrollable | +--org.eclipse.swt.widgets.Composite | +--org.eclipse.swt.widgets.Tree
Safe:
ACCENTS, accessible, background, drawCount, foreground, handle, hCursor, layoutData, menu, parent, toolTipText
CANVAS, COMCTL32_MAJOR, COMCTL32_MINOR, data, DEFAULT_HEIGHT, DEFAULT_WIDTH, DISABLED, DISPOSED, eventTable, HIDDEN, keys, MAJOR, MINOR, Mnemonic, state, style, values
Tree(Composite parent,
int style)
void
addSelectionListener(SelectionListener listener)
SelectionListener
interface.
void
addTreeListener(TreeListener listener)
TreeListener
interface.
TreeItem
getItem(Point point)
int
getItemCount()
int
getItemHeight()
TreeItem[]
getItems()
TreeItem
getParentItem()
TreeItem or null when the receiver is a
root.
TreeItem[]
getSelection()
TreeItems that are currently
selected in the receiver.
void
removeSelectionListener(SelectionListener listener)
void
removeTreeListener(TreeListener listener)
void
setInsertMark(TreeItem item,
boolean before)
void
setSelection(TreeItem[] items)
void
setTopItem(TreeItem item)
_getChildren, _getTabList, checkSubclass, computeTabList, getChildren, getChildrenCount, getLayout, getTabList, hooksKeys, layout, layout, minimumSize, moveAbove, moveBelow, releaseChildren, resizeChildren, resizeChildren, setFocus, setLayout, setResizeChildren, setTabGroupFocus, setTabItemFocus, setTabList, translateMnemonic, updateFont, WM_ERASEBKGND, WM_GETDLGCODE, WM_GETFONT, WM_NOTIFY, WM_PAINT, WM_SETFONT, WM_SIZE, WM_SYSCOMMAND
computeTrim, createScrollBar, getClientArea, getHorizontalBar, getVerticalBar, widgetExtStyle, WM_HSCROLL, WM_MOUSEWHEEL, WM_VSCROLL, wmScroll
addControlListener, addFocusListener, addHelpListener, addKeyListener, addMouseListener, addMouseMoveListener, addMouseTrackListener, addPaintListener, addTraverseListener, checkOrientation, computeSize, computeTabGroup, computeTabRoot, defaultFont, defaultForeground, deregister, destroyWidget, drawBackground, drawBackground, findBrush, findCursor, findMnemonic, fixFocus, forceFocus, forceResize, getAccessible, getBackground, getBorderWidth, getBounds, getCodePage, getDisplay, getEnabled, getFont, getForeground, getLayoutData, getLocation, getMenu, getParent, getPath, getShell, getSize, getToolTipText, getVisible, hasCursor, hasFocus, internal_dispose_GC, internal_new_GC, isActive, isDisposed, isEnabled, isFocusAncestor, isFocusControl, isReparentable, isShowing, isTabGroup, isTabItem, isVisible, menuShell, mnemonicHit, mnemonicMatch, moveAbove, moveBelow, new_Accessible, pack, pack, redraw, redraw, register, releaseHandle, removeControlListener, removeFocusListener, removeHelpListener, removeKeyListener, removeMouseListener, removeMouseMoveListener, removeMouseTrackListener, removePaintListener, removeTraverseListener, sendKeyEvent, sendKeyEvent, sendMouseEvent, sendMouseEvent, setBackground, setBounds, setBounds, setCapture, setCursor, setDefaultFont, setEnabled, setFont, setForeground, setLayoutData, setLocation, setLocation, setMenu, setParent, setRadioFocus, setRadioSelection, setSavedFocus, setSize, setSize, setToolTipText, setVisible, sort, subclass, toControl, toControl, toDisplay, toDisplay, transferActive, transferFocus, translateAccelerator, translateMnemonic, translateTraversal, traverse, traverse, traverseEscape, traverseGroup, traverseItem, traverseMnemonic, traversePage, traverseReturn, unsubclass, update, update, windowProc, WM_ACTIVATE, WM_CLEAR, WM_CLOSE, WM_COMMAND, WM_CONTEXTMENU, WM_CTLCOLOR, WM_CUT, WM_DESTROY, WM_DRAWITEM, WM_ENDSESSION, WM_HELP, WM_HOTKEY, WM_IME_CHAR, WM_IME_COMPOSITION, WM_INITMENUPOPUP, WM_KEYUP, WM_LBUTTONDBLCLK, WM_LBUTTONUP, WM_MBUTTONDBLCLK, WM_MBUTTONDOWN, WM_MBUTTONUP, WM_MEASUREITEM, WM_MENUCHAR, WM_MENUSELECT, WM_MOUSEACTIVATE, WM_MOUSEHOVER, WM_MOUSELEAVE, WM_MOUSEMOVE, WM_MOVE, WM_NCACTIVATE, WM_NCCALCSIZE, WM_NCHITTEST, WM_PALETTECHANGED, WM_PASTE, WM_PRINTCLIENT, WM_QUERYENDSESSION, WM_QUERYNEWPALETTE, WM_QUERYOPEN, WM_RBUTTONDBLCLK, WM_RBUTTONUP, WM_SETCURSOR, WM_SETREDRAW, WM_SETTINGCHANGE, WM_SHOWWINDOW, WM_SYSCHAR, WM_SYSKEYDOWN, WM_SYSKEYUP, WM_TIMER, WM_UNDO, WM_WINDOWPOSCHANGING, wmColorChild, wmCommandChild, wmDrawChild, wmMeasureChild, wmScrollChild
addDisposeListener, addListener, checkBits, checkParent, checkWidget, dispose, error, filters, getData, getData, getName, getNameText, getStyle, hooks, isListening, isValidSubclass, isValidThread, mbcsToWcs, mbcsToWcs, notifyListeners, postEvent, postEvent, releaseChild, releaseResources, removeDisposeListener, removeListener, removeListener, sendEvent, sendEvent, sendEvent, sendEvent, setData, setData, setInputState, setKeyState, toString, wcsToMbcs, wcsToMbcs
int hAnchor
TreeItem[] items
ImageList imageList
boolean dragStarted
boolean ignoreSelect
boolean ignoreExpand
boolean ignoreDeselect
boolean customDraw
static final int TreeProc
static final org.eclipse.swt.internal.win32.TCHAR TreeClass
public Tree(Composite parent, 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.
parent - a composite control which will be the parent of the new instance (cannot be null)style - the style of control to constructSWT.SINGLE,
SWT.MULTI,
SWT.CHECK,
Widget.checkSubclass(),
Widget.getStyle()public void addSelectionListener(SelectionListener listener)
SelectionListener
interface.
When widgetSelected is called, the item field of the event object is valid.
If the reciever has SWT.CHECK style set and the check selection changes,
the event object detail field contains the value SWT.CHECK.
widgetDefaultSelected is typically called when an item is double-clicked.
The item field of the event object is valid for default selection, but the detail field is not used.
listener - the listener which should be notifiedSelectionListener,
removeSelectionListener(org.eclipse.swt.events.SelectionListener),
SelectionEventpublic void addTreeListener(TreeListener listener)
TreeListener
interface.
listener - the listener which should be notifiedTreeListener,
removeTreeListener(org.eclipse.swt.events.TreeListener)int callWindowProc(int msg, int wParam, int lParam)
callWindowProc in class Scrollablestatic int checkStyle(int style)
public Point computeSize(int wHint, int hHint, boolean changed)
computeSize in class CompositewHint - the width hint (can be SWT.DEFAULT)hHint - the height hint (can be SWT.DEFAULT)changed - true if the control's contents have changed, and false otherwise
Layout,
Control.getBorderWidth(),
Control.getBounds(),
Control.getSize(),
Control.pack(),
"computeTrim, getClientArea for controls that implement them"void createHandle()
createHandle in class Compositevoid createItem(TreeItem item, int hParent, int hInsertAfter)
void createWidget()
createWidget in class Scrollableint defaultBackground()
defaultBackground in class Controlpublic void deselectAll()
void destroyItem(TreeItem item)
int getBackgroundPixel()
getBackgroundPixel in class Controlint getForegroundPixel()
getForegroundPixel in class Controlpublic TreeItem getItem(Point point)
point - the point used to locate the item
public int getItemCount()
public int getItemHeight()
public TreeItem[] getItems()
Note: This is not the actual structure used by the receiver to maintain its list of items, so modifying the array will not affect the receiver.
public TreeItem getParentItem()
TreeItem or null when the receiver is a
root.
public TreeItem[] getSelection()
TreeItems that are currently
selected in the receiver. An empty array indicates that no
items are selected.
Note: This is not the actual structure used by the receiver to maintain its selection, so modifying the array will not affect the receiver.
public int getSelectionCount()
public TreeItem getTopItem()
int imageIndex(Image image)
boolean releaseItem(TreeItem item, org.eclipse.swt.internal.win32.TVITEM tvItem)
void releaseItems(TreeItem[] nodes, org.eclipse.swt.internal.win32.TVITEM tvItem)
void releaseWidget()
releaseWidget in class Compositepublic void removeAll()
public void removeSelectionListener(SelectionListener listener)
listener - the listener which should no longer be notifiedSelectionListener,
addSelectionListener(org.eclipse.swt.events.SelectionListener)public void removeTreeListener(TreeListener listener)
listener - the listener which should no longer be notifiedTreeListener,
addTreeListener(org.eclipse.swt.events.TreeListener)public void setInsertMark(TreeItem item, boolean before)
item - the insert item. Null will clear the insertion mark.public void selectAll()
void setBackgroundPixel(int pixel)
setBackgroundPixel in class Controlvoid setBounds(int x, int y, int width, int height, int flags)
void setCheckboxImageList()
void setForegroundPixel(int pixel)
setForegroundPixel in class Controlpublic void setRedraw(boolean redraw)
redraw - the new redraw stateControl.redraw(),
Control.update()public void setSelection(TreeItem[] items)
items - the array of itemsdeselectAll()public void setTopItem(TreeItem item)
item - the item to be showngetTopItem()void showItem(int hItem)
public void showItem(TreeItem item)
item - the item to be shownshowSelection()public void showSelection()
showItem(TreeItem)String toolTipText(org.eclipse.swt.internal.win32.NMTTDISPINFO hdr)
toolTipText in class Compositeint widgetStyle()
widgetStyle in class Compositeorg.eclipse.swt.internal.win32.TCHAR windowClass()
windowClass in class Scrollableint windowProc()
windowProc in class Scrollableorg.eclipse.swt.internal.win32.LRESULT WM_CHAR(int wParam, int lParam)
org.eclipse.swt.internal.win32.LRESULT WM_GETOBJECT(int wParam, int lParam)
WM_GETOBJECT in class Controlorg.eclipse.swt.internal.win32.LRESULT WM_KEYDOWN(int wParam, int lParam)
WM_KEYDOWN in class Controlorg.eclipse.swt.internal.win32.LRESULT WM_KILLFOCUS(int wParam, int lParam)
WM_KILLFOCUS in class Controlorg.eclipse.swt.internal.win32.LRESULT WM_LBUTTONDOWN(int wParam, int lParam)
WM_LBUTTONDOWN in class Compositeorg.eclipse.swt.internal.win32.LRESULT WM_RBUTTONDOWN(int wParam, int lParam)
WM_RBUTTONDOWN in class Controlorg.eclipse.swt.internal.win32.LRESULT WM_SETFOCUS(int wParam, int lParam)
WM_SETFOCUS in class Controlorg.eclipse.swt.internal.win32.LRESULT WM_SYSCOLORCHANGE(int wParam, int lParam)
WM_SYSCOLORCHANGE in class Compositeorg.eclipse.swt.internal.win32.LRESULT wmNotifyChild(int wParam, int lParam)
wmNotifyChild in class Control