|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectmadkit.utils.graphics.GraphicUtils
public class GraphicUtils
Constructor Summary | |
---|---|
GraphicUtils()
|
Method Summary | |
---|---|
static void |
addMenuItem(java.awt.event.ActionListener al,
javax.swing.JMenu m,
java.lang.String label,
java.lang.String command,
int key)
|
static void |
addMenuItem(java.awt.event.ActionListener al,
javax.swing.JMenu m,
java.lang.String label,
java.lang.String command,
int key,
int ckey)
|
static void |
addRadioButtonMenuItem(java.awt.event.ActionListener al,
javax.swing.JMenu m,
java.lang.String label,
java.lang.String command,
boolean b,
javax.swing.ButtonGroup g)
|
static javax.swing.JButton |
addTool(java.awt.event.ActionListener al,
javax.swing.JToolBar toolBar,
java.lang.String name,
java.lang.String descr,
java.lang.String imageName)
|
static void |
debug(java.lang.Object s)
|
static void |
debug(java.lang.Object o,
java.lang.Object s)
|
static void |
execute(java.lang.String url)
Tries to launch the application associated to the file.. |
static java.lang.String |
getExtension(java.io.File f)
|
static java.awt.Container |
getFrameParent(java.awt.Container _c)
|
static java.awt.Frame |
getRealFrameParent(java.awt.Component c)
get the Frame that surrounds a component. |
static boolean |
isPopupTrigger(java.awt.event.MouseEvent evt)
Returns if the specified event is the popup trigger event. |
static boolean |
isWindowsPlatform()
Try to determine whether this application is running under Windows or some other platform by examing the "os.name" property. |
static void |
log(java.lang.String s)
|
static void |
requestFocus(java.awt.Window win,
java.awt.Component comp)
Focuses on the specified component as soon as the window becomes active. |
static void |
showPopupMenu(javax.swing.JPopupMenu popup,
java.awt.Component comp,
int x,
int y)
Shows the specified popup menu, ensuring it is displayed within the bounds of the screen. |
static void |
showPopupMenu(javax.swing.JPopupMenu popup,
java.awt.Component comp,
int x,
int y,
boolean point)
Shows the specified popup menu, ensuring it is displayed within the bounds of the screen. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public GraphicUtils()
Method Detail |
---|
public static void log(java.lang.String s)
public static void debug(java.lang.Object s)
public static void debug(java.lang.Object o, java.lang.Object s)
public static java.lang.String getExtension(java.io.File f)
public static java.awt.Frame getRealFrameParent(java.awt.Component c)
public static java.awt.Container getFrameParent(java.awt.Container _c)
public static void addMenuItem(java.awt.event.ActionListener al, javax.swing.JMenu m, java.lang.String label, java.lang.String command, int key)
public static void addMenuItem(java.awt.event.ActionListener al, javax.swing.JMenu m, java.lang.String label, java.lang.String command, int key, int ckey)
public static javax.swing.JButton addTool(java.awt.event.ActionListener al, javax.swing.JToolBar toolBar, java.lang.String name, java.lang.String descr, java.lang.String imageName)
public static void addRadioButtonMenuItem(java.awt.event.ActionListener al, javax.swing.JMenu m, java.lang.String label, java.lang.String command, boolean b, javax.swing.ButtonGroup g)
public static void requestFocus(java.awt.Window win, java.awt.Component comp)
win
- The windowcomp
- The componentpublic static boolean isPopupTrigger(java.awt.event.MouseEvent evt)
evt
- The event Taken from jEdit 3.2pre8public static void showPopupMenu(javax.swing.JPopupMenu popup, java.awt.Component comp, int x, int y)
popup
- The popup menucomp
- The component to show it forx
- The x co-ordinatey
- The y co-ordinate taken from jEdit 4.0pre1public static void showPopupMenu(javax.swing.JPopupMenu popup, java.awt.Component comp, int x, int y, boolean point)
popup
- The popup menucomp
- The component to show it forx
- The x co-ordinatey
- The y co-ordinatepoint
- If true, then the popup originates from a single point;
otherwise it will originate from the component itself. This
affects positioning in the case where the popup does not fit
onscreen. Taken from jEdit 4.0public static void execute(java.lang.String url)
url:
- the name of the file to be executedpublic static boolean isWindowsPlatform()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |