Documentation ¶
Overview ¶
Package pdfdraw implements a library for rendering and reading PDFs
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterBackend ¶
func RegisterBackend(name string, opener BackendOpener)
Register a new pdfdraw backend
Types ¶
type BackendOpener ¶
A BackendOpener is a function that can be used to open a Document using a specific backend
type Document ¶
type Document interface { // Get the total number of pages in the Document NumPages() int // Get a Page Page(idx int) Page }
Document represents a PDF document
type Page ¶
type Page interface { // Get the internal size of the Page Size() (width float64, height float64) // Render the page to an image.Image Render(width int, height int, opts *RenderOptions) image.Image }
Page represents a page in a Document
type RenderOptions ¶
type RenderOptions struct { // The color to fill the image with before it is drawn. FillColor color.RGBA // Disable anti-aliasing NoAA bool }
RenderOptions specifies a set of options for rendering a page.
Click to show internal directories.
Click to hide internal directories.