Package org.apache.fop.render.txt.border
Class BorderManager
- java.lang.Object
-
- org.apache.fop.render.txt.border.BorderManager
-
public class BorderManager extends java.lang.ObjectThis keeps all information about borders for current processed page.
-
-
Constructor Summary
Constructors Constructor Description BorderManager(int pageWidth, int pageHeight, TXTState state)Constructs BorderManger, usingpageWidthandpageHeightfor creatingborderInfo.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddBorderElement(int x, int y, int style, int type)Adds border element toborderInfo.java.lang.CharactergetCharacter(int x, int y)intgetHeight()intgetStartX()intgetStartY()intgetWidth()voidsetHeight(int height)Sets height of current processed border.voidsetStartX(int startX)Sets x-coordinate of upper left point of current processed border.voidsetStartY(int startY)Sets y-coordinate of upper left point of current processed border.voidsetWidth(int width)Sets width of current processed border.
-
-
-
Constructor Detail
-
BorderManager
public BorderManager(int pageWidth, int pageHeight, TXTState state)Constructs BorderManger, usingpageWidthandpageHeightfor creatingborderInfo.- Parameters:
pageWidth- page widthpageHeight- page heightstate- TXTState
-
-
Method Detail
-
addBorderElement
public void addBorderElement(int x, int y, int style, int type)Adds border element toborderInfo.- Parameters:
x- x-coordinatey- y-coordinatestyle- border-styletype- border element type, binary representation of wich gives information about availability or absence of corresponding side.
-
getCharacter
public java.lang.Character getCharacter(int x, int y)- Parameters:
x- x-coordinatey- y-coordinate- Returns:
- if border element at point (x,y) is available, returns instance of Character, created on char, given by corresponding border element, otherwise returns null.
-
getWidth
public int getWidth()
- Returns:
- width of current processed border.
-
setWidth
public void setWidth(int width)
Sets width of current processed border.- Parameters:
width- width of border
-
getHeight
public int getHeight()
- Returns:
- height of current processed border.
-
setHeight
public void setHeight(int height)
Sets height of current processed border.- Parameters:
height- height of border
-
getStartX
public int getStartX()
- Returns:
- x-coordinate of upper left point of current processed border.
-
setStartX
public void setStartX(int startX)
Sets x-coordinate of upper left point of current processed border.- Parameters:
startX- x-coordinate of upper left border's point.
-
getStartY
public int getStartY()
- Returns:
- y-coordinate of upper left point of current processed border.
-
setStartY
public void setStartY(int startY)
Sets y-coordinate of upper left point of current processed border.- Parameters:
startY- y-coordinate of upper left border's point.
-
-