Documentation ¶
Overview ¶
Package kandinsky contains functions and data for marshaling data and data structures to valid SVG documents.
Supported types: all int types, float32, float64, bool, structs, slices
Marshal objects by calling Marshal with the object and a nominal SVG document size.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Marshal ¶
Marshal marshals a value into a valid SVG document represented as a byte slice. Users should note that size here represents a nominal document size; SVG documents are vector graphics and as such do not have a notion of image size. This will simply provide a sensible default for web browsers or other viewers when displaying the output.
Types ¶
type InvalidValueError ¶
type InvalidValueError struct {
// contains filtered or unexported fields
}
InvalidValueError represents an error condition where the given value for a type is not marshalable by kandinsky.
func (InvalidValueError) Error ¶
func (e InvalidValueError) Error() string
type UnsupportedTypeError ¶
type UnsupportedTypeError struct {
// contains filtered or unexported fields
}
UnsupportedTypeError represents an error condition where kandinsky does not support the provided type for marshaling.
func (UnsupportedTypeError) Error ¶
func (e UnsupportedTypeError) Error() string