You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Make blit stylable end to end, the way Dear ImGui's style stack is, but data-driven. The theme today is one flat record of colours and metrics shared by every widget, with one pad that serves both container padding and control text inset.
Themes are TOML read and written through std.data.toml, the same format the state store (#95) persists in, rather than a format of blit's own.
Acceptance
A per-widget style record for every widget kind (button, toggle, slider, field, section, window, tab, scrollbar, list, chart, tooltip, menu, overlay, modal), with state variants: normal, hot, active, on, disabled, focused
Each style covers fill, text colour, border colour and width, corner radii, padding (split into container padding and control inset), margins, min sizes, gradient and shadow, drawn with the primitives from feat: vector draw primitives #79
A push/pop style stack that overrides any field for a scope, and named style classes a caller can apply to a widget call
Themes load from TOML, with every field addressable, and reload at runtime without rebuilding
Built-in themes: dark, light, high contrast, and the current look as the default
A theme editor widget built from blit itself, editing a live theme and writing it out
Theme fields are documented in one table that is the source of truth
Activity
feat(#81): style records per widget kind, derived from theme tokens
feat(#81): overrides, classes and themes on a context
feat(#81): every widget paints through its style records
feat(#81): menus, tab bars and popups paint through style records
fix(#81): the harness derives its styles after changing the corner token
feat(#81): a theme editor built from blit's widgets
docs(#81): themes, styles, overrides, classes, TOML and the editor
test(#81): the box painter's gradient, outline and shadow
feat(#81): overlays, toasts and tooltips paint through style records
feat(#81)!: widget kinds are a registry on the theme
Merge pull request #136 from briar-systems/feat/81