<html>
<head>
<base href="https://bugs.freedesktop.org/" />
</head>
<body>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW --- - Add new PDFWriter class for writing PDF with printing options"
href="https://bugs.freedesktop.org/show_bug.cgi?id=71213#c31">Comment # 31</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW --- - Add new PDFWriter class for writing PDF with printing options"
href="https://bugs.freedesktop.org/show_bug.cgi?id=71213">bug 71213</a>
from <span class="vcard"><a class="email" href="mailto:mkasik@redhat.com" title="Marek Kasik <mkasik@redhat.com>"> <span class="fn">Marek Kasik</span></a>
</span></b>
<pre>(In reply to <a href="show_bug.cgi?id=71213#c19">comment #19</a>)
<span class="quote">> (In reply to <a href="show_bug.cgi?id=71213#c18">comment #18</a>)
> > for (int i = 0; i < (int)pages.size(); i++) {
> >- pageNum = pages[i];
> >+ pageNum = pages[i]->getNum();
> >+ doc = pages[i]->getDoc();
> > if (pageSet == ALL ||
> > (pageSet == ODD && outputPageNum % 2 == 1) ||
> > (pageSet == EVEN && outputPageNum % 2 == 0)) {
> > Object pageObj;
> > Ref *refPage = doc->getCatalog()->getPageRef(pageNum);
> > doc->getXRef()->fetch(refPage->num, refPage->gen, &pageObj);
> >- markPageObjects(pageObj.getDict(), numberUp > 1 ? gFalse : gTrue);
> >+ markPageObjects(doc, pageObj.getDict(), numberUp > 1 ? gFalse : gTrue);
> > if (fontEmbedRequired)
> >- replaceNonEmbeddedFonts(pageObj.getDict(), &pageObj, *refPage);
> >+ replaceNonEmbeddedFonts(doc, pageObj.getDict(), &pageObj, *refPage);
> > pageObj.free();
> > }
>
> I don't see how this works. The objects from each document will be mixed
> together and overwrite each other. All pages from each document need to be
> marked and written separately with an offset applied to the object numbering
> of each document to prevent the object numbers from clashing.</span >
I checked just order of pages, I forgot to look at individual streams.
<span class="quote">> I have already updated my patches to include multiple documents but am still
> reworking the font embedding patch. I wanted to get it all working before
> reposting but I'll go ahead and post what I already have working.</span >
Thank you.</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>