Documentation
¶
Index ¶
- func SetFontLoader(loader FontLoader)
- type Color
- func (c *Color) HSVA() [4]float64
- func (c *Color) Index() int
- func (c *Color) RGBADouble() [4]float64
- func (c *Color) RGBAInt() [4]int
- func (c *Color) RGBAUint() [4]uint
- func (c *Color) SetHSVA(v [4]float64)
- func (c *Color) SetIndex(v int)
- func (c *Color) SetRGBADouble(v [4]float64)
- func (c *Color) SetRGBAInt(v [4]int)
- func (c *Color) SetRGBAUint(v [4]uint)
- func (c *Color) SetString(v string)
- func (c *Color) SetType(v ColorType)
- func (c *Color) String() string
- func (c *Color) Type() ColorType
- type ColorType
- type Context
- func (c *Context) Clone(ctx context.Context) (*Context, error)
- func (c *Context) Close() error
- func (c *Context) FreeClonedContext(ctx context.Context) error
- func (c *Context) FreeLayout(ctx context.Context, g *cgraph.Graph) error
- func (c *Context) Layout(ctx context.Context, g *cgraph.Graph, engine string) error
- func (c *Context) RenderData(ctx context.Context, g *cgraph.Graph, format string, w io.Writer) error
- func (c *Context) RenderFilename(ctx context.Context, g *cgraph.Graph, format, filename string) error
- func (c *Context) RenderImage(ctx context.Context, g *cgraph.Graph, format string) (image.Image, error)
- type DefaultRenderEngine
- func (e *DefaultRenderEngine) BeginAnchor(_ context.Context, _ *Job, _, _, _, _ string) error
- func (e *DefaultRenderEngine) BeginCluster(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) BeginEdge(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) BeginEdges(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) BeginGraph(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) BeginJob(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) BeginLabel(_ context.Context, _ *Job, _ LabelType) error
- func (e *DefaultRenderEngine) BeginLayer(_ context.Context, _ *Job, layerName string, layerNum, numLayers int) error
- func (e *DefaultRenderEngine) BeginNode(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) BeginNodes(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) BeginPage(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) BezierCurve(_ context.Context, _ *Job, _ []*PointFloat, _ bool) error
- func (e *DefaultRenderEngine) Comment(_ context.Context, _ *Job, _ string) error
- func (e *DefaultRenderEngine) Ellipse(_ context.Context, _ *Job, _ []*PointFloat, _ bool) error
- func (e *DefaultRenderEngine) EndAnchor(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) EndCluster(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) EndEdge(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) EndEdges(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) EndGraph(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) EndJob(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) EndLabel(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) EndLayer(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) EndNode(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) EndNodes(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) EndPage(_ context.Context, _ *Job) error
- func (e *DefaultRenderEngine) LibraryShape(_ context.Context, _ *Job, _ string, _ []*PointFloat, _ bool) error
- func (e *DefaultRenderEngine) Polygon(_ context.Context, _ *Job, _ []*PointFloat, _ bool) error
- func (e *DefaultRenderEngine) Polyline(_ context.Context, _ *Job, _ []*PointFloat) error
- func (e *DefaultRenderEngine) ResolveColor(_ context.Context, _ *Job, _ *Color) error
- func (e *DefaultRenderEngine) TextSpan(_ context.Context, _ *Job, _ *PointFloat, _ *TextSpan) error
- type DeviceFeature
- type DevicePlugin
- type DevicePluginOption
- type FillType
- type FontLoader
- type ImageRenderer
- func (r *ImageRenderer) BeginPage(ctx context.Context, job *Job) error
- func (r *ImageRenderer) BezierCurve(ctx context.Context, job *Job, a []*PointFloat, filled bool) error
- func (r *ImageRenderer) Ellipse(ctx context.Context, job *Job, p []*PointFloat, filled bool) error
- func (r *ImageRenderer) EndPage(ctx context.Context, job *Job) error
- func (r *ImageRenderer) Polygon(ctx context.Context, job *Job, a []*PointFloat, filled bool) error
- func (r *ImageRenderer) Polyline(ctx context.Context, job *Job, a []*PointFloat) error
- func (r *ImageRenderer) TextSpan(ctx context.Context, job *Job, p *PointFloat, span *TextSpan) error
- type Job
- func (j *Job) DPI() *PointFloat
- func (j *Job) ExternalContext() bool
- func (j *Job) Height() uint64
- func (j *Job) Object() *ObjectState
- func (j *Job) OutputData() []byte
- func (j *Job) OutputDataPosition() uint
- func (j *Job) OutputFileName() string
- func (j *Job) OutputLangName() string
- func (j *Job) Scale() *Scale
- func (j *Job) SetDPI(v *PointFloat)
- func (j *Job) SetHeight(v uint64)
- func (j *Job) SetOutputData(v []byte)
- func (j *Job) SetOutputDataPosition(v uint)
- func (j *Job) SetOutputFileName(v string)
- func (j *Job) SetOutputLangName(v string)
- func (j *Job) SetScale(v *Scale)
- func (j *Job) SetTranslation(v *Translation)
- func (j *Job) SetWidth(v uint64)
- func (j *Job) SetZoom(v float64)
- func (j *Job) Translation() *Translation
- func (j *Job) Width() uint64
- func (j *Job) Zoom() float64
- type LabelType
- type ObjectState
- func (s *ObjectState) Fill() FillType
- func (s *ObjectState) FillColor() *Color
- func (s *ObjectState) Pen() PenType
- func (s *ObjectState) PenColor() *Color
- func (s *ObjectState) PenWidth() float64
- func (s *ObjectState) RawStyle() []string
- func (s *ObjectState) SetFill(v FillType)
- func (s *ObjectState) SetFillColor(v *Color)
- func (s *ObjectState) SetPen(v PenType)
- func (s *ObjectState) SetPenColor(v *Color)
- func (s *ObjectState) SetPenWidth(v float64)
- func (s *ObjectState) StopColor() *Color
- type PenType
- type Plugin
- type PointFloat
- type PostScriptAlias
- func (s *PostScriptAlias) Family() string
- func (s *PostScriptAlias) Name() string
- func (s *PostScriptAlias) SVGFontFamily() string
- func (s *PostScriptAlias) SVGFontStyle() string
- func (s *PostScriptAlias) SVGFontWeight() string
- func (s *PostScriptAlias) SetFamily(v string)
- func (s *PostScriptAlias) SetName(v string)
- func (s *PostScriptAlias) SetSVGFontFamily(v string)
- func (s *PostScriptAlias) SetSVGFontStyle(v string)
- func (s *PostScriptAlias) SetSVGFontWeight(v string)
- func (s *PostScriptAlias) SetStretch(v string)
- func (s *PostScriptAlias) SetStyle(v string)
- func (s *PostScriptAlias) SetWeight(v string)
- func (s *PostScriptAlias) SetXFigCode(v int)
- func (s *PostScriptAlias) Stretch() string
- func (s *PostScriptAlias) Style() string
- func (s *PostScriptAlias) Weight() string
- func (s *PostScriptAlias) XFigCode() int
- type RenderEngine
- type RenderFeature
- type RenderPlugin
- type RenderPluginOption
- type Scale
- type TextFont
- func (f *TextFont) Color() string
- func (f *TextFont) Count() uint
- func (f *TextFont) Flags() uint
- func (f *TextFont) Name() string
- func (f *TextFont) PostScriptAlias() *PostScriptAlias
- func (f *TextFont) SetColor(v string)
- func (f *TextFont) SetCount(v uint)
- func (f *TextFont) SetFlags(v uint)
- func (f *TextFont) SetName(v string)
- func (f *TextFont) SetPostScriptAlias(v *PostScriptAlias)
- func (f *TextFont) SetSize(v float64)
- func (f *TextFont) Size() float64
- type TextSpan
- func (s *TextSpan) Font() *TextFont
- func (s *TextSpan) Just() int
- func (s *TextSpan) SetFont(v *TextFont)
- func (s *TextSpan) SetJust(v int)
- func (s *TextSpan) SetSize(v *PointFloat)
- func (s *TextSpan) SetText(v string)
- func (s *TextSpan) SetYOffsetCenterLine(v float64)
- func (s *TextSpan) SetYOffsetLayout(v float64)
- func (s *TextSpan) Size() *PointFloat
- func (s *TextSpan) Text() string
- func (s *TextSpan) YOffsetCenterLine() float64
- func (s *TextSpan) YOffsetLayout() float64
- type Translation
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SetFontLoader ¶ added in v0.2.2
func SetFontLoader(loader FontLoader)
Types ¶
type Color ¶
type Color struct {
// contains filtered or unexported fields
}
func (*Color) RGBADouble ¶ added in v0.2.0
func (*Color) SetRGBADouble ¶ added in v0.2.0
func (*Color) SetRGBAInt ¶ added in v0.2.0
func (*Color) SetRGBAUint ¶ added in v0.2.0
type ColorType ¶ added in v0.2.0
type ColorType int64
var ( HSVADouble ColorType = ColorType(wasm.HSVA_DOUBLE) RGBAByte ColorType = ColorType(wasm.RGBA_BYTE) RGBAWord ColorType = ColorType(wasm.RGBA_WORD) RGBADouble ColorType = ColorType(wasm.RGBA_DOUBLE) ColorString ColorType = ColorType(wasm.COLOR_STRING) ColorIndex ColorType = ColorType(wasm.COLOR_INDEX) )
type Context ¶
type Context struct {
// contains filtered or unexported fields
}
func NewWithPlugins ¶ added in v0.2.0
func (*Context) FreeClonedContext ¶ added in v0.2.0
func (*Context) FreeLayout ¶
func (*Context) RenderData ¶
func (*Context) RenderFilename ¶
type DefaultRenderEngine ¶ added in v0.2.0
type DefaultRenderEngine struct { }
func (*DefaultRenderEngine) BeginAnchor ¶ added in v0.2.0
func (*DefaultRenderEngine) BeginCluster ¶ added in v0.2.0
func (e *DefaultRenderEngine) BeginCluster(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) BeginEdge ¶ added in v0.2.0
func (e *DefaultRenderEngine) BeginEdge(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) BeginEdges ¶ added in v0.2.0
func (e *DefaultRenderEngine) BeginEdges(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) BeginGraph ¶ added in v0.2.0
func (e *DefaultRenderEngine) BeginGraph(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) BeginJob ¶ added in v0.2.0
func (e *DefaultRenderEngine) BeginJob(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) BeginLabel ¶ added in v0.2.0
func (*DefaultRenderEngine) BeginLayer ¶ added in v0.2.0
func (*DefaultRenderEngine) BeginNode ¶ added in v0.2.0
func (e *DefaultRenderEngine) BeginNode(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) BeginNodes ¶ added in v0.2.0
func (e *DefaultRenderEngine) BeginNodes(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) BeginPage ¶ added in v0.2.0
func (e *DefaultRenderEngine) BeginPage(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) BezierCurve ¶ added in v0.2.0
func (e *DefaultRenderEngine) BezierCurve(_ context.Context, _ *Job, _ []*PointFloat, _ bool) error
func (*DefaultRenderEngine) Ellipse ¶ added in v0.2.0
func (e *DefaultRenderEngine) Ellipse(_ context.Context, _ *Job, _ []*PointFloat, _ bool) error
func (*DefaultRenderEngine) EndAnchor ¶ added in v0.2.0
func (e *DefaultRenderEngine) EndAnchor(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) EndCluster ¶ added in v0.2.0
func (e *DefaultRenderEngine) EndCluster(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) EndEdge ¶ added in v0.2.0
func (e *DefaultRenderEngine) EndEdge(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) EndEdges ¶ added in v0.2.0
func (e *DefaultRenderEngine) EndEdges(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) EndGraph ¶ added in v0.2.0
func (e *DefaultRenderEngine) EndGraph(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) EndJob ¶ added in v0.2.0
func (e *DefaultRenderEngine) EndJob(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) EndLabel ¶ added in v0.2.0
func (e *DefaultRenderEngine) EndLabel(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) EndLayer ¶ added in v0.2.0
func (e *DefaultRenderEngine) EndLayer(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) EndNode ¶ added in v0.2.0
func (e *DefaultRenderEngine) EndNode(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) EndNodes ¶ added in v0.2.0
func (e *DefaultRenderEngine) EndNodes(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) EndPage ¶ added in v0.2.0
func (e *DefaultRenderEngine) EndPage(_ context.Context, _ *Job) error
func (*DefaultRenderEngine) LibraryShape ¶ added in v0.2.0
func (e *DefaultRenderEngine) LibraryShape(_ context.Context, _ *Job, _ string, _ []*PointFloat, _ bool) error
func (*DefaultRenderEngine) Polygon ¶ added in v0.2.0
func (e *DefaultRenderEngine) Polygon(_ context.Context, _ *Job, _ []*PointFloat, _ bool) error
func (*DefaultRenderEngine) Polyline ¶ added in v0.2.0
func (e *DefaultRenderEngine) Polyline(_ context.Context, _ *Job, _ []*PointFloat) error
func (*DefaultRenderEngine) ResolveColor ¶ added in v0.2.0
func (*DefaultRenderEngine) TextSpan ¶ added in v0.2.0
func (e *DefaultRenderEngine) TextSpan(_ context.Context, _ *Job, _ *PointFloat, _ *TextSpan) error
type DeviceFeature ¶ added in v0.2.0
type DeviceFeature int64
var ( DeviceDoesPages DeviceFeature = DeviceFeature(wasm.DEVICE_DOES_PAGES) DeviceDoesLayers DeviceFeature = DeviceFeature(wasm.DEVICE_DOES_LAYERS) DeviceEvents DeviceFeature = DeviceFeature(wasm.DEVICE_EVENTS) DeviceDoesTrueColor DeviceFeature = DeviceFeature(wasm.DEVICE_DOES_TRUECOLOR) DeviceBinaryFormat DeviceFeature = DeviceFeature(wasm.DEVICE_BINARY_FORMAT) DeviceCompressedFormat DeviceFeature = DeviceFeature(wasm.DEVICE_COMPRESSED_FORMAT) DeviceNoWriter DeviceFeature = DeviceFeature(wasm.DEVICE_NO_WRITER) )
type DevicePlugin ¶ added in v0.2.0
type DevicePlugin struct {
// contains filtered or unexported fields
}
func JPGDevicePlugin ¶ added in v0.2.0
func JPGDevicePlugin(ctx context.Context) (*DevicePlugin, error)
func NewDevicePlugin ¶ added in v0.2.0
func NewDevicePlugin(ctx context.Context, typ string, opts ...DevicePluginOption) (*DevicePlugin, error)
func PNGDevicePlugin ¶ added in v0.2.0
func PNGDevicePlugin(ctx context.Context) (*DevicePlugin, error)
type DevicePluginOption ¶ added in v0.2.0
type DevicePluginOption func(*deviceConfig)
func WithDeviceDPI ¶ added in v0.2.0
func WithDeviceDPI(x, y float64) DevicePluginOption
func WithDeviceFeatures ¶ added in v0.2.0
func WithDeviceFeatures(features ...DeviceFeature) DevicePluginOption
func WithDeviceQuality ¶ added in v0.2.0
func WithDeviceQuality(quality int) DevicePluginOption
type FontLoader ¶ added in v0.2.2
type ImageRenderer ¶
type ImageRenderer struct { *DefaultRenderEngine // contains filtered or unexported fields }
func (*ImageRenderer) BeginPage ¶
func (r *ImageRenderer) BeginPage(ctx context.Context, job *Job) error
func (*ImageRenderer) BezierCurve ¶
func (r *ImageRenderer) BezierCurve(ctx context.Context, job *Job, a []*PointFloat, filled bool) error
func (*ImageRenderer) Ellipse ¶
func (r *ImageRenderer) Ellipse(ctx context.Context, job *Job, p []*PointFloat, filled bool) error
func (*ImageRenderer) EndPage ¶
func (r *ImageRenderer) EndPage(ctx context.Context, job *Job) error
func (*ImageRenderer) Polygon ¶
func (r *ImageRenderer) Polygon(ctx context.Context, job *Job, a []*PointFloat, filled bool) error
func (*ImageRenderer) Polyline ¶
func (r *ImageRenderer) Polyline(ctx context.Context, job *Job, a []*PointFloat) error
func (*ImageRenderer) TextSpan ¶
func (r *ImageRenderer) TextSpan(ctx context.Context, job *Job, p *PointFloat, span *TextSpan) error
type Job ¶
type Job struct {
// contains filtered or unexported fields
}
func (*Job) DPI ¶ added in v0.2.2
func (j *Job) DPI() *PointFloat
func (*Job) ExternalContext ¶ added in v0.2.0
func (*Job) Object ¶ added in v0.2.0
func (j *Job) Object() *ObjectState
func (*Job) OutputData ¶ added in v0.2.0
func (*Job) OutputDataPosition ¶ added in v0.2.0
func (*Job) OutputFileName ¶ added in v0.2.0
func (*Job) OutputLangName ¶ added in v0.2.0
func (*Job) SetDPI ¶ added in v0.2.2
func (j *Job) SetDPI(v *PointFloat)
func (*Job) SetOutputData ¶ added in v0.2.0
func (*Job) SetOutputDataPosition ¶ added in v0.2.0
func (*Job) SetOutputFileName ¶ added in v0.2.0
func (*Job) SetOutputLangName ¶ added in v0.2.0
func (*Job) SetTranslation ¶ added in v0.2.0
func (j *Job) SetTranslation(v *Translation)
func (*Job) Translation ¶ added in v0.2.0
func (j *Job) Translation() *Translation
type LabelType ¶ added in v0.2.0
type LabelType int
var ( LabelPlain LabelType = LabelType(wasm.LABEL_PLAIN) LabelHTML LabelType = LabelType(wasm.LABEL_HTML) )
type ObjectState ¶ added in v0.2.0
type ObjectState struct {
// contains filtered or unexported fields
}
func (*ObjectState) Fill ¶ added in v0.2.0
func (s *ObjectState) Fill() FillType
func (*ObjectState) FillColor ¶ added in v0.2.0
func (s *ObjectState) FillColor() *Color
func (*ObjectState) Pen ¶ added in v0.2.0
func (s *ObjectState) Pen() PenType
func (*ObjectState) PenColor ¶ added in v0.2.0
func (s *ObjectState) PenColor() *Color
func (*ObjectState) PenWidth ¶ added in v0.2.0
func (s *ObjectState) PenWidth() float64
func (*ObjectState) RawStyle ¶ added in v0.2.1
func (s *ObjectState) RawStyle() []string
func (*ObjectState) SetFill ¶ added in v0.2.0
func (s *ObjectState) SetFill(v FillType)
func (*ObjectState) SetFillColor ¶ added in v0.2.0
func (s *ObjectState) SetFillColor(v *Color)
func (*ObjectState) SetPen ¶ added in v0.2.0
func (s *ObjectState) SetPen(v PenType)
func (*ObjectState) SetPenColor ¶ added in v0.2.0
func (s *ObjectState) SetPenColor(v *Color)
func (*ObjectState) SetPenWidth ¶ added in v0.2.0
func (s *ObjectState) SetPenWidth(v float64)
func (*ObjectState) StopColor ¶ added in v0.2.1
func (s *ObjectState) StopColor() *Color
type PointFloat ¶ added in v0.2.0
type PointFloat struct {
// contains filtered or unexported fields
}
func (*PointFloat) SetX ¶ added in v0.2.0
func (p *PointFloat) SetX(x float64)
func (*PointFloat) SetY ¶ added in v0.2.0
func (p *PointFloat) SetY(y float64)
func (*PointFloat) X ¶ added in v0.2.0
func (p *PointFloat) X() float64
func (*PointFloat) Y ¶ added in v0.2.0
func (p *PointFloat) Y() float64
type PostScriptAlias ¶ added in v0.2.0
type PostScriptAlias struct {
// contains filtered or unexported fields
}
func (*PostScriptAlias) Family ¶ added in v0.2.0
func (s *PostScriptAlias) Family() string
func (*PostScriptAlias) Name ¶ added in v0.2.0
func (s *PostScriptAlias) Name() string
func (*PostScriptAlias) SVGFontFamily ¶ added in v0.2.0
func (s *PostScriptAlias) SVGFontFamily() string
func (*PostScriptAlias) SVGFontStyle ¶ added in v0.2.0
func (s *PostScriptAlias) SVGFontStyle() string
func (*PostScriptAlias) SVGFontWeight ¶ added in v0.2.0
func (s *PostScriptAlias) SVGFontWeight() string
func (*PostScriptAlias) SetFamily ¶ added in v0.2.0
func (s *PostScriptAlias) SetFamily(v string)
func (*PostScriptAlias) SetName ¶ added in v0.2.0
func (s *PostScriptAlias) SetName(v string)
func (*PostScriptAlias) SetSVGFontFamily ¶ added in v0.2.0
func (s *PostScriptAlias) SetSVGFontFamily(v string)
func (*PostScriptAlias) SetSVGFontStyle ¶ added in v0.2.0
func (s *PostScriptAlias) SetSVGFontStyle(v string)
func (*PostScriptAlias) SetSVGFontWeight ¶ added in v0.2.0
func (s *PostScriptAlias) SetSVGFontWeight(v string)
func (*PostScriptAlias) SetStretch ¶ added in v0.2.0
func (s *PostScriptAlias) SetStretch(v string)
func (*PostScriptAlias) SetStyle ¶ added in v0.2.0
func (s *PostScriptAlias) SetStyle(v string)
func (*PostScriptAlias) SetWeight ¶ added in v0.2.0
func (s *PostScriptAlias) SetWeight(v string)
func (*PostScriptAlias) SetXFigCode ¶ added in v0.2.0
func (s *PostScriptAlias) SetXFigCode(v int)
func (*PostScriptAlias) Stretch ¶ added in v0.2.0
func (s *PostScriptAlias) Stretch() string
func (*PostScriptAlias) Style ¶ added in v0.2.0
func (s *PostScriptAlias) Style() string
func (*PostScriptAlias) Weight ¶ added in v0.2.0
func (s *PostScriptAlias) Weight() string
func (*PostScriptAlias) XFigCode ¶ added in v0.2.0
func (s *PostScriptAlias) XFigCode() int
type RenderEngine ¶ added in v0.2.0
type RenderEngine interface { BeginJob(ctx context.Context, job *Job) error EndJob(ctx context.Context, job *Job) error BeginGraph(ctx context.Context, job *Job) error EndGraph(ctx context.Context, job *Job) error BeginLayer(ctx context.Context, job *Job, layerName string, layerNum, numLayers int) error EndLayer(ctx context.Context, job *Job) error BeginPage(ctx context.Context, job *Job) error EndPage(ctx context.Context, job *Job) error BeginCluster(ctx context.Context, job *Job) error EndCluster(ctx context.Context, job *Job) error BeginNodes(ctx context.Context, job *Job) error EndNodes(ctx context.Context, job *Job) error BeginEdges(ctx context.Context, job *Job) error EndEdges(ctx context.Context, job *Job) error BeginNode(ctx context.Context, job *Job) error EndNode(ctx context.Context, job *Job) error BeginEdge(ctx context.Context, job *Job) error EndEdge(ctx context.Context, job *Job) error BeginAnchor(ctx context.Context, job *Job, href, tooltip, target, id string) error EndAnchor(ctx context.Context, job *Job) error BeginLabel(ctx context.Context, job *Job, labelType LabelType) error EndLabel(ctx context.Context, job *Job) error TextSpan(ctx context.Context, job *Job, point *PointFloat, textSpan *TextSpan) error ResolveColor(ctx context.Context, job *Job, color *Color) error Ellipse(ctx context.Context, job *Job, points []*PointFloat, filled bool) error Polygon(ctx context.Context, job *Job, points []*PointFloat, filled bool) error BezierCurve(ctx context.Context, job *Job, points []*PointFloat, filled bool) error Polyline(ctx context.Context, job *Job, points []*PointFloat) error Comment(ctx context.Context, job *Job, comment string) error LibraryShape(ctx context.Context, job *Job, s string, points []*PointFloat, filled bool) error }
type RenderFeature ¶ added in v0.2.0
type RenderFeature int64
var ( RenderYGoesDown RenderFeature = RenderFeature(wasm.RENDER_Y_GOES_DOWN) RenderDoesTransform RenderFeature = RenderFeature(wasm.RENDER_DOES_TRANSFORM) RenderDoesLabels RenderFeature = RenderFeature(wasm.RENDER_DOES_LABELS) RenderDoesMaps RenderFeature = RenderFeature(wasm.RENDER_DOES_MAPS) RenderDoesMapRectangle RenderFeature = RenderFeature(wasm.RENDER_DOES_MAP_RECTANGLE) RenderDoesMapCircle RenderFeature = RenderFeature(wasm.RENDER_DOES_MAP_CIRCLE) RenderDoesMapPolygon RenderFeature = RenderFeature(wasm.RENDER_DOES_MAP_POLYGON) RenderDoesMapEllipse RenderFeature = RenderFeature(wasm.RENDER_DOES_MAP_ELLIPSE) RenderDoesMapBspline RenderFeature = RenderFeature(wasm.RENDER_DOES_MAP_BSPLINE) RenderDoesTooltips RenderFeature = RenderFeature(wasm.RENDER_DOES_TOOLTIPS) RenderDoesTargets RenderFeature = RenderFeature(wasm.RENDER_DOES_TARGETS) RenderDoesZ RenderFeature = RenderFeature(wasm.RENDER_DOES_Z) RenderNoWhiteBg RenderFeature = RenderFeature(wasm.RENDER_NO_WHITE_BG) )
type RenderPlugin ¶ added in v0.2.0
type RenderPlugin struct {
// contains filtered or unexported fields
}
func JPGRenderPlugin ¶ added in v0.2.0
func JPGRenderPlugin(ctx context.Context) (*RenderPlugin, error)
func NewRenderPlugin ¶ added in v0.2.0
func NewRenderPlugin(ctx context.Context, typ string, engine RenderEngine, opts ...RenderPluginOption) (*RenderPlugin, error)
func PNGRenderPlugin ¶ added in v0.2.0
func PNGRenderPlugin(ctx context.Context) (*RenderPlugin, error)
type RenderPluginOption ¶ added in v0.2.0
type RenderPluginOption func(*renderConfig)
func WithRenderColorType ¶ added in v0.2.0
func WithRenderColorType(typ ColorType) RenderPluginOption
func WithRenderFeatures ¶ added in v0.2.0
func WithRenderFeatures(features ...RenderFeature) RenderPluginOption
func WithRenderPAD ¶ added in v0.2.0
func WithRenderPAD(pad float64) RenderPluginOption
func WithRenderQuality ¶ added in v0.2.0
func WithRenderQuality(quality int) RenderPluginOption
type Scale ¶ added in v0.2.0
type Scale = PointFloat
type TextFont ¶ added in v0.2.0
type TextFont struct {
// contains filtered or unexported fields
}
func (*TextFont) PostScriptAlias ¶ added in v0.2.0
func (f *TextFont) PostScriptAlias() *PostScriptAlias
func (*TextFont) SetPostScriptAlias ¶ added in v0.2.0
func (f *TextFont) SetPostScriptAlias(v *PostScriptAlias)
type TextSpan ¶
type TextSpan struct {
// contains filtered or unexported fields
}
func (*TextSpan) SetSize ¶ added in v0.2.0
func (s *TextSpan) SetSize(v *PointFloat)
func (*TextSpan) SetYOffsetCenterLine ¶ added in v0.2.0
func (*TextSpan) SetYOffsetLayout ¶ added in v0.2.0
func (*TextSpan) Size ¶ added in v0.2.0
func (s *TextSpan) Size() *PointFloat
func (*TextSpan) YOffsetCenterLine ¶ added in v0.2.0
func (*TextSpan) YOffsetLayout ¶ added in v0.2.0
type Translation ¶ added in v0.2.0
type Translation = PointFloat
Click to show internal directories.
Click to hide internal directories.