mirror of
https://github.com/storytold/craft-libs.git
synced 2026-11-07 13:23:29 +00:00
egui reports a monitor's size but not its place, so Viewports guessed that monitors tile the desktop. A maximized window's corner is a few points outside its monitor on Windows, which took a monitor up and to the left that doesn't exist, and every window cascaded from it opened off screen. The guess is also wrong whenever monitors differ in size or sit at other offsets. Add Viewports::set_monitors: the app lists the monitors in physical pixels and the driver picks the one showing most of the previous window, at that window's scale. For apps that don't list them yet, the guess now allows for a maximized window's frame. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>