|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objecty.view.AbstractCustomNodePainter
y.view.BevelNodePainter
public class BevelNodePainter
This class is an implementation of GenericNodeRealizer.Painter that draws a rounded
rectangle with a bevel border and an optional simple drop shadow in a shiny fashion.
![]() |
![]() |
| Constructor Summary | |
|---|---|
BevelNodePainter()
|
|
| Method Summary | |
|---|---|
boolean |
contains(NodeRealizer context,
double x,
double y)
Used as a callback for the GenericNodeRealizer.contains(double, double) method. |
double |
getInset()
|
double |
getRadius()
Returns the radius of the rounded corners of the rounded rectangle shape. |
Color |
getShadowColor()
Gets the color of the shadow. |
boolean |
isDrawShadow()
Returns whether the painter will draw a drop shadow effect. |
protected void |
paintNode(NodeRealizer context,
Graphics2D graphics,
boolean sloppy)
paints a node realizer with a bevel border in a shiny fashion. |
void |
setDrawShadow(boolean drawShadow)
Sets whether the painter will draw a drop shadow effect. |
void |
setInset(double inset)
sets the distance of the bevel border from the real border. |
void |
setRadius(double radius)
Sets the radius of the rounded corners of the rounded rectangle shape. |
void |
setShadowColor(Color shadowColor)
Sets the color of the shadow. |
| Methods inherited from class y.view.AbstractCustomNodePainter |
|---|
backupGraphics, createSelectionColor, getFillColor, getFillColor2, getFillPaint, getLineColor, getLinePaint, getLineStroke, initializeFill, initializeLine, paint, paintSloppy, restoreGraphics |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public BevelNodePainter()
| Method Detail |
|---|
protected void paintNode(NodeRealizer context,
Graphics2D graphics,
boolean sloppy)
paintNode in class AbstractCustomNodePaintercontext - the node realizer to be drawngraphics - where to draw the node realizersloppy - if true, only a rectangle is drawnAbstractCustomNodePainter.initializeLine(NodeRealizer, Graphics2D),
AbstractCustomNodePainter.initializeFill(NodeRealizer, Graphics2D)public double getRadius()
public void setRadius(double radius)
radius - the radius to use for the rounded rectangle corners.public double getInset()
public void setInset(double inset)
inset - inset of bevel borderpublic boolean isDrawShadow()
false.
public void setDrawShadow(boolean drawShadow)
false.
drawShadow - whether to draw a shadow.public Color getShadowColor()
public void setShadowColor(Color shadowColor)
shadowColor - the color of the shadow.
public boolean contains(NodeRealizer context,
double x,
double y)
GenericNodeRealizer.ContainsTestGenericNodeRealizer.contains(double, double) method.
contains in interface GenericNodeRealizer.ContainsTest
|
© Copyright 2000-2008, yWorks GmbH. All rights reserved. |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||