-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add TableBuilder::drag_to_scroll
#3100
Conversation
@KYovchevski If I understand #3097 correctly, you want to be able to set
I gave I ran 3 versions of the demo app ( diff --git a/crates/egui_demo_lib/src/demo/table_demo.rs b/crates/egui_demo_lib/src/demo/table_demo.rs
index 8fdea420..ceeadf4a 100644
--- a/crates/egui_demo_lib/src/demo/table_demo.rs
+++ b/crates/egui_demo_lib/src/demo/table_demo.rs
@@ -127,6 +127,7 @@ impl TableDemo {
let mut table = TableBuilder::new(ui)
.striped(self.striped)
.resizable(self.resizable)
+ .drag_to_scroll(false)
.cell_layout(egui::Layout::left_to_right(egui::Align::Center))
.column(Column::auto())
.column(Column::initial(100.0).range(40.0..=300.0))
I failed to notice any difference between the cases — I was always able to scroll the table by dragging its body: 2023-06-26.23-34-12.mp4@KYovchevski What is the desired effect? |
@vvv The desired effect is to expose the body's underlying I just tested on both
|
@KYovchevski Ah, I understand why it didn't work for me! I used “two fingers scrolling” gesture on MacBook's trackpad. That is equivalent to scrolling with mouse's wheel. It is not the same as dragging. When I use a mouse or click-and-drag properly with a trackpad, the PR works as intended. Sorry for the noise. |
I'm not sure why the CI isn't kicking in. Perhaps try merging in latest |
e8865d1
to
64a0646
Compare
Closes #3097