New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rehabilitated 4 border-image tests and created 4 reference files #23808
Rehabilitated 4 border-image tests and created 4 reference files #23808
Conversation
They weren't removed intentionally; they were simply never added! 35f109a is the commit that added the test originally and notably neither in that commit nor any other commit were the images added. I presume this was simply just a mistake when they were moved into the CSS testsuite. Their omission was #10808, so this at least partly fixes that issue. |
div | ||
{ | ||
border: 40px double red; | ||
border-image-slice: 40% 15% 20% 5%; | ||
border-image-source: url("../support/9grid40-30-20-10-red.png"); | ||
border-image-source: url("support/9grid40-30-20-10-red.png"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So, I know this is not you fault but the fault of the original author... but this image is too simple to actually check for the proper condition. If the UA only slices off the first 1px off each side, it will still render correctly. We need an image that doesn't only detect when the UA slices too much, but also if it slices off too little.
My suggestion here is to use a skewed "striped border": design the image so that once it is sliced and squished into the border, it creates an evenly striped border. Since the numbers here are all divisible by a factor of 5, then 5 even stripes on each side would work well. The image will be uneven from side to side, but once it is squished into the border it will be even all the way around.
If there are stripes missing in the test, then we know the UA sliced too little of the image. If there is red in the test, then it sliced too much. It has to slice exactly the right amount.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fantasai, I need more time to carefully read your comment. Right now, I do not know what "skewed 'striped border'", "evenly striped border" and what "squished" mean.
"skewed striped border" == "bordure rayée asymétrique"
"evenly striped border" == "bordure uniformément rayée"
"squished" == "écrasé"
but I do understand that the test would be ideal (at least, more challenging) if an image was designed in a way that display failures if the UA slices too much or slices too little.
and 1 PR (PR25825) for |
Here's how the border-image-slice-00[5|7] tests look with the skewed striped border, evenly striped border and squishing ideas: http://www.gtalbot.org/BrowserBugsSection/CSS3Backgrounds/border-image-slice-005-newer-GT.html http://www.gtalbot.org/BrowserBugsSection/CSS3Backgrounds/border-image-slice-007-newer-GT.html When the slicing is 20px or 10px, then fuzzy anti-aliased pixels appear with the 3 browsers (Firefox 68.12.0 ESR, Chromium 83.0.4103.116 and Epiphany 3.32.1.2 using WebKitGTK+ 2.28.4) that I checked. When the slicing is 40px or 30px, then there is no fuzzy anti-aliased pixels appearing with the same 3 browsers. So, one idea to try to overcome this problem would be to create a new border-image-source which would be a rescaled version of the 100px by 100px border-image-source to become a 300px by 300px border-image-source which would maintain the alternation of stripes (3 filled blue stripes interleaving 2 transparent stripes) typical of the original border-image-source. |
No fuzzy anti-alias pixels appears now in the following tests, as far as I can see in the 3 tested browsers... although it must be said that the 2 border-image-source now have a filesize of 709 kilo-bytes and 711 kilo-bytes. http://www.gtalbot.org/BrowserBugsSection/CSS3Backgrounds/border-image-slice-005-newest2-GT.html http://www.gtalbot.org/BrowserBugsSection/CSS3Backgrounds/border-image-slice-007-newest2-GT.html [Edit september 28th] |
Okay. I will close this PR. Then I will create another PR (PR25825) which will contain: |
Closing this PR. New PR for border-image-slice-00[ 5 | 7] is |
border-image-shorthand-002.htm
border-image-shorthand-003.htm
border-image-slice-005.htm
border-image-slice-007.htm
reference/border-image-shorthand-002-ref.html
reference/border-image-shorthand-003-ref.html
reference/border-image-slice-005-ref.html
reference/border-image-slice-007-ref.html
support/9grid40-30-20-10-red.png
support/9grid40-30-20-10-lime.png
These 4 tests are originally from Microsoft.
Presumably the 9grid40-30-20-10-red.png and
9grid40-30-20-10-lime.png images were removed
intentionally. I have recreated, customized them
to make sense inside the tests.