gui/label.go

16 lines
266 B
Go

package gui
import (
"go.wit.com/widget"
)
func (parent *Node) NewLabel(text string) *Node {
newNode := parent.newNode(text, widget.Label)
newNode.label = text
newNode.progname = text
// inform the toolkits
sendAction(newNode, widget.Add)
return newNode
}