|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Defines the requirements for an object that displays a drawing element.
Method Summary | |
boolean |
elementContains(java.lang.Object element,
java.awt.geom.Point2D point)
Tests if the given element contains the given point. |
boolean |
elementIntersects(java.lang.Object element,
java.awt.geom.Rectangle2D rectangle)
Tests if the given element intersects with the given rectangle. |
java.awt.Rectangle |
getElementBounds(java.lang.Object element)
Gets the bounding box for the element. |
java.awt.geom.Rectangle2D |
getElementBounds2D(java.lang.Object element)
Return the high precision bounding box of the element. |
void |
paintDrawingElement(java.awt.Graphics graphics,
java.lang.Object element)
Paints the given element. |
Method Detail |
public void paintDrawingElement(java.awt.Graphics graphics, java.lang.Object element)
graphics
- graphics context to use for paintingelement
- element to be paintedpublic java.awt.Rectangle getElementBounds(java.lang.Object element)
element
- element to be queried for bounding box
public java.awt.geom.Rectangle2D getElementBounds2D(java.lang.Object element)
element
- element to be queried for bounding box
public boolean elementIntersects(java.lang.Object element, java.awt.geom.Rectangle2D rectangle)
element
- element to be checked for intersectionrectangle
- rectangle to be checked for intersection
public boolean elementContains(java.lang.Object element, java.awt.geom.Point2D point)
element
- element to be checkedpoint
- point to be checked
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |