(parent Container, style uint32)
| 26 | } |
| 27 | |
| 28 | func NewLabelWithStyle(parent Container, style uint32) (*Label, error) { |
| 29 | l := new(Label) |
| 30 | |
| 31 | if err := l.init(l, parent, style); err != nil { |
| 32 | return nil, err |
| 33 | } |
| 34 | |
| 35 | l.SetTextAlignment(AlignNear) |
| 36 | |
| 37 | l.MustRegisterProperty("Text", NewProperty( |
| 38 | func() interface{} { |
| 39 | return l.Text() |
| 40 | }, |
| 41 | func(v interface{}) error { |
| 42 | return l.SetText(assertStringOr(v, "")) |
| 43 | }, |
| 44 | l.textChangedPublisher.Event())) |
| 45 | |
| 46 | return l, nil |
| 47 | } |
| 48 | |
| 49 | func (l *Label) asStatic() *static { |
| 50 | return &l.static |
no test coverage detected
searching dependent graphs…