SetTitle sets the title of the window.
(text string)
| 104 | |
| 105 | // SetTitle sets the title of the window. |
| 106 | func (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 |
| 120 | func (w *Window) Add(ichild IPanel) *Window { |
no test coverage detected