ucar.unidata.ui.drawing
Class RectangleGlyph

java.lang.Object
  extended by ucar.unidata.ui.drawing.Glyph
      extended by ucar.unidata.ui.drawing.RectangleGlyph
All Implemented Interfaces:
Cloneable
Direct Known Subclasses:
CompositeGlyph, ImageGlyph, MetSymbol

public class RectangleGlyph
extends Glyph

Class RectangleGlyph

Author:
IDV development team

Field Summary
static String ATTR_RECTTYPE
          _more_
 Rectangle bounds
          _more_
static String CIRCLE
          _more_
static String FCIRCLE
          _more_
static String FRECTANGLE
          _more_
static String FROUNDRECT
          _more_
static String RECTANGLE
          _more_
static String ROUNDRECT
          _more_
static int TYPE_CIRCLE
          _more_
static int TYPE_RECT
          _more_
static int TYPE_RRECT
          _more_
 
Fields inherited from class ucar.unidata.ui.drawing.Glyph
ATTR_BGCOLOR, ATTR_CHILDREN, ATTR_CLASS, ATTR_COLOR, ATTR_FILL, ATTR_HEIGHT, ATTR_IMAGE, ATTR_LINEWIDTH, ATTR_PARENT, ATTR_PTS, ATTR_STRETCHY, ATTR_TEXT, ATTR_TYPE, ATTR_WIDTH, baseline, H_SEL_WIDTH, highlightColor, idToGlyph, MIN_DISTANCE_TO_STRETCH, PT_CENTER, PT_H_LEFT, PT_H_MIDDLE, PT_H_RIGHT, PT_LL, PT_LM, PT_LR, PT_ML, PT_MM, PT_MR, PT_P1, PT_P2, PT_PREFIX, PT_UL, PT_UM, PT_UR, PT_V_LOWER, PT_V_MIDDLE, PT_V_UPPER, RECTPOINTNAMES, RECTPOINTS, SEL_WIDTH, TAG_GLYPH, underline, url
 
Constructor Summary
RectangleGlyph()
          _more_
RectangleGlyph(int x, int y)
          _more_
RectangleGlyph(String typeName, int x, int y, int w, int h)
          _more_
 
Method Summary
protected  Object clone()
          _more_
 double distance(int x, int y)
          _more_
 int getBottom()
          _more_
 Rectangle getBounds()
          _more_
 boolean getEqualSides()
          _more_
 int getLeft()
          _more_
static Point getPoint(String pt, Rectangle b)
          _more_
 String getPositionAttr()
          _more_
 String getStretchPoint(int x, int y)
          _more_
 boolean getSymetricReshape()
          _more_
 int getTop()
          _more_
 void moveBy(int x, int y)
          _more_
 void moveTo(int x, int y)
          _more_
 void paint(Graphics g, DisplayCanvas c)
          _more_
 void setAttr(String name, String value)
          _more_
 void setPoints(int[] p, int cnt)
          _more_
 void setSize(int w, int h)
          _more_
protected  void setType(String typeName)
          _more_
 String stretchTo(int x, int y, String pt, boolean correct)
          _more_
 
Methods inherited from class ucar.unidata.ui.drawing.Glyph
boundsChanged, canStretch, distance, doRemove, flipY, getAttrs, getBackground, getBackground, getBeingCreated, getCreateCommand, getCursor, getFilled, getForeground, getId, getLineWidth, getMoveCommand, getPersistent, getPointOnRect, getPointOnRect, getRectPointName, getRepaintBounds, getStretchPoint, getStretchy, getXml, initDone, makeAttr, notifyChange, paintHighlight, paintSelection, paintSelectionPoints, pickable, processAttrs, setBackground, setBeingCreated, setFilled, setForeground, setId, setLineWidth, setParent, setStretchy, stretchTo, stretchTo, toRect, transformOutput, transformOutput, transformOutputX, transformOutputY
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RECTANGLE

public static final String RECTANGLE
_more_

See Also:
Constant Field Values

FRECTANGLE

public static final String FRECTANGLE
_more_

See Also:
Constant Field Values

ROUNDRECT

public static final String ROUNDRECT
_more_

See Also:
Constant Field Values

FROUNDRECT

public static final String FROUNDRECT
_more_

See Also:
Constant Field Values

CIRCLE

public static final String CIRCLE
_more_

See Also:
Constant Field Values

FCIRCLE

public static final String FCIRCLE
_more_

See Also:
Constant Field Values

ATTR_RECTTYPE

public static final String ATTR_RECTTYPE
_more_

See Also:
Constant Field Values

bounds

public Rectangle bounds
_more_


TYPE_RECT

public static final int TYPE_RECT
_more_

See Also:
Constant Field Values

TYPE_RRECT

public static final int TYPE_RRECT
_more_

See Also:
Constant Field Values

TYPE_CIRCLE

public static final int TYPE_CIRCLE
_more_

See Also:
Constant Field Values
Constructor Detail

RectangleGlyph

public RectangleGlyph()
_more_


RectangleGlyph

public RectangleGlyph(int x,
                      int y)
_more_

Parameters:
x -
y -

RectangleGlyph

public RectangleGlyph(String typeName,
                      int x,
                      int y,
                      int w,
                      int h)
_more_

Parameters:
typeName -
x -
y -
w -
h -
Method Detail

getEqualSides

public boolean getEqualSides()
_more_

Returns:
_more_

getSymetricReshape

public boolean getSymetricReshape()
_more_

Returns:
_more_

setType

protected void setType(String typeName)
_more_

Parameters:
typeName -

clone

protected Object clone()
                throws CloneNotSupportedException
_more_

Overrides:
clone in class Glyph
Returns:
_more_
Throws:
CloneNotSupportedException

getBounds

public Rectangle getBounds()
_more_

Specified by:
getBounds in class Glyph
Returns:
_more_

getBottom

public int getBottom()
_more_

Returns:
_more_

getTop

public int getTop()
_more_

Returns:
_more_

getLeft

public int getLeft()
_more_

Returns:
_more_

paint

public void paint(Graphics g,
                  DisplayCanvas c)
_more_

Overrides:
paint in class Glyph
Parameters:
g -
c -

distance

public double distance(int x,
                       int y)
_more_

Specified by:
distance in class Glyph
Parameters:
x -
y -
Returns:
_more_

stretchTo

public String stretchTo(int x,
                        int y,
                        String pt,
                        boolean correct)
_more_

Overrides:
stretchTo in class Glyph
Parameters:
x -
y -
pt -
correct -
Returns:
_more_

getPoint

public static Point getPoint(String pt,
                             Rectangle b)
_more_

Parameters:
pt -
b -
Returns:
_more_

getStretchPoint

public String getStretchPoint(int x,
                              int y)
_more_

Overrides:
getStretchPoint in class Glyph
Parameters:
x -
y -
Returns:
_more_

moveBy

public void moveBy(int x,
                   int y)
_more_

Specified by:
moveBy in class Glyph
Parameters:
x -
y -

moveTo

public void moveTo(int x,
                   int y)
_more_

Specified by:
moveTo in class Glyph
Parameters:
x -
y -

setPoints

public void setPoints(int[] p,
                      int cnt)
_more_

Overrides:
setPoints in class Glyph
Parameters:
p -
cnt -

getPositionAttr

public String getPositionAttr()
_more_

Returns:
_more_

setAttr

public void setAttr(String name,
                    String value)
_more_

Overrides:
setAttr in class Glyph
Parameters:
name -
value -

setSize

public void setSize(int w,
                    int h)
_more_

Parameters:
w -
h -