Documentation ¶
Index ¶
- func ParseCSSProperty(propType PropertyType, value string) (interface{}, error)
- func ParseHexColor(hexColor string) color.Color
- type IPropertiesContainer
- type IPropertyOwner
- type PropertiesChangesList
- type PropertiesChangesListItem
- type PropertiesChangesStack
- type PropertiesContainer
- func (c *PropertiesContainer) AddProperty(name string, prop *Property)
- func (c *PropertiesContainer) GetProperties() []*Property
- func (c *PropertiesContainer) InitPropertiesContainer()
- func (c *PropertiesContainer) NotifyChangedToContainer(prop *Property)
- func (c *PropertiesContainer) Property(name string) *Property
- func (c *PropertiesContainer) PropertyValue(name string) interface{}
- func (c *PropertiesContainer) SetPropertyChangeNotifier(OnPropertyChangedForEditor func(prop *Property))
- func (c *PropertiesContainer) SetPropertyValue(name string, value interface{})
- type Property
- func (c *Property) Bool() bool
- func (c *Property) Code() string
- func (c *Property) Color() color.Color
- func (c *Property) DefaultValueForType(propertyType PropertyType) interface{}
- func (c *Property) Dispose()
- func (c *Property) Float64() float64
- func (c *Property) Init(name string, w IPropertyOwner)
- func (c *Property) Int() int
- func (c *Property) Int32() int32
- func (c *Property) SaveToStruct() *PropertyStruct
- func (c *Property) SetOwnValue(value interface{})
- func (c *Property) SetStyledValue(subclass string, value string, score int)
- func (c *Property) SetUnstyled(isUnstyled bool)
- func (c *Property) SetVisible(visible bool)
- func (c *Property) String() string
- func (c *Property) Value() interface{}
- func (c *Property) ValueOwn() interface{}
- func (c *Property) ValueStyle(subclass string) interface{}
- func (c *Property) ValueStyleScore(subclass string) int
- func (c *Property) Visible() bool
- type PropertyStruct
- type PropertyType
- type PropertyValue
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ParseCSSProperty ¶
func ParseCSSProperty(propType PropertyType, value string) (interface{}, error)
func ParseHexColor ¶
ToRGB converts the HEXColor to and RGBColor
Types ¶
type IPropertiesContainer ¶
type IPropertiesContainer interface { AddProperty(name string, prop *Property) GetProperties() []*Property SetPropertyValue(name string, value interface{}) PropertyValue(name string) interface{} Property(name string) *Property SetPropertyChangeNotifier(OnPropertyChangedForEditor func(prop *Property)) NotifyChangedToContainer(prop *Property) }
type IPropertyOwner ¶
type IPropertyOwner interface {
Subclass() string
}
type PropertiesChangesList ¶
type PropertiesChangesList struct {
// contains filtered or unexported fields
}
func NewPropertiesChangesList ¶
func NewPropertiesChangesList() *PropertiesChangesList
func (*PropertiesChangesList) AddItem ¶
func (c *PropertiesChangesList) AddItem(propContainer IPropertiesContainer, propName string, value interface{})
func (*PropertiesChangesList) Items ¶
func (c *PropertiesChangesList) Items() []*PropertiesChangesListItem
type PropertiesChangesListItem ¶
type PropertiesChangesListItem struct { Name string Value interface{} PropContainer IPropertiesContainer }
type PropertiesChangesStack ¶
type PropertiesChangesStack struct {
// contains filtered or unexported fields
}
func NewPropertiesChangesStack ¶
func NewPropertiesChangesStack() *PropertiesChangesStack
func (*PropertiesChangesStack) AddList ¶
func (c *PropertiesChangesStack) AddList(list *PropertiesChangesList)
func (*PropertiesChangesStack) Undo ¶
func (c *PropertiesChangesStack) Undo() *PropertiesChangesList
type PropertiesContainer ¶
type PropertiesContainer struct { OnPropertyChanged func(prop *Property) OnPropertyChangedForEditor func(prop *Property) // contains filtered or unexported fields }
func (*PropertiesContainer) AddProperty ¶
func (c *PropertiesContainer) AddProperty(name string, prop *Property)
func (*PropertiesContainer) GetProperties ¶
func (c *PropertiesContainer) GetProperties() []*Property
func (*PropertiesContainer) InitPropertiesContainer ¶
func (c *PropertiesContainer) InitPropertiesContainer()
func (*PropertiesContainer) NotifyChangedToContainer ¶
func (c *PropertiesContainer) NotifyChangedToContainer(prop *Property)
func (*PropertiesContainer) Property ¶
func (c *PropertiesContainer) Property(name string) *Property
func (*PropertiesContainer) PropertyValue ¶
func (c *PropertiesContainer) PropertyValue(name string) interface{}
func (*PropertiesContainer) SetPropertyChangeNotifier ¶
func (c *PropertiesContainer) SetPropertyChangeNotifier(OnPropertyChangedForEditor func(prop *Property))
func (*PropertiesContainer) SetPropertyValue ¶
func (c *PropertiesContainer) SetPropertyValue(name string, value interface{})
type Property ¶
type Property struct { Name string DisplayName string Type PropertyType SubType string GroupName string DefaultValue interface{} OnChanged func(property *Property, oldValue interface{}, newValue interface{}) // contains filtered or unexported fields }
func NewProperty ¶
func NewProperty(name string, propertyType PropertyType) *Property
func (*Property) DefaultValueForType ¶
func (c *Property) DefaultValueForType(propertyType PropertyType) interface{}
func (*Property) Init ¶
func (c *Property) Init(name string, w IPropertyOwner)
func (*Property) SaveToStruct ¶
func (c *Property) SaveToStruct() *PropertyStruct
func (*Property) SetOwnValue ¶
func (c *Property) SetOwnValue(value interface{})
func (*Property) SetStyledValue ¶
func (*Property) SetUnstyled ¶
func (*Property) SetVisible ¶
func (*Property) ValueStyle ¶
func (*Property) ValueStyleScore ¶
type PropertyStruct ¶
type PropertyType ¶
type PropertyType string
const ( PropertyTypeBool PropertyType = "bool" PropertyTypeInt PropertyType = "int" PropertyTypeInt32 PropertyType = "int32" PropertyTypeColor PropertyType = "color" PropertyTypeDouble PropertyType = "double" PropertyTypeString PropertyType = "string" PropertyTypeMultiline PropertyType = "multiline" )
type PropertyValue ¶
Click to show internal directories.
Click to hide internal directories.