After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 760560 - Icon buttons wider in GTK+ 3.19.6
Icon buttons wider in GTK+ 3.19.6
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Themes
3.19.x
Other Linux
: Normal minor
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2016-01-13 02:53 UTC by Adam Williamson
Modified: 2016-03-05 01:53 UTC
See Also:
GNOME target: 3.20
GNOME version: ---


Attachments
screenshot showing both old, square (in virt-manager) and new, fat (in anaconda) icon buttons (102.07 KB, image/png)
2016-01-13 02:53 UTC, Adam Williamson
Details
button with image (1.69 KB, text/plain)
2016-02-14 21:32 UTC, Lukas
Details
but they're not square! (25.83 KB, image/png)
2016-03-02 18:15 UTC, Matthias Clasen
Details
how it looks in 3.18 (still not quite square, but smaller) (23.97 KB, image/png)
2016-03-02 18:16 UTC, Matthias Clasen
Details

Description Adam Williamson 2016-01-13 02:53:41 UTC
Created attachment 318930 [details]
screenshot showing both old, square (in virt-manager) and new, fat (in anaconda) icon buttons

I don't know if this is a bug or intentional, but it seems worth reporting. With GTK+ 3.19.6, buttons which have no text label but rather just an icon are wider than before. This is visible in several places, e.g. in virt-manager (the row of icons shown above the display of a running VM), and in anaconda (the + / - / 'refresh' buttons at the bottom of the left-hand pane in the custom partitioning screen).

In previous GTK+ releases the buttons were, I think, perfectly square; they now appear weirdly fat, to eyes used to the old appearance, and of course the extra width is basically wasted, it's just empty greyness.

I'm attaching a screenshot which shows virt-manager running under Fedora 22 (so using an older GTK+; you can see the buttons in virt-manager itself are square), with the VM showing the custom partitioning screen in today's Rawhide nightly installer; you can see the buttons in the installer are 'fat'.
Comment 1 Lapo Calamandrei 2016-01-13 12:06:09 UTC
Confirming it's not intentional, thanks for reporting.
Comment 2 Matthias Clasen 2016-02-13 22:15:15 UTC
How is this toolbar constructed ?
I just added an 'inline-toolbar' example to gtk3-widget-factory, and it shows up as expected (square image buttons).
Comment 3 Lapo Calamandrei 2016-02-13 23:59:49 UTC
Can you check (with the gtk+ inspector) which are the style classes of the wider buttons?
Comment 4 Lukas 2016-02-14 21:32:41 UTC
Created attachment 321160 [details]
button with image

In gtk 3.18 this rule applied to image buttons (gtk-contained.css:918):
.button.image-button, GtkScaleButton.button,
  GtkVolumeButton.button, .header-bar .titlebutton.button,
  .titlebar .titlebutton.button {
    padding: 8px; }

In master, only the unspecific button padding (padding: 4px 8px;) applies.

See glade file for test case.
Comment 5 Lapo Calamandrei 2016-02-14 22:13:01 UTC
Sizing is done differently now with min-height and min-width in the mix, what was done in 3.18 doesn't count much, those buttons may be wider for the wrong style classes applied or some construction I'm not considering in the theme.
Comment 6 Matthias Clasen 2016-02-28 03:20:53 UTC
If you need an example in GTK+, gtk3-demo CSS/Style Classes has an inline toolbar that is affected by this.
Comment 7 Lapo Calamandrei 2016-03-02 17:53:59 UTC
The gtk3-demo example looks good to me, even if the buttons in the inline-toolbar (incorrectly) sport both image-button and text-button styleclasses.
Comment 8 Matthias Clasen 2016-03-02 18:15:18 UTC
Created attachment 322898 [details]
but they're not square!
Comment 9 Matthias Clasen 2016-03-02 18:16:23 UTC
Created attachment 322900 [details]
how it looks in 3.18 (still not quite square, but smaller)
Comment 10 Lapo Calamandrei 2016-03-02 18:31:26 UTC
Right, buttons are not square there, I was looking at the wrong branch (...), this is caused by the text-button styleclass being there though.
Comment 11 Matthias Clasen 2016-03-04 02:50:09 UTC
removing the text-button style class doesn't change the size of those buttons
Comment 12 Lapo Calamandrei 2016-03-04 13:03:08 UTC
In the widget factory toolbar you'll havr to remove all of them to have the right size, no idea why, but it's totally not Adwaita related