Skip to content

gui_toolkit 0.95.0

Choose a tag to compare

@sachahjkl sachahjkl released this 07 Nov 15:31
· 3 commits to master since this release
v0.95.0
8952b5a

Added

  • Contrast: ui.luminance and ui.contrast (WCAG's ratio), ui.to_oklch / ui.from_oklch for linear colours, and ui.readable(fg, ground, ratio): the colour moved along its OKLCH lightness, its hue and chroma kept, only as far as it must to read on the ground (lighter on a dark one, darker on a light one).
  • The system's light / dark, on Windows too, and when it changes: platform.dark_mode_preferred() reads Windows' app mode (AppsUseLightTheme) as it read the portal and GTK on Linux; platform.color_scheme_serial() moves when the choice may have changed (WM_SETTINGCHANGE "ImmersiveColorSet", the portal's SettingChanged): an app that follows the system compares one integer a frame.