applyStyleScene calls ApplyStyle on all widgets in the Scene, This is needed whenever the window geometry, DPI, etc is updated, which affects styling.
()
| 241 | // This is needed whenever the window geometry, DPI, |
| 242 | // etc is updated, which affects styling. |
| 243 | func (sc *Scene) applyStyleScene() { |
| 244 | sc.updating = true // prevent rendering |
| 245 | defer func() { sc.updating = false }() |
| 246 | |
| 247 | sc.StyleTree() |
| 248 | sc.needsLayout = true |
| 249 | } |
| 250 | |
| 251 | // doRebuild does the full re-render and RenderContext Rebuild flag |
| 252 | // should be used by Widgets to rebuild things that are otherwise |