Class IGridPanel

  extended by igeo.gui.IComponent
      extended by igeo.gui.IPanel
          extended by igeo.gui.IScreenTogglePanel
              extended by igeo.gui.IGridPanel
All Implemented Interfaces:
IPanelI, IServerI, java.awt.event.ComponentListener, java.awt.event.FocusListener, java.awt.event.KeyListener, java.awt.event.MouseListener, java.awt.event.MouseMotionListener, java.awt.event.MouseWheelListener, java.awt.event.WindowListener, java.util.EventListener

public class IGridPanel
extends IScreenTogglePanel

A panel class to contain multiple IPane in grid layout with toggle function to switch showing only one pane and showing all panes.

Satoru Sugihara

Nested Class Summary
Nested classes/interfaces inherited from class igeo.gui.IPanel
Field Summary
 IPane[][] gridPanes
 double[] heightRatio
 double[] widthRatio
 int xnum
 int ynum
Fields inherited from class igeo.gui.IScreenTogglePanel
fullPaneOrigHeight, fullPaneOrigWidth, fullPaneOrigX, fullPaneOrigY, fullScreenPane
Fields inherited from class igeo.gui.IPanel
bounds, currentMousePane, firstDraw, ig, panes, parentContainer, serverStateCount, sizeChanged, skipAutoFocus, startDynamicServer
Fields inherited from class igeo.gui.IComponent
height, visible, width, x, y
Constructor Summary
IGridPanel(int x, int y, int width, int height, int xnum, int ynum)
IGridPanel(int x, int y, int width, int height, int xnum, int ynum, IPane[][] panes)
Method Summary
static int[] getPositionArrayFromRatio(double[] ratio, int totalLen)
 void setSize(int w, int h)
 void setupGrid(double[] widthRatio, double[] heightRatio, IPane[][] panes)
 void setupGrid(int xnum, int ynum, IPane[][] panes)
Methods inherited from class igeo.gui.IScreenTogglePanel
disableFullScreen, draw, enableFullScreen, enableFullScreen, isFull, keyPressed, mouseClicked, setVisible
Methods inherited from class igeo.gui.IPanel
addPane, chooseFile, chooseFile, chooseFile, clearPane, componentHidden, componentMoved, componentResized, componentShown, currentPane, focus, focusGained, focusLost, getBounds, getIG, getPaneAt, getPaneAt, keyReleased, keyTyped, mouseDragged, mouseEntered, mouseExited, mouseMoved, mousePressed, mouseReleased, mouseWheelMoved, pane, paneNum, postdraw, predraw, removePane, saveDialog, server, setBounds, setIG, setParent, skipAutoFocus, startDynamicServer, windowActivated, windowClosed, windowClosing, windowDeactivated, windowDeiconified, windowIconified, windowOpened
Methods inherited from class igeo.gui.IComponent
contains, getHeight, getWidth, getX, getY, isVisible, setBounds, setBounds, setLocation
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface igeo.gui.IPanelI
getHeight, getWidth, getX, getY

Field Detail


public IPane[][] gridPanes


public int xnum


public int ynum


public double[] widthRatio


public double[] heightRatio
Constructor Detail


public IGridPanel(int x,
                  int y,
                  int width,
                  int height,
                  int xnum,
                  int ynum)


public IGridPanel(int x,
                  int y,
                  int width,
                  int height,
                  int xnum,
                  int ynum,
                  IPane[][] panes)
Method Detail


public void setupGrid(int xnum,
                      int ynum,
                      IPane[][] panes)


public void setupGrid(double[] widthRatio,
                      double[] heightRatio,
                      IPane[][] panes)
widthRatio - Array of relative width ratio. Actual width is calculatd by each ratio divided by sum of ratios
heightRatio - Array of relative height ratio. Actual height is calculatd by each ratio divided by sum of ratios


public static int[] getPositionArrayFromRatio(double[] ratio,
                                              int totalLen)


public void setSize(int w,
                    int h)
Specified by:
setSize in interface IPanelI
setSize in class IScreenTogglePanel