Versions in this module Expand all Collapse all v0 v0.8.29 Jul 20, 2021 Changes in this version + const AlignCenter + const AlignDistribute + const AlignJustify + const AlignLeft + const AlignRight + const BorderDashSmall + const BorderDashed + const BorderDotDash + const BorderDotDotDash + const BorderDotted + const BorderDouble + const BorderDoubleThickness + const BorderEmboss + const BorderEngrave + const BorderHairline + const BorderInset + const BorderOutset + const BorderShadowed + const BorderSingleThickness + const BorderStripped + const BorderThickThinLarge + const BorderThickThinMedium + const BorderThickThinSmall + const BorderThinThickLarge + const BorderThinThickMedium + const BorderThinThickSmall + const BorderThinThickThinLarge + const BorderThinThickThinMedium + const BorderTriple + const BorderWavy + const BorderWavyDouble + const ColorAqua + const ColorBlack + const ColorBlue + const ColorGray + const ColorGreen + const ColorLime + const ColorMagenta + const ColorMaroon + const ColorNavy + const ColorOlive + const ColorPurple + const ColorRed + const ColorSilver + const ColorTeal + const ColorWhite + const ColorYellow + const FontArial + const FontComicSansMS + const FontCourierNew + const FontSymbol + const FontTimesNewRoman + const FormatA2 + const FormatA3 + const FormatA4 + const FormatA5 + const FormatLetter + const ImageFormatJpeg + const ImageFormatPng + const OrientationLandscape + const OrientationPortrait + const VAlignBottom + const VAlignJustify + const VAlignMiddle + const VAlignTop + func RunServer(port int) + type ColorTable []colorItem + func (cTbl *ColorTable) AddColor(c color.RGBA, name string) *ColorTable + type Document struct + func NewDocument() *Document + func (doc *Document) AddColor(c color.RGBA, name string) *Document + func (doc *Document) AddFont(family string, charset int, prq int, name string, code string) *Document + func (doc *Document) AddParagraph() *Paragraph + func (doc *Document) AddTable() *Table + func (doc *Document) Export() []byte + func (doc *Document) GetMaxContentWidth() int + func (doc *Document) GetTableCellWidthByRatio(tableWidth int, ratio ...float64) []int + func (doc *Document) NewColorTable() *ColorTable + func (doc *Document) NewFontTable() *FontTable + func (doc *Document) SetFormat(format string) *Document + func (doc *Document) SetMarginBottom(value int) *Document + func (doc *Document) SetMarginLeft(value int) *Document + func (doc *Document) SetMarginRight(value int) *Document + func (doc *Document) SetMarginTop(value int) *Document + func (doc *Document) SetOrientation(orientation string) *Document + type FontTable []font + func NewFontTable() *FontTable + func (ft *FontTable) AddFont(family string, charset int, prq int, name string, code string) *FontTable + type Paragraph struct + func (p *Paragraph) AddNewLine() *Paragraph + func (p *Paragraph) AddText(textStr string, fontSize int, fontCode string, colorCode string) *Text + func (par *Paragraph) AddPicture(source []byte, format string) *Picture + func (par *Paragraph) SetAlign(align string) *Paragraph + func (par *Paragraph) SetIndentFirstLine(value int) *Paragraph + func (par *Paragraph) SetIndentLeft(value int) *Paragraph + func (par *Paragraph) SetIndentRight(value int) *Paragraph + type Picture struct + func (pic *Picture) SetCropBottom(cropB int) *Picture + func (pic *Picture) SetCropLeft(cropL int) *Picture + func (pic *Picture) SetCropRight(cropR int) *Picture + func (pic *Picture) SetCropTop(cropT int) *Picture + func (pic *Picture) SetHeight(height int) *Picture + func (pic *Picture) SetScaleX(scaleX int) *Picture + func (pic *Picture) SetScaleY(scaleY int) *Picture + func (pic *Picture) SetWidth(width int) *Picture + type Table struct + func (t *Table) AddTableRow() *TableRow + func (t *Table) GetTableCellWidthByRatio(ratio ...float64) []int + func (t *Table) SetAlign(align string) *Table + func (t *Table) SetBorder(isBorder bool) *Table + func (t *Table) SetBorderBottom(isBorder bool) *Table + func (t *Table) SetBorderColor(color string) *Table + func (t *Table) SetBorderLeft(isBorder bool) *Table + func (t *Table) SetBorderRight(isBorder bool) *Table + func (t *Table) SetBorderStyle(bStyle string) *Table + func (t *Table) SetBorderTop(isBorder bool) *Table + func (t *Table) SetBorderWidth(value int) *Table + func (t *Table) SetMarginBottom(value int) *Table + func (t *Table) SetMarginLeft(value int) *Table + func (t *Table) SetMarginRight(value int) *Table + func (t *Table) SetMarginTop(value int) *Table + func (t *Table) SetPadding(value int) *Table + func (t *Table) SetPaddingBottom(value int) *Table + func (t *Table) SetPaddingLeft(value int) *Table + func (t *Table) SetPaddingRight(value int) *Table + func (t *Table) SetPaddingTop(value int) *Table + func (t *Table) SetWidth(width int) *Table + type TableCell struct + func (dc *TableCell) AddParagraph() *Paragraph + func (dc *TableCell) SetBackgroundColor(color string) *TableCell + func (dc *TableCell) SetBorder(isBorder bool) *TableCell + func (dc *TableCell) SetBorderBottom(value bool) *TableCell + func (dc *TableCell) SetBorderColor(color string) *TableCell + func (dc *TableCell) SetBorderLeft(value bool) *TableCell + func (dc *TableCell) SetBorderRight(value bool) *TableCell + func (dc *TableCell) SetBorderStyle(bStyle string) *TableCell + func (dc *TableCell) SetBorderTop(value bool) *TableCell + func (dc *TableCell) SetBorderWidth(value int) *TableCell + func (dc *TableCell) SetMarginBottom(value int) *TableCell + func (dc *TableCell) SetMarginLeft(value int) *TableCell + func (dc *TableCell) SetMarginRight(value int) *TableCell + func (dc *TableCell) SetMarginTop(value int) *TableCell + func (dc *TableCell) SetPadding(value int) *TableCell + func (dc *TableCell) SetPaddingBottom(value int) *TableCell + func (dc *TableCell) SetPaddingLeft(value int) *TableCell + func (dc *TableCell) SetPaddingRight(value int) *TableCell + func (dc *TableCell) SetPaddingTop(value int) *TableCell + func (dc *TableCell) SetVAlign(valign string) *TableCell + func (dc *TableCell) SetVerticalMergedFirst() *TableCell + func (dc *TableCell) SetVerticalMergedNext() *TableCell + func (dc *TableCell) SetWidth(cellWidth int) *TableCell + type TableRow struct + func (tr *TableRow) AddDataCell(width int) *TableCell + func (tr *TableRow) SetBorder(isBorder bool) *TableRow + func (tr *TableRow) SetBorderBottom(isBorder bool) *TableRow + func (tr *TableRow) SetBorderColor(color string) *TableRow + func (tr *TableRow) SetBorderLeft(isBorder bool) *TableRow + func (tr *TableRow) SetBorderRight(isBorder bool) *TableRow + func (tr *TableRow) SetBorderStyle(bStyle string) *TableRow + func (tr *TableRow) SetBorderTop(isBorder bool) *TableRow + func (tr *TableRow) SetBorderWidth(value int) *TableRow + type Text struct + func (text *Text) SetBold() *Text + func (text *Text) SetColor(colorCode string) *Text + func (text *Text) SetItalic() *Text + func (text *Text) SetRotate() *Text + func (text *Text) SetScaps() *Text + func (text *Text) SetStrike() *Text + func (text *Text) SetSub() *Text + func (text *Text) SetSuper() *Text + func (text *Text) SetUnderlining() *Text