tracer

package
v0.0.9 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2024 License: BSD-3-Clause Imports: 12 Imported by: 0

Documentation

Overview

Package tracer provides a function to dump the current layout tree, which may be used in debug mode.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FormatMaybeFloat

func FormatMaybeFloat(v properties.MaybeFloat) string

Types

type Drawer added in v0.0.3

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

func NewDrawerFile added in v0.0.3

func NewDrawerFile(outFile string) Drawer

NewDrawerFile panics if an error occurs.

func NewDrawerNoOp added in v0.0.3

func NewDrawerNoOp() Drawer
func (dr Drawer) AddExternalLink(x, y, w, h fl, url string)

func (Drawer) AddFileAnnotation added in v0.0.3

func (dr Drawer) AddFileAnnotation(x, y, w, h fl, id string)

func (Drawer) AddFont added in v0.0.3

func (dr Drawer) AddFont(backend.Font, []byte) *backend.FontChars
func (dr Drawer) AddInternalLink(x, y, w, h fl, anchorName string)

func (Drawer) AddPage added in v0.0.3

func (dr Drawer) AddPage(left, top, right, bottom fl) backend.Page

func (Drawer) Clip added in v0.0.3

func (dr Drawer) Clip(evenOdd bool)

func (Drawer) ClosePath added in v0.0.3

func (dr Drawer) ClosePath()

func (Drawer) CreateAnchors added in v0.0.3

func (dr Drawer) CreateAnchors(anchors [][]backend.Anchor)

func (Drawer) CubicTo added in v0.0.3

func (dr Drawer) CubicTo(x1, y1, x2, y2, x3, y3 fl)

func (Drawer) DrawGradient added in v0.0.3

func (dr Drawer) DrawGradient(gradient backend.GradientLayout, width, height fl)

func (Drawer) DrawRasterImage added in v0.0.3

func (dr Drawer) DrawRasterImage(img backend.RasterImage, width, height fl)

func (Drawer) DrawText added in v0.0.3

func (dr Drawer) DrawText(text []backend.TextDrawing)

func (Drawer) DrawWithOpacity added in v0.0.3

func (dr Drawer) DrawWithOpacity(opacity fl, group backend.Canvas)

func (Drawer) EmbedFile added in v0.0.3

func (dr Drawer) EmbedFile(id string, a backend.Attachment)

func (Drawer) GetRectangle added in v0.0.3

func (dr Drawer) GetRectangle() (left, top, right, bottom fl)

func (Drawer) GetTransform added in v0.0.3

func (dr Drawer) GetTransform() matrix.Transform

func (Drawer) LineTo added in v0.0.3

func (dr Drawer) LineTo(x fl, y fl)

func (Drawer) MoveTo added in v0.0.3

func (dr Drawer) MoveTo(x fl, y fl)

func (Drawer) NewGroup added in v0.0.3

func (dr Drawer) NewGroup(x, y, width, height fl) backend.Canvas

func (Drawer) OnNewStack added in v0.0.3

func (dr Drawer) OnNewStack(f func())

func (Drawer) Paint added in v0.0.3

func (dr Drawer) Paint(op backend.PaintOp)

func (Drawer) Rectangle added in v0.0.3

func (dr Drawer) Rectangle(x fl, y fl, width fl, height fl)

func (Drawer) SetAlphaMask added in v0.0.3

func (dr Drawer) SetAlphaMask(mask backend.Canvas)

func (Drawer) SetAttachments added in v0.0.3

func (dr Drawer) SetAttachments(as []backend.Attachment)

func (Drawer) SetAuthors added in v0.0.3

func (dr Drawer) SetAuthors(authors []string)

func (Drawer) SetBleedBox added in v0.0.3

func (dr Drawer) SetBleedBox(left, top, right, bottom fl)

func (Drawer) SetBlendingMode added in v0.0.3

func (dr Drawer) SetBlendingMode(mode string)

func (Drawer) SetBookmarks added in v0.0.3

func (dr Drawer) SetBookmarks([]backend.BookmarkNode)

func (Drawer) SetColorPattern added in v0.0.3

func (dr Drawer) SetColorPattern(backend.Canvas, fl, fl, matrix.Transform, bool)

func (Drawer) SetColorRgba added in v0.0.3

func (dr Drawer) SetColorRgba(color parser.RGBA, stroke bool)

func (Drawer) SetCreator added in v0.0.3

func (dr Drawer) SetCreator(creator string)

func (Drawer) SetDash added in v0.0.3

func (dr Drawer) SetDash(dashes []fl, offset fl)

func (Drawer) SetDateCreation added in v0.0.3

func (dr Drawer) SetDateCreation(d time.Time)

func (Drawer) SetDateModification added in v0.0.3

func (dr Drawer) SetDateModification(d time.Time)

func (Drawer) SetDescription added in v0.0.3

func (dr Drawer) SetDescription(description string)

func (Drawer) SetKeywords added in v0.0.3

func (dr Drawer) SetKeywords(keywords []string)

func (Drawer) SetLineWidth added in v0.0.3

func (dr Drawer) SetLineWidth(width fl)

func (Drawer) SetMediaBox added in v0.0.3

func (dr Drawer) SetMediaBox(left, top, right, bottom fl)

func (Drawer) SetProducer added in v0.0.3

func (dr Drawer) SetProducer(producer string)

func (Drawer) SetStrokeOptions added in v0.0.3

func (dr Drawer) SetStrokeOptions(backend.StrokeOptions)

func (Drawer) SetTextPaint added in v0.0.3

func (dr Drawer) SetTextPaint(backend.PaintOp)

func (Drawer) SetTitle added in v0.0.3

func (dr Drawer) SetTitle(title string)

func (Drawer) SetTrimBox added in v0.0.3

func (dr Drawer) SetTrimBox(left, top, right, bottom fl)

func (Drawer) State added in v0.0.3

func (dr Drawer) State() backend.GraphicState

func (Drawer) Transform added in v0.0.3

func (dr Drawer) Transform(mt matrix.Transform)

type Tracer

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

func NewTracer

func NewTracer(outFile string) Tracer

NewTracer panics if an error occurs.

func (Tracer) Dump

func (t Tracer) Dump(line string)

func (Tracer) DumpTree

func (t Tracer) DumpTree(box boxes.Box, context string)

Jump to

Keyboard shortcuts

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