vegan meat pizza

Personal Blog about anything - mostly programming, cooking and random thoughts
For the app I'm currently working on I need to react to mouse inputs in a drawing area. I need the position of the mouse and the possibility to react to mouse clicks.
The mouse position can be obtained by using an EventControllerMotion. This is added to the DrawingArea.
let pos_controller = EventControllerMotion::new();
pos_controller.connect_motion(move |_con, x, y| {
...
});
drawing_area.add_controller(pos_controller);
For each mouse button you want to "observe" a GestureClick is created and added to the DrawingArea.
let gesture_click = GestureClick::builder()
.button(GDK_BUTTON_PRIMARY as u32)
.build();
gesture_click.connect_pressed(move |_, _, _, _| {
// create to mouse click
});
drawing_area.add_controller(gesture_click);
I'm currently building an application using gtk-rs using GTK4. To react to key presses the EventControllerKey can be used. This is added as a controller to the main window.
let control_key = gtk::EventControllerKey::new();
control_key.connect_key_pressed(move |_, key, _, _| {
match key {
gdk::Key::Right => { ... },
gdk::Key::Left => { ... },
gdk::Key::Up => { ... },
gdk::Key::Down => { ... },
_ => (),
}
glib::Propagation::Proceed
});
window.add_controller(control_key);
Alle Zutaten in einen Standmixer geben und solange zerkleinern bisam ein feines Pulver hat. Sobald die richtige Konsistenz erreicht ist, "fließt" der Parmesan nicht mehr richtig beim mixen und leicht klumpig wird.
After seeing how I put a child barrier together my daughter is obsessed with screws. She will try to turn any screw she can find, using any item barely resembling a screwdriver. Naturally, she got her own set of tools :).
As the set didn't include any screws I've decided to print some for her. The screws are compatible with the wrench and screwdriver of the "klein Bosch Work-Box". The holes of the block are loose enough to easily screw in the bolts.
I've used Blender to create these. For my first try I've created my own screw using the "Screw" modifier applied to a triangle. This worked okay, but the resulting screw was too loose and would just slip into the hole. For the next try I used the plugin "Bolt Factory" to create the screw part and only kept my previously designed head.
Things I've learned:
All files can be used under the CC-BY 4.0 License.