Gtk4 - gtk_widget_compute_bounds and gtk_widget_get_allocation give different result when CSS transform is applied

Hey, newbie here. I don’t know if this is a bug or expected but:

When using a widget with a transform: scale(2) applied on it, gtk_widget_compute_bounds and gtk_widget_get_allocation yield different results. The allocation has the original width as without any scale, whereas compute_bounds gives it with a factor of 2 multiplied.
This seems to be breaking functionality in ScrolledWindow’s and Viewports (probably at other places also), since after analysing the source code of gtkviewport.c, I gathered the reason why I can only see a portion of the zoomed in version, and the adjustments and scrollbars on the scrolled window don’t update.
Also, since get_allocation is supposed to be deprecated and replaced with compute_bounds, I think it’s important that they both yield the same values :slight_smile:
If this is a bug, please let me know and I can file a bug report (and maybe work on a fix).

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