|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.lowagie.text.rtf.RtfCell
A Helper Class for the RtfWriter
.
Do not use it directly
ONLY FOR USE WITH THE RtfWriter NOT with the RtfWriter2.
Parts of this Class were contributed by Steffen Stundzig. Many thanks for the
improvements.
Updates by Benoit WIART
Field Summary
private static byte[]
cellBackgroundColor
Cell background color
private static byte[]
cellBorderBottom
Cell border bottom
private static byte[]
cellBorderLeft
Cell border left
private static byte[]
cellBorderRight
Cell border right
private static byte[]
cellBorderTop
Cell border top
private static byte[]
cellEnd
End of cell
protected static byte[]
cellInTable
Cell is part of table
private static byte[]
cellMergeFirst
First cell to merge with - Horizontal
private static byte[]
cellMergePrev
Merge cell with previous horizontal cell
private int
cellpadding
cell padding, because the table only renders the left and right cell padding
and not the top and bottom one
private static byte[]
cellPaddingBottom
padding bottom
private static byte[]
cellPaddingBottomUnit
padding bottom unit
private static byte[]
cellPaddingLeft
padding left
private static byte[]
cellPaddingLeftUnit
padding left unit
private static byte[]
cellPaddingRight
padding right
private static byte[]
cellPaddingRightUnit
padding right unit
private static byte[]
cellPaddingTop
padding top
private static byte[]
cellPaddingTopUnit
padding top unit
private int
cellRight
Cell right border position
private static byte[]
cellRightBorder
Cell right border position
private static byte[]
cellVerticalAlignBottom
Cell content vertical alignment bottom
private static byte[]
cellVerticalAlignCenter
Cell content vertical alignment center
private static byte[]
cellVerticalAlignTop
Cell content vertical alignment top
private static byte[]
cellVMergeFirst
First cell to merge with - Vertical
private static byte[]
cellVMergePrev
Merge cell with previous vertical cell
private int
cellWidth
Cell width
private static byte[]
cellWidthStyle
Cell width format
private static byte[]
cellWidthTag
Cell width
private boolean
emptyCell
Is this an empty cell
private RtfTable
mainTable
The RtfTable
to which this RtfCell
belongs.
private static int
MERGE_BOTH_FIRST
A possible value for merging
private static int
MERGE_BOTH_PREV
A possible value for merging
private static int
MERGE_HORIZ_FIRST
A possible value for merging
private static int
MERGE_HORIZ_PREV
A possible value for merging
private static int
MERGE_VERT_FIRST
A possible value for merging
private static int
MERGE_VERT_PREV
A possible value for merging
private int
mergeType
Type of merging to do
private Cell
store
Cell
containing the actual data
private RtfWriter
writer
The RtfWriter
to which this RtfCell
belongs.
Constructor Summary
RtfCell(RtfWriter writer,
RtfTable mainTable)
Create a new RtfCell
.
Method Summary
int
getCellRight()
Get the position of the right border of this RtfCell
.
int
getCellWidth()
Get the with of this RtfCell
Cell
getStore()
Get the Cell
with the actual content.
int
importCell(Cell cell,
int cellLeft,
int cellWidth,
int x,
int y,
int cellpadding)
Import a Cell
.
void
setCellRight(int value)
Sets the right position of the cell
void
setCellWidth(int value)
sets the width of the cell
void
setMerge(int mergeType,
RtfCell mergeCell)
Sets the merge type and the RtfCell
with which this
RtfCell
is to be merged.
boolean
writeCellContent(ByteArrayOutputStream os)
Write the content of the RtfCell
.
boolean
writeCellSettings(ByteArrayOutputStream os)
Write the properties of the RtfCell
.
private void
writeInt(ByteArrayOutputStream out,
int i)
Write an Integer to the Outputstream.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Field Detail
MERGE_HORIZ_FIRST
private static final int MERGE_HORIZ_FIRST
MERGE_VERT_FIRST
private static final int MERGE_VERT_FIRST
MERGE_BOTH_FIRST
private static final int MERGE_BOTH_FIRST
MERGE_HORIZ_PREV
private static final int MERGE_HORIZ_PREV
MERGE_VERT_PREV
private static final int MERGE_VERT_PREV
MERGE_BOTH_PREV
private static final int MERGE_BOTH_PREV
cellMergeFirst
private static final byte[] cellMergeFirst
cellVMergeFirst
private static final byte[] cellVMergeFirst
cellMergePrev
private static final byte[] cellMergePrev
cellVMergePrev
private static final byte[] cellVMergePrev
cellVerticalAlignBottom
private static final byte[] cellVerticalAlignBottom
cellVerticalAlignCenter
private static final byte[] cellVerticalAlignCenter
cellVerticalAlignTop
private static final byte[] cellVerticalAlignTop
cellBorderLeft
private static final byte[] cellBorderLeft
cellBorderRight
private static final byte[] cellBorderRight
cellBorderTop
private static final byte[] cellBorderTop
cellBorderBottom
private static final byte[] cellBorderBottom
cellBackgroundColor
private static final byte[] cellBackgroundColor
cellWidthStyle
private static final byte[] cellWidthStyle
cellWidthTag
private static final byte[] cellWidthTag
cellRightBorder
private static final byte[] cellRightBorder
cellInTable
protected static final byte[] cellInTable
cellEnd
private static final byte[] cellEnd
cellPaddingTop
private static final byte[] cellPaddingTop
cellPaddingTopUnit
private static final byte[] cellPaddingTopUnit
cellPaddingBottom
private static final byte[] cellPaddingBottom
cellPaddingBottomUnit
private static final byte[] cellPaddingBottomUnit
cellPaddingLeft
private static final byte[] cellPaddingLeft
cellPaddingLeftUnit
private static final byte[] cellPaddingLeftUnit
cellPaddingRight
private static final byte[] cellPaddingRight
cellPaddingRightUnit
private static final byte[] cellPaddingRightUnit
writer
private RtfWriter writer
RtfWriter
to which this RtfCell
belongs.
mainTable
private RtfTable mainTable
RtfTable
to which this RtfCell
belongs.
cellWidth
private int cellWidth
cellRight
private int cellRight
store
private Cell store
Cell
containing the actual data
emptyCell
private boolean emptyCell
mergeType
private int mergeType
cellpadding
private int cellpadding
Constructor Detail
RtfCell
public RtfCell(RtfWriter writer,
RtfTable mainTable)
RtfCell
.
writer
- The RtfWriter
that this RtfCell
belongs tomainTable
- The RtfTable
that created the
RtfRow
that created the RtfCell
:-)
Method Detail
importCell
public int importCell(Cell cell,
int cellLeft,
int cellWidth,
int x,
int y,
int cellpadding)
Cell
.
cell
- The Cell
containing the data for this
RtfCell
cellLeft
- The position of the left bordercellWidth
- The default width of a cellx
- The column index of this RtfCell
y
- The row index of this RtfCell
cellpadding
- the cellpadding
writeCellSettings
public boolean writeCellSettings(ByteArrayOutputStream os)
throws DocumentException
RtfCell
.
os
- The OutputStream
to which to write the properties
of the RtfCell
to.
DocumentException
writeCellContent
public boolean writeCellContent(ByteArrayOutputStream os)
throws DocumentException
RtfCell
.
os
- The OutputStream
to which to write the content of
the RtfCell
to.
DocumentException
setMerge
public void setMerge(int mergeType,
RtfCell mergeCell)
RtfCell
with which this
RtfCell
is to be merged.
mergeType
- The merge type specifies the kind of merge to be applied
(MERGE_HORIZ_PREV, MERGE_VERT_PREV, MERGE_BOTH_PREV)mergeCell
- The RtfCell
that the cell at x and y is to
be merged with
getStore
public Cell getStore()
Cell
with the actual content.
Cell
which is contained in the RtfCell
getCellWidth
public int getCellWidth()
RtfCell
RtfCell
setCellWidth
public void setCellWidth(int value)
value
- a width
getCellRight
public int getCellRight()
RtfCell
.
setCellRight
public void setCellRight(int value)
value
- a cell position
writeInt
private void writeInt(ByteArrayOutputStream out,
int i)
throws IOException
out
- The OutputStream
to be written to.i
- The int to be written.
IOException
Overview
Package
Class
Tree
Deprecated
Index
Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD