gzz.view
Class LinebrokenCellContentView
java.lang.Object
|
+--gzz.view.CellView
|
+--gzz.view.LinebrokenCellContentView
- public class LinebrokenCellContentView
- extends CellView
A cell content view showing a cell's text, broken into lines.
Doesn't scroll, currently.
Method Summary |
protected void |
addVobs(java.lang.String s,
gzz.vob.linebreaking.HChain ch,
int start,
int end,
float scale)
|
protected gzz.vob.linebreaking.HChain |
getChain(Cell c,
float scale)
|
protected gzz.vob.linebreaking.HChain |
getChain(java.lang.String s,
float scale)
|
float |
getHeight(Cell c,
float forWidth,
float scale)
Get the height necessary to layout a range of text in a cell,
at a given width and scale. |
void |
getSize(Cell c,
float scale,
ViewContext context,
float[] out)
Get the default size of the cell at a given scale. |
void |
place(Cell c,
VobScene vs,
int box,
ViewContext context)
Place the contents of one cell into the given coord system. |
void |
place(Cell c,
VobScene vs,
int box,
ViewContext context,
java.lang.String textColor)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
rcsid
public static final java.lang.String rcsid
- See Also:
- Constant Field Values
dbg
public static boolean dbg
style
protected TextStyle style
widthString
protected java.lang.String widthString
baselined
protected boolean baselined
LinebrokenCellContentView
public LinebrokenCellContentView(TextStyle style)
LinebrokenCellContentView
public LinebrokenCellContentView(TextStyle style,
java.lang.String widthString)
LinebrokenCellContentView
public LinebrokenCellContentView(TextStyle style,
java.lang.String widthString,
boolean baselined)
getHeight
public float getHeight(Cell c,
float forWidth,
float scale)
- Get the height necessary to layout a range of text in a cell,
at a given width and scale.
getSize
public void getSize(Cell c,
float scale,
ViewContext context,
float[] out)
- Description copied from class:
CellView
- Get the default size of the cell at a given scale.
This method exists for the benefit of AWT, where fonts cannot
be scaled accurately.
Note that the returned width and height are in Box scale:
they are not multiplied by the scale parameter.
- Overrides:
getSize
in class CellView
- Parameters:
c
- The cell to get size for, or null for a default size.
place
public void place(Cell c,
VobScene vs,
int box,
ViewContext context)
- Description copied from class:
CellView
- Place the contents of one cell into the given coord system.
The coordsys given shall be a mapping from the rectangle
(0,w)x(0,h) onto the screen.
- Specified by:
place
in class CellView
- Parameters:
box
- A coordinate system, into whose "unit square"
the cell will be placed.
Note that some coordinate systems
(box, orthoBox) set their "unit
square" not to be 0..1 x 0..1.
place
public void place(Cell c,
VobScene vs,
int box,
ViewContext context,
java.lang.String textColor)
getChain
protected gzz.vob.linebreaking.HChain getChain(Cell c,
float scale)
getChain
protected gzz.vob.linebreaking.HChain getChain(java.lang.String s,
float scale)
addVobs
protected void addVobs(java.lang.String s,
gzz.vob.linebreaking.HChain ch,
int start,
int end,
float scale)