com.jhlabs.image
Class BorderFilter
- BufferedImageOp, Cloneable
public class BorderFilter
A filter to add a border around an image using the supplied Paint, which may be null for no painting.
BorderFilter() - Construct a BorderFilter which does nothing.
|
BorderFilter(int leftBorder, int topBorder, int rightBorder, int bottomBorder, Paint borderPaint) - Construct a BorderFilter.
|
BorderFilter
public BorderFilter()
Construct a BorderFilter which does nothing.
BorderFilter
public BorderFilter(int leftBorder,
int topBorder,
int rightBorder,
int bottomBorder,
Paint borderPaint)
Construct a BorderFilter.
leftBorder
- the left border valuetopBorder
- the top border valuerightBorder
- the right border valuebottomBorder
- the bottom border valueborderPaint
- the paint with which to fill the border
filter
public BufferedImage filter(BufferedImage src,
BufferedImage dst)
getBorderPaint
public Paint getBorderPaint()
Get the border paint.
- the paint with which to fill the border
getBottomBorder
public int getBottomBorder()
Returns the border border value.
getLeftBorder
public int getLeftBorder()
Returns the left border value.
getRightBorder
public int getRightBorder()
Returns the right border value.
getTopBorder
public int getTopBorder()
Returns the top border value.
setBorderPaint
public void setBorderPaint(Paint borderPaint)
Set the border paint.
borderPaint
- the paint with which to fill the border
setBottomBorder
public void setBottomBorder(int bottomBorder)
Set the border size on the bottom edge.
bottomBorder
- the number of pixels of border to add to the edge
setLeftBorder
public void setLeftBorder(int leftBorder)
Set the border size on the left edge.
leftBorder
- the number of pixels of border to add to the edge
setRightBorder
public void setRightBorder(int rightBorder)
Set the border size on the right edge.
rightBorder
- the number of pixels of border to add to the edge
setTopBorder
public void setTopBorder(int topBorder)
Set the border size on the top edge.
topBorder
- the number of pixels of border to add to the edge
toString
public String toString()