mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-27 06:00:22 +00:00
widget: Don't do a 0-size check before snapshotting
Even widgets with an empty allocation may still want to draw stuff. Examples include shadows or child widgets with negative margins. Fixes GtkEntry's progressbar not showing up anymore.
This commit is contained in:
parent
8d8db89669
commit
e8fef1147f
@ -13336,8 +13336,7 @@ gtk_widget_create_render_node (GtkWidget *widget,
|
||||
|
||||
/* Offset to content allocation */
|
||||
gtk_snapshot_offset (snapshot, margin.left + padding.left + border.left, margin.top + border.top + padding.top);
|
||||
if (gtk_widget_get_width (widget) > 0 && gtk_widget_get_height (widget) > 0)
|
||||
klass->snapshot (widget, snapshot);
|
||||
klass->snapshot (widget, snapshot);
|
||||
gtk_snapshot_offset (snapshot, - (padding.left + border.left), -(border.top + padding.top));
|
||||
|
||||
gtk_css_style_snapshot_outline (style,
|
||||
|
Loading…
Reference in New Issue
Block a user