Resizing dialog to match fixed aspect ratio frame

Is there a way to get a signal in GTK4 when a dialog resizes and when the user ends a resize?
I’d like my dialog to ‘shrink wrap’ around my GtkAspectFrame (containing a GtkDrawingArea).
I was able to do this in GTK3 in a roundabout way using the focus-in-event, focus-out-event and size-allocate signals. (resize the dialog to the corect proportions when the user finishes the resize of the dialog)

Here, I’ve resized the dialog horizontally but, as you see, it doesn’t match the fixed aspect ratio frame.
Ideally, the dialog would be locked to the frame, so that it would change size with the restriction to maintain the frame aspect ratio.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.