| 
 | Jadex 0.941 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjadex.util.SGUI
Static helper class with useful gui related methods.
| Constructor Summary | |
| SGUI() | |
| Method Summary | |
| static Point | calculateMiddlePosition(Window win)Calculate the middle position of a window relativ to | 
| static Point | calculateMiddlePosition(Window outer,
                        Window win)Calculate the middle position of a window relativ to | 
| static Action | createAction(String name,
             Icon icon,
             ActionListener listener)Create an action. | 
| static JMenuBar | createMenuBar(Action[] actions)Create a menu bar, given a list of actions. | 
| static JToolBar | createToolBar(String name,
              Action[] actions)Create a tool bar, given a list of actions. | 
| static Window | getWindowParent(Component comp)Get the window parent if any. | 
| static Object | makeIcon(Class baseclass,
         String imgloc)Utility method that creates a UIDefaults.LazyValue that creates an ImageIcon for the specified gifFilefilename. | 
| static void | renderObject(Graphics g,
             Component comp,
             double cellw,
             double cellh,
             int x,
             int y,
             int gridwidth)Render an object on a grid. | 
| Methods inherited from class java.lang.Object | 
| equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Constructor Detail | 
public SGUI()
| Method Detail | 
public static JMenuBar createMenuBar(Action[] actions)
actions - The actions (null is mapped to separator).
public static JToolBar createToolBar(String name,
                                     Action[] actions)
name - The name of the toolbar.actions - The actions (null is mapped to separator).
public static Action createAction(String name,
                                  Icon icon,
                                  ActionListener listener)
name - The name.icon - The path to the icon.listener - The action listener.
public static Object makeIcon(Class baseclass,
                              String imgloc)
gifFile filename.
public static void renderObject(Graphics g,
                                Component comp,
                                double cellw,
                                double cellh,
                                int x,
                                int y,
                                int gridwidth)
g - The graphics object.comp - The object to render.cellw - The cell width.cellh - The cell height.public static Point calculateMiddlePosition(Window win)
public static Point calculateMiddlePosition(Window outer,
                                            Window win)
public static Window getWindowParent(Component comp)
comp - The component.
| 
 | Jadex 0.941 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Copyright (C) 2002-2005 Lars Braubach, Alexander Pokahr, Andrzej Walczak - University of Hamburg. Use is subject to license terms.