view! {
gtk::Window {
gtk::Box {
// Set the orientation property of the Box.
orientation: Vertical,
// Create a Button inside the Box.
gtk::Button {
// Send the message Increment when the button is clicked.
clicked => Increment,
label: "+",
},
gtk::Label {
// Bind the text property of the label to the counter attribute of the model.
text: &self.model.counter.to_string(),
},
gtk::Button {
clicked => Decrement,
label: "-",
},
},
delete_event(_, _) => (Quit, Inhibit(false)),
}
}