Replies: 1 comment 1 reply
-
struct MyState {
visible: bool
}
impl MyState {
fn ui(&mut self, ui: &mut egui::Ui) {
ui.checkbox(&mut self.visible, "Is the other stuff visible?");
ui.add_visible_ui(|ui| {
ui.label("Only visible some times!):
});
}
} |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hey,
I'm not sure what to call this, so sorry for that. I want to have a button that when clicked will hide/show another widget button. I've been looking through the examples but I think I've confused myself. I feel like this is something basic that I missed somewhere.
Edit:: I added a screenshot to help. I want to click on the filter icon(top right) and be able to hide/unhide the ui.group in the white box.
Is there a way to do this? If so, could you please write up a small simple test example?
Thanks,
Matthew
Beta Was this translation helpful? Give feedback.
All reactions