public class ConstUI extends Object
Modifier and Type | Field and Description |
---|---|
static int |
COLOR_BACKGROUND_BLUE
The default blue-component of the background color
|
static int |
COLOR_BACKGROUND_GREEN
The default green-component of the background color
|
static int |
COLOR_BACKGROUND_RED
The default red-component of the background color
|
static int |
COLOR_GRAPH_BLUE
The default blue-component of the graph background color
|
static int |
COLOR_GRAPH_GREEN
The default green-component of the graph background color
|
static int |
COLOR_GRAPH_RED
The default red-component of the graph background color
|
static int |
COLOR_TAB_BLUE
The default blue-component of the tab selected color
|
static int |
COLOR_TAB_GREEN
The default green-component of the tab selected color
|
static int |
COLOR_TAB_RED
The default red-component of the tab selected color
|
static int |
GRID_SIZE
Default grid size to which the graphical views snap.
|
static int |
ICON_SIZE
Default icon size
|
static int |
INTERVAL_MS_TRANS_CANVAS_REFRESH
the default canvas refresh interval for running transformations
|
static int |
LINE_WIDTH
Default line width for arrows & around icons
|
static int |
NOTE_MIN_SIZE
The minimal size of a note on a graphical view (width & height)
|
static int |
TOOLTIP_OFFSET
Offset between pointer and tooltip position.
|
Constructor and Description |
---|
ConstUI() |
Modifier and Type | Method and Description |
---|---|
static void |
displayMenu(org.eclipse.swt.widgets.Menu menu,
org.eclipse.swt.widgets.Control control) |
static void |
displayMenu(org.pentaho.ui.xul.containers.XulMenupopup xulMenuPopup,
org.eclipse.swt.widgets.Control control) |
static org.eclipse.swt.widgets.TreeItem |
findTreeItem(org.eclipse.swt.widgets.TreeItem parent,
String name) |
static org.eclipse.swt.widgets.TreeItem |
findTreeItem(org.eclipse.swt.widgets.TreeItem parent,
String parentName,
String name)
Finds a TreeItem with a certain label (name) in a (part of a) tree.
|
static void |
flipExpanded(org.eclipse.swt.widgets.TreeItem ti)
Flips the TreeItem from expanded to not expanded or vice-versa.
|
static int |
getTreeLevel(org.eclipse.swt.widgets.TreeItem ti)
Determine the level of where the TreeItem is position in a tree.
|
static String |
getTreePath(org.eclipse.swt.widgets.TreeItem ti,
int from)
Return the tree path seperated by Const.FILE_SEPARATOR, starting from a certain depth in the tree.
|
static String[] |
getTreeStrings(org.eclipse.swt.widgets.TreeItem ti)
Get an array of strings containing the path from the given TreeItem to the parent.
|
public static final int ICON_SIZE
public static final int LINE_WIDTH
public static final int GRID_SIZE
public static final int NOTE_MIN_SIZE
public static final int TOOLTIP_OFFSET
public static final int COLOR_BACKGROUND_RED
public static final int COLOR_BACKGROUND_GREEN
public static final int COLOR_BACKGROUND_BLUE
public static final int COLOR_GRAPH_RED
public static final int COLOR_GRAPH_GREEN
public static final int COLOR_GRAPH_BLUE
public static final int COLOR_TAB_RED
public static final int COLOR_TAB_GREEN
public static final int COLOR_TAB_BLUE
public static final int INTERVAL_MS_TRANS_CANVAS_REFRESH
public static final int getTreeLevel(org.eclipse.swt.widgets.TreeItem ti)
ti
- The TreeItempublic static final String[] getTreeStrings(org.eclipse.swt.widgets.TreeItem ti)
ti
- The TreeItem to look atpublic static final String getTreePath(org.eclipse.swt.widgets.TreeItem ti, int from)
ti
- The TreeItem to get the path forfrom
- The depth to start at, use 0 to get the complete tree.public static final void flipExpanded(org.eclipse.swt.widgets.TreeItem ti)
ti
- The TreeItem to flip.public static final org.eclipse.swt.widgets.TreeItem findTreeItem(org.eclipse.swt.widgets.TreeItem parent, String name)
public static final org.eclipse.swt.widgets.TreeItem findTreeItem(org.eclipse.swt.widgets.TreeItem parent, String parentName, String name)
parent
- The TreeItem where we start looking.parentName
- The name of the parent to match as well (null=not used)name
- The name or item label to look for.public static void displayMenu(org.pentaho.ui.xul.containers.XulMenupopup xulMenuPopup, org.eclipse.swt.widgets.Control control)
public static void displayMenu(org.eclipse.swt.widgets.Menu menu, org.eclipse.swt.widgets.Control control)