gishur.gui
Class Rectangle_Primitive

java.lang.Object
  |
  +--java.awt.geom.RectangularShape
        |
        +--java.awt.geom.Rectangle2D
              |
              +--java.awt.Rectangle
                    |
                    +--gishur.gui.Rectangle_Primitive
All Implemented Interfaces:
java.lang.Cloneable, GraphicPrimitive, java.io.Serializable, java.awt.Shape

public class Rectangle_Primitive
extends java.awt.Rectangle
implements GraphicPrimitive

Achsenparalleles Rechteck.

See Also:
Serialized Form

Inner classes inherited from class java.awt.geom.Rectangle2D
java.awt.geom.Rectangle2D.Double, java.awt.geom.Rectangle2D.Float
 
Fields inherited from class java.awt.Rectangle
height, width, x, y
 
Fields inherited from class java.awt.geom.Rectangle2D
OUT_BOTTOM, OUT_LEFT, OUT_RIGHT, OUT_TOP
 
Constructor Summary
Rectangle_Primitive()
          Konstruktoren.
Rectangle_Primitive(int width, int height)
           
Rectangle_Primitive(int x, int y, int width, int height)
           
Rectangle_Primitive(java.awt.Rectangle r)
           
 
Method Summary
 java.awt.Rectangle getBounds()
          Liefert das kleinste umschließende (achsenparallele) Rechteck.
 java.awt.Point getCenter()
          Liefert das Zentrum.
 boolean in(int x, int y)
          Liegt der Punkt (x,y) im Primitiv (inkl.
 void paint(java.awt.Graphics g)
          Malt das Primitiv auf das Graphics g.
 java.lang.String toString()
           
 
Methods inherited from class java.awt.Rectangle
add, add, add, contains, contains, contains, contains, createIntersection, createUnion, equals, getBounds2D, getHeight, getLocation, getSize, getWidth, getX, getY, grow, inside, intersection, intersects, isEmpty, move, outcode, reshape, resize, setBounds, setBounds, setLocation, setLocation, setRect, setSize, setSize, translate, union
 
Methods inherited from class java.awt.geom.Rectangle2D
add, add, add, contains, contains, getPathIterator, getPathIterator, hashCode, intersect, intersects, intersectsLine, intersectsLine, outcode, setFrame, setRect, union
 
Methods inherited from class java.awt.geom.RectangularShape
clone, contains, contains, getCenterX, getCenterY, getFrame, getMaxX, getMaxY, getMinX, getMinY, intersects, setFrame, setFrame, setFrameFromCenter, setFrameFromCenter, setFrameFromDiagonal, setFrameFromDiagonal
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface gishur.gui.GraphicPrimitive
translate
 
Methods inherited from interface java.awt.Shape
contains, contains, contains, contains, getPathIterator, getPathIterator, intersects, intersects
 

Constructor Detail

Rectangle_Primitive

public Rectangle_Primitive()
Konstruktoren.

Rectangle_Primitive

public Rectangle_Primitive(int width,
                           int height)

Rectangle_Primitive

public Rectangle_Primitive(int x,
                           int y,
                           int width,
                           int height)

Rectangle_Primitive

public Rectangle_Primitive(java.awt.Rectangle r)
Method Detail

in

public boolean in(int x,
                  int y)
Liegt der Punkt (x,y) im Primitiv (inkl. Rand)
Specified by:
in in interface GraphicPrimitive
Returns:
true, falls (x,y) im Primitiv

getBounds

public java.awt.Rectangle getBounds()
Liefert das kleinste umschließende (achsenparallele) Rechteck.
Specified by:
getBounds in interface GraphicPrimitive
Overrides:
getBounds in class java.awt.Rectangle
Returns:
kleinstes umschließende Rechteck

getCenter

public java.awt.Point getCenter()
Liefert das Zentrum.
Specified by:
getCenter in interface GraphicPrimitive
Following copied from interface: gishur.gui.GraphicPrimitive
Returns:
Zentrum

paint

public void paint(java.awt.Graphics g)
Malt das Primitiv auf das Graphics g.
Specified by:
paint in interface GraphicPrimitive
Parameters:
Graphics, - auf dem gemalt wird.

toString

public java.lang.String toString()
Overrides:
toString in class java.awt.Rectangle