PoDoFo::PdfSimpleTableModel Class Reference

#include <PdfTable.h>

Inheritance diagram for PoDoFo::PdfSimpleTableModel:

PoDoFo::PdfTableModel

List of all members.

Public Member Functions

 PdfSimpleTableModel ()
 PdfSimpleTableModel (int nCols, int nRows)
void SetFont (PdfFont *pFont)
void SetAlignment (EPdfAlignment eAlignment)
void SetAlignment (EPdfVerticalAlignment eAlignment)
void SetBackgroundColor (const PdfColor &rColor)
void SetForegroundColor (const PdfColor &rColor)
void SetBackgroundEnabled (bool bEnable)
void SetWordWrapEnabled (bool bEnable)
void SetBorderEnabled (bool bEnable)
void SetBorderWidth (double dWidth)
void SetText (int col, int row, const PdfString &rsString)
virtual PdfString GetText (int col, int row) const
virtual EPdfAlignment GetAlignment (int col, int row) const
virtual EPdfVerticalAlignment GetVerticalAlignment (int col, int row) const
virtual PdfFontGetFont (int col, int row) const
virtual bool HasBackgroundColor (int col, int row) const
virtual PdfColor GetBackgroundColor (int col, int row) const
virtual PdfColor GetForegroundColor (int col, int row) const
virtual bool HasWordWrap (int col, int row) const
virtual bool HasBorders () const
virtual double GetBorderWidth () const
virtual PdfColor GetBorderColor (int col, int row) const
virtual bool HasImage (int col, int row) const
virtual PdfImageGetImage (int col, int row) const


Detailed Description

An implementation of a simple PdfTableModel.

Constructor & Destructor Documentation

PoDoFo::PdfSimpleTableModel::PdfSimpleTableModel (  ) 

Creates an empty PdfSimpleTableModel that does not contain any data.

Using this model will result in drawing an empty table!

PoDoFo::PdfSimpleTableModel::PdfSimpleTableModel ( int  nCols,
int  nRows 
)

Creates an empty PdfSimpleTableModel that does not contain any data.

Using this model will result in drawing an empty table!

Parameters:
nCols number of columns of the data in this table model (must match the PdfTable object)
nRows number of rows of the data in this table model (must match the PdfTable object)
You can set the tables data using SetText.
See also:
SetText


Member Function Documentation

EPdfAlignment PoDoFo::PdfSimpleTableModel::GetAlignment ( int  col,
int  row 
) const [inline, virtual]

Parameters:
col the column of the table cell
row the row of the table cell
Returns:
the horizontal alignment of the contents in the cell

Implements PoDoFo::PdfTableModel.

PdfColor PoDoFo::PdfSimpleTableModel::GetBackgroundColor ( int  col,
int  row 
) const [inline, virtual]

Parameters:
col the column of the table cell
row the row of the table cell
Returns:
the background color of the specified cell

Implements PoDoFo::PdfTableModel.

PdfColor PoDoFo::PdfSimpleTableModel::GetBorderColor ( int  col,
int  row 
) const [inline, virtual]

Parameters:
col the column of the table cell
row the row of the table cell
Returns:
the border color

Implements PoDoFo::PdfTableModel.

double PoDoFo::PdfSimpleTableModel::GetBorderWidth (  )  const [inline, virtual]

Returns:
the stroke witdth of the border line

Implements PoDoFo::PdfTableModel.

PdfFont * PoDoFo::PdfSimpleTableModel::GetFont ( int  col,
int  row 
) const [inline, virtual]

Parameters:
col the column of the table cell
row the row of the table cell
Returns:
the font of this table cell or NULL to use the default font

Implements PoDoFo::PdfTableModel.

PdfColor PoDoFo::PdfSimpleTableModel::GetForegroundColor ( int  col,
int  row 
) const [inline, virtual]

Parameters:
col the column of the table cell
row the row of the table cell
Returns:
the foreground (text) color of the specified cell

Implements PoDoFo::PdfTableModel.

PdfImage * PoDoFo::PdfSimpleTableModel::GetImage ( int  col,
int  row 
) const [inline, virtual]

Parameters:
col the column of the table cell
row the row of the table cell
Returns:
the image for the specified cell or NULL if the cell has no image

Implements PoDoFo::PdfTableModel.

PdfString PoDoFo::PdfSimpleTableModel::GetText ( int  col,
int  row 
) const [inline, virtual]

Parameters:
col the column of the table cell
row the row of the table cell
Returns:
the contents string of this table cell

Implements PoDoFo::PdfTableModel.

EPdfVerticalAlignment PoDoFo::PdfSimpleTableModel::GetVerticalAlignment ( int  col,
int  row 
) const [inline, virtual]

Parameters:
col the column of the table cell
row the row of the table cell
Returns:
the vertical alignment of the contents in the cell

Implements PoDoFo::PdfTableModel.

bool PoDoFo::PdfSimpleTableModel::HasBackgroundColor ( int  col,
int  row 
) const [inline, virtual]

Parameters:
col the column of the table cell
row the row of the table cell
Returns:
true if this cell has a background color

Implements PoDoFo::PdfTableModel.

bool PoDoFo::PdfSimpleTableModel::HasBorders (  )  const [inline, virtual]

Returns:
true if the table should have a border around all cells.

false if no cell border should be visible

Cell borders are always drawn using the current PdfPainter settings.

Implements PoDoFo::PdfTableModel.

bool PoDoFo::PdfSimpleTableModel::HasImage ( int  col,
int  row 
) const [inline, virtual]

Parameters:
col the column of the table cell
row the row of the table cell
Returns:
true if the table cell contains an image

Implements PoDoFo::PdfTableModel.

bool PoDoFo::PdfSimpleTableModel::HasWordWrap ( int  col,
int  row 
) const [inline, virtual]

Parameters:
col the column of the table cell
row the row of the table cell
Returns:
true if the specified cell should use wordwrapping

Implements PoDoFo::PdfTableModel.

void PoDoFo::PdfSimpleTableModel::SetAlignment ( EPdfVerticalAlignment  eAlignment  )  [inline]

Set the vertical alignment of the contents in all table cells

Parameters:
eAlignment the vertiical alignment of text in a table cell

void PoDoFo::PdfSimpleTableModel::SetAlignment ( EPdfAlignment  eAlignment  )  [inline]

Set the horizontal alignment of the contents in all table cells

Parameters:
eAlignment the horizontal alignment of text in a table cell

void PoDoFo::PdfSimpleTableModel::SetBackgroundColor ( const PdfColor rColor  )  [inline]

Set the background color of the table cells

Parameters:
rColor the background color

void PoDoFo::PdfSimpleTableModel::SetBackgroundEnabled ( bool  bEnable  )  [inline]

Sets wether all cells have a background color or not

Parameters:
bEnable if true all cells have a background color

void PoDoFo::PdfSimpleTableModel::SetBorderEnabled ( bool  bEnable  )  [inline]

Sets wether all cells have a border or not.

Parameters:
bEnable if true a border will be drawn using the current PdfPainter settings

void PoDoFo::PdfSimpleTableModel::SetBorderWidth ( double  dWidth  )  [inline]

Sets the stroke width of the border around the table.

Parameters:
dWidth the stroke width of the border

void PoDoFo::PdfSimpleTableModel::SetFont ( PdfFont pFont  )  [inline]

Set the font that will be used to draw all table contents.

Parameters:
pFont the font for the table contents

void PoDoFo::PdfSimpleTableModel::SetForegroundColor ( const PdfColor rColor  )  [inline]

Set the foreground color of the table cells

Parameters:
rColor the foreground color

void PoDoFo::PdfSimpleTableModel::SetText ( int  col,
int  row,
const PdfString rsString 
) [inline]

Sets the contents of a specific cell

Parameters:
col the column of the table cell
row the row of the table cell
rsString the contents of this cell

void PoDoFo::PdfSimpleTableModel::SetWordWrapEnabled ( bool  bEnable  )  [inline]

Sets wether all cells have wordwrapping or not

Parameters:
bEnable if true all cells have wordwrapping


Generated on Sat May 2 02:52:12 2009 for PoDoFo by  doxygen 1.5.7.1