I need this:
paint(void *data, int width, int height) where
data is in ARBG32 format and paint it to a
GtkWindow. I can’t decide when
paint will be called.
First try was to use a
GtkDrawingArea but it decides when to paint (that got into the way). I can also call
gtk_widget_queue_draw, but when it decides to paint itself I have nothing. Using the “old” buffer would not do it, because when It decides to paint the window layout probably changed.
In general, I inform the “toolkit” the layout changed and it upload pixels in the
The ideal (I think at the moment) is to have a layer positioned within the GtkWindow bounds and draw those pixels there.
This gives me some direction:
Custom widgets in GTK 4 – Drawing – GTK Development Blog.
But I still can’t formulate the “best” option.