Closed Bug 1269108 Opened 8 years ago Closed 2 months ago

GTK3 padding added to author padding in buttons is too much

Categories

(Core :: Widget: Gtk, defect, P4)

46 Branch
defect

Tracking

()

RESOLVED WONTFIX

People

(Reporter: mozilla, Unassigned)

References

(Blocks 1 open bug)

Details

(Keywords: regression, Whiteboard: tpi:+)

Attachments

(1 file)

Attached image screenshot.jpg
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:46.0) Gecko/20100101 Firefox/46.0
Build ID: 20160421124000

Steps to reproduce:

I have just updated to Firefox 46, which is the first release I've used with gtk3 rather than gtk2. (I use XFCE, so most applications I use are gtk2.) On various pages, there are now errors in the layout that did not occur with gtk2. Most noticeably, the padding of form submission buttons (and other elements such as "select" combo boxes) is now too great. I have gtk-3.14 running on CentOS 7.2, but running Firefox downloaded directly from Mozilla. I use the default Adwaita theme that is built into gtk.


Actual results:

I have attached a screenshot showing the search box on Wikipedia. The two buttons should fit on the same line. Using the Inspector, the computed padding-left and padding-right is 5.73333px for these two buttons, yet the buttons as displayed clearly have more padding than this.
Blocks: gtk3
Component: Untriaged → Widget: Gtk
Product: Firefox → Core
I think ideally, HasAuthorSpecifiedRules(aFrame, NS_AUTHOR_SPECIFIED_PADDING)) should be used to only add GTK padding and return true from nsNativeThemeGTK::GetWidgetPadding() when there is no author-specified padding.
Blocks: 1260061
Status: UNCONFIRMED → NEW
Ever confirmed: true
Keywords: regression
Summary: Button padding incorrect in gtk 3.14 → GTK3 padding added to author padding in buttons is too much
Blocks: 1228281
No longer blocks: 1260061
See Also: → 1260061
Possibly a duplicate of 1236342?
Edit:

(In reply to Karl Tomlinson (ni?:karlt) from comment #1)
> I think ideally, HasAuthorSpecifiedRules(aFrame,
> NS_AUTHOR_SPECIFIED_PADDING)) should be used to only add GTK padding and
> return true from nsNativeThemeGTK::GetWidgetPadding() when there is no
> author-specified padding.

Isn't this already the case? In my linked report above on my testcase without adding a custom padding the left and right padding are shown as 6px in the Box Model of the Object Inspector. But if I add the attribute 'style="padding-left: 1px; padding-right: 1px;"' the left and right padding are successfully showing 1px and not 7px.
(In reply to sworddragon2 from comment #3)
> In my linked report above on my testcase
> without adding a custom padding the left and right padding are shown as 6px
> in the Box Model of the Object Inspector. But if I add the attribute
> 'style="padding-left: 1px; padding-right: 1px;"' the left and right padding
> are successfully showing 1px and not 7px.

The GTK padding may be in the border rather than the padding, in the object inspector, but I don't actually know whether the inspector sees the gtk padding and border or not.

(In reply to sworddragon2 from comment #2)
> Possibly a duplicate of 1236342?

This bug is about buttons with document author specified padding.
Bug 1236342 has a button without author padding.
Priority: -- → P4
Whiteboard: tpi:+
Severity: normal → S3

Non native widgets don't have this issue.

Status: NEW → RESOLVED
Closed: 2 months ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: