Skip to content
Snippets Groups Projects
user avatar
Daniel Holbert authored
Bug 1823516: Adjust text-input-block-size.optional.html to use Ahem with a nice font-size, for predictable whole-number baselines and sizing. r=ntim

Before this patch, Firefox fails this test's expectations on Linux, with a 1px
sizing discrepancy between the input element in a vertical writing-mode
vs. horizontal.

That discrepancy is almost certainly due to the difference in baselines
(central vs. ideographic) in vertical vs. horizontal writing-modes, and the
fact that pixel-snapping that baseline might produce a +/-1px difference in
block-position and block-size of the line, inside the form-field.

This patch changes the test to use the Ahem font with a font-size of 30px,
which should have a whole-pixel-valued central as well as ideographic baseline;
so no pixel-snapping should be necessary, and the input element's size should
be be consistent, just as the test expects it to be.

This patch also makes one non-functional change, to explicitly declare the
charset as UTF-8, per WPT best-practices from
http://web-platform-tests.org/writing-tests/general-guidelines.html#character-encoding

Differential Revision: https://phabricator.services.mozilla.com/D173191
d43f206a
History
An explanation of the Firefox Source Code Directory Structure and links to
project pages with documentation can be found at:

    https://firefox-source-docs.mozilla.org/contributing/directory_structure.html

For information on how to build Firefox from the source code and create the patch see:

    https://firefox-source-docs.mozilla.org/contributing/contribution_quickref.html

If you have a question about developing Firefox, and can't find the solution
on https://firefox-source-docs.mozilla.org/, you can try asking your question on Matrix at chat.mozilla.org in `Introduction` (https://chat.mozilla.org/#/room/#introduction:mozilla.org) channel.


Nightly development builds can be downloaded from:

    https://archive.mozilla.org/pub/firefox/nightly/latest-mozilla-central/
            - or -
    https://www.mozilla.org/firefox/channel/desktop/#nightly

Keep in mind that nightly builds, which are used by Firefox developers for
testing, may be buggy.