Page MenuHomePhabricator

Download as PDF: Font for <p> inside <td> is larger than expected
Open, LowPublic

Description

Steps to reproduce:

  1. Go to https://en.wikipedia.org/w/index.php?title=List_of_scientific_publications_by_Albert_Einstein&oldid=961085451
  2. Download as PDF.
  3. Search the document for "Antwort auf vorstehende" and "separate reprint".
  4. Compare font size of the PDF to the original HTML (it is bigger)
  5. Compare font size of the original HTML to the media print version of the HTML (also bigger)

Reported at:
en-wp Teahouse "Font size too large in downloaded pdf file" by user Brianmarkle.

Event Timeline

Aklapper renamed this task from (bug, minor) download as PDF - font for <p> inside <td> is larger than expected to Download as PDF: Font for <p> inside <td> is larger than expected.Jun 9 2020, 5:30 AM
Aklapper added a project: PDF-Rendering.
Mholloway added a project: Proton.
Mholloway subscribed.

Verified that this issue is still present after the recent Proton updates. I'll tag it with Proton for now, but I suspect that the cause is ultimately with styles coming in from elsewhere.

MSantos subscribed.

The problematic style comes from Vector print styles: https://gerrit.wikimedia.org/r/plugins/gitiles/mediawiki/skins/Vector/+/refs/heads/master/resources/skins.vector.styles/common/print.less#101

IMO the error should be fixed upstream or on the wiki page. I'll keep Proton but remove our team from it, please feel free to retag if needed.

Jdlrobson subscribed.

To make sure I understand this applies to paragraph tags within td cells?

To make sure I understand this applies to paragraph tags within td cells?

Exactly, and somehow references are getting this DOM structure and print style is affecting it.

TheDJ subscribed.

So applies to normal printing as well.

Screenshot 2020-08-06 at 15.15.04.png (782×604 px, 109 KB)