Documentation ¶
Overview ¶
Package paint implements view display properties.
func (v *View) Build(ctx *view.Context) view.Model { return view.Model{ Painter: &paint.Style{ BackgroundColor: colornames.Green, CornerRadius: 3, }, } }
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AnimatedStyle ¶
type AnimatedStyle struct { Style Style Transparency comm.Float64Notifier BackgroundColor comm.ColorNotifier BorderColor comm.ColorNotifier BorderWidth comm.Float64Notifier CornerRadius comm.Float64Notifier ShadowRadius comm.Float64Notifier ShadowOffset layout.PointNotifier ShadowColor comm.ColorNotifier // contains filtered or unexported fields }
AnimatedStyle is the animated version of Style.
func (*AnimatedStyle) Notify ¶
func (as *AnimatedStyle) Notify(f func()) comm.Id
Notify implements the Painter interface.
func (*AnimatedStyle) PaintStyle ¶
func (as *AnimatedStyle) PaintStyle() Style
PaintStyle implements the Painter interface.
func (*AnimatedStyle) Unnotify ¶
func (as *AnimatedStyle) Unnotify(id comm.Id)
Unnotify implements the Painter interface.
type Style ¶
type Style struct { Transparency float64 BackgroundColor color.Color BorderColor color.Color BorderWidth float64 CornerRadius float64 ShadowRadius float64 ShadowOffset layout.Point ShadowColor color.Color }
Style is a list of display properties of that views can set.
func (*Style) MarshalProtobuf ¶
func (*Style) PaintStyle ¶
PaintStyle implements the Painter interface.
Click to show internal directories.
Click to hide internal directories.