Top Fields Constructors Methods
org.hsqldb.util

pack-priv Class Grid

extends Panel
Class Inheritance
Imports
java.util.ArrayList, java.awt.Color, .Cursor, .Dimension, .Event, .Font, .FontMetrics, .Graphics, .Image, .Panel, .Scrollbar, .SystemColor

Author
Thomas Mueller (Hypersonic SQL Group)
Since
Hypersonic SQL
Version
2.5.0

Field Summary

Modifier and TypeField and Description
private boolean
private Dimension
protected Font
private FontMetrics
private Graphics
private int
private int
private int[]
private int
private int
private int
private int
private Image
protected int
private int
private int
private int
private int
private int
private int
private int
private Scrollbar
private Scrollbar
protected String[]
protected ArrayList<String[]>

Constructor Summary

AccessConstructor and Description
public
Grid()

Constructor declaration

Method Summary

Modifier and TypeMethod and Description
public void
addRow(String[] data)

pack-priv void
private void
private String
get(int x, int y)

pack-priv ArrayList<String[]>
private String
getDisplay(int x, int y)

pack-priv String[]
private static int
public Dimension
getMinimumSize()

Overrides java.awt.Container.getMinimumSize.

Returns the minimum size of this container.

public Dimension
getPreferredSize()

Overrides java.awt.Container.getPreferredSize.

Returns the preferred size of this container.

public boolean
handleEvent(Event e)

Overrides java.awt.Component.handleEvent.

References Deprecated Event is deprecated or references (maybe indirectly) at least one deprecated element.

public Dimension
minimumSize()

Overrides java.awt.Container.minimumSize.

Returns the minimum size of this component.

public boolean
mouseDrag(Event e, int x, int y)

Overrides java.awt.Component.mouseDrag.

References Deprecated Event is deprecated or references (maybe indirectly) at least one deprecated element.

public boolean
mouseExit(Event e, int x, int y)

Overrides java.awt.Component.mouseExit.

References Deprecated Event is deprecated or references (maybe indirectly) at least one deprecated element.

public boolean
mouseMove(Event e, int x, int y)

Overrides java.awt.Component.mouseMove.

References Deprecated Event is deprecated or references (maybe indirectly) at least one deprecated element.

public void
paint(Graphics g)

Overrides java.awt.Container.paint.

Paints the container.

public Dimension
preferredSize()

Overrides java.awt.Container.preferredSize.

Returns the component's preferred size.

public void
setBounds(int x, int y, int w, int h)

Overrides java.awt.Component.setBounds.

Moves and resizes this component.

public void
setHead(String[] head)

public void
setMinimumSize(Dimension d)

Overrides java.awt.Component.setMinimumSize.

Sets the minimum size of this component to a constant value.

public void
public void
update(Graphics g)

Overrides java.awt.Container.update.

Updates the container.

Inherited from java.awt.Panel:
addNotifygetAccessibleContext

Field Detail

bDragback to summary
private boolean bDrag
dMinimumback to summary
private Dimension dMinimum
fFontback to summary
protected Font fFont
fMetricsback to summary
private FontMetrics fMetrics
gImageback to summary
private Graphics gImage
iColCountback to summary
private int iColCount
iColDragback to summary
private int iColDrag
iColWidthback to summary
private int[] iColWidth
iFirstRowback to summary
private int iFirstRow
iGridHeightback to summary
private int iGridHeight
iGridWidthback to summary
private int iGridWidth
iHeightback to summary
private int iHeight
iImageback to summary
private Image iImage
iRowCountback to summary
protected int iRowCount
iRowHeightback to summary
private int iRowHeight
iSbHeightback to summary
private int iSbHeight
iSbWidthback to summary
private int iSbWidth
iWidthback to summary
private int iWidth
iXback to summary
private int iX
iXDragback to summary
private int iXDrag
iYback to summary
private int iY
sbHorizback to summary
private Scrollbar sbHoriz
sbVertback to summary
private Scrollbar sbVert
sColHeadback to summary
protected String[] sColHead
vDataback to summary
protected ArrayList<String[]> vData

Constructor Detail

Gridback to summary
public Grid()

Constructor declaration

Method Detail

addRowback to summary
public void addRow(String[] data)
adjustScrollback to summary
pack-priv void adjustScroll()
calcAutoWidthback to summary
private void calcAutoWidth(int i)
getback to summary
private String get(int x, int y)
getDataback to summary
pack-priv ArrayList<String[]> getData()
getDisplayback to summary
private String getDisplay(int x, int y)
getHeadback to summary
pack-priv String[] getHead()
getMaxHeightback to summary
private static int getMaxHeight(FontMetrics f)
getMinimumSizeback to summary
public Dimension getMinimumSize()

Overrides java.awt.Container.getMinimumSize.

Doc from java.awt.Container.getMinimumSize.

Returns the minimum size of this container. If the minimum size has not been set explicitly by Component#setMinimumSize(Dimension) and this Container has a non-null LayoutManager, then LayoutManager#minimumLayoutSize(Container) is used to calculate the minimum size.

Note

some implementations may cache the value returned from the LayoutManager. Implementations that cache need not invoke minimumLayoutSize on the LayoutManager every time this method is invoked, rather the LayoutManager will only be queried after the Container becomes invalid.

getPreferredSizeback to summary
public Dimension getPreferredSize()

Overrides java.awt.Container.getPreferredSize.

Doc from java.awt.Container.getPreferredSize.

Returns the preferred size of this container. If the preferred size has not been set explicitly by Component#setPreferredSize(Dimension) and this Container has a non-null LayoutManager, then LayoutManager#preferredLayoutSize(Container) is used to calculate the preferred size.

Note

some implementations may cache the value returned from the LayoutManager. Implementations that cache need not invoke preferredLayoutSize on the LayoutManager every time this method is invoked, rather the LayoutManager will only be queried after the Container becomes invalid.

handleEventback to summary
public boolean handleEvent(Event e)

Overrides java.awt.Component.handleEvent.

References Deprecated

Event is deprecated or references (maybe indirectly) at least one deprecated element.

See corresponding docs for further information.

minimumSizeback to summary
public Dimension minimumSize()

Overrides java.awt.Container.minimumSize.

Doc from java.awt.Component.minimumSize.

Returns the minimum size of this component.

mouseDragback to summary
public boolean mouseDrag(Event e, int x, int y)

Overrides java.awt.Component.mouseDrag.

References Deprecated

Event is deprecated or references (maybe indirectly) at least one deprecated element.

See corresponding docs for further information.

mouseExitback to summary
public boolean mouseExit(Event e, int x, int y)

Overrides java.awt.Component.mouseExit.

References Deprecated

Event is deprecated or references (maybe indirectly) at least one deprecated element.

See corresponding docs for further information.

mouseMoveback to summary
public boolean mouseMove(Event e, int x, int y)

Overrides java.awt.Component.mouseMove.

References Deprecated

Event is deprecated or references (maybe indirectly) at least one deprecated element.

See corresponding docs for further information.

paintback to summary
public void paint(Graphics g)

Overrides java.awt.Container.paint.

Doc from java.awt.Container.paint.

Paints the container. This forwards the paint to any lightweight components that are children of this container. If this method is reimplemented, super.paint(g) should be called so that lightweight components are properly rendered. If a child component is entirely clipped by the current clipping setting in g, paint() will not be forwarded to that child.

preferredSizeback to summary
public Dimension preferredSize()

Overrides java.awt.Container.preferredSize.

Doc from java.awt.Component.preferredSize.

Returns the component's preferred size.

setBoundsback to summary
public void setBounds(int x, int y, int w, int h)

Overrides java.awt.Component.setBounds.

Doc from java.awt.Component.setBounds.

Moves and resizes this component. The new location of the top-left corner is specified by x and y, and the new size is specified by width and height.

This method changes layout-related information, and therefore, invalidates the component hierarchy.

setHeadback to summary
public void setHead(String[] head)
setMinimumSizeback to summary
public void setMinimumSize(Dimension d)

Overrides java.awt.Component.setMinimumSize.

Doc from java.awt.Component.setMinimumSize.

Sets the minimum size of this component to a constant value. Subsequent calls to getMinimumSize will always return this value. Setting the minimum size to null restores the default behavior.

updateback to summary
public void update()
updateback to summary
public void update(Graphics g)

Overrides java.awt.Container.update.

Doc from java.awt.Container.update.

Updates the container. This forwards the update to any lightweight components that are children of this container. If this method is reimplemented, super.update(g) should be called so that lightweight components are properly rendered. If a child component is entirely clipped by the current clipping setting in g, update() will not be forwarded to that child.