MCPcopy
hub / github.com/g3n/engine / SetTitle

Method SetTitle

gui/window.go:106–117  ·  view source on GitHub ↗

SetTitle sets the title of the window.

(text string)

Source from the content-addressed store, hash-verified

104
105// SetTitle sets the title of the window.
106func (w *Window) SetTitle(text string) {
107
108 if w.title == nil {
109 w.title = newWindowTitle(w, text)
110 w.title.Subscribe(OnCursor, w.onCursor)
111 w.Panel.Add(w.title)
112 } else {
113 w.title.label.SetText(text)
114 }
115 w.update()
116 w.recalc()
117}
118
119// Add adds a child panel to the client area of this window
120func (w *Window) Add(ichild IPanel) *Window {

Callers 1

buildWindowFunction · 0.95

Calls 6

updateMethod · 0.95
recalcMethod · 0.95
newWindowTitleFunction · 0.85
SubscribeMethod · 0.65
AddMethod · 0.45
SetTextMethod · 0.45

Tested by

no test coverage detected