Repository navigation
Conversation
…torytold#6639) The File page's side menu was laid out at a fixed height, so in a window too short for it the items below the window's bottom edge (Options and About, and more as the window gets shorter) were cut off, and the wheel over the menu did nothing. The menu below the back button is now a vertical scroll area, and a menu item reached with Tab scrolls into view. When the whole menu fits, About and the community link stay at the bottom of the menu as before. Tests cover the wheel and Tab in a short window, left to right and right to left, and About's place when the menu fits, with and without the macOS title bar.
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|
Fixes #6639.
The File page's side menu was laid out at a fixed height with nothing to scroll it. In a window too short for the menu, the items below the window's bottom edge (Options and About, and more as the window gets shorter) were cut off, and the wheel over the menu did nothing. This happened left to right and right to left.
In
crates/ui-egui/src/backstage.rs, the menu items and the bottom links (About and the community link) are now in a vertical scroll area below the back button, and an item reached with Tab scrolls into view. When the whole menu fits, About and the community link stay at the bottom of the menu as before.Tests in
crates/ui-egui/src/backstage/tests.rs:the_side_menu_scrolls_with_the_wheel_in_a_short_window: a 360 point tall window, left to right and right to left (a fixture catalog, so it does not need the translations). It fails without the scroll area: Options stays at y 490 to 528 in both directions after the wheel.tab_to_about_scrolls_it_into_a_short_window: Tab to About in the same window, both directions. It fails without the scroll-into-view: About gets the focus at y 376 to 408, below the window's bottom edge at 352.about_stays_at_the_bottom_of_a_side_menu_that_fits: About's place in a 900 point window, both directions, with and without the macOS title bar.Checks
Run on Linux (Ubuntu 26.04) on 6f9c45a, based on
mainat 60415e0:cargo fmt --all -- --checkcargo clippy -p wordcraft-ui-egui --all-targets -- -D warningscargo test -p wordcraft-ui-egui --no-fail-fast: 1,259 passed, 3 failed, 3 ignored. WithoutCRAFT_I18N_DIRandCRAFT_FONTS_DIR,backstage::tests::rtl_template_titles_are_right_alignedandtheme::tests::interface_symbols_have_glyphsfail with the same messages on 60415e0.tests::a_pointer_zoom_stretches_pages_until_it_stopsfailed in the full run and passed in three runs on its own.Summary by CodeRabbit