consume_key behavior #1274
-
I have recently discovered this crate and was looking for ways to use modifiers. By looking at the demo I found the EasyMark editor that features toggles with ctrl/cmd + the corresponding key, which is very close to my use case. The editor makes use of As this may not be very clear I attached a screen capture to illustrate what happens. EDIT This happens only in DEBUG mode, in release mode the editor works fine. Wondering what causes the issue, but I have not been able to find it. I noticed that ctrl+Z works correctly, so I considered using the same approach as in if ui.input().modifiers.command_only() && ui.input().key_pressed(key) {
[...]
}; Instead of the one in if ui
.input_mut()
.consume_key(egui::Modifiers::new().command(true), key)
{
[...]
}; My guess is that either there is a bug in I can reproduce the issue both in Linux and Windows and I am available for any further information. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Following fd3fb72 the issue is no longer present. |
Beta Was this translation helpful? Give feedback.
Following fd3fb72 the issue is no longer present.