MCPcopy Index your code
hub / github.com/g3n/engine / applyStyle

Method applyStyle

gui/folder.go:163–175  ·  view source on GitHub ↗

applyStyle applies the specified style

(s *FolderStyle)

Source from the content-addressed store, hash-verified

161
162// applyStyle applies the specified style
163func (f *Folder) applyStyle(s *FolderStyle) {
164
165 f.Panel.ApplyStyle(&s.PanelStyle)
166
167 icode := 0
168 if f.contentPanel.GetPanel().Visible() {
169 icode = 1
170 }
171 f.icon.SetText(string(s.Icons[icode]))
172 f.icon.SetColor4(&s.FgColor)
173 f.label.SetBgColor4(&s.BgColor)
174 f.label.SetColor4(&s.FgColor)
175}
176
177func (f *Folder) recalc() {
178

Callers 1

updateMethod · 0.95

Calls 6

VisibleMethod · 0.65
GetPanelMethod · 0.65
ApplyStyleMethod · 0.45
SetTextMethod · 0.45
SetColor4Method · 0.45
SetBgColor4Method · 0.45

Tested by

no test coverage detected