Support 0.5px borders with subpixels on high DPI devices |
|||||||||
Issue descriptionProblem: Native apps commonly have borders that are only 1 hardware pixel, and on a device with a 2.0 device pixel ratio, it would equal 0.5 CSS pixels. I'm told subpixels are supported all major browsers except Chrome (note I haven't verified), which makes supporting hairline pixels difficult, since Chrome sees border-width: 0.5px as invalid and doesn’t set a border at all. Proposal: If subpixels cannot be easily supported, can a pixel width of 0.5px be rounded up to 1px instead of being invalid? Assigning to reed for help triaging to the right person
,
Jun 28 2016
non-zero border widths are already rounded up to 1px, can confirm. owencm@: did you want to track a feature request for subpixel support or shall I close this?
,
Jun 28 2016
,
Oct 19 2016
Needs-Feedback and no reply for more than 2 weeks.
,
Oct 19 2016
Sorry for slow reply. Yes, I believe subpixel support is important for building high polish web apps on modern devices. This is a feature request to add support for 0.5px borders to be represented as a single pixel on high DPI devices.
,
Feb 12 2017
Style team needs to alter the data type for BorderValue widths to accommodate floating point values: https://cs.chromium.org/chromium/src/third_party/WebKit/Source/core/style/BorderValue.h?sq=package:chromium&dr&l=35
,
Mar 13 2017
Just for the record, floating point BorderValue width was landed in https://crrev.com/934becac5daa91ea979fb66e4ae21761ca11ebc9 The paint side of subpixel border has not been implemented, so currently, borders will always round to CSS pixels.
,
Mar 13 2017
,
Dec 6 2017
,
Feb 28 2018
|
|||||||||
►
Sign in to add a comment |
|||||||||
Comment 1 by timloh@chromium.org
, Jun 27 2016