pdfbox-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Blake McBride <blake1...@gmail.com>
Subject Re: How to reset text on a new page?
Date Thu, 10 Mar 2016 14:50:17 GMT
Thanks, but getting a little confused here.  Let me ask this:

Each page in a document has its own PDPageContentStream _and_ PDPage.  This
means that there is a one-to-one relationship between PDPageContentStream's
and PDPage objects.  Is that (always) true?

Thanks.

Blake



On Wed, Mar 9, 2016 at 12:28 AM, Tilman Hausherr <THausherr@t-online.de>
wrote:

> You must create a new content stream object for each page. And of course
> also a new PDPage object too.
>
> Tilman
>
>
> Am 09.03.2016 um 04:31 schrieb Blake McBride:
>
>> Hi,
>>
>> I get that one starts text with contentStream.beginText() and ends text
>> with contentStream.endText().  And I get that one gets a new page with doc
>> .addPage(page).  But when I use all this to print two pages, I end up with
>> two pages each with the same text (the merge of the contents of the two
>> pages).  How can I clear the page contents for a new page?  (I didn't see
>> an example that printed two pages in the examples.)
>>
>> Thanks!
>>
>> Blake McBride
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
> For additional commands, e-mail: users-help@pdfbox.apache.org
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message