cell

Methods

(inner) cell(x, y, width, height, text, lineNumber, align) → {jsPDF}

Source:
Parameters:
Name Type Description
x number
y number
width number
height number
text string
lineNumber number

lineNumber

align string
Returns:

jsPDF-instance

Type
jsPDF

(inner) cellAddPage()

Source:

(inner) getTextDimensions(txt) → {Object}

Source:
Parameters:
Name Type Description
txt string
Returns:

dimensions

Type
Object

(inner) printHeaderRow(lineNumber, new_page)

Source:

Output the store header row

Parameters:
Name Type Description
lineNumber number

The line number to output the header at

new_page boolean

(inner) setHeaderFunction(func)

Source:
Parameters:
Name Type Description
func function

(inner) setTableHeaderRow(config)

Source:

Store the config for outputting a table header

Parameters:
Name Type Description
config Array.<Object>

An array of cell configs that would define a header row: Each config matches the config used by jsPDFAPI.cell except the lineNumber parameter is excluded

(inner) table(xopt, yopt, dataopt, headersopt) → {jsPDF}

Source:

Create a table from a set of data.

Parameters:
Name Type Attributes Description
x Integer <optional>

: left-position for top-left corner of table

y Integer <optional>

top-position for top-left corner of table

data Array.<Object> <optional>

An array of objects containing key-value pairs corresponding to a row of data.

headers Array.<String> <optional>

Omit or null to auto-generate headers at a performance cost

config.printHeaders Object <optional>

True to print column headers at the top of every page

config.autoSize Object <optional>

True to dynamically set the column widths to match the widest cell value

config.margins Object <optional>

margin values for left, top, bottom, and width

config.fontSize Object <optional>

Integer fontSize to use (optional)

config.padding Object <optional>

cell-padding in pt to use (optional)

config.headerBackgroundColor Object <optional>

default is #c8c8c8 (optional)

config.headerTextColor Object <optional>

default is #000 (optional)

config.rowStart Object <optional>

callback to handle before print each row (optional)

config.cellStart Object <optional>

callback to handle before print each cell (optional)

Returns:

jsPDF-instance

Type
jsPDF