Documentation
¶
Index ¶
- Constants
- Variables
- type EdgeOptions
- type FontConfig
- type HorizontalAlignment
- type Options
- type Renderer
- func (r Renderer) EdgeRenderer(fromID, toID string, edge *lpg.Edge, w io.Writer) (bool, error)
- func (r Renderer) NodeBoxRenderer(ID string, node *lpg.Node, wr io.Writer) (bool, error)
- func (r Renderer) NodeTableRenderer(ID string, node *lpg.Node, wr io.Writer) (bool, error)
- func (r Renderer) Render(g *lpg.Graph, graphName string, out io.Writer) error
- type TableCellOptions
- type TableOptions
- type VerticalAlignment
Constants ¶
View Source
const HALIGN_CENTER = "CENTER"
View Source
const HALIGN_LEFT = "LEFT"
View Source
const HALIGN_RIGHT = "RIGHT"
View Source
const HALIGN_TEXT = "TEXT"
View Source
const VALIGN_BOTTOM = "BOTTOM"
View Source
const VALIGN_MIDDLE = "MIDDLE"
View Source
const VALIGN_TOP = "TOP"
Variables ¶
View Source
var DefaultFontConfig = FontConfig{
Face: "Courier",
Size: 10,
Color: "gray20",
}
Functions ¶
This section is empty.
Types ¶
type EdgeOptions ¶
type EdgeOptions struct {
Font FontConfig
Color string
}
func (EdgeOptions) String ¶
func (e EdgeOptions) String() string
type FontConfig ¶
func (FontConfig) String ¶
func (f FontConfig) String() string
func (FontConfig) Write ¶
func (f FontConfig) Write(s string) string
type HorizontalAlignment ¶
type HorizontalAlignment string
type Options ¶
type Options struct {
Font FontConfig
Color string
Rankdir string
Table TableOptions
Labels TableCellOptions
Properties TableCellOptions
Edges EdgeOptions
}
func DefaultOptions ¶
func DefaultOptions() Options
type Renderer ¶
type Renderer struct {
Options Options
NodeSelectorFunc func(*lpg.Node) bool
EdgeSelectorFunc func(*lpg.Edge) bool
}
func (Renderer) EdgeRenderer ¶
func (Renderer) NodeBoxRenderer ¶
func (Renderer) NodeTableRenderer ¶
type TableCellOptions ¶
type TableCellOptions struct {
Align HorizontalAlignment `dot:"ALIGN"`
Balign HorizontalAlignment `dot:"BALIGN"`
BGColor string `dot:"BGCOLOR"`
Border string `dot:"BORDER"`
CellPadding string `dot:"CELLPADDING"`
CellSpacing string `dot:"CELLSPACING"`
Color string `dot:"COLOR"`
ColSpan int `dot:"COLSPAN"`
HRef string `dot:"HREF"`
Port string `dot:"PORT"`
RowSpan int `dot:"ROWSPAN"`
Style string `dot:"STYLE"`
Target string `dot:"TARGET"`
Valign VerticalAlignment `dot:"VALIGN"`
Font FontConfig
}
func (TableCellOptions) String ¶
func (t TableCellOptions) String() string
type TableOptions ¶
type TableOptions struct {
Align HorizontalAlignment `dot:"ALIGN"`
BGColor string `dot:"BGCOLOR"`
Border string `dot:"BORDER"`
CellBorder string `dot:"CELLBORDER"`
CellPadding string `dot:"CELLPADDING"`
CellSpacing string `dot:"CELLSPACING"`
Color string `dot:"COLOR"`
Columns int `dot:"COLUMNS"`
HRef string `dot:"HREF"`
ID string `dot:"ID"`
Port string `dot:"PORT"`
Rows int `dot:"ROWS"`
Sides int `dot:"SIDES"`
Style string `dot:"STYLE"`
Target string `dot:"TARGET"`
Title string `dot:"TITLE"`
Valign VerticalAlignment `dot:"VALIGN"`
}
func (TableOptions) String ¶
func (t TableOptions) String() string
type VerticalAlignment ¶
type VerticalAlignment string
Click to show internal directories.
Click to hide internal directories.