<html>
    <head>
      <base href="https://bugs.webkit.org/" />
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - Setting contentInset on a WKWebView's scroll view does not work for PDFs."
   href="https://bugs.webkit.org/show_bug.cgi?id=161875">161875</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Setting contentInset on a WKWebView's scroll view does not work for PDFs.
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>WebKit
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>WebKit Nightly Build
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>iOS
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>iOS 9.3
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>Normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P2
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>New Bugs
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>webkit-unassigned&#64;lists.webkit.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>gchatz&#64;chromium.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="attachment.cgi?id=288614" name="attach_288614" title="test app">attachment 288614</a> <a href="attachment.cgi?id=288614&amp;action=edit" title="test app">[details]</a></span>
test app

Summary:
If I set the top content inset on the scroll view of a WKWebView during the 
- webView:didFinishNavigation: callback, the content is pushed down at page load for regular webpages but not for PDFs. Instead, the PDF loads as scrolled to the top, and the user has to manually scroll it to make room for the inset.

Steps to Reproduce:
Run attached test app which does the following steps:
1. Loads a PDF in a WKWebView
2. Sets contentInset during the -webView:didFinishNavigation callback. 

Expected Results:
PDF loads scrolled down with enough room for the content inset (see screenshot.)

Actual Results:
PDF is scrolled to the top. (see screenshot)

Version:
Since at least iOS 9.0

Configuration:
iPhones and iPads</pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>