-
I'm currently developing my own drawing application, which uses egui. Drawing is done using the mouse. When a mouse button is pressed down it is supposed to draw. Unfortunately currently egui moves the window when the mouse "drags" it. How can I prevent this? I don't want the window to be fixed in place, but only moveable by the borders. This problem is probably part of a broader one: Being able to customize how the user can interact with egui. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 10 replies
-
There is a painting demo at https://emilk.github.io/egui/#demo with the source code at https://github.com/emilk/egui/blob/master/egui_demo_lib/src/apps/demo/painting.rs The critical part you are missing is |
Beta Was this translation helpful? Give feedback.
There is a painting demo at https://emilk.github.io/egui/#demo with the source code at https://github.com/emilk/egui/blob/master/egui_demo_lib/src/apps/demo/painting.rs
The critical part you are missing is
Sense::drag()
- this tells egui that you will be catching drags, and that egui should not use them