egui/crates/egui_kittest/tests/snapshots
Lucas Meurer 6d312cc4c7
Add support for scrolling via accesskit / kittest (#7286)
I need to scroll in a snapshot test in my app, and kittest had no
utilities for this. Event::MouseWheel is error prone. This adds support
for some accesskit scroll actions, and uses this in kittest to add
helpers to scroll to a node / scroll the scroll area surrounding a node.

The accesskit code says down/up/left/right `Scrolls by approximately one
screen in a specific direction.`. Unfortunately it's difficult to get
the size of a "screen" (I guess that would be the size of the containing
scroll area)where I implemented the scrolling, so for now I've hardcoded
it to 100px. I think scrolling a fixed amount is still better than not
scrolling at all.

---------

Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>
2025-07-03 12:02:05 +02:00
..
menu Improve text sharpness (#5838) 2025-03-21 12:56:47 +01:00
combobox_closed.png Improve text sharpness (#5838) 2025-03-21 12:56:47 +01:00
combobox_opened.png Improve text sharpness (#5838) 2025-03-21 12:56:47 +01:00
image_snapshots.png Improve text sharpness (#5838) 2025-03-21 12:56:47 +01:00
readme_example.png Create custom `egui_kittest::Node` (#7138) 2025-06-17 12:17:38 +02:00
should_wait_for_images.png Add `ImageLoader::has_pending` and `wait_for_pending_images` (#7030) 2025-05-08 09:27:52 +02:00
test_scroll_initial.png Add support for scrolling via accesskit / kittest (#7286) 2025-07-03 12:02:05 +02:00
test_scroll_scrolled.png Add support for scrolling via accesskit / kittest (#7286) 2025-07-03 12:02:05 +02:00
test_shrink.png Improve text sharpness (#5838) 2025-03-21 12:56:47 +01:00