implementation_webassembly

package
v1.13.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 19, 2024 License: MIT Imports: 30 Imported by: 0

Documentation

Index

Constants

View Source
const (
	FPDF_ERR_SUCCESS  FPDF_ERR = 0
	FPDF_ERR_UNKNOWN           = 1
	FPDF_ERR_FILE              = 2
	FPDF_ERR_FORMAT            = 3
	FPDF_ERR_PASSWORD          = 4
	FPDF_ERR_SECURITY          = 5
	FPDF_ERR_PAGE              = 6
)

Variables

View Source
var CurrentLocalTimeHandler requests.SetLocaltimeFunction
View Source
var CurrentTimeHandler requests.SetTimeFunction
View Source
var CurrentUnsupportedObjectHandler requests.UnSpObjProcessHandler
View Source
var FileAvailables = struct {
	Refs  map[uint32]*DataAvailHandle
	Mutex *sync.Mutex
}{
	Refs:  map[uint32]*DataAvailHandle{},
	Mutex: &sync.Mutex{},
}
View Source
var FileHints = struct {
	Refs  map[uint32]*DataAvailHandle
	Mutex *sync.Mutex
}{
	Refs:  map[uint32]*DataAvailHandle{},
	Mutex: &sync.Mutex{},
}
View Source
var FileReaders = struct {
	Refs    map[uint32]*FileReaderRef
	Counter uint32
	Mutex   *sync.Mutex
}{
	Refs:    map[uint32]*FileReaderRef{},
	Counter: 0,
	Mutex:   &sync.Mutex{},
}
View Source
var FileWriters = struct {
	Refs    map[uint32]*FileWriterRef
	Counter uint32
	Mutex   *sync.Mutex
}{
	Refs:    map[uint32]*FileWriterRef{},
	Counter: 0,
	Mutex:   &sync.Mutex{},
}
View Source
var FormFillInfoHandles = struct {
	Refs  map[uint32]*FormFillInfo
	Mutex *sync.Mutex
}{
	Refs:  map[uint32]*FormFillInfo{},
	Mutex: &sync.Mutex{},
}
View Source
var PauseHandles = struct {
	Refs  map[references.FPDF_PAGE]*PauseHandle
	Mutex *sync.RWMutex
}{
	Refs:  map[references.FPDF_PAGE]*PauseHandle{},
	Mutex: &sync.RWMutex{},
}

Functions

This section is empty.

Types

type ActionHandle

type ActionHandle struct {
	// contains filtered or unexported fields
}

type AnnotationHandle

type AnnotationHandle struct {
	// contains filtered or unexported fields
}

type AttachmentHandle

type AttachmentHandle struct {
	// contains filtered or unexported fields
}

type BitmapHandle

type BitmapHandle struct {
	// contains filtered or unexported fields
}

type BookmarkHandle

type BookmarkHandle struct {
	// contains filtered or unexported fields
}

type ByteArrayPointer

type ByteArrayPointer struct {
	Pointer uint64
	Free    func()
	Value   func(copy bool) ([]byte, error)
}

type BytesReaderCloser

type BytesReaderCloser struct {
	// contains filtered or unexported fields
}

A Reader implements the io.Reader, io.ReaderAt, io.WriterTo, io.Seeker, io.ByteScanner, and io.RuneScanner interfaces by reading from a byte slice. Unlike a Buffer, a Reader is read-only and supports seeking.

func NewBytesReaderCloser

func NewBytesReaderCloser(b []byte) *BytesReaderCloser

BytesReaderCloser returns a new Reader reading from b.

func (*BytesReaderCloser) Close

func (r *BytesReaderCloser) Close() error

func (*BytesReaderCloser) Len

func (r *BytesReaderCloser) Len() int

Len returns the number of bytes of the unread portion of the slice.

func (*BytesReaderCloser) Read

func (r *BytesReaderCloser) Read(b []byte) (n int, err error)

Read implements the io.Reader interface.

func (*BytesReaderCloser) ReadAt

func (r *BytesReaderCloser) ReadAt(b []byte, off int64) (n int, err error)

ReadAt implements the io.ReaderAt interface.

func (*BytesReaderCloser) ReadByte

func (r *BytesReaderCloser) ReadByte() (byte, error)

ReadByte implements the io.ByteReader interface.

func (*BytesReaderCloser) ReadRune

func (r *BytesReaderCloser) ReadRune() (ch rune, size int, err error)

ReadRune implements the io.RuneReader interface.

func (*BytesReaderCloser) Reset

func (r *BytesReaderCloser) Reset(b []byte)

Reset resets the Reader to be reading from b.

func (*BytesReaderCloser) Seek

func (r *BytesReaderCloser) Seek(offset int64, whence int) (int64, error)

Seek implements the io.Seeker interface.

func (*BytesReaderCloser) Size

func (r *BytesReaderCloser) Size() int64

Size returns the original length of the underlying byte slice. Size is the number of bytes available for reading via ReadAt. The returned value is always the same and is not affected by calls to any other method.

func (*BytesReaderCloser) UnreadByte

func (r *BytesReaderCloser) UnreadByte() error

UnreadByte complements ReadByte in implementing the io.ByteScanner interface.

func (*BytesReaderCloser) UnreadRune

func (r *BytesReaderCloser) UnreadRune() error

UnreadRune complements ReadRune in implementing the io.RuneScanner interface.

func (*BytesReaderCloser) WriteTo

func (r *BytesReaderCloser) WriteTo(w io.Writer) (n int64, err error)

WriteTo implements the io.WriterTo interface.

type CFPDF_WIDESTRING

type CFPDF_WIDESTRING struct {
	Pointer uint64
	Free    func()
}

type CString

type CString struct {
	Pointer uint64
	Free    func()
}

type ClipPathHandle

type ClipPathHandle struct {
	// contains filtered or unexported fields
}

type DataAvailHandle

type DataAvailHandle struct {
	DataAvailableCallback func(offset, size uint64) bool
	AddSegmentCallback    func(offset, size uint64)
	// contains filtered or unexported fields
}

type DestHandle

type DestHandle struct {
	// contains filtered or unexported fields
}

type DocumentHandle

type DocumentHandle struct {
	// contains filtered or unexported fields
}

func (*DocumentHandle) Close

Close closes the internal references in FPDF

type DoublePointer

type DoublePointer struct {
	Pointer uint64
	Free    func()
	Value   func() (float64, error)
}

type FPDF_ERR

type FPDF_ERR int

type FS_POINTFArrayPointer

type FS_POINTFArrayPointer struct {
	Pointer uint64
	Size    uint64
	Free    func()
	Value   func() ([]structs.FPDF_FS_POINTF, error)
}

type FS_POINTFPointer

type FS_POINTFPointer struct {
	Pointer uint64
	Free    func()
	Value   func() (*structs.FPDF_FS_POINTF, error)
}

type FileReaderRef

type FileReaderRef struct {
	Reader       io.ReadSeeker
	FileAccess   *uint64
	ParamPointer *uint64
}

type FileWriterRef

type FileWriterRef struct {
	Writer    io.Writer
	FileWrite *uint64
}

type FloatArrayPointer

type FloatArrayPointer struct {
	Pointer uint64
	Size    uint64
	Free    func()
	Value   func() ([]float32, error)
}

type FloatPointer

type FloatPointer struct {
	Pointer uint64
	Free    func()
	Value   func() (float32, error)
}

type FontHandle

type FontHandle struct {
	// contains filtered or unexported fields
}

type FormFillInfo

type FormFillInfo struct {
	Struct           *uint64
	FormFillInfo     *structs.FPDF_FORMFILLINFO
	FormHandleHandle *FormHandleHandle
	Instance         *PdfiumImplementation
}

func (*FormFillInfo) FFI_DoGoToAction

func (f *FormFillInfo) FFI_DoGoToAction(nPageIndex, zoomMode, fPosArray, sizeofArray uint32)

func (*FormFillInfo) FFI_DoURIAction

func (f *FormFillInfo) FFI_DoURIAction(bsURI uint32)

func (*FormFillInfo) FFI_ExecuteNamedAction

func (f *FormFillInfo) FFI_ExecuteNamedAction(namedActionPointer uint64)

func (*FormFillInfo) FFI_GetCurrentPage

func (f *FormFillInfo) FFI_GetCurrentPage(document uint64) uint64

func (*FormFillInfo) FFI_GetLocalTime

func (f *FormFillInfo) FFI_GetLocalTime() structs.FPDF_SYSTEMTIME

func (*FormFillInfo) FFI_GetPage

func (f *FormFillInfo) FFI_GetPage(document uint64, pageIndex int) uint64

func (*FormFillInfo) FFI_GetRotation

func (f *FormFillInfo) FFI_GetRotation(page uint64) int

func (*FormFillInfo) FFI_Invalidate_CB

func (f *FormFillInfo) FFI_Invalidate_CB(page uint32, left, top, right, bottom uint64)

func (*FormFillInfo) FFI_KillTimer

func (f *FormFillInfo) FFI_KillTimer(nTimerID int)

func (*FormFillInfo) FFI_OnChange

func (f *FormFillInfo) FFI_OnChange()

func (*FormFillInfo) FFI_OutputSelectedRect

func (f *FormFillInfo) FFI_OutputSelectedRect(page uint32, left, top, right, bottom uint64)

func (*FormFillInfo) FFI_SetCursor

func (f *FormFillInfo) FFI_SetCursor(cursor uint32)

func (*FormFillInfo) FFI_SetTextFieldFocus

func (f *FormFillInfo) FFI_SetTextFieldFocus(value uint32, valueLen uint32, isFocus uint32)

func (*FormFillInfo) FFI_SetTimer

func (f *FormFillInfo) FFI_SetTimer(uElapse, lpTimerFunc uint32) int

func (*FormFillInfo) Release

func (f *FormFillInfo) Release()

type FormHandleHandle

type FormHandleHandle struct {
	// contains filtered or unexported fields
}

type FunctionWrapper

type FunctionWrapper struct {
	// contains filtered or unexported fields
}

func (*FunctionWrapper) Call

func (f *FunctionWrapper) Call(ctx context.Context, params ...uint64) (ret []uint64, err error)

Call implements the same method as documented on api.Function.

func (*FunctionWrapper) Definition

func (f *FunctionWrapper) Definition() api.FunctionDefinition

Definition implements the same method as documented on api.FunctionDefinition.

type GlyphPathHandle

type GlyphPathHandle struct {
	// contains filtered or unexported fields
}

type IntArrayPointer

type IntArrayPointer struct {
	Pointer uint64
	Size    uint64
	Free    func()
	Value   func() ([]int, error)
}

type IntPointer

type IntPointer struct {
	Pointer uint64
	Free    func()
	Value   func() (int, error)
}

type JavaScriptActionHandle

type JavaScriptActionHandle struct {
	// contains filtered or unexported fields
}

type LinkHandle

type LinkHandle struct {
	// contains filtered or unexported fields
}

type LongPointer

type LongPointer struct {
	Pointer uint64
	Free    func()
	Value   func() (int64, error)
}

type PageHandle

type PageHandle struct {
	// contains filtered or unexported fields
}

func (*PageHandle) Close

func (p *PageHandle) Close(pi *PdfiumImplementation)

Close closes the internal references in FPDF

type PageLinkHandle

type PageLinkHandle struct {
	// contains filtered or unexported fields
}

type PageObjectHandle

type PageObjectHandle struct {
	// contains filtered or unexported fields
}

type PageObjectMarkHandle

type PageObjectMarkHandle struct {
	// contains filtered or unexported fields
}

type PageRangeHandle

type PageRangeHandle struct {
	// contains filtered or unexported fields
}

type PathSegmentHandle

type PathSegmentHandle struct {
	// contains filtered or unexported fields
}

type PauseHandle

type PauseHandle struct {
	StringRef uint64
	Pointer   uint64
	Callback  func() bool
}

type PdfiumImplementation

type PdfiumImplementation struct {

	// Wazero items
	Context   context.Context
	Functions map[string]api.Function
	Module    api.Module
	// contains filtered or unexported fields
}

Here is the real implementation of Pdfium

func GetInstance

func GetInstance(ctx context.Context, functions map[string]api.Function, module api.Module) *PdfiumImplementation

func (*PdfiumImplementation) ByteArrayPointer

func (p *PdfiumImplementation) ByteArrayPointer(size uint64, in []byte) (*ByteArrayPointer, error)

func (*PdfiumImplementation) CFPDF_WIDESTRING

func (p *PdfiumImplementation) CFPDF_WIDESTRING(input string) (*CFPDF_WIDESTRING, error)

func (*PdfiumImplementation) CSizeDouble

func (p *PdfiumImplementation) CSizeDouble() uint64

func (*PdfiumImplementation) CSizeFS_POINTF

func (p *PdfiumImplementation) CSizeFS_POINTF() uint64

func (*PdfiumImplementation) CSizeFloat

func (p *PdfiumImplementation) CSizeFloat() uint64

func (*PdfiumImplementation) CSizeInt

func (p *PdfiumImplementation) CSizeInt() uint64

func (*PdfiumImplementation) CSizeLong

func (p *PdfiumImplementation) CSizeLong() uint64

func (*PdfiumImplementation) CSizePointer

func (p *PdfiumImplementation) CSizePointer() uint64

func (*PdfiumImplementation) CSizeStructFPDF_IMAGEOBJ_METADATA

func (p *PdfiumImplementation) CSizeStructFPDF_IMAGEOBJ_METADATA() uint64

func (*PdfiumImplementation) CSizeStructFS_MATRIX

func (p *PdfiumImplementation) CSizeStructFS_MATRIX() uint64

func (*PdfiumImplementation) CSizeStructFS_QUADPOINTSF

func (p *PdfiumImplementation) CSizeStructFS_QUADPOINTSF() uint64

func (*PdfiumImplementation) CSizeStructFS_RECTF

func (p *PdfiumImplementation) CSizeStructFS_RECTF() uint64

func (*PdfiumImplementation) CSizeStructFS_SIZEF

func (p *PdfiumImplementation) CSizeStructFS_SIZEF() uint64

func (*PdfiumImplementation) CSizeUInt

func (p *PdfiumImplementation) CSizeUInt() uint64

func (*PdfiumImplementation) CSizeULong

func (p *PdfiumImplementation) CSizeULong() uint64

func (*PdfiumImplementation) CString

func (p *PdfiumImplementation) CString(input string) (*CString, error)

func (*PdfiumImplementation) CStructFPDF_IMAGEOBJ_METADATA

func (p *PdfiumImplementation) CStructFPDF_IMAGEOBJ_METADATA(in *structs.FPDF_IMAGEOBJ_METADATA) (uint64, func() (*structs.FPDF_IMAGEOBJ_METADATA, error), error)

func (*PdfiumImplementation) CStructFS_MATRIX

func (p *PdfiumImplementation) CStructFS_MATRIX(in *structs.FPDF_FS_MATRIX) (uint64, func() (*structs.FPDF_FS_MATRIX, error), error)

func (*PdfiumImplementation) CStructFS_QUADPOINTSF

func (p *PdfiumImplementation) CStructFS_QUADPOINTSF(in *structs.FPDF_FS_QUADPOINTSF) (uint64, func() (*structs.FPDF_FS_QUADPOINTSF, error), error)

func (*PdfiumImplementation) CStructFS_RECTF

func (p *PdfiumImplementation) CStructFS_RECTF(in *structs.FPDF_FS_RECTF) (uint64, func() (*structs.FPDF_FS_RECTF, error), error)

func (*PdfiumImplementation) CStructFS_SIZEF

func (p *PdfiumImplementation) CStructFS_SIZEF(in *structs.FPDF_FS_SIZEF) (uint64, func() (*structs.FPDF_FS_SIZEF, error), error)

func (*PdfiumImplementation) Close

func (p *PdfiumImplementation) Close() error

func (*PdfiumImplementation) CreateFileAccessReader

func (p *PdfiumImplementation) CreateFileAccessReader(fileSize int64, reader io.ReadSeeker) (*uint64, *uint32, error)

func (*PdfiumImplementation) DoublePointer

func (p *PdfiumImplementation) DoublePointer(in *float64) (*DoublePointer, error)

func (*PdfiumImplementation) FORM_CanRedo

func (p *PdfiumImplementation) FORM_CanRedo(request *requests.FORM_CanRedo) (*responses.FORM_CanRedo, error)

FORM_CanRedo Find out if it is possible for the current focused widget in a given form to perform a redo operation.

func (*PdfiumImplementation) FORM_CanUndo

func (p *PdfiumImplementation) FORM_CanUndo(request *requests.FORM_CanUndo) (*responses.FORM_CanUndo, error)

FORM_CanUndo Find out if it is possible for the current focused widget in a given form to perform an undo operation.

func (*PdfiumImplementation) FORM_DoDocumentAAction

FORM_DoDocumentAAction This method is required for performing the document's additional-action. This method will do nothing if there is no document additional-action corresponding to the specified type.

func (*PdfiumImplementation) FORM_DoDocumentJSAction

FORM_DoDocumentJSAction This method is required for performing document-level JavaScript actions. It should be invoked after the PDF document has been loaded. If there is document-level JavaScript action embedded in the document, this method will execute the JavaScript action. Otherwise, the method will do nothing.

func (*PdfiumImplementation) FORM_DoDocumentOpenAction

FORM_DoDocumentOpenAction This method is required for performing open-action when the document is opened. This method will do nothing if there are no open-actions embedded in the document.

func (*PdfiumImplementation) FORM_DoPageAAction

FORM_DoPageAAction This method is required for performing the page object's additional-action when opened or closed. This method will do nothing if no additional-action corresponding to the specified type exists.

func (*PdfiumImplementation) FORM_ForceToKillFocus

FORM_ForceToKillFocus Call this member function to force to kill the focus of the form field which has focus. If it would kill the focus of a form field, save the value of form field if was changed by theuser.

func (*PdfiumImplementation) FORM_GetFocusedAnnot

FORM_GetFocusedAnnot Call this member function to get the currently focused annotation. Not currently supported for XFA forms - will report no focused annotation. Must call FPDFPage_CloseAnnot() when the annotation returned by this function is no longer needed. Experimental API.

func (*PdfiumImplementation) FORM_GetFocusedText

FORM_GetFocusedText Call this function to obtain the text within the current focused field, if any. Experimental API

func (*PdfiumImplementation) FORM_GetSelectedText

FORM_GetSelectedText Call this function to obtain selected text within a form text field or form combobox text field.

func (*PdfiumImplementation) FORM_IsIndexSelected

FORM_IsIndexSelected returns whether or not the value at index of the focused annotation is currently selected. Intended for use with listbox/combobox widget types. Default implementation is a no-op that will return false for other types. Not currently supported for XFA forms - will return false. Experimental API

func (*PdfiumImplementation) FORM_OnAfterLoadPage

FORM_OnAfterLoadPage This method is required for implementing all the form related functions. Should be invoked after user successfully loaded a PDF page, and FPDFDOC_InitFormFillEnvironment() has been invoked.

func (*PdfiumImplementation) FORM_OnBeforeClosePage

FORM_OnBeforeClosePage This method is required for implementing all the form related functions. Should be invoked before user closes the PDF page.

func (*PdfiumImplementation) FORM_OnChar

func (p *PdfiumImplementation) FORM_OnChar(request *requests.FORM_OnChar) (*responses.FORM_OnChar, error)

FORM_OnChar Call this member function when a keystroke translates to a nonsystem character.

func (*PdfiumImplementation) FORM_OnFocus

func (p *PdfiumImplementation) FORM_OnFocus(request *requests.FORM_OnFocus) (*responses.FORM_OnFocus, error)

FORM_OnFocus This function focuses the form annotation at a given point. If the annotation at the point already has focus, nothing happens. If there is no annotation at the point, removes form focus.

func (*PdfiumImplementation) FORM_OnKeyDown

FORM_OnKeyDown Call this member function when a nonsystem key is pressed.

func (*PdfiumImplementation) FORM_OnKeyUp

func (p *PdfiumImplementation) FORM_OnKeyUp(request *requests.FORM_OnKeyUp) (*responses.FORM_OnKeyUp, error)

FORM_OnKeyUp Call this member function when a nonsystem key is released. Currently unimplemented and always returns false. PDFium reserves this API and may implement it in the future on an as-needed basis.

func (*PdfiumImplementation) FORM_OnLButtonDoubleClick

FORM_OnLButtonDoubleClick Call this member function when the user double clicks the left mouse button.

func (*PdfiumImplementation) FORM_OnLButtonDown

FORM_OnLButtonDown Call this member function when the user presses the left mouse button.

func (*PdfiumImplementation) FORM_OnLButtonUp

FORM_OnLButtonUp Call this member function when the user releases the left mouse button.

func (*PdfiumImplementation) FORM_OnMouseMove

FORM_OnMouseMove Call this member function when the mouse cursor moves.

func (*PdfiumImplementation) FORM_OnMouseWheel

FORM_OnMouseWheel Call this member function when the user scrolls the mouse wheel. For X and Y delta, the caller must normalize platform-specific wheel deltas. e.g. On Windows, a delta value of 240 for a WM_MOUSEWHEEL event normalizes to 2, since Windows defines WHEEL_DELTA as 120. Experimental API

func (*PdfiumImplementation) FORM_OnRButtonDown

FORM_OnRButtonDown Call this member function when the user presses the right mouse button. At the present time, has no effect except in XFA builds, but is included for the sake of symmetry.

func (*PdfiumImplementation) FORM_OnRButtonUp

FORM_OnRButtonUp Call this member function when the user releases the right mouse button. At the present time, has no effect except in XFA builds, but is included for the sake of symmetry.

func (*PdfiumImplementation) FORM_Redo

func (p *PdfiumImplementation) FORM_Redo(request *requests.FORM_Redo) (*responses.FORM_Redo, error)

FORM_Redo Make the current focussed widget perform a redo operation.

func (*PdfiumImplementation) FORM_ReplaceAndKeepSelection

FORM_ReplaceAndKeepSelection Call this function to replace the selected text in a form text field or user-editable form combobox text field with another text string (which can be empty or non-empty). If there is no selected text, this function will append the replacement text after the current caret position. After the insertion, the inserted text will be selected. Experimental API

func (*PdfiumImplementation) FORM_ReplaceSelection

FORM_ReplaceSelection Call this function to replace the selected text in a form text field or user-editable form combobox text field with another text string (which can be empty or non-empty). If there is no selected text, this function will append the replacement text after the current caret position.

func (*PdfiumImplementation) FORM_SelectAllText

FORM_SelectAllText Call this function to select all the text within the currently focused form text field or form combobox text field. Experimental API

func (*PdfiumImplementation) FORM_SetFocusedAnnot

FORM_SetFocusedAnnot Call this member function to set the currently focused annotation. The annotation can't be nil. To kill focus, use FORM_ForceToKillFocus() instead. Experimental API.

func (*PdfiumImplementation) FORM_SetIndexSelected

FORM_SetIndexSelected selects/deselects the value at the given index of the focused annotation. Intended for use with listbox/combobox widget types. Comboboxes have at most a single value selected at a time which cannot be deselected. Deselect on a combobox is a no-op that returns false. Default implementation is a no-op that will return false for other types. Not currently supported for XFA forms - will return false. Experimental API

func (*PdfiumImplementation) FORM_Undo

func (p *PdfiumImplementation) FORM_Undo(request *requests.FORM_Undo) (*responses.FORM_Undo, error)

FORM_Undo Make the current focussed widget perform an undo operation.

func (*PdfiumImplementation) FPDFAction_GetDest

FPDFAction_GetDest returns the destination of a specific go-to or remote-goto action. Only action with type PDF_ACTION_ACTION_GOTO and PDF_ACTION_ACTION_REMOTEGOTO can have destination data. In case of remote goto action, the application should first use function FPDFAction_GetFilePath to get file path, then load that particular document, and use its document handle to call this function.

func (*PdfiumImplementation) FPDFAction_GetFilePath

FPDFAction_GetFilePath returns the file path from a remote goto or launch action. Only works on actions that have the type FPDF_ACTION_ACTION_REMOTEGOTO or FPDF_ACTION_ACTION_LAUNCH.

func (*PdfiumImplementation) FPDFAction_GetType

FPDFAction_GetType returns the action associated with a bookmark item.

func (*PdfiumImplementation) FPDFAction_GetURIPath

FPDFAction_GetURIPath returns the URI path from a URI action.

func (*PdfiumImplementation) FPDFAnnot_AddFileAttachment added in v1.12.0

FPDFAnnot_AddFileAttachment Add an embedded file to the given annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_AddInkStroke

FPDFAnnot_AddInkStroke adds a new InkStroke, represented by an array of points, to the InkList of the annotation. The API creates an InkList if one doesn't already exist in the annotation. This API works only for ink annotations. Please refer to ISO 32000-1:2008 spec, section 12.5.6.13. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_AppendAttachmentPoints

FPDFAnnot_AppendAttachmentPoints appends to the list of attachment points (i.e. quadpoints) of an annotation. If the annotation's appearance stream is defined and this annotation is of a type with quadpoints, then update the bounding box too if the new quadpoints define a bigger one. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_AppendObject

FPDFAnnot_AppendObject adds the given object to the given annotation. The object must have been created by FPDFPageObj_CreateNew{Path|Rect}() or FPDFPageObj_New{Text|Image}Obj(), and will be owned by the annotation. Note that an object cannot belong to more than one annotation. Currently, only ink and stamp annotations are supported by this API. Also note that only path, image, and text objects have APIs for creation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_CountAttachmentPoints

FPDFAnnot_CountAttachmentPoints returns the number of sets of quadpoints of an annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetAP

FPDFAnnot_GetAP returns the AP (appearance string) from annotation's dictionary for a given appearance mode. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetAttachmentPoints

FPDFAnnot_GetAttachmentPoints returns the attachment points (i.e. quadpoints) of an annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetBorder

FPDFAnnot_GetBorder returns the characteristics of the annotation's border (rounded rectangle). Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetColor

FPDFAnnot_GetColor returns the color of an annotation. If no color is specified, default to yellow for highlight annotation, black for all else. Fails when called on annotations with appearance streams already defined; instead use FPDFPath_Get{Stroke|Fill}Color(). Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFileAttachment added in v1.12.0

FPDFAnnot_GetFileAttachment get the attachment from the given annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFlags

FPDFAnnot_GetFlags returns the annotation flags of the given annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFocusableSubtypes

FPDFAnnot_GetFocusableSubtypes returns the list of focusable annotation subtype as set by host. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFocusableSubtypesCount

FPDFAnnot_GetFocusableSubtypesCount returns the count of focusable annotation subtypes as set by host. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFontColor added in v1.13.0

FPDFAnnot_GetFontColor returns the RGB value of the font color for an annotation with variable text. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFontSize

FPDFAnnot_GetFontSize returns the float value of the font size for an annotation with variable text. If 0, the font is to be auto-sized: its size is computed as a function of the height of the annotation rectangle. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFormAdditionalActionJavaScript

FPDFAnnot_GetFormAdditionalActionJavaScript returns the JavaScript of an event of the annotation's additional actions. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFormControlCount

FPDFAnnot_GetFormControlCount returns the count of annotations in the annotation's control group. A group of interactive form annotations is collectively called a form control group. Here, annotation, an interactive form annotation, should be either a radio button or a checkbox. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFormControlIndex

FPDFAnnot_GetFormControlIndex returns the index of the given annotation it's control group. A group of interactive form annotations is collectively called a form control group. Here, the annotation, an interactive form annotation, should be either a radio button or a checkbox. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFormFieldAlternateName

FPDFAnnot_GetFormFieldAlternateName returns the alternate name of an annotation, which is an interactive form annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFormFieldAtPoint

FPDFAnnot_GetFormFieldAtPoint returns an interactive form annotation whose rectangle contains a given point on a page. Must call FPDFPage_CloseAnnot() when the annotation returned is no longer needed. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFormFieldExportValue

FPDFAnnot_GetFormFieldExportValue returns the export value of the given annotation which is an interactive form annotation. Intended for use with radio button and checkbox widget annotations. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFormFieldFlags

FPDFAnnot_GetFormFieldFlags returns the form field annotation flags of the given annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFormFieldName

FPDFAnnot_GetFormFieldName returns the name of the given annotation, which is an interactive form annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFormFieldType

FPDFAnnot_GetFormFieldType returns the form field type of the given annotation, which is an interactive form annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetFormFieldValue

FPDFAnnot_GetFormFieldValue returns the value of the given annotation, which is an interactive form annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetInkListCount

FPDFAnnot_GetInkListCount returns the number of paths in the ink list of an ink annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetInkListPath

FPDFAnnot_GetInkListPath returns a path in the ink list of an ink annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetLine

FPDFAnnot_GetLine returns the starting and ending coordinates of a line annotation. Experimental API.

FPDFAnnot_GetLink returns FPDF_LINK object for the given annotation. Intended to use for link annotations. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetLinkedAnnot

FPDFAnnot_GetLinkedAnnot returns the annotation corresponding to the given key in the annotations's dictionary. Common keys for linking annotations include "IRT" and "Popup". Must call FPDFPage_CloseAnnot() when the annotation returned by this function is no longer needed. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetNumberValue

FPDFAnnot_GetNumberValue returns the float value corresponding to the given key in the annotations's dictionary. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetObject

FPDFAnnot_GetObject returns the object in the given annotation at the given index. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetObjectCount

FPDFAnnot_GetObjectCount returns the total number of objects in the given annotation, including path objects, text objects, external objects, image objects, and shading objects. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetOptionCount

FPDFAnnot_GetOptionCount returns the number of options in the annotation's "Opt" dictionary. Intended for use with listbox and combobox widget annotations. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetOptionLabel

FPDFAnnot_GetOptionLabel returns the string value for the label of the option at the given index in annotation's "Opt" dictionary. Intended for use with listbox and combobox widget annotations. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetRect

FPDFAnnot_GetRect returns the annotation rectangle defining the location of the annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetStringValue

FPDFAnnot_GetStringValue returns the string value corresponding to the given key in the annotations's dictionary. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetSubtype

FPDFAnnot_GetSubtype returns the subtype of an annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetValueType

FPDFAnnot_GetValueType returns the type of the value corresponding to the given key the annotation's dictionary. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_GetVertices

FPDFAnnot_GetVertices returns the vertices of a polygon or polyline annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_HasAttachmentPoints

FPDFAnnot_HasAttachmentPoints returns whether the annotation is of a type that has attachment points (i.e. quadpoints). Quadpoints are the vertices of the rectangle that encompasses the texts affected by the annotation. They provide the coordinates in the page where the annotation is attached. Only text markup annotations (i.e. highlight, strikeout, squiggly, and underline) and link annotations have quadpoints. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_HasKey

FPDFAnnot_HasKey checks whether the given annotation's dictionary has the given key as a key. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_IsChecked

FPDFAnnot_IsChecked returns whether the given annotation is a form widget that is checked. Intended for use with checkbox and radio button widgets. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_IsObjectSupportedSubtype

FPDFAnnot_IsObjectSupportedSubtype checks whether an annotation subtype is currently supported for object extraction, update, and removal. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_IsOptionSelected

FPDFAnnot_IsOptionSelected returns whether or not the option at the given index in annotation's "Opt" dictionary is selected. Intended for use with listbox and combobox widget annotations. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_IsSupportedSubtype

FPDFAnnot_IsSupportedSubtype returns whether an annotation subtype is currently supported for creation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_RemoveInkList

FPDFAnnot_RemoveInkList removes an InkList in the given annotation. This API works only for ink annotations. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_RemoveObject

FPDFAnnot_RemoveObject removes the object in the given annotation at the given index. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_SetAP

FPDFAnnot_SetAP sets the AP (appearance string) in annotations's dictionary for a given appearance mode. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_SetAttachmentPoints

FPDFAnnot_SetAttachmentPoints replaces the attachment points (i.e. quadpoints) set of an annotation at the given quad index. This index needs to be within the result of FPDFAnnot_CountAttachmentPoints(). If the annotation's appearance stream is defined and this annotation is of a type with quadpoints, then update the bounding box too if the new quadpoints define a bigger one. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_SetBorder

FPDFAnnot_SetBorder sets the characteristics of the annotation's border (rounded rectangle). Experimental API.

func (*PdfiumImplementation) FPDFAnnot_SetColor

FPDFAnnot_SetColor sets the color of an annotation. Fails when called on annotations with appearance streams already defined; instead use FPDFPath_Set{Stroke|Fill}Color(). Experimental API.

func (*PdfiumImplementation) FPDFAnnot_SetFlags

FPDFAnnot_SetFlags sets the annotation flags of the given annotation. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_SetFocusableSubtypes

FPDFAnnot_SetFocusableSubtypes sets the list of focusable annotation subtypes. Annotations of subtype FPDF_ANNOT_WIDGET are by default focusable. New subtypes set using this API will override the existing subtypes. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_SetRect

FPDFAnnot_SetRect sets the annotation rectangle defining the location of the annotation. If the annotation's appearance stream is defined and this annotation is of a type without quadpoints, then update the bounding box too if the new rectangle defines a bigger one. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_SetStringValue

FPDFAnnot_SetStringValue sets the string value corresponding to the given key in the annotations's dictionary, overwriting the existing value if any. The value type would be FPDF_OBJECT_STRING after this function call succeeds. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_SetURI

FPDFAnnot_SetURI adds a URI action to the given annotation, overwriting the existing action, if any. Experimental API.

func (*PdfiumImplementation) FPDFAnnot_UpdateObject

FPDFAnnot_UpdateObject updates the given object in the given annotation. The object must be in the annotation already and must have been retrieved by FPDFAnnot_GetObject(). Currently, only ink and stamp annotations are supported by this API. Also note that only path, image, and text objects have APIs for modification; see FPDFPath_*(), FPDFText_*(), and FPDFImageObj_*(). Experimental API.

func (*PdfiumImplementation) FPDFAttachment_GetFile

FPDFAttachment_GetFile gets the file data of the given attachment. Experimental API.

func (*PdfiumImplementation) FPDFAttachment_GetName

FPDFAttachment_GetName returns the name of the attachment file. Experimental API.

func (*PdfiumImplementation) FPDFAttachment_GetStringValue

FPDFAttachment_GetStringValue gets the string value corresponding to the given key in the params dictionary of the embedded file attachment. Experimental API.

func (*PdfiumImplementation) FPDFAttachment_GetValueType

FPDFAttachment_GetValueType returns the type of the value corresponding to the given key in the params dictionary of the embedded attachment. Experimental API.

func (*PdfiumImplementation) FPDFAttachment_HasKey

FPDFAttachment_HasKey check if the params dictionary of the given attachment has the given key as a key. Experimental API.

func (*PdfiumImplementation) FPDFAttachment_SetFile

FPDFAttachment_SetFile set the file data of the given attachment, overwriting the existing file data if any. The creation date and checksum will be updated, while all other dictionary entries will be deleted. Note that only contents with a length smaller than INT_MAX is supported. Experimental API.

func (*PdfiumImplementation) FPDFAttachment_SetStringValue

FPDFAttachment_SetStringValue sets the string value corresponding to the given key in the params dictionary of the embedded file attachment, overwriting the existing value if any. Experimental API.

func (*PdfiumImplementation) FPDFAvail_Create

FPDFAvail_Create creates a document availability provider. FPDFAvail_Destroy() must be called when done with the availability provider.

func (*PdfiumImplementation) FPDFAvail_Destroy

FPDFAvail_Destroy destroys the given document availability provider.

func (*PdfiumImplementation) FPDFAvail_GetDocument

FPDFAvail_GetDocument returns the document from the availability provider. When FPDFAvail_IsDocAvail() returns TRUE, call FPDFAvail_GetDocument() to retrieve the document handle.

func (*PdfiumImplementation) FPDFAvail_GetFirstPageNum

FPDFAvail_GetFirstPageNum returns the page number for the first available page in a linearized PDF. For most linearized PDFs, the first available page will be the first page, however, some PDFs might make another page the first available page. For non-linearized PDFs, this function will always return zero.

func (*PdfiumImplementation) FPDFAvail_IsDocAvail

FPDFAvail_IsDocAvail checks if the document is ready for loading, if not, gets download hints. Applications should call this function whenever new data arrives, and process all the generated download hints, if any, until the function returns enums.PDF_FILEAVAIL_DATA_ERROR or enums.PDF_FILEAVAIL_DATA_AVAIL. if hints is nil, the function just check current document availability.

Once all data is available, call FPDFAvail_GetDocument() to get a document handle.

func (*PdfiumImplementation) FPDFAvail_IsFormAvail

FPDFAvail_IsFormAvail This function can be called only after FPDFAvail_GetDocument() is called. Applications should call this function whenever new data arrives and process all the generated download hints, if any, until this function returns enums.PDF_FILEAVAIL_DATA_ERROR or enums.PDF_FILEAVAIL_DATA_AVAIL. Applications can then perform page loading. if hints is nil, the function just check current availability of specified page.

func (*PdfiumImplementation) FPDFAvail_IsLinearized

FPDFAvail_IsLinearized Check whether a document is a linearized PDF. FPDFAvail_IsLinearized() will return enums.PDF_FILEAVAIL_LINEARIZED or enums.PDF_FILEAVAIL_NOT_LINEARIZED when we have 1k of data. If the files size less than 1k, it returns enums.PDF_FILEAVAIL_LINEARIZATION_UNKNOWN as there is insufficient information to determine if the PDF is linearlized.

func (*PdfiumImplementation) FPDFAvail_IsPageAvail

FPDFAvail_IsPageAvail checks if the given page index is ready for loading, if not, it will call the hints to fetch more data.

func (*PdfiumImplementation) FPDFBitmap_Create

FPDFBitmap_Create Create a device independent bitmap (FXDIB).

func (*PdfiumImplementation) FPDFBitmap_CreateEx

FPDFBitmap_CreateEx Create a device independent bitmap (FXDIB) with an external buffer. Similar to FPDFBitmap_Create function, but allows for more formats and an external buffer is supported. The bitmap created by this function can be used in any place that a FPDF_BITMAP handle is required.

If an external buffer is used, then the caller should destroy the buffer. FPDFBitmap_Destroy() will not destroy the buffer.

It is recommended to use FPDFBitmap_GetStride() to get the stride value.

Not supported on multi-threaded usage.

func (*PdfiumImplementation) FPDFBitmap_Destroy

FPDFBitmap_Destroy destroys a bitmap and release all related buffers. This function will not destroy any external buffers provided when the bitmap was created.

func (*PdfiumImplementation) FPDFBitmap_FillRect

FPDFBitmap_FillRect fills a rectangle in a bitmap. This function sets the color and (optionally) alpha value in the specified region of the bitmap.

NOTE: If the alpha channel is used, this function does NOT composite the background with the source color, instead the background will be replaced by the source color and the alpha.

If the alpha channel is not used, the alpha parameter is ignored.

func (*PdfiumImplementation) FPDFBitmap_GetBuffer

FPDFBitmap_GetBuffer returns the data buffer of a bitmap. The stride may be more than width * number of bytes per pixel

Applications can use this function to get the bitmap buffer pointer, then manipulate any color and/or alpha values for any pixels in the bitmap.

Use FPDFBitmap_GetFormat() to find out the format of the data.

func (*PdfiumImplementation) FPDFBitmap_GetFormat

FPDFBitmap_GetFormat returns the format of the bitmap. Only formats supported by FPDFBitmap_CreateEx are supported by this function.

func (*PdfiumImplementation) FPDFBitmap_GetHeight

FPDFBitmap_GetHeight returns the height of a bitmap.

func (*PdfiumImplementation) FPDFBitmap_GetStride

FPDFBitmap_GetStride returns the number of bytes for each line in the bitmap buffer.

func (*PdfiumImplementation) FPDFBitmap_GetWidth

FPDFBitmap_GetWidth returns the width of a bitmap.

func (*PdfiumImplementation) FPDFBookmark_Find

FPDFBookmark_Find finds a bookmark in the document, using the bookmark title.

func (*PdfiumImplementation) FPDFBookmark_GetAction

FPDFBookmark_GetAction returns the action associated with a bookmark item. If this function returns a valid handle, it is valid as long as the bookmark is valid. If the returned action is nil, you should try FPDFBookmark_GetDest.

func (*PdfiumImplementation) FPDFBookmark_GetCount

FPDFBookmark_GetCount returns the number of children of a bookmark. Experimental API.

func (*PdfiumImplementation) FPDFBookmark_GetDest

FPDFBookmark_GetDest returns the destination associated with a bookmark item. If the returned destination is nil, none is associated to the bookmark item.

func (*PdfiumImplementation) FPDFBookmark_GetFirstChild

FPDFBookmark_GetFirstChild returns the first child of a bookmark item, or the first top level bookmark item. Note that another name for the bookmarks is the document outline, as described in ISO 32000-1:2008, section 12.3.3.

func (*PdfiumImplementation) FPDFBookmark_GetNextSibling

FPDFBookmark_GetNextSibling returns the next bookmark item at the same level. Note that the caller is responsible for handling circular bookmark references, as may arise from malformed documents.

func (*PdfiumImplementation) FPDFBookmark_GetTitle

FPDFBookmark_GetTitle returns the title of a bookmark.

func (*PdfiumImplementation) FPDFCatalog_IsTagged

FPDFCatalog_IsTagged determines if the given document represents a tagged PDF. For the definition of tagged PDF, See (see 10.7 "Tagged PDF" in PDF Reference 1.7). Experimental API.

func (*PdfiumImplementation) FPDFCatalog_SetLanguage added in v1.13.0

FPDFCatalog_SetLanguage sets the language of a document. Experimental API.

func (*PdfiumImplementation) FPDFClipPath_CountPathSegments

FPDFClipPath_CountPathSegments returns the number of segments inside one path of the given clip path. Experimental API.

func (*PdfiumImplementation) FPDFClipPath_CountPaths

FPDFClipPath_CountPaths returns the number of paths inside the given clip path. Experimental API.

func (*PdfiumImplementation) FPDFClipPath_GetPathSegment

FPDFClipPath_GetPathSegment returns the segment in one specific path of the given clip path at index. Experimental API.

func (*PdfiumImplementation) FPDFDOC_ExitFormFillEnvironment

FPDFDOC_ExitFormFillEnvironment takes ownership of the handle and exits form fill environment.

func (*PdfiumImplementation) FPDFDOC_InitFormFillEnvironment

FPDFDOC_InitFormFillEnvironment initializes form fill environment This function should be called before any form fill operation. Not supported on multi-threaded usage due to its bidirectional nature.

func (*PdfiumImplementation) FPDFDest_GetDestPageIndex

FPDFDest_GetDestPageIndex returns the page index from destination data.

func (*PdfiumImplementation) FPDFDest_GetLocationInPage

FPDFDest_GetLocationInPage returns the (x, y, zoom) location of dest in the destination page, if the destination is in [page /XYZ x y zoom] syntax.

func (*PdfiumImplementation) FPDFDest_GetView

FPDFDest_GetView returns the view (fit type) for a given dest. Experimental API.

func (*PdfiumImplementation) FPDFDoc_AddAttachment

FPDFDoc_AddAttachment adds an embedded file with the given name in the given document. If the name is empty, or if the name is the name of an existing embedded file in the document, or if the document's embedded file name tree is too deep (i.e. the document has too many embedded files already), then a new attachment will not be added. Experimental API.

func (*PdfiumImplementation) FPDFDoc_CloseJavaScriptAction

FPDFDoc_CloseJavaScriptAction closes a loaded FPDF_JAVASCRIPT_ACTION object. Experimental API.

func (*PdfiumImplementation) FPDFDoc_DeleteAttachment

FPDFDoc_DeleteAttachment deletes the embedded attachment at the given index in the given document. Note that this does not remove the attachment data from the PDF file; it simply removes the file's entry in the embedded files name tree so that it does not appear in the attachment list. This behavior may change in the future. Experimental API.

func (*PdfiumImplementation) FPDFDoc_GetAttachment

FPDFDoc_GetAttachment returns the embedded attachment at the given index in the given document. Note that the returned attachment handle is only valid while the document is open. Experimental API.

func (*PdfiumImplementation) FPDFDoc_GetAttachmentCount

FPDFDoc_GetAttachmentCount returns the number of embedded files in the given document. Experimental API.

func (*PdfiumImplementation) FPDFDoc_GetJavaScriptAction

FPDFDoc_GetJavaScriptAction returns the JavaScript action at the given index in the given document. Experimental API.

func (*PdfiumImplementation) FPDFDoc_GetJavaScriptActionCount

FPDFDoc_GetJavaScriptActionCount returns the number of JavaScript actions in the given document. Experimental API.

func (*PdfiumImplementation) FPDFDoc_GetPageMode

FPDFDoc_GetPageMode returns the document's page mode, which describes how the document should be displayed when opened.

func (*PdfiumImplementation) FPDFFont_Close

FPDFFont_Close closes a loaded PDF font

func (*PdfiumImplementation) FPDFFont_GetAscent

FPDFFont_GetAscent returns ascent distance of a font. Ascent is the maximum distance in points above the baseline reached by the glyphs of the font. One point is 1/72 inch (around 0.3528 mm). Experimental API.

func (*PdfiumImplementation) FPDFFont_GetBaseFontName added in v1.13.0

FPDFFont_GetBaseFontName returns the base font name of a font. Experimental API.

func (*PdfiumImplementation) FPDFFont_GetDescent

FPDFFont_GetDescent returns the descent distance of a font. Descent is the maximum distance in points below the baseline reached by the glyphs of the font. One point is 1/72 inch (around 0.3528 mm). Experimental API.

func (*PdfiumImplementation) FPDFFont_GetFamilyName added in v1.13.0

FPDFFont_GetFamilyName returns the family name of a font. Experimental API.

func (*PdfiumImplementation) FPDFFont_GetFlags

FPDFFont_GetFlags returns the descriptor flags of a font. Returns the bit flags specifying various characteristics of the font as defined in ISO 32000-1:2008, table 123. Experimental API.

func (*PdfiumImplementation) FPDFFont_GetFontData

FPDFFont_GetFontData returns the decoded data from the given font. Experimental API.

func (*PdfiumImplementation) FPDFFont_GetGlyphPath

FPDFFont_GetGlyphPath returns the glyphpath describing how to draw a font glyph. Experimental API.

func (*PdfiumImplementation) FPDFFont_GetGlyphWidth

FPDFFont_GetGlyphWidth returns the width of a glyph in a font. Glyph width is the distance from the end of the prior glyph to the next glyph. This will be the vertical distance for vertical writing. Experimental API.

func (*PdfiumImplementation) FPDFFont_GetIsEmbedded

FPDFFont_GetIsEmbedded returns whether the given font is embedded or not. Experimental API.

func (*PdfiumImplementation) FPDFFont_GetItalicAngle

FPDFFont_GetItalicAngle returns the italic angle of a font. The italic angle of a font is defined as degrees counterclockwise from vertical. For a font that slopes to the right, this will be negative. Experimental API.

func (*PdfiumImplementation) FPDFFont_GetWeight

FPDFFont_GetWeight returns the font weight of a font. Typical values are 400 (normal) and 700 (bold). Experimental API.

func (*PdfiumImplementation) FPDFFormObj_CountObjects

FPDFFormObj_CountObjects returns the number of page objects inside the given form object.

func (*PdfiumImplementation) FPDFFormObj_GetObject

FPDFFormObj_GetObject returns the page object in the given form object at the given index.

func (*PdfiumImplementation) FPDFGlyphPath_CountGlyphSegments

FPDFGlyphPath_CountGlyphSegments returns the number of segments inside the given glyphpath. Experimental API.

func (*PdfiumImplementation) FPDFGlyphPath_GetGlyphPathSegment

FPDFGlyphPath_GetGlyphPathSegment returns the segment in glyphpath at the given index. Experimental API.

func (*PdfiumImplementation) FPDFImageObj_GetBitmap

FPDFImageObj_GetBitmap returns a bitmap rasterization of the given image object. FPDFImageObj_GetBitmap() only operates on the image object and does not take the associated image mask into account. It also ignores the matrix for the image object. The returned bitmap will be owned by the caller, and FPDFBitmap_Destroy() must be called on the returned bitmap when it is no longer needed.

func (*PdfiumImplementation) FPDFImageObj_GetImageDataDecoded

FPDFImageObj_GetImageDataDecoded returns the decoded image data of the image object. The decoded data is the uncompressed image data, i.e. the raw image data after having all filters applied.

func (*PdfiumImplementation) FPDFImageObj_GetImageDataRaw

FPDFImageObj_GetImageDataRaw returns the raw image data of the image object. The raw data is the image data as stored in the PDF without applying any filters.

func (*PdfiumImplementation) FPDFImageObj_GetImageFilter

FPDFImageObj_GetImageFilter returns the filter at index of the image object's list of filters. Note that the filters need to be applied in order, i.e. the first filter should be applied first, then the second, etc.

func (*PdfiumImplementation) FPDFImageObj_GetImageFilterCount

FPDFImageObj_GetImageFilterCount returns the number of filters (i.e. decoders) of the image in image object.

func (*PdfiumImplementation) FPDFImageObj_GetImageMetadata

FPDFImageObj_GetImageMetadata returns the image metadata of the image object, including dimension, DPI, bits per pixel, and colorspace. If the image object is not an image object or if it does not have an image, then the return value will be false. Otherwise, failure to retrieve any specific parameter would result in its value being 0.

func (*PdfiumImplementation) FPDFImageObj_GetImagePixelSize added in v1.5.0

FPDFImageObj_GetImagePixelSize get the image size in pixels. Faster method to get only image size. Experimental API.

func (*PdfiumImplementation) FPDFImageObj_GetRenderedBitmap

FPDFImageObj_GetRenderedBitmap returns a bitmap rasterization of the given image object that takes the image mask and image matrix into account. To render correctly, the caller must provide the document associated with the image object. If there is a page associated with the image object the caller should provide that as well. The returned bitmap will be owned by the caller, and FPDFBitmap_Destroy() must be called on the returned bitmap when it is no longer needed. Experimental API.

func (*PdfiumImplementation) FPDFImageObj_LoadJpegFile

FPDFImageObj_LoadJpegFile loads an image from a JPEG image file and then set it into the given image object. The image object might already have an associated image, which is shared and cached by the loaded pages. In that case, we need to clear the cached image for all the loaded pages. Pass the pages and page count to this API to clear the image cache. If the image is not previously shared, nil is a valid pages value.

func (*PdfiumImplementation) FPDFImageObj_LoadJpegFileInline

FPDFImageObj_LoadJpegFileInline The image object might already have an associated image, which is shared and cached by the loaded pages. In that case, we need to clear the cached image for all the loaded pages. Pass the pages and page count to this API to clear the image cache. If the image is not previously shared, nil is a valid pages value. This function loads the JPEG image inline, so the image content is copied to the file. This allows the file access and its associated data to be deleted after this function returns.

func (*PdfiumImplementation) FPDFImageObj_SetBitmap

FPDFImageObj_SetBitmap sets the given bitmap to the given image object.

func (*PdfiumImplementation) FPDFImageObj_SetMatrix

FPDFImageObj_SetMatrix sets the transform matrix of the given image object. The matrix is composed as:

|a c e|
|b d f|

and can be used to scale, rotate, shear and translate the image object. Will be deprecated once FPDFPageObj_SetMatrix() is stable.

func (*PdfiumImplementation) FPDFJavaScriptAction_GetName

FPDFJavaScriptAction_GetName returns the name from the javascript handle. Experimental API.

func (*PdfiumImplementation) FPDFJavaScriptAction_GetScript

FPDFJavaScriptAction_GetScript returns the script from the javascript handle Experimental API.

FPDFLink_CloseWebLinks releases resources used by weblink feature.

FPDFLink_CountQuadPoints returns the count of quadrilateral points to the link.

FPDFLink_CountRects returns the count of rectangular areas for the link.

FPDFLink_CountWebLinks returns the count of detected web links.

FPDFLink_Enumerate Enumerates all the link annotations in a page.

FPDFLink_GetAction returns the action info for a link If this function returns a valid handle, it is valid as long as the link is valid.

FPDFLink_GetAnnot returns a FPDF_ANNOTATION object for a link. Experimental API.

FPDFLink_GetAnnotRect returns the count of quadrilateral points to the link.

FPDFLink_GetDest returns the destination info for a link.

FPDFLink_GetLinkAtPoint finds a link at a point on a page. You can convert coordinates from screen coordinates to page coordinates using FPDF_DeviceToPage().

FPDFLink_GetLinkZOrderAtPoint finds the Z-order of link at a point on a page. You can convert coordinates from screen coordinates to page coordinates using FPDF_DeviceToPage().

FPDFLink_GetQuadPoints returns the quadrilateral points for the specified quad index in the link.

FPDFLink_GetRect returns the boundaries of a rectangle for a link.

FPDFLink_GetTextRange returns the start char index and char count for a link. Experimental API.

FPDFLink_GetURL returns the URL information for a detected web link.

FPDFLink_LoadWebLinks prepares information about weblinks in a page. Weblinks are those links implicitly embedded in PDF pages. PDF also has a type of annotation called "link" (FPDFTEXT doesn't deal with that kind of link). FPDFTEXT weblink feature is useful for automatically detecting links in the page contents. For example, things like "https://www.example.com" will be detected, so applications can allow user to click on those characters to activate the link, even the PDF doesn't come with link annotations.

FPDFLink_CloseWebLinks must be called to release resources.

func (*PdfiumImplementation) FPDFPageObjMark_CountParams

FPDFPageObjMark_CountParams returns the number of key/value pair parameters in the given mark. Experimental API.

func (*PdfiumImplementation) FPDFPageObjMark_GetName

FPDFPageObjMark_GetName returns the name of a content mark. Experimental API.

func (*PdfiumImplementation) FPDFPageObjMark_GetParamBlobValue

FPDFPageObjMark_GetParamBlobValue returns the value of a blob property in a content mark by key. Experimental API.

func (*PdfiumImplementation) FPDFPageObjMark_GetParamIntValue

FPDFPageObjMark_GetParamIntValue returns the value of a number property in a content mark by key as int. FPDFPageObjMark_GetParamValueType() should have returned FPDF_OBJECT_NUMBER for this property. Experimental API.

func (*PdfiumImplementation) FPDFPageObjMark_GetParamKey

FPDFPageObjMark_GetParamKey returns the key of a property in a content mark. Experimental API.

func (*PdfiumImplementation) FPDFPageObjMark_GetParamStringValue

FPDFPageObjMark_GetParamStringValue returns the value of a string property in a content mark by key. Experimental API.

func (*PdfiumImplementation) FPDFPageObjMark_GetParamValueType

FPDFPageObjMark_GetParamValueType returns the type of the value of a property in a content mark by key. Experimental API.

func (*PdfiumImplementation) FPDFPageObjMark_RemoveParam

FPDFPageObjMark_RemoveParam removes a property from a content mark by key. Experimental API.

func (*PdfiumImplementation) FPDFPageObjMark_SetBlobParam

FPDFPageObjMark_SetBlobParam sets the value of a blob property in a content mark by key. If a parameter with the given key exists, its value is set to the given value. Otherwise, it is added as a new parameter. Experimental API.

func (*PdfiumImplementation) FPDFPageObjMark_SetIntParam

FPDFPageObjMark_SetIntParam sets the value of an int property in a content mark by key. If a parameter with the given key exists, its value is set to the given value. Otherwise, it is added as a new parameter. Experimental API.

func (*PdfiumImplementation) FPDFPageObjMark_SetStringParam

FPDFPageObjMark_SetStringParam sets the value of a string property in a content mark by key. If a parameter with the given key exists, its value is set to the given value. Otherwise, it is added as a new parameter. Experimental API.

func (*PdfiumImplementation) FPDFPageObj_AddMark

FPDFPageObj_AddMark adds a new content mark to the given page object. Experimental API.

func (*PdfiumImplementation) FPDFPageObj_CountMarks

FPDFPageObj_CountMarks returns the count of content marks in a page object. Experimental API.

func (*PdfiumImplementation) FPDFPageObj_CreateNewPath

FPDFPageObj_CreateNewPath creates a new path object at an initial position.

func (*PdfiumImplementation) FPDFPageObj_CreateNewRect

FPDFPageObj_CreateNewRect creates a closed path consisting of a rectangle.

func (*PdfiumImplementation) FPDFPageObj_CreateTextObj

FPDFPageObj_CreateTextObj creates a new text object using a loaded font.

func (*PdfiumImplementation) FPDFPageObj_Destroy

FPDFPageObj_Destroy destroys the page object by releasing its resources. The page object must have been created by FPDFPageObj_CreateNew{Path|Rect}() or FPDFPageObj_New{Text|Image}Obj(). This function must be called on newly-created objects if they are not added to a page through FPDFPage_InsertObject() or to an annotation through FPDFAnnot_AppendObject().

func (*PdfiumImplementation) FPDFPageObj_GetBounds

FPDFPageObj_GetBounds returns the bounding box of the given page object.

func (*PdfiumImplementation) FPDFPageObj_GetClipPath

FPDFPageObj_GetClipPath Get the clip path of the page object. Experimental API.

func (*PdfiumImplementation) FPDFPageObj_GetDashArray

FPDFPageObj_GetDashArray returns the line dash array of the page object. Experimental API.

func (*PdfiumImplementation) FPDFPageObj_GetDashCount

FPDFPageObj_GetDashCount returns the line dash array size of the page object. Experimental API.

func (*PdfiumImplementation) FPDFPageObj_GetDashPhase

FPDFPageObj_GetDashPhase returns the line dash phase of the page object. Experimental API.

func (*PdfiumImplementation) FPDFPageObj_GetFillColor

FPDFPageObj_GetFillColor returns the fill RGBA of a page object

func (*PdfiumImplementation) FPDFPageObj_GetLineCap

FPDFPageObj_GetLineCap returns the line cap of the page object.

func (*PdfiumImplementation) FPDFPageObj_GetLineJoin

FPDFPageObj_GetLineJoin returns the line join of the page object.

func (*PdfiumImplementation) FPDFPageObj_GetMark

FPDFPageObj_GetMark returns the content mark of a page object at the given index. Experimental API.

func (*PdfiumImplementation) FPDFPageObj_GetMarkedContentID added in v1.13.0

FPDFPageObj_GetMarkedContentID returns the marked content ID of a page object. Experimental API.

func (*PdfiumImplementation) FPDFPageObj_GetMatrix

FPDFPageObj_GetMatrix returns the transform matrix of a page object. The matrix is composed as:

|a c e|
|b d f|

and can be used to scale, rotate, shear and translate the page object. Experimental API.

func (*PdfiumImplementation) FPDFPageObj_GetRotatedBounds

FPDFPageObj_GetRotatedBounds Get the quad points that bounds the page object. Similar to FPDFPageObj_GetBounds(), this returns the bounds of a page object. When the object is rotated by a non-multiple of 90 degrees, this API returns a tighter bound that cannot be represented with just the 4 sides of a rectangle.

Currently only works the following page object types: FPDF_PAGEOBJ_TEXT and FPDF_PAGEOBJ_IMAGE. Experimental API.

func (*PdfiumImplementation) FPDFPageObj_GetStrokeColor

FPDFPageObj_GetStrokeColor returns the stroke RGBA of a page object

func (*PdfiumImplementation) FPDFPageObj_GetStrokeWidth

FPDFPageObj_GetStrokeWidth returns the stroke width of a page object.

func (*PdfiumImplementation) FPDFPageObj_GetType

FPDFPageObj_GetType returns the type of the given page object.

func (*PdfiumImplementation) FPDFPageObj_HasTransparency

FPDFPageObj_HasTransparency returns whether the given page object contains transparency.

func (*PdfiumImplementation) FPDFPageObj_NewImageObj

FPDFPageObj_NewImageObj creates a new image object.

func (*PdfiumImplementation) FPDFPageObj_NewTextObj

FPDFPageObj_NewTextObj creates a new text object using one of the standard PDF fonts.

func (*PdfiumImplementation) FPDFPageObj_RemoveMark

FPDFPageObj_RemoveMark removes the given content mark from the given page object. Experimental API.

func (*PdfiumImplementation) FPDFPageObj_SetBlendMode

FPDFPageObj_SetBlendMode sets the blend mode of the page object.

func (*PdfiumImplementation) FPDFPageObj_SetDashArray

FPDFPageObj_SetDashArray sets the line dash array of the page object. Experimental API.

func (*PdfiumImplementation) FPDFPageObj_SetDashPhase

FPDFPageObj_SetDashPhase sets the line dash phase of the page object. Experimental API.

func (*PdfiumImplementation) FPDFPageObj_SetFillColor

FPDFPageObj_SetFillColor sets the fill RGBA of a page object

func (*PdfiumImplementation) FPDFPageObj_SetLineCap

FPDFPageObj_SetLineCap sets the line cap of the page object.

func (*PdfiumImplementation) FPDFPageObj_SetLineJoin

FPDFPageObj_SetLineJoin sets the line join of the page object.

func (*PdfiumImplementation) FPDFPageObj_SetMatrix

FPDFPageObj_SetMatrix sets the transform matrix on a page object. The matrix is composed as:

|a c e|
|b d f|

and can be used to scale, rotate, shear and translate the page object. Experimental API.

func (*PdfiumImplementation) FPDFPageObj_SetStrokeColor

FPDFPageObj_SetStrokeColor sets the stroke RGBA of a page object.

func (*PdfiumImplementation) FPDFPageObj_SetStrokeWidth

FPDFPageObj_SetStrokeWidth sets the stroke width of a page object

func (*PdfiumImplementation) FPDFPageObj_Transform

FPDFPageObj_Transform transforms the page object by the given matrix. The matrix is composed as:

|a c e|
|b d f|

and can be used to scale, rotate, shear and translate the page object.

func (*PdfiumImplementation) FPDFPageObj_TransformClipPath

FPDFPageObj_TransformClipPath transform (scale, rotate, shear, move) the clip path of page object.

func (*PdfiumImplementation) FPDFPageObj_TransformF added in v1.13.0

FPDFPageObj_TransformF transforms the page object by the given matrix. The matrix is composed as:

|a c e|
|b d f|

and can be used to scale, rotate, shear and translate the page object. Experimental API.

func (*PdfiumImplementation) FPDFPage_CloseAnnot

FPDFPage_CloseAnnot closes an annotation. Must be called when the annotation returned by FPDFPage_CreateAnnot() or FPDFPage_GetAnnot() is no longer needed. This function does not remove the annotation from the document. Experimental API.

func (*PdfiumImplementation) FPDFPage_CountObjects

FPDFPage_CountObjects returns the number of page objects inside the given page.

func (*PdfiumImplementation) FPDFPage_CreateAnnot

FPDFPage_CreateAnnot creates an annotation in the given page of the given subtype. If the specified subtype is illegal or unsupported, then a new annotation will not be created. Must call FPDFPage_CloseAnnot() when the annotation returned by this function is no longer needed. Experimental API.

func (*PdfiumImplementation) FPDFPage_Delete

FPDFPage_Delete deletes the page at the given index.

func (*PdfiumImplementation) FPDFPage_Flatten

FPDFPage_Flatten makes annotations and form fields become part of the page contents itself.

func (*PdfiumImplementation) FPDFPage_FormFieldZOrderAtPoint

FPDFPage_FormFieldZOrderAtPoint returns the form field z-order by point.

func (*PdfiumImplementation) FPDFPage_GenerateContent

FPDFPage_GenerateContent generates the contents of the page.

func (*PdfiumImplementation) FPDFPage_GetAnnot

FPDFPage_GetAnnot returns annotation at the given page and index. Must call FPDFPage_CloseAnnot() when the annotation returned by this function is no longer needed. Experimental API.

func (*PdfiumImplementation) FPDFPage_GetAnnotCount

FPDFPage_GetAnnotCount returns the number of annotations in a given page. Experimental API.

func (*PdfiumImplementation) FPDFPage_GetAnnotIndex

FPDFPage_GetAnnotIndex returns the index of the given annotation in the given page. This is the opposite of FPDFPage_GetAnnot(). Experimental API.

func (*PdfiumImplementation) FPDFPage_GetArtBox

FPDFPage_GetArtBox gets the "ArtBox" entry from the page dictionary.

func (*PdfiumImplementation) FPDFPage_GetBleedBox

FPDFPage_GetBleedBox gets the "BleedBox" entry from the page dictionary.

func (*PdfiumImplementation) FPDFPage_GetCropBox

FPDFPage_GetCropBox gets the "CropBox" entry from the page dictionary.

func (*PdfiumImplementation) FPDFPage_GetDecodedThumbnailData

FPDFPage_GetDecodedThumbnailData returns the decoded data from the thumbnail of the given page if it exists. Experimental API.

func (*PdfiumImplementation) FPDFPage_GetMediaBox

FPDFPage_GetMediaBox gets the "MediaBox" entry from the page dictionary

func (*PdfiumImplementation) FPDFPage_GetObject

FPDFPage_GetObject returns the object at the given index.

func (*PdfiumImplementation) FPDFPage_GetRawThumbnailData

FPDFPage_GetRawThumbnailData returns the raw data from the thumbnail of the given page if it exists. Experimental API.

func (*PdfiumImplementation) FPDFPage_GetRotation

FPDFPage_GetRotation returns the page rotation.

func (*PdfiumImplementation) FPDFPage_GetThumbnailAsBitmap

FPDFPage_GetThumbnailAsBitmap returns the thumbnail of the given page as a FPDF_BITMAP. Experimental API.

func (*PdfiumImplementation) FPDFPage_GetTrimBox

FPDFPage_GetTrimBox gets the "TrimBox" entry from the page dictionary.

func (*PdfiumImplementation) FPDFPage_HasFormFieldAtPoint

FPDFPage_HasFormFieldAtPoint returns the form field type by point.

func (*PdfiumImplementation) FPDFPage_HasTransparency

FPDFPage_HasTransparency returns whether the page has transparency.

func (*PdfiumImplementation) FPDFPage_InsertClipPath

FPDFPage_InsertClipPath Clip the page content, the page content that outside the clipping region become invisible.

func (*PdfiumImplementation) FPDFPage_InsertObject

FPDFPage_InsertObject inserts the given object into a page.

func (*PdfiumImplementation) FPDFPage_New

func (p *PdfiumImplementation) FPDFPage_New(request *requests.FPDFPage_New) (*responses.FPDFPage_New, error)

FPDFPage_New creates a new PDF page. The page should be closed with FPDF_ClosePage() when finished as with any other page in the document.

func (*PdfiumImplementation) FPDFPage_RemoveAnnot

FPDFPage_RemoveAnnot removes the annotation in the given page at the given index. Experimental API.

func (*PdfiumImplementation) FPDFPage_RemoveObject

FPDFPage_RemoveObject removes an object from a page. Ownership is transferred to the caller. Call FPDFPageObj_Destroy() to free it. Experimental API.

func (*PdfiumImplementation) FPDFPage_SetArtBox

FPDFPage_SetArtBox sets the "ArtBox" entry to the page dictionary.

func (*PdfiumImplementation) FPDFPage_SetBleedBox

FPDFPage_SetBleedBox sets the "BleedBox" entry to the page dictionary.

func (*PdfiumImplementation) FPDFPage_SetCropBox

FPDFPage_SetCropBox sets the "CropBox" entry to the page dictionary.

func (*PdfiumImplementation) FPDFPage_SetMediaBox

FPDFPage_SetMediaBox sets the "MediaBox" entry to the page dictionary.

func (*PdfiumImplementation) FPDFPage_SetRotation

FPDFPage_SetRotation sets the page rotation for a given page.

func (*PdfiumImplementation) FPDFPage_SetTrimBox

FPDFPage_SetTrimBox sets the "TrimBox" entry to the page dictionary.

func (*PdfiumImplementation) FPDFPage_TransFormWithClip

FPDFPage_TransFormWithClip applies the transforms to the page.

func (*PdfiumImplementation) FPDFPage_TransformAnnots

FPDFPage_TransformAnnots transforms all annotations in the given page. The matrix is composed as:

|a c e|
|b d f|

and can be used to scale, rotate, shear and translate the page annotations.

func (*PdfiumImplementation) FPDFPathSegment_GetClose

FPDFPathSegment_GetClose returns whether the segment closes the current subpath of a given path.

func (*PdfiumImplementation) FPDFPathSegment_GetPoint

FPDFPathSegment_GetPoint returns the coordinates of the given segment.

func (*PdfiumImplementation) FPDFPathSegment_GetType

FPDFPathSegment_GetType returns the type of the given segment.

func (*PdfiumImplementation) FPDFPath_BezierTo

FPDFPath_BezierTo adds a cubic Bezier curve to the given path, starting at the current point.

func (*PdfiumImplementation) FPDFPath_Close

FPDFPath_Close closes the current subpath of a given path.

func (*PdfiumImplementation) FPDFPath_CountSegments

FPDFPath_CountSegments returns the number of segments inside the given path. A segment is a command, created by e.g. FPDFPath_MoveTo(), FPDFPath_LineTo() or FPDFPath_BezierTo().

func (*PdfiumImplementation) FPDFPath_GetDrawMode

FPDFPath_GetDrawMode returns the drawing mode of a path.

func (*PdfiumImplementation) FPDFPath_GetPathSegment

FPDFPath_GetPathSegment returns the segment in the given path at the given index.

func (*PdfiumImplementation) FPDFPath_LineTo

FPDFPath_LineTo adds a line between the current point and a new point in the path.

func (*PdfiumImplementation) FPDFPath_MoveTo

FPDFPath_MoveTo moves a path's current point. Note that no line will be created between the previous current point and the new one.

func (*PdfiumImplementation) FPDFPath_SetDrawMode

FPDFPath_SetDrawMode sets the drawing mode of a path.

func (*PdfiumImplementation) FPDFSignatureObj_GetByteRange

FPDFSignatureObj_GetByteRange returns the byte range of a signature object. Experimental API.

func (*PdfiumImplementation) FPDFSignatureObj_GetContents

FPDFSignatureObj_GetContents returns the contents of a signature object. Experimental API.

func (*PdfiumImplementation) FPDFSignatureObj_GetDocMDPPermission

FPDFSignatureObj_GetDocMDPPermission returns the DocMDP permission of a signature object. Experimental API.

func (*PdfiumImplementation) FPDFSignatureObj_GetReason

FPDFSignatureObj_GetReason returns the reason (comment) of the signature object. Experimental API.

func (*PdfiumImplementation) FPDFSignatureObj_GetSubFilter

FPDFSignatureObj_GetSubFilter returns the encoding of the value of a signature object. Experimental API.

func (*PdfiumImplementation) FPDFSignatureObj_GetTime

FPDFSignatureObj_GetTime returns the time of signing of a signature object. Experimental API.

func (*PdfiumImplementation) FPDFTextObj_GetFont

FPDFTextObj_GetFont returns the font of a text object. Experimental API.

func (*PdfiumImplementation) FPDFTextObj_GetFontSize

FPDFTextObj_GetFontSize returns the font size of a text object.

func (*PdfiumImplementation) FPDFTextObj_GetRenderedBitmap

FPDFTextObj_GetRenderedBitmap returns a bitmap rasterization of the given text object. To render correctly, the caller must provide the document associated with the text object. If there is a page associated with text object, the caller should provide that as well. The returned bitmap will be owned by the caller, and FPDFBitmap_Destroy() must be called on the returned bitmap when it is no longer needed. Experimental API.

func (*PdfiumImplementation) FPDFTextObj_GetText

FPDFTextObj_GetText returns the text of a text object.

func (*PdfiumImplementation) FPDFTextObj_GetTextRenderMode

FPDFTextObj_GetTextRenderMode returns the text rendering mode of a text object.

func (*PdfiumImplementation) FPDFTextObj_SetTextRenderMode

FPDFTextObj_SetTextRenderMode sets the text rendering mode of a text object. Experimental API.

func (*PdfiumImplementation) FPDFText_ClosePage

FPDFText_ClosePage Release all resources allocated for a text page information structure.

func (*PdfiumImplementation) FPDFText_CountChars

FPDFText_CountChars returns the number of characters in a page. Characters in a page form a "stream", inside the stream, each character has an index. We will use the index parameters in many of FPDFTEXT functions. The first character in the page has an index value of zero.

func (*PdfiumImplementation) FPDFText_CountRects

FPDFText_CountRects returns the count of rectangular areas occupied by a segment of text, and caches the result for subsequent FPDFText_GetRect() calls. This function, along with FPDFText_GetRect can be used by applications to detect the position on the page for a text segment, so proper areas can be highlighted. The FPDFText_* functions will automatically merge small character boxes into bigger one if those characters are on the same line and use same font settings.

func (*PdfiumImplementation) FPDFText_FindClose

FPDFText_FindClose releases a search context.

func (*PdfiumImplementation) FPDFText_FindNext

FPDFText_FindNext searches in the direction from page start to end.

func (*PdfiumImplementation) FPDFText_FindPrev

FPDFText_FindPrev searches in the direction from page end to start.

func (*PdfiumImplementation) FPDFText_FindStart

FPDFText_FindStart returns a handle to search a page.

func (*PdfiumImplementation) FPDFText_GetBoundedText

FPDFText_GetBoundedText extract unicode text within a rectangular boundary on the page.

func (*PdfiumImplementation) FPDFText_GetCharAngle

FPDFText_GetCharAngle returns the character rotation angle. Experimental API.

func (*PdfiumImplementation) FPDFText_GetCharBox

FPDFText_GetCharBox returns the bounding box of a particular character. All positions are measured in PDF "user space".

func (*PdfiumImplementation) FPDFText_GetCharIndexAtPos

FPDFText_GetCharIndexAtPos returns the index of a character at or nearby a certain position on the page.

func (*PdfiumImplementation) FPDFText_GetCharIndexFromTextIndex

FPDFText_GetCharIndexFromTextIndex returns the character index in the text page internal character list. Where the character index is an index of the text returned from FPDFText_GetText().

func (*PdfiumImplementation) FPDFText_GetCharOrigin

FPDFText_GetCharOrigin returns origin of a particular character. All positions are measured in PDF "user space".

func (*PdfiumImplementation) FPDFText_GetFillColor

FPDFText_GetFillColor returns the fill color of a particular character. Experimental API.

func (*PdfiumImplementation) FPDFText_GetFontInfo

FPDFText_GetFontInfo returns the font name and flags of a particular character. Experimental API.

func (*PdfiumImplementation) FPDFText_GetFontSize

FPDFText_GetFontSize returns the font size of a particular character.

func (*PdfiumImplementation) FPDFText_GetFontWeight

FPDFText_GetFontWeight returns the font weight of a particular character. Experimental API.

func (*PdfiumImplementation) FPDFText_GetLooseCharBox

FPDFText_GetLooseCharBox returns a "loose" bounding box of a particular character, i.e., covering the entire glyph bounds, without taking the actual glyph shape into account. All positions are measured in PDF "user space". Experimental API.

func (*PdfiumImplementation) FPDFText_GetMatrix

FPDFText_GetMatrix returns the effective transformation matrix for a particular character. All positions are measured in PDF "user space". Experimental API.

func (*PdfiumImplementation) FPDFText_GetRect

FPDFText_GetRect returns a rectangular area from the result generated by FPDFText_CountRects Note: this method only works if you called FPDFText_CountRects first.

func (*PdfiumImplementation) FPDFText_GetSchCount

FPDFText_GetSchCount returns the number of matched characters in the search result.

func (*PdfiumImplementation) FPDFText_GetSchResultIndex

FPDFText_GetSchResultIndex returns the starting character index of the search result.

func (*PdfiumImplementation) FPDFText_GetStrokeColor

FPDFText_GetStrokeColor returns the stroke color of a particular character. Experimental API.

func (*PdfiumImplementation) FPDFText_GetText

FPDFText_GetText extracts unicode text string from the page. This function ignores characters without unicode information. It returns all characters on the page, even those that are not visible when the page has a cropbox. To filter out the characters outside of the cropbox, use FPDF_GetPageBoundingBox() and FPDFText_GetCharBox().

func (*PdfiumImplementation) FPDFText_GetTextIndexFromCharIndex

FPDFText_GetTextIndexFromCharIndex returns the text index in the text page internal character list. Where the text index is an index of the character in the internal character list.

func (*PdfiumImplementation) FPDFText_GetTextObject added in v1.13.0

FPDFText_GetTextObject returns the FPDF_PAGEOBJECT associated with a given character. Experimental API.

func (*PdfiumImplementation) FPDFText_GetUnicode

FPDFText_GetUnicode returns the unicode of a character in a page.

func (*PdfiumImplementation) FPDFText_HasUnicodeMapError

FPDFText_HasUnicodeMapError a character in a page has an invalid unicode mapping. Experimental API.

func (*PdfiumImplementation) FPDFText_IsGenerated

FPDFText_IsGenerated returns whether a character in a page is generated by PDFium. Experimental API.

func (*PdfiumImplementation) FPDFText_IsHyphen added in v1.8.0

FPDFText_IsHyphen returns whether a character in a page is a hyphen. Experimental API.

func (*PdfiumImplementation) FPDFText_LoadCidType2Font added in v1.11.0

FPDFText_LoadCidType2Font returns a font object loaded from a stream of data for a type 2 CID font. The font is loaded into the document. Unlike FPDFText_LoadFont(), the ToUnicode data and the CIDToGIDMap data are caller provided, instead of auto-generated. The loaded font can be closed using FPDFFont_Close(). Experimental API.

func (*PdfiumImplementation) FPDFText_LoadFont

FPDFText_LoadFont returns a font object loaded from a stream of data. The font is loaded into the document. Various font data structures, such as the ToUnicode data, are auto-generated based on the inputs. The loaded font can be closed using FPDFFont_Close().

func (*PdfiumImplementation) FPDFText_LoadPage

FPDFText_LoadPage returns a handle to the text page information structure. Application must call FPDFText_ClosePage to release the text page

func (*PdfiumImplementation) FPDFText_LoadStandardFont

FPDFText_LoadStandardFont loads one of the standard 14 fonts per PDF spec 1.7 page 416. The preferred way of using font style is using a dash to separate the name from the style, for example 'Helvetica-BoldItalic'. The loaded font can be closed using FPDFFont_Close. Experimental API.

func (*PdfiumImplementation) FPDFText_SetCharcodes

FPDFText_SetCharcodes sets the text using charcodes for a text object. If it had text, it will be replaced.

func (*PdfiumImplementation) FPDFText_SetText

FPDFText_SetText sets the text for a text object. If it had text, it will be replaced.

func (*PdfiumImplementation) FPDF_CloseDocument

FPDF_CloseDocument closes the references, releases the resources.

func (*PdfiumImplementation) FPDF_ClosePage

FPDF_ClosePage unloads a page by reference.

func (*PdfiumImplementation) FPDF_CloseXObject

FPDF_CloseXObject closes an FPDF_XOBJECT handle created by FPDF_NewXObjectFromPage(). Experimental API.

func (*PdfiumImplementation) FPDF_CopyViewerPreferences

FPDF_CopyViewerPreferences copies the viewer preferences from one PDF document to another

func (*PdfiumImplementation) FPDF_CountNamedDests

FPDF_CountNamedDests returns the count of named destinations in the PDF document.

func (*PdfiumImplementation) FPDF_CreateClipPath

FPDF_CreateClipPath creates a new clip path, with a rectangle inserted.

func (*PdfiumImplementation) FPDF_CreateNewDocument

FPDF_CreateNewDocument returns a new document.

func (*PdfiumImplementation) FPDF_DestroyClipPath

FPDF_DestroyClipPath destroys the clip path.

func (*PdfiumImplementation) FPDF_DeviceToPage

FPDF_DeviceToPage converts the screen coordinates of a point to page coordinates. The page coordinate system has its origin at the left-bottom corner of the page, with the X-axis on the bottom going to the right, and the Y-axis on the left side going up.

NOTE: this coordinate system can be altered when you zoom, scroll, or rotate a page, however, a point on the page should always have the same coordinate values in the page coordinate system.

The device coordinate system is device dependent. For screen device, its origin is at the left-top corner of the window. However this origin can be altered by the Windows coordinate transformation utilities.

You must make sure the start_x, start_y, size_x, size_y and rotate parameters have exactly same values as you used in the FPDF_RenderPage() function call.

func (*PdfiumImplementation) FPDF_DocumentHasValidCrossReferenceTable

FPDF_DocumentHasValidCrossReferenceTable returns whether the document's cross reference table is valid or not. Experimental API.

func (*PdfiumImplementation) FPDF_FFLDraw

func (p *PdfiumImplementation) FPDF_FFLDraw(request *requests.FPDF_FFLDraw) (*responses.FPDF_FFLDraw, error)

FPDF_FFLDraw renders FormFields and popup window on a page to a device independent bitmap. This function is designed to render annotations that are user-interactive, which are widget annotations (for FormFields) and popup annotations. With the FPDF_ANNOT flag, this function will render a popup annotation when users mouse-hover on a non-widget annotation. Regardless of FPDF_ANNOT flag, this function will always render widget annotations for FormFields. In order to implement the FormFill functions, implementation should call this function after rendering functions, such as FPDF_RenderPageBitmap() or FPDF_RenderPageBitmap_Start(), have finished rendering the page contents.

func (*PdfiumImplementation) FPDF_GetDocPermissions

FPDF_GetDocPermissions returns the permissions of the PDF.

func (*PdfiumImplementation) FPDF_GetDocUserPermissions added in v1.9.0

FPDF_GetDocUserPermissions returns the user permissions of the PDF. Experimental API.

func (*PdfiumImplementation) FPDF_GetFileIdentifier

FPDF_GetFileIdentifier Get the file identifier defined in the trailer of a document. Experimental API.

func (*PdfiumImplementation) FPDF_GetFileVersion

FPDF_GetFileVersion returns the version of the PDF file.

func (*PdfiumImplementation) FPDF_GetFormType

FPDF_GetFormType returns the type of form contained in the PDF document. If document is nil, then the return value is FORMTYPE_NONE. Experimental API

func (*PdfiumImplementation) FPDF_GetLastError

FPDF_GetLastError returns the last error code of a PDFium function, which is just called. Usually, this function is called after a PDFium function returns, in order to check the error code of the previous PDFium function. If the previous SDK call succeeded, the return value of this function is not defined. This function only works in conjunction with APIs that mention FPDF_GetLastError() in their documentation. Please note that when using go-pdfium from the same instance (on single-threaded any instance) from different subroutines, FPDF_GetLastError might already be reset from executing another PDFium method.

func (*PdfiumImplementation) FPDF_GetMetaText

FPDF_GetMetaText returns the requested metadata.

func (*PdfiumImplementation) FPDF_GetNamedDest

FPDF_GetNamedDest returns the named destination by index.

func (*PdfiumImplementation) FPDF_GetNamedDestByName

FPDF_GetNamedDestByName returns the destination handle for the given name.

func (*PdfiumImplementation) FPDF_GetPageAAction

FPDF_GetPageAAction returns an additional-action from page. If this function returns a valid handle, it is valid as long as the page is valid. Experimental API

func (*PdfiumImplementation) FPDF_GetPageBoundingBox

FPDF_GetPageBoundingBox returns the bounding box of the page. This is the intersection between its media box and its crop box. Experimental API.

func (*PdfiumImplementation) FPDF_GetPageCount

FPDF_GetPageCount counts the amount of pages.

func (*PdfiumImplementation) FPDF_GetPageHeight

FPDF_GetPageHeight returns the height of a page.

func (*PdfiumImplementation) FPDF_GetPageHeightF

FPDF_GetPageHeightF returns the page height in float32. Experimental API.

func (*PdfiumImplementation) FPDF_GetPageLabel

FPDF_GetPageLabel returns the label for the given page.

func (*PdfiumImplementation) FPDF_GetPageSizeByIndex

FPDF_GetPageSizeByIndex returns the size of a page by the page index.

func (*PdfiumImplementation) FPDF_GetPageSizeByIndexF

FPDF_GetPageSizeByIndexF returns the size of the page at the given index. Prefer FPDF_GetPageSizeByIndexF(). This will be deprecated in the future. Experimental API.

func (*PdfiumImplementation) FPDF_GetPageWidth

FPDF_GetPageWidth returns the width of a page.

func (*PdfiumImplementation) FPDF_GetPageWidthF

FPDF_GetPageWidthF returns the page width in float32. Experimental API.

func (*PdfiumImplementation) FPDF_GetSecurityHandlerRevision

FPDF_GetSecurityHandlerRevision returns the revision number of security handlers of the file.

func (*PdfiumImplementation) FPDF_GetSignatureCount

FPDF_GetSignatureCount returns the total number of signatures in the document. Experimental API.

func (*PdfiumImplementation) FPDF_GetSignatureObject

FPDF_GetSignatureObject returns the Nth signature of the document. Experimental API.

func (*PdfiumImplementation) FPDF_GetTrailerEnds

FPDF_GetTrailerEnds returns the byte offsets of trailer ends. Experimental API.

func (*PdfiumImplementation) FPDF_GetXFAPacketContent

FPDF_GetXFAPacketContent returns the content of a packet in the XFA array. Experimental API.

func (*PdfiumImplementation) FPDF_GetXFAPacketCount

FPDF_GetXFAPacketCount returns the number of valid packets in the XFA entry. Experimental API.

func (*PdfiumImplementation) FPDF_GetXFAPacketName

FPDF_GetXFAPacketName returns the name of a packet in the XFA array. Experimental API.

func (*PdfiumImplementation) FPDF_ImportNPagesToOne

FPDF_ImportNPagesToOne creates a new document from source document. The pages of source document will be combined to provide NumPagesOnXAxis x NumPagesOnYAxis pages per page of the output document. Experimental API.

func (*PdfiumImplementation) FPDF_ImportPages

FPDF_ImportPages imports some pages from one PDF document to another one.

func (*PdfiumImplementation) FPDF_ImportPagesByIndex

FPDF_ImportPagesByIndex imports pages to a FPDF_DOCUMENT. Experimental API.

func (*PdfiumImplementation) FPDF_LoadCustomDocument

FPDF_LoadCustomDocument loads a PDF document from a custom access descriptor. This is implemented as an io.ReadSeeker in go-pdfium. This is only really efficient for single threaded usage, the multi-threaded usage will just load the file in memory because it can't transfer readers over gRPC. The single-threaded usage will actually efficiently walk over the PDF as it's being used by PDFium. Loaded document can be closed by FPDF_CloseDocument(). If this function fails, you can use FPDF_GetLastError() to retrieve the reason why it failed.

func (*PdfiumImplementation) FPDF_LoadDocument

FPDF_LoadDocument opens and load a PDF document from a file path. Loaded document can be closed by FPDF_CloseDocument(). If this function fails, you can use FPDF_GetLastError() to retrieve the reason why it failed.

func (*PdfiumImplementation) FPDF_LoadMemDocument

FPDF_LoadMemDocument opens and load a PDF document from memory. Loaded document can be closed by FPDF_CloseDocument(). If this function fails, you can use FPDF_GetLastError() to retrieve the reason why it failed.

func (*PdfiumImplementation) FPDF_LoadMemDocument64

FPDF_LoadMemDocument64 opens and load a PDF document from memory. Loaded document can be closed by FPDF_CloseDocument(). If this function fails, you can use FPDF_GetLastError() to retrieve the reason why it failed. Experimental API.

func (*PdfiumImplementation) FPDF_LoadPage

FPDF_LoadPage loads a page and returns a reference.

func (*PdfiumImplementation) FPDF_LoadXFA

func (p *PdfiumImplementation) FPDF_LoadXFA(request *requests.FPDF_LoadXFA) (*responses.FPDF_LoadXFA, error)

FPDF_LoadXFA load XFA fields of the document if it consists of XFA fields.

func (*PdfiumImplementation) FPDF_MovePages added in v1.9.0

FPDF_MovePages Move the given pages to a new index position. When this call fails, the document may be left in an indeterminate state. Experimental API.

func (*PdfiumImplementation) FPDF_NewFormObjectFromXObject

FPDF_NewFormObjectFromXObject creates a new form object from an FPDF_XOBJECT object. Experimental API.

func (*PdfiumImplementation) FPDF_NewXObjectFromPage

FPDF_NewXObjectFromPage creates a template to generate form xobjects from the source document's page at the given index, for use in the destination document. Experimental API.

func (*PdfiumImplementation) FPDF_PageToDevice

FPDF_PageToDevice converts the page coordinates of a point to screen coordinates. See comments for FPDF_DeviceToPage().

func (*PdfiumImplementation) FPDF_RemoveFormFieldHighlight

FPDF_RemoveFormFieldHighlight removes the form field highlight color in the document.

func (*PdfiumImplementation) FPDF_RenderPage

FPDF_RenderPage renders contents of a page to a device (screen, bitmap, or printer). This feature does not work on multi-threaded usage as you will need to give a device handle. Windows only!

func (*PdfiumImplementation) FPDF_RenderPageBitmap

FPDF_RenderPageBitmap renders contents of a page to a device independent bitmap.

func (*PdfiumImplementation) FPDF_RenderPageBitmapWithColorScheme_Start

FPDF_RenderPageBitmapWithColorScheme_Start starts to render page contents to a device independent bitmap progressively with a specified color scheme for the content. Not supported on multi-threaded usage. Experimental API.

func (*PdfiumImplementation) FPDF_RenderPageBitmapWithMatrix

FPDF_RenderPageBitmapWithMatrix renders contents of a page to a device independent bitmap.

func (*PdfiumImplementation) FPDF_RenderPageBitmap_Start

FPDF_RenderPageBitmap_Start starts to render page contents to a device independent bitmap progressively.

func (*PdfiumImplementation) FPDF_RenderPage_Close

FPDF_RenderPage_Close Release the resource allocate during page rendering. Need to be called after finishing rendering or cancel the rendering. Not supported on multi-threaded usage.

func (*PdfiumImplementation) FPDF_RenderPage_Continue

FPDF_RenderPage_Continue continues rendering a PDF page. Not supported on multi-threaded usage.

func (*PdfiumImplementation) FPDF_SaveAsCopy

FPDF_SaveAsCopy saves the document to a copy.

func (*PdfiumImplementation) FPDF_SaveWithVersion

FPDF_SaveWithVersion save the document to a copy, with a specific file version.

func (*PdfiumImplementation) FPDF_SetFormFieldHighlightAlpha

FPDF_SetFormFieldHighlightAlpha sets the transparency of the form field highlight color in the document.

func (*PdfiumImplementation) FPDF_SetFormFieldHighlightColor

FPDF_SetFormFieldHighlightColor sets the highlight color of the specified (or all) form fields in the document.

func (*PdfiumImplementation) FPDF_SetPrintMode

FPDF_SetPrintMode sets printing mode when printing on Windows. Experimental API. Windows only!

func (*PdfiumImplementation) FPDF_SetSandBoxPolicy

FPDF_SetSandBoxPolicy set the policy for the sandbox environment.

func (*PdfiumImplementation) FPDF_StructElement_Attr_CountChildren added in v1.13.0

FPDF_StructElement_Attr_CountChildren returns the count of the number of children values in an attribute. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_Attr_GetBlobValue

FPDF_StructElement_Attr_GetBlobValue returns the value of a blob attribute in an attribute map by name as string. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_Attr_GetBooleanValue

FPDF_StructElement_Attr_GetBooleanValue returns the value of a boolean attribute in an attribute map by name as FPDF_BOOL. FPDF_StructElement_Attr_GetType() should have returned FPDF_OBJECT_BOOLEAN for this property. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_Attr_GetChildAtIndex added in v1.13.0

FPDF_StructElement_Attr_GetChildAtIndex returns a child from an attribute at the given index. The index must be less than the result of FPDF_StructElement_Attr_CountChildren(). Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_Attr_GetCount

FPDF_StructElement_Attr_GetCount returns the number of attributes in a structure element attribute map. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_Attr_GetName

FPDF_StructElement_Attr_GetName returns the name of an attribute in a structure element attribute map. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_Attr_GetNumberValue

FPDF_StructElement_Attr_GetNumberValue returns the value of a number attribute in an attribute map by name as float. FPDF_StructElement_Attr_GetType() should have returned FPDF_OBJECT_NUMBER for this property. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_Attr_GetStringValue

FPDF_StructElement_Attr_GetStringValue returns the value of a string attribute in an attribute map by name as string. FPDF_StructElement_Attr_GetType() should have returned FPDF_OBJECT_STRING or FPDF_OBJECT_NAME for this property. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_Attr_GetType

FPDF_StructElement_Attr_GetType returns the type of an attribute in a structure element attribute map. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_Attr_GetValue added in v1.13.0

FPDF_StructElement_Attr_GetValue returns a handle to a value for an attribute in a structure element attribute map. The caller does not own the handle. The handle remains valid as long as the struct_attribute, remains valid. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_CountChildren

FPDF_StructElement_CountChildren counts the number of children for the structure element.

func (*PdfiumImplementation) FPDF_StructElement_GetActualText

FPDF_StructElement_GetActualText returns the actual text for a given element. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_GetAltText

FPDF_StructElement_GetAltText returns the alt text for a given element.

func (*PdfiumImplementation) FPDF_StructElement_GetAttributeAtIndex

FPDF_StructElement_GetAttributeAtIndex returns an attribute object in the structure element. If the attribute object exists but is not a dict, then this function will return an error. This will also return an error for out of bounds indices. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_GetAttributeCount

FPDF_StructElement_GetAttributeCount returns the number of attributes for the structure element. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_GetChildAtIndex

FPDF_StructElement_GetChildAtIndex returns a child in the structure element. If the child exists but is not an element, then this function will return an error. This will also return an error for out of bounds indices.

func (*PdfiumImplementation) FPDF_StructElement_GetChildMarkedContentID added in v1.9.0

FPDF_StructElement_GetChildMarkedContentID returns the child's content id. If the child exists but is not a stream or object, then this function will return an error. This will also return an error for out of bounds indices. Compared to FPDF_StructElement_GetMarkedContentIdAtIndex, it is scoped to the current page. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_GetID

FPDF_StructElement_GetID returns the ID for a given element. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_GetLang

FPDF_StructElement_GetLang returns the case-insensitive IETF BCP 47 language code for an element. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_GetMarkedContentID

FPDF_StructElement_GetMarkedContentID returns the marked content ID for a given element.

func (*PdfiumImplementation) FPDF_StructElement_GetMarkedContentIdAtIndex

FPDF_StructElement_GetMarkedContentIdAtIndex returns the marked content id at a given index for a given element. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_GetMarkedContentIdCount

FPDF_StructElement_GetMarkedContentIdCount returns the count of marked content ids for a given element. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_GetObjType

FPDF_StructElement_GetObjType returns the object type (/Type) for a given element. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_GetParent

FPDF_StructElement_GetParent returns the parent of the structure element. If structure element is StructTreeRoot, then this function will return an error. Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_GetStringAttribute

FPDF_StructElement_GetStringAttribute returns a struct element attribute of type "name" or "string" Experimental API.

func (*PdfiumImplementation) FPDF_StructElement_GetTitle

FPDF_StructElement_GetTitle returns the title (/T) for a given element.

func (*PdfiumImplementation) FPDF_StructElement_GetType

FPDF_StructElement_GetType returns the type (/S) for a given element.

func (*PdfiumImplementation) FPDF_StructTree_Close

FPDF_StructTree_Close releases a resource allocated by FPDF_StructTree_GetForPage().

func (*PdfiumImplementation) FPDF_StructTree_CountChildren

FPDF_StructTree_CountChildren counts the number of children for the structure tree.

func (*PdfiumImplementation) FPDF_StructTree_GetChildAtIndex

FPDF_StructTree_GetChildAtIndex returns a child in the structure tree.

func (*PdfiumImplementation) FPDF_StructTree_GetForPage

FPDF_StructTree_GetForPage returns the structure tree for a page.

func (*PdfiumImplementation) FPDF_VIEWERREF_GetDuplex

FPDF_VIEWERREF_GetDuplex returns the paper handling option to be used when printing from the print dialog.

func (*PdfiumImplementation) FPDF_VIEWERREF_GetName

FPDF_VIEWERREF_GetName returns the contents for a viewer ref, with a given key. The value must be of type "name".

func (*PdfiumImplementation) FPDF_VIEWERREF_GetNumCopies

FPDF_VIEWERREF_GetNumCopies returns the number of copies to be printed.

func (*PdfiumImplementation) FPDF_VIEWERREF_GetPrintPageRange

FPDF_VIEWERREF_GetPrintPageRange returns the page numbers to initialize print dialog box when file is printed.

func (*PdfiumImplementation) FPDF_VIEWERREF_GetPrintPageRangeCount

FPDF_VIEWERREF_GetPrintPageRangeCount returns the number of elements in a FPDF_PAGERANGE. Experimental API.

func (*PdfiumImplementation) FPDF_VIEWERREF_GetPrintPageRangeElement

FPDF_VIEWERREF_GetPrintPageRangeElement returns an element from a FPDF_PAGERANGE. Experimental API.

func (*PdfiumImplementation) FPDF_VIEWERREF_GetPrintScaling

FPDF_VIEWERREF_GetPrintScaling returns whether the PDF document prefers to be scaled or not.

func (*PdfiumImplementation) FSDK_SetLocaltimeFunction

FSDK_SetLocaltimeFunction sets a replacement function for calls to localtime(). This API is intended to be used only for testing, thus may cause PDFium to behave poorly in production environments. Since callbacks can't be transferred between processes in gRPC, you can only use this in single-threaded mode.

func (*PdfiumImplementation) FSDK_SetTimeFunction

FSDK_SetTimeFunction sets a replacement function for calls to time(). This API is intended to be used only for testing, thus may cause PDFium to behave poorly in production environments. Since callbacks can't be transferred between processes in gRPC, you can only use this in single-threaded mode.

func (*PdfiumImplementation) FSDK_SetUnSpObjProcessHandler

FSDK_SetUnSpObjProcessHandler set ups an unsupported object handler. Since callbacks can't be transferred between processes in gRPC, you can only use this in single-threaded mode.

func (*PdfiumImplementation) FS_POINTFArrayPointer

func (p *PdfiumImplementation) FS_POINTFArrayPointer(size uint64, in []structs.FPDF_FS_POINTF) (*FS_POINTFArrayPointer, error)

func (*PdfiumImplementation) FS_POINTFPointer

func (p *PdfiumImplementation) FS_POINTFPointer(in *structs.FPDF_FS_POINTF) (*FS_POINTFPointer, error)

func (*PdfiumImplementation) FloatArrayPointer

func (p *PdfiumImplementation) FloatArrayPointer(size uint64) (*FloatArrayPointer, error)

func (*PdfiumImplementation) FloatPointer

func (p *PdfiumImplementation) FloatPointer(in *float32) (*FloatPointer, error)

func (*PdfiumImplementation) Free

func (p *PdfiumImplementation) Free(pointer uint64) error

func (*PdfiumImplementation) GetActionInfo

func (*PdfiumImplementation) GetAttachments

GetAttachments returns all the attachments of a document. Experimental API.

func (*PdfiumImplementation) GetBookmarks

func (p *PdfiumImplementation) GetBookmarks(request *requests.GetBookmarks) (*responses.GetBookmarks, error)

GetBookmarks returns all the bookmarks of a document.

func (*PdfiumImplementation) GetDestInfo

func (p *PdfiumImplementation) GetDestInfo(request *requests.GetDestInfo) (*responses.GetDestInfo, error)

func (*PdfiumImplementation) GetJavaScriptActions

GetJavaScriptActions returns all the JavaScript Actions of a document. Experimental API.

func (*PdfiumImplementation) GetMetaData

func (p *PdfiumImplementation) GetMetaData(request *requests.GetMetaData) (*responses.GetMetaData, error)

GetMetaData returns the metadata values of the document.

func (*PdfiumImplementation) GetPageSize

func (p *PdfiumImplementation) GetPageSize(request *requests.GetPageSize) (*responses.GetPageSize, error)

GetPageSize returns the page size in points One point is 1/72 inch (around 0.3528 mm)

func (*PdfiumImplementation) GetPageSizeInPixels

GetPageSizeInPixels returns the pixel size of a page given the page number and the DPI.

func (*PdfiumImplementation) GetPageText

func (p *PdfiumImplementation) GetPageText(request *requests.GetPageText) (*responses.GetPageText, error)

GetPageText returns the text of a page

func (*PdfiumImplementation) GetPageTextStructured

GetPageTextStructured returns the text of a page in a structured way

func (*PdfiumImplementation) IntArrayPointer

func (p *PdfiumImplementation) IntArrayPointer(size uint64) (*IntArrayPointer, error)

func (*PdfiumImplementation) IntPointer

func (p *PdfiumImplementation) IntPointer() (*IntPointer, error)

func (*PdfiumImplementation) Lock

func (p *PdfiumImplementation) Lock()

func (*PdfiumImplementation) LongPointer

func (p *PdfiumImplementation) LongPointer() (*LongPointer, error)

func (*PdfiumImplementation) Malloc

func (p *PdfiumImplementation) Malloc(size uint64) (uint64, error)

func (*PdfiumImplementation) OpenDocument

func (p *PdfiumImplementation) OpenDocument(request *requests.OpenDocument) (*responses.OpenDocument, error)

func (*PdfiumImplementation) Ping

func (p *PdfiumImplementation) Ping() (string, error)

func (*PdfiumImplementation) RenderPageInDPI

RenderPageInDPI renders a specific page in a specific dpi, the result is an image.

func (*PdfiumImplementation) RenderPageInPixels

RenderPageInPixels renders a specific page in a specific pixel size, the result is an image. The given resolution is a maximum, we automatically calculate either the width or the height to make sure it stays withing the maximum resolution.

func (*PdfiumImplementation) RenderPagesInDPI

RenderPagesInDPI renders a list of pages in a specific dpi, the result is an image.

func (*PdfiumImplementation) RenderPagesInPixels

RenderPagesInPixels renders a list of pages in a specific pixel size, the result is an image. The given resolution is a maximum, we automatically calculate either the width or the height to make sure it stays withing the maximum resolution.

func (*PdfiumImplementation) RenderToFile

func (p *PdfiumImplementation) RenderToFile(request *requests.RenderToFile) (*responses.RenderToFile, error)

func (*PdfiumImplementation) UIntArrayPointer

func (p *PdfiumImplementation) UIntArrayPointer(size uint64) (*UIntArrayPointer, error)

func (*PdfiumImplementation) UIntPointer

func (p *PdfiumImplementation) UIntPointer() (*UIntPointer, error)

func (*PdfiumImplementation) ULongPointer

func (p *PdfiumImplementation) ULongPointer() (*ULongPointer, error)

func (*PdfiumImplementation) Unlock

func (p *PdfiumImplementation) Unlock()

type SchHandleHandle

type SchHandleHandle struct {
	// contains filtered or unexported fields
}

type SearchHandle

type SearchHandle struct {
	// contains filtered or unexported fields
}

type SignatureHandle

type SignatureHandle struct {
	// contains filtered or unexported fields
}

type StructElementAttributeHandle

type StructElementAttributeHandle struct {
	// contains filtered or unexported fields
}

type StructElementAttributeValueHandle added in v1.13.0

type StructElementAttributeValueHandle struct {
	// contains filtered or unexported fields
}

type StructElementHandle

type StructElementHandle struct {
	// contains filtered or unexported fields
}

type StructTreeHandle

type StructTreeHandle struct {
	// contains filtered or unexported fields
}

type TextPageHandle

type TextPageHandle struct {
	// contains filtered or unexported fields
}

type UIntArrayPointer

type UIntArrayPointer struct {
	Pointer uint64
	Size    uint64
	Free    func()
	Value   func() ([]uint, error)
}

type UIntPointer

type UIntPointer struct {
	Pointer uint64
	Free    func()
	Value   func() (uint, error)
}

type ULongPointer

type ULongPointer struct {
	Pointer uint64
	Free    func()
	Value   func() (uint64, error)
}

type XObjectHandle

type XObjectHandle struct {
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL