You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi and thank you so much for the crate,
just starting to get my head around it, i've been learning egui and have a few things working but would like to use the bevy ecs - so thought this crate might allow me to rework what I have in that context.
The issue i'm having is
can't really zoom on the egui Plot in the wasm build.
the native build on mac allows for zoom using the cmd and touchpad, but when I try this on the web build the zoom is not restricted to the plot, the whole interface zooms.
is there any way to prevent the zoom event from propagating to the rest of the interface on the web build?
panning to the left and right on the web is triggering browser gestures, so triggering back and forward navigation - I think it's the same question about stopping touch events propagating above the plot.
also understand that propagation is probably not the correct work given bevy_egui is translating the bevy input to egui input, but hopefully the question is clear.
any chance of getting pinch to zoom working, I notice that the bevy code have magnification and rotation from the touch-pad - but says it's restricted to mac, can live without it but thought i'd ask if it's even possible.
an example of the code that's i'm seeing the issues about in looks like
bevy_egui::egui::CentralPanel::default().show(egui_ctx.ctx_mut(), |ui| {
ui.label("stuff to show zoom");
ui.button("some button");
let plot = Plot::new("pattern maker plot drawing")
//.legend(Legend::default().position(Corner::RightBottom))
.show_x(true) //shows the marker lines from the cursor
.show_y(true) //shows the marker lines from the cursor
.data_aspect(1.0)
.allow_zoom(true) //(self.drawing_tool_toolbar.drawing_tool == pm_models::DrawingToolKind::Select)
.allow_drag(true)
.allow_scroll(true)
.show_axes([true, true]);
//.x_axis_formatter(my_x_axis_formatter)
//.y_axis_formatter(my_y_axis_formatter);
//.clamp_grid(clamp_grid)
//.include_x(0.0);
//let response : Response;
let res = plot.show(ui, |plot_ui| {
//build out the instructions from the pattern, adding the points and lines as required.
//adjust ponit poisitions based on current drag details.
});
//response
});
Hi and thank you so much for the crate,
just starting to get my head around it, i've been learning egui and have a few things working but would like to use the bevy ecs - so thought this crate might allow me to rework what I have in that context.
The issue i'm having is
can't really zoom on the egui Plot in the wasm build.
the native build on mac allows for zoom using the cmd and touchpad, but when I try this on the web build the zoom is not restricted to the plot, the whole interface zooms.
is there any way to prevent the zoom event from propagating to the rest of the interface on the web build?
panning to the left and right on the web is triggering browser gestures, so triggering back and forward navigation - I think it's the same question about stopping touch events propagating above the plot.
also understand that propagation is probably not the correct work given bevy_egui is translating the bevy input to egui input, but hopefully the question is clear.
an example of the code that's i'm seeing the issues about in looks like
`impl Plugin for ExamplePlugin {
fn build(&self, app: &mut App) {
app
.add_systems(Update, show_legacy_pattern);
}
}
pub (crate) fn show_legacy_pattern(
mut egui_ctx: EguiContexts,
){
}`
have an example app to demonstrate the functionality https://github.com/learnplaycreate/bevy_egui_touch_examples
appreciate the help,
The text was updated successfully, but these errors were encountered: