New issue
Advanced search Search tips

Issue 742488 link

Starred by 2 users

Issue metadata

Status: Assigned
Owner:
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 2
Type: Bug



Sign in to add a comment

Print to PDF ignores SVG lines sometimes

Reported by o...@hindsiteinc.com, Jul 13 2017

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3071.115 Safari/537.36

Steps to reproduce the problem:
Try Print to PDF the following code:

<html>
<head>
</head>
  <body>
      <div style="width: 400px;transform:translate(310px, 436px); ">

        <svg width="400" height="1" style="margin-top:5px;" >
          <rect style="fill:#5C7C7B;" width="400" height="1"></rect>
        </svg>

        <svg width="400" height="1" style="margin-top:5px;" >
          <rect style="fill:#5C7C7B;" width="400" height="1"></rect>
        </svg>

      </div>
    </body>
</html>

What is the expected behavior?
Should see two lines in the PDF file

What went wrong?
PDF file is empty, screenshot attached

Did this work before? N/A 

Chrome version: 59.0.3071.115  Channel: stable
OS Version: OS X 10.11.6
Flash Version:
 
111.jpg
157 KB View Download
Components: Internals>Printing Blink>SVG
On Linux with Chrome 59, I see 1 line. With Chrome 61, I see 2. Will check Mac in a bit.
Components: -Internals>Printing Internals>Skia>PDF
Waiting on Mac info. I can't repro on linux with Version 60.0.3112.50 (Official Build) beta (64-bit)
Labels: BugSource-Chromium Needs-Feedback PaintTeamTriaged-20170713
NextAction: 2017-07-27
Got distracted... On Mac with Chrome 59 I get both lines.
Since I can consistently reproduce the 1 vs 2 lines issue in comment 1, I bisected and that came down to r468823.

Back on Mac, I can't reproduce with Chrome Canary either. This Mac is running 10.12 and does not have a hidpi monitor, if that makes any difference.
Attaching the test case as a file to verify on multiple machines.
cr742488.html
428 bytes View Download
Labels: -Needs-Feedback
NextAction: ----
Owner: schenney@chromium.org
Status: Assigned (was: Unconfirmed)
The outcome on an old M-56 install on Mac HighDPI depends on the page size and orientation, which makes me think this is a clipping issue that might be deliberate. That also explains why a minor change in the page size that goes with the blamed patch would cause the issue to come or go. M-59 has the same behavior.

I think this might be WontFix, but I'll look into it some more when I get some time to review.
Attaching another test file.
A lot of lines are missing in Mac\Windows Chrome 59, but works good on the desktop Chrome 61, however headless chrome 61 (linux) has about third of the lines missing. Is there any way to make headless chrome to produce the same results as the desktop version?
test.html
27.8 KB View Download

Sign in to add a comment