Skip to content

Add global app color-scheme API with repaint support#120

Open
crispy-computing-machine wants to merge 3 commits into
masterfrom
codex/add-global-color-scheme-options
Open

Add global app color-scheme API with repaint support#120
crispy-computing-machine wants to merge 3 commits into
masterfrom
codex/add-global-color-scheme-options

Conversation

@crispy-computing-machine

Copy link
Copy Markdown
Owner

Summary

  • Added a new public API wb_set_color_scheme(array $options) to configure app-wide visual styling.
  • Implemented a native global scheme model (WBCOLORSCHEME) in WinBinder core.
  • Applied global colors during control color messages (WM_CTLCOLOR*) so text/background updates propagate across controls.
  • Added WM_ERASEBKGND handling to repaint backgrounds with either a solid color or configurable bitmap image and optional client-border tint for top-level windows.
  • Added full-window redraw propagation after scheme updates so existing controls repaint immediately.
  • Updated stubs and exports so the new API is discoverable from PHP.

New API

wb_set_color_scheme(array $options): bool

Supported keys:

  • enabled (bool)
  • background_color (int RGB)
  • text_color (int RGB)
  • border_color (int RGB)
  • background_image (string path to BMP)

Notes

  • Background images are loaded via LoadImage(..., IMAGE_BITMAP, LR_LOADFROMFILE).
  • Theme updates are global and trigger redraw of registered WinBinder windows/children.

Codex Task

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant