Solaar/lib/solaar
Ken Sanislo 6c99d2f9d1 PerKey dialog: size window from measured natural size
The dialog used hardcoded offsets to compute its target size from the
canvas's size_request:

    target_w = canvas_w + 32  # 8 wrapper border * 2 + ~16 scrollbar slack
    target_h = canvas_h + 80  # 8 wrapper border * 2 + 50 toolbar + slack

Two problems with that:

1. The "+32" only covered the canvas's width plus borders, not the
   toolbar's width. Small layouts (e.g. an 8-LED mouse: canvas ~172px)
   produced a window narrower than the toolbar wanted (~261px with
   the icon buttons + palette + color picker + unset toggle), causing
   toolbar overflow / clipping.

2. The "+80" assumed a fixed toolbar height and scrollbar slack —
   wrong on themes with chunkier buttons or different scrollbar
   metrics, and brittle to any future toolbar additions.

Replace with `wrapper.get_preferred_size()`. GTK already aggregates
the canvas's size_request through ScrolledWindow + the editor VBox +
the wrapper's border into a natural size that accounts for every
contribution, including the toolbar's width. Drop the now-unused
`canvas_size()` shim from PerKeyEditor.
2026-05-12 12:51:36 -04:00
..
cli cli: enumerate LED effects under RGB_EFFECTS / COLOR_LED_EFFECTS in solaar show (#3213) 2026-05-12 09:54:30 -04:00
ui PerKey dialog: size window from measured natural size 2026-05-12 12:51:36 -04:00
__init__.py Fix warnings from automatic code inspections 2024-10-11 07:42:38 -04:00
configuration.py config: tolerate devices with no unitId 2026-02-05 10:50:49 -05:00
custom_logger.py Introduce custom logger 2025-01-02 07:56:46 -05:00
dbus.py solaar: Remove outdated logger enabled checks 2025-01-02 09:26:31 -05:00
gtk.py docs: update help messages for CLI commands 2025-12-21 18:03:53 -05:00
i18n.py Unsupported locale: Fall back to English (#2891) 2025-09-08 09:44:45 -04:00
listener.py centurion: support PRO X 2 LIGHTSPEED headphones Centurion features (#3150) 2026-04-14 11:43:23 -04:00
tasks.py solaar: Remove outdated logger enabled checks 2025-01-02 09:26:31 -05:00
version release 1.1.19 2026-01-08 12:32:44 -05:00