gecko-dev/layout/forms
Daniel Holbert f95dd888e1 Bug 1562057: Change size-contained & empty select elements to have the same inline-size. r=TYLin
Per the css-contain specification, size contained elements must be sized as if
they were empty. Up until now, we've been handling that by just using "0" as
the intrinsic size of some components, but that doesn't actually match the size
of a "true" empty select, which has some nonzero width from:
 (a) the default inline-axis padding on the display frame (added in a rule for
     the ::-moz-display-comboboxcontrol-frame pseudo, in forms.css).

 (b) the width (inline-size) of the display frame's "placeholder" space
     character, which has a small intrinsic width (but which really only exists
     for *block-axis* sizing and alignment, when no option is selected from
     the dropdown).

This patch addresses issue (a) by explicitly adding the display frame's
inline-axis padding to size-contained elements, and it addresses issue (b) by
changing to use a zero-width space character in empty select elements.

So: as of this patch, size-contained select elements are getting a little wider
(to address (a)), and empty select elements are also getting a little skinnier
(to address (b)), and they'll end up being the same width.

(I chose U+FEFF "zero-width non-breaking-space" since we were previously using
a non-breaking space character. I'm not sure if the non-breaking aspect matters,
but I figured I'd preserve that to be on the safe side.)

Differential Revision: https://phabricator.services.mozilla.com/D48791

--HG--
extra : moz-landing-system : lando
2019-10-12 16:11:54 +00:00
..
crashtests Bug 1510785 - Skip all XBL related tests when XBL is disabled. r=bzbarsky 2019-10-08 23:52:46 +00:00
test Bug 1582531 - Update fission annotations for skipped tests that are now passing succesfully, r=kmag 2019-09-27 14:25:10 +00:00
moz.build
nsButtonFrameRenderer.cpp Bug 1574493 - Part 3. Stop rounding rects/clips during display list building. r=jrmuizel 2019-09-14 16:17:04 +00:00
nsButtonFrameRenderer.h
nsCheckboxRadioFrame.cpp Bug 1544343 - part 2: Make factory methods take mozilla::PresShell instead of nsIPresShell r=emilio 2019-04-16 07:24:49 +00:00
nsCheckboxRadioFrame.h
nsColorControlFrame.cpp Bug 1544343 - part 2: Make factory methods take mozilla::PresShell instead of nsIPresShell r=emilio 2019-04-16 07:24:49 +00:00
nsColorControlFrame.h Bug 1544343 - part 2: Make factory methods take mozilla::PresShell instead of nsIPresShell r=emilio 2019-04-16 07:24:49 +00:00
nsComboboxControlFrame.cpp Bug 1562057: Change size-contained & empty select elements to have the same inline-size. r=TYLin 2019-10-12 16:11:54 +00:00
nsComboboxControlFrame.h Bug 1561794 - Do not crop display text of themed comboboxes due to padding. r=dbaron 2019-07-20 14:54:33 +00:00
nsDateTimeControlFrame.cpp Bug 1571250 - Convert flags passed to ReflowChild, FinishReflowChild, SyncFrameViewAfterReflow and from GetXULLayoutFlags / GetLayoutFlags into an enum class. r=TYLin 2019-08-08 19:48:19 +00:00
nsDateTimeControlFrame.h Bug 1567191 - Move datetime input widget attribute handling code to HTMLInputElement. r=smaug 2019-08-05 22:11:57 +02:00
nsFieldSetFrame.cpp Bug 1581467 - Use DisplayInside() / DisplayOutside() a bit more. r=mats 2019-10-07 12:27:27 +00:00
nsFieldSetFrame.h Bug 1566945 - Add a parameter to nsContainerFrame::InsertFrames for aPrevFrame's line box. r=dholbert 2019-07-17 23:34:45 +00:00
nsFileControlFrame.cpp Bug 1561322 - Allow spoofing strings in HTML forms r=baku,Pike 2019-07-24 13:22:22 +00:00
nsFileControlFrame.h
nsGfxButtonControlFrame.cpp Bug 1561322 - Allow spoofing strings in HTML forms r=baku,Pike 2019-07-24 13:22:22 +00:00
nsGfxButtonControlFrame.h
nsHTMLButtonControlFrame.cpp Bug 1571250 - Convert flags passed to ReflowChild, FinishReflowChild, SyncFrameViewAfterReflow and from GetXULLayoutFlags / GetLayoutFlags into an enum class. r=TYLin 2019-08-08 19:48:19 +00:00
nsHTMLButtonControlFrame.h Bug 1566945 - Add a parameter to nsContainerFrame::InsertFrames for aPrevFrame's line box. r=dholbert 2019-07-17 23:34:45 +00:00
nsIFormControlFrame.h
nsImageControlFrame.cpp Bug 1259660 - Moved mozilla::WidgetMosueEventBase::buttonType in MouseEvents.h to mozilla::MouseButton in EventForwards.h, and mozilla::WidgetMouseEventBase::buttonsFlag to mozilla::MouseButtonsFlag r=masayuki 2019-04-21 20:13:34 +00:00
nsISelectControlFrame.h
nsITextControlFrame.h
nsLegendFrame.cpp Bug 1544343 - part 2: Make factory methods take mozilla::PresShell instead of nsIPresShell r=emilio 2019-04-16 07:24:49 +00:00
nsLegendFrame.h
nsListControlFrame.cpp Bug 1488828: For collapsed select controls in the content process, set the number of rows to the maximum instead of 1. r=dholbert 2019-09-13 03:59:51 +00:00
nsListControlFrame.h Bug 1543315 - part 15: Mark PresShell::ScrollFrameRectIntoView() as MOZ_CAN_RUN_SCRIPT r=smaug 2019-05-06 13:57:46 +00:00
nsMeterFrame.cpp Bug 1571250 - Convert flags passed to ReflowChild, FinishReflowChild, SyncFrameViewAfterReflow and from GetXULLayoutFlags / GetLayoutFlags into an enum class. r=TYLin 2019-08-08 19:48:19 +00:00
nsMeterFrame.h
nsNumberControlFrame.cpp Bug 1585216 - Propagate the inner text field's baseline as the baseline for a number input. r=dholbert 2019-10-10 20:45:32 +00:00
nsNumberControlFrame.h Bug 1585216 - Propagate the inner text field's baseline as the baseline for a number input. r=dholbert 2019-10-10 20:45:32 +00:00
nsProgressFrame.cpp Bug 1571250 - Convert flags passed to ReflowChild, FinishReflowChild, SyncFrameViewAfterReflow and from GetXULLayoutFlags / GetLayoutFlags into an enum class. r=TYLin 2019-08-08 19:48:19 +00:00
nsProgressFrame.h
nsRangeFrame.cpp Bug 1571250 - Convert flags passed to ReflowChild, FinishReflowChild, SyncFrameViewAfterReflow and from GetXULLayoutFlags / GetLayoutFlags into an enum class. r=TYLin 2019-08-08 19:48:19 +00:00
nsRangeFrame.h Bug 1544343 - part 2: Make factory methods take mozilla::PresShell instead of nsIPresShell r=emilio 2019-04-16 07:24:49 +00:00
nsSelectsAreaFrame.cpp Bug 1549751 - Part 2: Add nsPaintedDisplayItem r=mattwoodrow 2019-05-08 13:49:56 +00:00
nsSelectsAreaFrame.h Bug 1544343 - part 2: Make factory methods take mozilla::PresShell instead of nsIPresShell r=emilio 2019-04-16 07:24:49 +00:00
nsTextControlFrame.cpp Bug 1571250 - Convert flags passed to ReflowChild, FinishReflowChild, SyncFrameViewAfterReflow and from GetXULLayoutFlags / GetLayoutFlags into an enum class. r=TYLin 2019-08-08 19:48:19 +00:00
nsTextControlFrame.h Bug 1548389 - part 3: Make editor mark text node in password field as "maybe masked" r=smaug 2019-07-22 03:54:16 +00:00