Documentation
¶
Overview ¶
Package entity contains all core entities.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cell ¶
Cell represents a cell inside the PDF.
func NewRootCell ¶
NewRootCell creates the main Cell.
func (Cell) GetDimensions ¶
func (c Cell) GetDimensions() *Dimensions
GetDimensions returns the dimensions of the Cell (width and height).
type Config ¶
type Config struct {
ProviderType consts.ProviderType
Dimensions *Dimensions
Margins *Margins
DefaultFont *props.Font
CustomFonts []CustomFont
GenerationMode consts.GenerationMode
ChunkWorkers int
Debug bool
MaxGridSize int
PageNumber *props.PageNumber
Protection *Protection
Compression bool
Metadata *Metadata
BackgroundImage *Image
DisableAutoPageBreak bool
HTMLLimits HTMLLimits
OutlineFromHeadings bool
Watermark *props.Watermark
}
Config is the configuration of a paper instance.
type CustomFont ¶
type CustomFont interface {
GetFamily() string
GetStyle() fontstyle.Type
GetFile() string
GetBytes() []byte
}
CustomFont is the representation of a font that can be added to the pdf.
type Dimensions ¶
Dimensions is the representation of a width and height.
type HTMLLimits ¶
type HTMLLimits = htmllimits.Limits
HTMLLimits caps resource use while translating untrusted HTML.
type Image ¶
type Image struct {
Bytes []byte
Extension extension.Type
Dimensions *Dimensions
}
Image is the representation of an image that can be added to the pdf.
type Metadata ¶
type Metadata struct {
Author *Utf8Text
Creator *Utf8Text
Subject *Utf8Text
Title *Utf8Text
CreationDate *time.Time
KeywordsStr *Utf8Text
}
Metadata is the representation of a PDF metadata.
type Protection ¶
type Protection struct {
Type protection.Type
UserPassword string
OwnerPassword string
Algorithm protection.Encryption
}
Protection is the representation of a pdf protection.
Click to show internal directories.
Click to hide internal directories.