MetaDone
metadone.client.grasyla2.visuallibrary.widgets.customBorders.PointingBorder Class Reference
Inheritance diagram for metadone.client.grasyla2.visuallibrary.widgets.customBorders.PointingBorder:
Collaboration diagram for metadone.client.grasyla2.visuallibrary.widgets.customBorders.PointingBorder:

List of all members.

Public Member Functions

 PointingBorder (Stroke stroke, Color strokeColor, Color backgroundColor, int margin, int outsideMargin, Insets points)
Insets getBorderInsets ()
void paint (Graphics2D g, Rectangle bounds)

Protected Member Functions

Shape makeShape (int[] x, int[] y)

Private Attributes

final Insets insets

Detailed Description

Rectangle border with borders pointing a given direction.

Author:
kma

Constructor & Destructor Documentation

metadone.client.grasyla2.visuallibrary.widgets.customBorders.PointingBorder.PointingBorder ( Stroke  stroke,
Color  strokeColor,
Color  backgroundColor,
int  margin,
int  outsideMargin,
Insets  points 
)

Initializes this border.

Parameters:
strokeThe stroke used to draw the lines.
strokeColorThe color of the stroke of the border.
backgroundColorThe color to fill the shape (null for a transparent shape).
marginThe margin between the border and the content.
outsideMarginThe outside margin.
pointsThe delta used to place the points (positive values point outside, negative inside)
Exceptions:
NullPointerExceptionwhen stroke, strokeColor or points is null

References metadone.client.grasyla2.visuallibrary.widgets.customBorders.AbstractCustomBorder.computeInsets(), metadone.client.grasyla2.visuallibrary.widgets.customBorders.AbstractCustomBorder.getStrokeWidth(), and metadone.client.grasyla2.visuallibrary.widgets.customBorders.PointingBorder.insets.


Member Function Documentation

Insets metadone.client.grasyla2.visuallibrary.widgets.customBorders.PointingBorder.getBorderInsets ( )
Shape metadone.client.grasyla2.visuallibrary.widgets.customBorders.PointingBorder.makeShape ( int[]  x,
int[]  y 
) [protected]

Builds the shape of the border from 8 points.

 0----1----2
 |         |
 7         3
 |         |
 6----5----4
 
Parameters:
xThe x positions
yThe y positions
Returns:
A shape to paint

Reimplemented in metadone.client.grasyla2.visuallibrary.widgets.customBorders.RoundedBorder.

Referenced by metadone.client.grasyla2.visuallibrary.widgets.customBorders.PointingBorder.paint().


Member Data Documentation


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Enumerations