zopyx / print-css-rocks

CSS Paged Media tutorial and review of tools (repository for print-css.rocks)
https://print-css.rocks
168 stars 29 forks source link

Test fixes #22

Closed faceless2 closed 2 years ago

faceless2 commented 2 years ago

Hi there - just running through your tests and I have a few comments:

lesson-cmyk

lesson-css-transformations

lesson-fonts-emoji

lesson-mathml-native

lesson-set-content

Great tests otherwise, lots of nasty corner cases for us to debug - thanks.

zopyx commented 2 years ago

lesson-css-transformations

  • you've got break-after: always, I think you want break-after: page

No, i want a break after each test section. Anway, the behavior is as expected.

zopyx commented 2 years ago

lesson-fonts-emoji

  • you're loading a @font-face with font-family: Emoji, but emoji is one of the generic font familes (Ref: https://www.w3.org/TR/css-fonts-4/#emoji-def) so this isn't going to work. To fix, either change it to "Emoji" (with quotes) both in the @font-face and the font-family, or pick literally almost any other word!

Good catch...fixed

zopyx commented 2 years ago
  • you need a <meta charset="utf-8">, there are some UTF8 sequences in the document and the default encoding for HTML is ISO8859-1. Same for the mathml torture test and lesson-right-to-left.

Thanks, fixed. I would assume that all renderers use utf8 by default

zopyx commented 2 years ago

The remaining issues need further investigations when I have more time

zopyx commented 2 years ago
  • the syntax from css-color-5 is (or will be) device-cmyk(c m y k). I think it's fairly widely supported now, whereas the cmyk(c,m,y,k) is common but has never been standardised. Ref: https://www.w3.org/TR/css-color-5/#device-cmyk (it was in color-4 but got bumped to color-5)

The CMYK test is clearly weak (because I don't know much about CYMK and don't know of any free tools for checking PDFs)

faceless2 commented 2 years ago

you've got break-after: always, I think you want break-after: page

The point I was making is that break-after: always is not valid CSS, so if you don't want the forced break you could just delete that rule. https://www.w3.org/TR/css-break-3/#break-between

zopyx commented 2 years ago

The point I was making is that break-after: always is not valid CSS, so if you don't want the forced break you could just delete that rule. https://www.w3.org/TR/css-break-3/#break-between

I replace all page-break-before|after with its modern variant

zopyx commented 2 years ago

I think all issues are now resolved and addressed