[ 
https://issues.apache.org/jira/browse/PDFBOX-1794?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13847765#comment-13847765
 ] 

Tilman Hausherr commented on PDFBOX-1794:
-----------------------------------------

I wanted to find out why there's a push without a pop. Excerpt of the PDF:
{code}
stream
277 0 72 0 216 720 d1
q
144 0 0 720 72 0 cm
BI
/W 12
/H 60
/BPC 1
/IM true
ID...........................EI
Q
endstream
{code}
q is push, Q is a pop. The Q is never read, because the section of 
PDFStreamParser that handles inline images (at  case 'I') expects a newline 
before the "EI", and therefore it goes till  the EOF of the stream. There's a 
comment that mentions that "the PDF spec is kinda unclear about this" - indeed. 
The comment also mentions a file UnderstandingWebSphereClassLoaders.pdf, 
however I can't get it. Anyway, I removed the
{code}
isSpaceOrReturn(twoBytesAgo)
{code}
part and now the Q is handled. The file of PDFBOX-1561 (mentioned in a comment) 
seems to work properly too, i.e. it doesn't crash.

The two "unread the EI operator" lines could be deleted as well, because the EI 
operator isn't handled anyway.

> Rendering Problem with Type 3 Fonts 
> ------------------------------------
>
>                 Key: PDFBOX-1794
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-1794
>             Project: PDFBox
>          Issue Type: Bug
>    Affects Versions: 1.8.3, 2.0.0
>         Environment: W7, XP
>            Reporter: Tilman Hausherr
>              Labels: type3
>         Attachments: PDFBOX-1794-vattenfall.pdf, 
> PDFBOX-1794-vattenfall.pdf-1.png, PDFBOX-1794-vattenfall.pdf-1.png
>
>
> The attached file does not render correctly.
> (This is the same problem mentioned in PDFBOX-1773, but this time its not 
> from my employer. I was able to find a tool (qpdf) to create an uncompressed 
> PDF file and this way to remove my customer#)



--
This message was sent by Atlassian JIRA
(v6.1.4#6159)

Reply via email to