pdfbox-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pete swulius <pswul...@gmail.com>
Subject Replace String example only allows me to use the characters already in the string
Date Tue, 05 Jun 2012 18:46:59 GMT
I'm very new to PDF and PDFBox, so I'm wondering if it's expected
behavior.  This is not the common problem of finding your string broken up
across many objects.

In the original PDF, I'm looking for the string: message

I use the reset() and append(x) methods like the example, but the value I
pass in to append(x) seems to be interpreted and only the characters [m, e,
s, a, g] are successfully rendered in the generated PDF.

For instance, if I try to replace it with: foobars

The generated PDF displays the string: as

If I re-create the original PDF to contain the full alphabet in the string,
it works as expected. (ie: instead of "message", it is
"abcdefghijklmnopqrstuvwxyz" and the generated PDF displays "foobars" )


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