<html>
    <head>
      <base href="https://bugs.freedesktop.org/" />
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Priority</th>
          <td>medium
          </td>
        </tr>

        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW --- - Incorrect positioning of text in PDFTOHTML"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=56293">56293</a>
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>poppler-bugs@lists.freedesktop.org
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Incorrect positioning of text in PDFTOHTML
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

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

        <tr>
          <th>OS</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>erik.engstroem@gmail.com
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>Other
          </td>
        </tr>

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

        <tr>
          <th>Version</th>
          <td>unspecified
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>pdftohtml
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>poppler
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="attachment.cgi?id=68923" name="attach_68923" title="pdf file inhibiting this behavior">attachment 68923</a> <a href="attachment.cgi?id=68923&action=edit" title="pdf file inhibiting this behavior">[details]</a></span>
pdf file inhibiting this behavior

PDFTOHTML converts text positions on certain PDF documents incorrect. Attached
is a document in which this happens. 

The following logic explains this further:
The size of an image of the first page is 1024x1408. The text "Brief article"
which can be seen highlighted should be positioned 19% from the top as seen
here:
<a href="http://imageshack.us/a/img526/6343/textshiftedpdf1.png">http://imageshack.us/a/img526/6343/textshiftedpdf1.png</a>

Poppler outputs this text with the following data when using pdftohtml -xml
<text top="409" left="447" width="80" height="15" font="0">Brief article</text>

The dimensions of this page according to poppler taken from the same xml file:
<page number="1" position="absolute" top="0" left="0" height="1488"
width="1063">

This would give us that the text should be according to poppler be positioned:
409/1488=0.27=27% which is clearly wrong. 

No other warning messages or errors were noted when converting this document</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>