As my girlfriend spent the easter weekend with her family I had time to spend some time with coding again. As I wanted to learn GTK for some time now I figured now is the time. My first attempts were trying to build a window with a menu, interacting with mouseclicks and using some other widgets. The code I came up is not really useful yet but let’s follow the release early, release often principle.
What works: Loading via filebrowser, displaying the opened image, resizing while preserving the aspect ration, getting mouseclicks in pixel position and in percentage of the image to get the same click position on the image regardless of the scaling factor and drawing on the image with cairo.
The other code is a gtk3-ified version of some of my earlier code published here.
What works: Getting live input from the serial port, displaying a matplotlib widget inside the gtk3 window with multiple plots, running the graph update inside a separate thread to keep the gui responsive.
You can find the code here: