|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object edu.ksu.cis.kdd.util.gui.GUIUtil
Smorgasbord of GUI utilities
Field Summary | |
protected static java.awt.BasicStroke |
defaultMarquee
|
protected static float[] |
defaultMarqueePattern
|
static java.awt.Dimension |
screenSize
|
Constructor Summary | |
GUIUtil()
|
Method Summary | |
static java.awt.Dimension |
center(java.awt.Dimension src,
java.awt.Dimension dest)
Center a dimension of src to dest |
static void |
centerToComponent(java.awt.Component src,
java.awt.Component dest)
Component src is centered within component dest. |
static void |
centerToScreen(java.awt.Component c)
Center component c to the screen |
static java.awt.Dimension |
centerToScreen(java.awt.Dimension src)
Center a dimension src to the screen |
static javax.swing.JComboBox |
createComboBox(java.util.Collection c)
|
static java.awt.BasicStroke |
createMarquee(float[] pattern)
|
static java.awt.BasicStroke |
createMarquee(float width,
float[] pattern)
|
static java.awt.BasicStroke |
createMarquee(float width,
float[] pattern,
float offset)
|
static void |
gbAdd(java.awt.Container c,
java.awt.Component comp,
int x,
int y,
int w,
int h,
int up,
int down,
int left,
int right,
int fill,
int anchor,
double wx,
double wy)
Grid bag add |
static java.awt.BasicStroke |
getDefaultMarquee()
|
static boolean |
isCenterMouseButton(java.awt.event.MouseEvent e)
|
static boolean |
isLeftMouseButton(java.awt.event.MouseEvent e)
|
static boolean |
isRightMouseButton(java.awt.event.MouseEvent e)
|
static javax.swing.LookAndFeel |
loadLookAndFeel(java.lang.String className)
|
static void |
loadTheme(java.lang.String themeFileName)
|
static void |
switchToNativeUI(java.awt.Component c)
Switch component c's look and feel to native user interface |
static void |
switchUI(java.lang.String laf)
|
static javax.swing.KeyStroke |
translateShortcut(java.lang.String shortcut)
Translate a string shortcut to the respective keystroke object for Swing |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static java.awt.Dimension screenSize
protected static float[] defaultMarqueePattern
protected static java.awt.BasicStroke defaultMarquee
Constructor Detail |
public GUIUtil()
Method Detail |
public static void switchToNativeUI(java.awt.Component c)
c
- public static void switchUI(java.lang.String laf)
public static javax.swing.LookAndFeel loadLookAndFeel(java.lang.String className) throws java.lang.ClassNotFoundException
java.lang.ClassNotFoundException
public static void loadTheme(java.lang.String themeFileName)
public static java.awt.Dimension center(java.awt.Dimension src, java.awt.Dimension dest)
src
- dest
-
public static java.awt.Dimension centerToScreen(java.awt.Dimension src)
src
-
public static void centerToScreen(java.awt.Component c)
c
- public static void centerToComponent(java.awt.Component src, java.awt.Component dest)
src
- dest
- public static void gbAdd(java.awt.Container c, java.awt.Component comp, int x, int y, int w, int h, int up, int down, int left, int right, int fill, int anchor, double wx, double wy)
c
- Containercomp
- Component to add to the containerx
- X coordinatey
- Y coordinatew
- Widthh
- Heightup
- Up margindown
- Down marginleft
- Left marginright
- Right marginfill
- Fill constantsanchor
- Anchor constantswx
- Weight xwy
- Weight ypublic static javax.swing.JComboBox createComboBox(java.util.Collection c)
public static boolean isRightMouseButton(java.awt.event.MouseEvent e)
public static boolean isLeftMouseButton(java.awt.event.MouseEvent e)
public static boolean isCenterMouseButton(java.awt.event.MouseEvent e)
public static java.awt.BasicStroke getDefaultMarquee()
public static java.awt.BasicStroke createMarquee(float[] pattern)
public static java.awt.BasicStroke createMarquee(float width, float[] pattern)
public static java.awt.BasicStroke createMarquee(float width, float[] pattern, float offset)
public static javax.swing.KeyStroke translateShortcut(java.lang.String shortcut)
shortcut
-
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |