Restore PDF/UA conformance after flattening the form

2022-02-16 Thread Kirsche, Ben
Hello everybody, I would like to ensure that a pre-existing PDF/UA document is still conformant after flattening its form. The issue is that the added text elements which are displaying the text fields contents are not marked accordingly. My current approach is to read all PDFormXObject parse

Re: Flattening does not affect widgets not linked to a field

2021-12-23 Thread Constantine Dokolas
ixup) > > BR > Maruan > > Am Donnerstag, dem 23.12.2021 um 15:52 +0200 schrieb Constantine > Dokolas: > > I need to make sure I understand how flattening is supposed to > > operate. > > > > I have a PDF that, as far as I can tell, was an AcroForm that &g

Re: Flattening does not affect widgets not linked to a field

2021-12-23 Thread sahy...@fileaffairs.de
existing widget annotations. PDDocumentCatalog.getAcroForm(PDDocumentFixup) BR Maruan Am Donnerstag, dem 23.12.2021 um 15:52 +0200 schrieb Constantine Dokolas: > I need to make sure I understand how flattening is supposed to > operate. > > I have a PDF that, as far as I can tell, was

Flattening does not affect widgets not linked to a field

2021-12-23 Thread Constantine Dokolas
I need to make sure I understand how flattening is supposed to operate. I have a PDF that, as far as I can tell, was an AcroForm that underwent some sort of partial flattening. What I see when opening it with the debugger, is a normal AcroForm object but without any fields. Instead, the widget

Re: Fwd: flattening

2021-08-11 Thread Tilman Hausherr
samples to showcase the flattening problem. As one can see, flattening did not remove the fields. One can see that the field names are stil there. The Flattening of the fields did not work. Expected Results I expected all fields, that were read only to be removed. Itext 2.1.7 does exactly that

RE: Fwd: flattening

2021-08-10 Thread Jason Pyeron
> From: Ranjeet Kuruvilla > Sent: Wednesday, June 23, 2021 7:14 AM > > Here is the code. > Can you post the test pdf files on github or similar? > > I finally manage to send samples to showcase the flattening problem. > > As one can see, flattening did not remove t

Re: Flattening Part 1

2021-06-27 Thread Tilman Hausherr
here's some code that fixes your PDF until we manage to fix the bug: for (PDField field : acroForm.getFieldTree()) {     if (!(field instanceof PDTerminalField))     {     continue;     }     PDTerminalField terminalField = (PDTerminalField) field;     List widgets = terminalField.getWidgets

Re: Flattening Part 1

2021-06-26 Thread Tilman Hausherr
Am 26.06.2021 um 08:08 schrieb Ranjeet Kuruvilla: Thanks for the reply. I am aware that the release just happened, but if the next one comes in the next months, that is fine by me. I've created https://issues.apache.org/jira/browse/PDFBOX-5225 . Feel free to comment. Tilman ---

Re: Flattening Part 1

2021-06-25 Thread Ranjeet Kuruvilla
Hey. Thanks for the reply. I am aware that the release just happened, but if the next one comes in the next months, that is fine by me. Cheers. On 26.06.21 06:05, Tilman Hausherr wrote: > Hi, > > In the meantime, another solution could be to fix this PDF. Some > fields have widgets that are not

Re: Flattening Part 1

2021-06-25 Thread Tilman Hausherr
Hi, In the meantime, another solution could be to fix this PDF. Some fields have widgets that are not connected to a page. These widgets should be removed or corrected. Maybe this is the result of another tool that ran over these PDFs? Tilman Am 26.06.2021 um 05:30 schrieb Ranjeet Kuruvilla

Re: Flattening Part 1

2021-06-25 Thread Tilman Hausherr
Am 26.06.2021 um 05:30 schrieb Ranjeet Kuruvilla: I am glad you agree. May I ask when a fix can be expected? I fathom this to be a major issue relevant to others as well. We usually do releases every 3-4 months and just had a release. We release snapshot builds when a bug is fixed. It is 5 am

Re: Flattening Part 1

2021-06-25 Thread Tilman Hausherr
I think I understand the problem: The code from buildPagesWidgetsMap that is run when there are widgets with missing page references does not consider the field list. So all widgets end up in the map instead of only those we care about. Tilman Am 26.06.2021 um 05:15 schrieb Tilman Hausherr:

Re: Flattening Part 1

2021-06-25 Thread Ranjeet Kuruvilla
I am glad you agree. May I ask when a fix can be expected? I fathom this to be a major issue relevant to others as well. On 26.06.21 05:15, Tilman Hausherr wrote: > I can reproduce the problem also with this code, where only a single > field is flattened: > >     PDAcroForm acroForm = doc.getD

Re: Flattening Part 1

2021-06-25 Thread Tilman Hausherr
I can reproduce the problem also with this code, where only a single field is flattened:     PDAcroForm acroForm = doc.getDocumentCatalog().getAcroForm();     List list = new ArrayList<>();     list.add(acroForm.getField("VN_NAME"));     acroForm.flatten(list, true); All annotat

Re: Flattening Part 1

2021-06-25 Thread Tilman Hausherr
I don't have Acrobat 5 but I did find a problem using the code you suggested: ALL page widget annotations are gone, instead of only those that were flattened. For example VP_TELEFON_FREIW is not readonly and it is still in the field list but missing from the page. The OK file does not bring

Re: Flattening Part 1

2021-06-24 Thread Tilman Hausherr
Am 24.06.2021 um 10:44 schrieb ranjeet.kuruvilla: I tried with 2.0.24. The fields are still there. SourceFailure is the important one. I did the same now with 2.0.24 (but with my short code) and the fields are gone. I assume you tested your 500 lines code. Please test my short code too. If

Re: Flattening Part 1

2021-06-24 Thread ranjeet.kuruvilla
I tried with 2.0.24. The fields are still there. SourceFailure is the important one. Original message From: Tilman Hausherr Date: 6/24/21 08:46 (GMT+01:00) To: users@pdfbox.apache.org Subject: Re: Flattening Part 1 Am 24.06.2021 um 08:03 schrieb Ranjeet Kuruvilla:> Wai

Re: Flattening Part 1

2021-06-23 Thread Tilman Hausherr
Am 24.06.2021 um 08:03 schrieb Ranjeet Kuruvilla: Wait a minute: Did you save it to file or did you transform it into byte[]. I can not save it into a file! I saved it into a file: doc.save(new File("X","SourceFailure-saved.pdf")); Tilman On 24.06.21 05:52, Ranjeet Kuruvilla wrote:

Re: Flattening Part 1

2021-06-23 Thread Ranjeet Kuruvilla
Wait a minute: Did you save it to file or did you transform it into byte[]. I can not save it into a file! On 24.06.21 05:52, Ranjeet Kuruvilla wrote: > I was aware of that. I prepared an example jar and a project, but that > project was larger than 1MB and so I was unable to send it! > > > Thank

Re: Flattening Part 1

2021-06-23 Thread Ranjeet Kuruvilla
I was aware of that. I prepared an example jar and a project, but that project was larger than 1MB and so I was unable to send it! Thank you for the help. I will try it out. On 24.06.21 05:50, Tilman Hausherr wrote: > I tried this code on the 3.0 version on the SourceFailure.pdf file. > >   

Re: Flattening Part 1

2021-06-23 Thread Tilman Hausherr
I tried this code on the 3.0 version on the SourceFailure.pdf file.     PDAcroForm acroForm = doc.getDocumentCatalog().getAcroForm();     List list = new ArrayList<>();     for (PDField field : acroForm.getFieldTree())     {     list.add(field);     }     acroForm.

Fwd: Fwd: flattening

2021-06-23 Thread Ranjeet Kuruvilla
Here is the code. Forwarded Message Subject:Fwd: flattening Date: Wed, 23 Jun 2021 13:12:18 +0200 From: Ranjeet Kuruvilla To: users@pdfbox.apache.org I finally manage to send samples to showcase the flattening problem. As one can see, flattening did not

Re: flattening

2021-05-26 Thread sahy...@fileaffairs.de
#x27;ve tested with the result is fine. BR Maruan > > In PdfBox every field is flattened, even though I delivered a list of > fields, that were meant to be flattened. > > It seems the PDF is destroyed by flattening. > > I have attached the code. > > On 25.05.2

Re: flattening

2021-05-25 Thread Tilman Hausherr
Hello, Please tell what PDFBox version you're using and create a MINIMAL reproducer. Your current code does not flatten at all (because flatten is commented out), and uses an external class do do something that isn't related to flattening. Your reproducer should just load the fi

Re: flattening

2021-05-25 Thread Ranjeet Kuruvilla
flattening. I have attached the code. On 25.05.21 19:27, Tilman Hausherr wrote: > Here's a PDF flattened by itext > https://github.com/itext/i7js-examples/blob/develop/cmpfiles/sandbox/acroforms/cmp_checkbox_flatten.pdf > > and they do something similar to what we do, i.e. remove

Re: flattening

2021-05-25 Thread Tilman Hausherr
sahy...@fileaffairs.de: Am Dienstag, dem 25.05.2021 um 18:33 +0200 schrieb Ranjeet Kuruvilla: Hallo. It is clear, that flattening does have a bug. Compare flattening of PDFBox with IText and you realize, that PDFBox destroys all fields, once I call acroform.flatten(fields, true) or acroform.flatten(fields,

Re: flattening

2021-05-25 Thread Tilman Hausherr
njeet Kuruvilla: Hallo. It is clear, that flattening does have a bug. Compare flattening of PDFBox with IText and you realize, that PDFBox destroys all fields, once I call acroform.flatten(fields, true) or acroform.flatten(fields, false) . How can I request someone to fix flattening and make it work

Re: flattening

2021-05-25 Thread sahy...@fileaffairs.de
Am Dienstag, dem 25.05.2021 um 18:33 +0200 schrieb Ranjeet Kuruvilla: > Hallo. > It is clear, that flattening does have a bug. Compare flattening of > PDFBox with IText and you realize, that PDFBox destroys all fields, > once > I call > > acroform.flatten(fields, true

flattening

2021-05-25 Thread Ranjeet Kuruvilla
Hallo. It is clear, that flattening does have a bug. Compare flattening of PDFBox with IText and you realize, that PDFBox destroys all fields, once I call acroform.flatten(fields, true) or acroform.flatten(fields, false) . How can I request someone to fix flattening and make it work like in

Re: PDF form flattening

2020-02-24 Thread Dick Martin
; > Just to be sure, I've also downloaded: > > - PDFpen 11.2.1 > > - PDFelement Version 7.5.9.2925.5262(20200214) > > > > and the issue is only reproducible in macOS' Preview. > > > > All the other PDF viewers treat the flattened PDF document as f

Re: PDF form flattening

2020-02-23 Thread Aleksandar Simic
On Sun, Feb 23, 2020 at 2:26 PM Thad Humphries wrote: > > Is this bug report posted somewhere that others may look and comment on it? > Others at my company have a history with Apple's PDFKit and other topics. > I'd like to point them to this issue. > Hello Thad this is the URL to the bug repor

Re: PDF form flattening

2020-02-23 Thread Thad Humphries
Aleksandar, Is this bug report posted somewhere that others may look and comment on it? Others at my company have a history with Apple's PDFKit and other topics. I'd like to point them to this issue. Thank you. On Sun, Feb 23, 2020 at 6:34 AM Aleksandar Simic wrote: > On Sun, Feb 23, 2020 at 1

Re: PDF form flattening

2020-02-23 Thread Aleksandar Simic
On Sun, Feb 23, 2020 at 11:04 AM Tilman Hausherr wrote: > Am 23.02.2020 um 11:50 schrieb Aleksandar Simic: > > > Should this issue be raised somewhere? (With Apple maybe?) > > Yes, please submit the file to apple. > Done. I've also included the link to this discussion in the bug report. Thank

Re: PDF form flattening

2020-02-23 Thread Tilman Hausherr
e issue is only reproducible in macOS' Preview. All the other PDF viewers treat the flattened PDF document as flat, where you can't check the checkboxes after flattening. Should this issue be raised somewhere? (With Apple maybe?) Yes, please submit the file to apple. Ask them if there is anyt

Re: PDF form flattening

2020-02-23 Thread Aleksandar Simic
he other PDF viewers treat the flattened PDF document as flat, where you can't check the checkboxes after flattening. Should this issue be raised somewhere? (With Apple maybe?) Does it need to be documented somewhere, like in the FAQ, so that others don't stumble on it? Because I implemen

Re: PDF form flattening

2020-02-22 Thread Thad Humphries
I'll take some of that back--I can add new checkboxes, but I can't remove checks placed before flattening. On Sat, Feb 22, 2020 at 3:28 PM Thad Humphries wrote: > I am seeing the same behavior that Dick is seeing with Tillman's file in > Preview (Version 10.1 (944.6.16.1))

Re: PDF form flattening

2020-02-22 Thread Thad Humphries
macOS' Preview PDF viewer, I can still check the > > checkboxes. > > > But *not* in Adobe's Acrobat Reader DC version 2020.006.20034. > > > > > > The upgraded the Clojure project and the behaviour is the same: > > > - I can check the checkboxe

Re: PDF form flattening

2020-02-22 Thread Dick Martin
is the same: > > - I can check the checkboxes in Preview > > - I can't check the checkboxes in Acrobat Reader DC > > > > What PDF viewer did you use to verify the flattening ? > > > Adobe Reader DC. > > Here's my result file: > > http://www.filedropp

Re: PDF form flattening

2020-02-22 Thread Tilman Hausherr
graded the Clojure project and the behaviour is the same: - I can check the checkboxes in Preview - I can't check the checkboxes in Acrobat Reader DC What PDF viewer did you use to verify the flattening ? Adobe Reader DC. Here's my result file: http://www.filedropper.com/interactiveform-

Re: PDF form flattening

2020-02-22 Thread Aleksandar Simic
ur is the same: - I can check the checkboxes in Preview - I can't check the checkboxes in Acrobat Reader DC What PDF viewer did you use to verify the flattening ? Btw using getFields() is not correct (see javadoc why) > Looking at: https://pdfbox.apache.org/docs/2.0.13/javadocs/org/apache

Re: PDF form flattening

2020-02-22 Thread Tilman Hausherr
Hi, What PDFBox version are you using? I tested it with the trunk and it works fine.     PDDocument doc = Loader.loadPDF(new File("XXX", "interactiveform.pdf"));     PDAcroForm acroForm = doc.getDocumentCatalog().getAcroForm();     for (PDField field : acroForm.getFields())   

PDF form flattening

2020-02-22 Thread Aleksandar Simic
Hello PDFBox users I'm trying to flatten a PDF form so that it's no longer editable. I can flatten the text fields, but the checkboxes are still editable (you're able to check them). I am doing this in Clojure, but that should not (I hope) do anything special I get a PDF, get its forms and then

Re: flattening text in PDPageContentStream

2019-05-31 Thread chitgoks
ok. for extra layer, would that be the Overlay class? it looks limited. maybe doing vector graphics , i will try. im trying to avoid annotations since im also doing annotations separately and i do not want that to appear in the annotations list since it will be just a watermark On Fri, May 31, 20

Re: flattening text in PDPageContentStream

2019-05-31 Thread Maruan Sahyoun
Using that approach the text will be selectable and as it's part of the regular content stream that's not easy to change. Potential options (just running some ideas - havn't tested these): - use a vector graphics as Tilman suggested - use an annotation and try to get that protected - put the water

Re: flattening text in PDPageContentStream

2019-05-30 Thread chitgoks
hi maruan. Yes everything should stay as is. I only wish to add a watermark text to every page and watermark page should not be selectable. so using PDPageContentStream currently, this is what i got. On Fri, May 31, 2019 at 2:10 PM Maruan Sahyoun wrote: > shall the regular text of the PDF still

Re: flattening text in PDPageContentStream

2019-05-30 Thread Tilman Hausherr
Am 31.05.2019 um 07:31 schrieb chitgoks: so i show some text in PDPageContentStream using showText() but these are selectable. is there a way to make these not selectable? like they're drawn in the page itself? anyone got ideas? You could add it as a vector graphic. I did this for the text anno

Re: flattening text in PDPageContentStream

2019-05-30 Thread Maruan Sahyoun
shall the regular text of the PDF still be selectable? > no. sorry. watermark as part of the page. instead of using images, i want > to use text as watermarks. > > On Fri, May 31, 2019 at 1:53 PM Maruan Sahyoun > wrote: > > > as part of an annotation? > > > > > Am 31.05.2019 um 07:47 schrieb

Re: flattening text in PDPageContentStream

2019-05-30 Thread chitgoks
no. sorry. watermark as part of the page. instead of using images, i want to use text as watermarks. On Fri, May 31, 2019 at 1:53 PM Maruan Sahyoun wrote: > as part of an annotation? > > > Am 31.05.2019 um 07:47 schrieb chitgoks : > > > > im creating watermark text. should i be using something d

Re: flattening text in PDPageContentStream

2019-05-30 Thread Maruan Sahyoun
as part of an annotation? > Am 31.05.2019 um 07:47 schrieb chitgoks : > > im creating watermark text. should i be using something different? > > On Fri, May 31, 2019 at 1:41 PM Maruan Sahyoun > wrote: > >> text at a page level is normally selectable - why do you want to prevent >> that? >> >>

Re: flattening text in PDPageContentStream

2019-05-30 Thread chitgoks
im creating watermark text. should i be using something different? On Fri, May 31, 2019 at 1:41 PM Maruan Sahyoun wrote: > text at a page level is normally selectable - why do you want to prevent > that? > > Or is that content stream part of a AcroForm field? > > BR > Maruan > > > Am 31.05.2019

Re: flattening text in PDPageContentStream

2019-05-30 Thread Maruan Sahyoun
text at a page level is normally selectable - why do you want to prevent that? Or is that content stream part of a AcroForm field? BR Maruan > Am 31.05.2019 um 07:31 schrieb chitgoks : > > so i show some text in PDPageContentStream using showText() but these are > selectable. > is there a way

flattening text in PDPageContentStream

2019-05-30 Thread chitgoks
so i show some text in PDPageContentStream using showText() but these are selectable. is there a way to make these not selectable? like they're drawn in the page itself? anyone got ideas?

Re: Form flattening with or without refresh

2019-05-14 Thread Andrea Vacondio
s not published so the current state was achieved by > > > looking at sample PDFs and reworking that. > > > > > > I'll look into the PDF provided to get an idea where the difference is > > > coming from. > > > > > > Having said that - as lon

Re: Form flattening with or without refresh

2019-05-13 Thread Maruan Sahyoun
tate was achieved by > > looking at sample PDFs and reworking that. > > > > I'll look into the PDF provided to get an idea where the difference is > > coming from. > > > > Having said that - as long as you didn't change the form content - using > &g

Re: Form flattening with or without refresh

2019-05-13 Thread Maruan Sahyoun
at sample PDFs and reworking that. > > > > I'll look into the PDF provided to get an idea where the difference is > > coming from. > > > > Having said that - as long as you didn't change the form content - using > > refreshAppearance=true should

Re: Form flattening with or without refresh

2019-05-13 Thread Andrea Vacondio
id that - as long as you didn't change the form content - using > refreshAppearance=true should't be neccesary when > flattening. > > BR > Maruan > > > Hi, we are having some issue when we try to flatten the form in the file > > f1040_sample.pdf > > We get

Re: Form flattening with or without refresh

2019-05-13 Thread Maruan Sahyoun
content - using refreshAppearance=true should't be neccesary when flattening. BR Maruan > Hi, we are having some issue when we try to flatten the form in the file > f1040_sample.pdf > We get slightly different results depending on the value of refresh > appearance, in particular

Form flattening with or without refresh

2019-05-13 Thread Andrea Vacondio
sh.pdf"); testPdf.save(file); } I isolated the field in the test case but we also get the same result when flattening the whole form, I included the Acrobat version of the flattened pdf. If we flatten the whole form with refreshAppearance=false we get pretty much the same result as

Re: Flattening (?) Problem 2.0.5->2.0.11

2019-02-01 Thread Aaron Mulder
ntStream = new PDPageContentStream(doc, page, > >>> PDPageContentStream.AppendMode.APPEND, true); > >>> contentStream.drawImage(image, 246, 36 ); > >>> contentStream.close(); > >>> doc.save(tempFile); > >>> doc.close(); > >>> &

Re: Flattening (?) Problem 2.0.5->2.0.11

2019-02-01 Thread Tilman Hausherr
rintout. (They do appear when I open the doc in Preview.) I don't really know why; I just tried updating to the latest on a lark. It feels like the flattening failed on 2.0.11. The printer is a bit dated and I think I went with flattening in the first place because that was the only way to

Re: Flattening (?) Problem 2.0.5->2.0.11

2019-02-01 Thread Aaron Mulder
> > With PDFBox 2.0.11 when I do the same, the form fields all come > > through as empty on the printout. (They do appear when I open the doc > > in Preview.) > > > > I don't really know why; I just tried updating to the latest on a > > lark. It feels lik

Re: Flattening (?) Problem 2.0.5->2.0.11

2019-01-30 Thread Tilman Hausherr
g to the latest on a lark. It feels like the flattening failed on 2.0.11. The printer is a bit dated and I think I went with flattening in the first place because that was the only way to get the doc to print correctly from the command line. I will stick with 2.0.5 for now because for this case it

Flattening (?) Problem 2.0.5->2.0.11

2019-01-30 Thread Aaron Mulder
.0.11 when I do the same, the form fields all come through as empty on the printout. (They do appear when I open the doc in Preview.) I don't really know why; I just tried updating to the latest on a lark. It feels like the flattening failed on 2.0.11. The printer is a bit dated and

Re: "Could not find font: /TimesNewRoman" when flattening form with refreshAppearances set to true.

2018-01-30 Thread Maruan Sahyoun
COSName{BaseFont}:COSName{Times-Roman};COSName{Encoding}:316217735;COSName{Name}:COSName{TiRo};COSName{Subtype}:81291287;COSName{Type}:2195567;}};COSName{ZaDb}:COSDictionary{COSName{Type}:2195567;COSName{Subtype}:81291287;COSName{BaseFont}:COSName{ZapfDingbats};};};} > -Original Message--

RE: "Could not find font: /TimesNewRoman" when flattening form with refreshAppearances set to true.

2018-01-29 Thread David Fertig
SName{Subtype}:81291287;COSName{BaseFont}:COSName{ZapfDingbats};};};} -Original Message- From: Maruan Sahyoun [mailto:sahy...@fileaffairs.de] Sent: Thursday, January 25, 2018 11:44 AM To: users@pdfbox.apache.org Subject: Re: "Could not find font: /TimesNewRoman" when flatt

Re: "Could not find font: /TimesNewRoman" when flattening form with refreshAppearances set to true.

2018-01-25 Thread Maruan Sahyoun
> Sent: Thursday, January 25, 2018 2:11 AM > To: users@pdfbox.apache.org > Subject: Re: "Could not find font: /TimesNewRoman" when flattening form with > refreshAppearances set to true. > > Hi, > What version are you using? > Tilman > > Am 25.01.2018 um 0

RE: "Could not find font: /TimesNewRoman" when flattening form with refreshAppearances set to true.

2018-01-25 Thread David Fertig
Sent: Thursday, January 25, 2018 2:11 AM To: users@pdfbox.apache.org Subject: Re: "Could not find font: /TimesNewRoman" when flattening form with refreshAppearances set to true. Hi, What version are you using? Tilman Am 25.01.2018 um 08:03 schrieb David Fertig: > I am loading a PDF file

Re: "Could not find font: /TimesNewRoman" when flattening form with refreshAppearances set to true.

2018-01-24 Thread Tilman Hausherr
Hi, What version are you using? Tilman Am 25.01.2018 um 08:03 schrieb David Fertig: I am loading a PDF file into a PDDocument , using its PDAcroForm.importFDF to import FDF field data, and then using PDAcroForm.flatten. When refreshAppearances is false PDAcroForm.flatten works, but when refre

"Could not find font: /TimesNewRoman" when flattening form with refreshAppearances set to true.

2018-01-24 Thread David Fertig
I am loading a PDF file into a PDDocument , using its PDAcroForm.importFDF to import FDF field data, and then using PDAcroForm.flatten. When refreshAppearances is false PDAcroForm.flatten works, but when refreshAppearances is true, I get the exception below. This happens on linux (where I've a

Re: Fwd: Problems with flattening

2017-07-04 Thread Fabio Salvi
tic pdf >> form >> Test.pdf. The result is pippo.pdf. The texts were set but there's a shift >> of the string to right of a char (see Capture.PNG)...I suppose that is >> caused by the flattening.. >> >> I wonder whether that has to do with my Form...but a

Re: Problems with flattening

2017-07-03 Thread Maruan Sahyoun
JzSzl2NXc >> >> The Test tries to set all the fields texts to 'test' in the static pdf form >> Test.pdf. The result is pippo.pdf. The texts were set but there's a shift >> of the string to right of a char (see Capture.PNG)...I suppose that is >> caused

Re: Fwd: Problems with flattening

2017-07-03 Thread Tilman Hausherr
pdf. The result is pippo.pdf. The texts were set but there's a shift of the string to right of a char (see Capture.PNG)...I suppose that is caused by the flattening.. I wonder whether that has to do with my Form...but as I try to set the values by hand, the texts aren't shifted...

Re: Fwd: Problems with flattening

2017-07-03 Thread Fabio Salvi
set but there's a shift of the string to right of a char (see Capture.PNG)...I suppose that is caused by the flattening.. I wonder whether that has to do with my Form...but as I try to set the values by hand, the texts aren't shifted... Thank you very much! Regards Fabio 2017-06-

Re: Fwd: Problems with flattening

2017-06-30 Thread Tilman Hausherr
Hi, Make sure you're using the latest version, 2.0.6. Please upload your files (including your PDF file) to a sharehoster. Tilman Am 30.06.2017 um 18:42 schrieb Fabio Salvi: Hi all, I'm using PDFBox to full a PDFForm and it works very well. I have a Problem as I try to flatten

Fwd: Problems with flattening

2017-06-30 Thread Fabio Salvi
> Hi all, > > I'm using PDFBox to full a PDFForm and it works very well. I have a > Problem as I try to flatten the Document. The field texts are moved to the > right by a char and not aligned with the label. > > Have you an idea what can cause such a problem? > > [image: Inline-Bild 1] > > Hier my

Re: Flattening a Form

2017-02-26 Thread Andreas Lehmkuehler
ontent on the page, if possible. I gather this is called "flattening" and I saw something that said I should just remove the AcroForm fields and the annotations would remain, or something like that. But my override goes in an element like this: 21 0 obj << /Type /Annot /T (SomeLa

Flattening a Form

2017-02-26 Thread Aaron Mulder
hese reasons I would prefer to eliminate the form fields when I append to the original document, and make my appearance streams just be content on the page, if possible. I gather this is called "flattening" and I saw something that said I should just remove the AcroForm fields and the annotati

Re: Form Filling/Flattening Problem

2016-04-01 Thread Maruan Sahyoun
Hi, > Am 01.04.2016 um 08:25 schrieb Maruan Sahyoun : > > Hi, > > flatten() will flatten the form fields but without refreshing the fields > appearance i.e. how you see it on the form. Now, as NeedAppearances is set to > true, the prior setValue() call also didn't refresh the fields appearance

Re: Form Filling/Flattening Problem

2016-03-31 Thread Maruan Sahyoun
Hi, flatten() will flatten the form fields but without refreshing the fields appearance i.e. how you see it on the form. Now, as NeedAppearances is set to true, the prior setValue() call also didn't refresh the fields appearance as the NeedAppearances flag tells the viewer to handle that. The

Re: Flattening

2013-01-24 Thread Lukas Baab
Hi Thomas, thanks for your advice! Unfortunately your advice does not work. If I get the Fields over the COSDictionary (as you recommend) AdobePdfReader still shows the form-fields. Just PDFBox does not recognise the form-fields any more. Do you (or someone else) have any idea whether I have to

Re: Flattening

2013-01-23 Thread Thomas Chojecki
Am 22.01.2013 13:25, schrieb Lukas Baab: Hi! Hi Lukas, How do I "flatten" a PDF-form (remove the form-field but keep the text of the field)? Jason asked this question already. (see http://mail-archives.apache.org/mod_mbox/pdfbox-users/201009.mbox/%3c4c9a326f.60...@rayman2200.de%3E) The answ

Flattening

2013-01-22 Thread Lukas Baab
Hi! How do I "flatten" a PDF-form (remove the form-field but keep the text of the field)? Jason asked this question already. (see http://mail-archives.apache.org/mod_mbox/pdfbox-users/201009.mbox/%3c4c9a326f.60...@rayman2200.de%3E) The answer was this: > a quick way to do this, is to remove the

AcroForm flattening

2012-02-10 Thread André Camilo
Hi all, I have a PDF with form fields created on Acrobat 9, and I would like to fill this fields and save the PDF flattened, without the form. I saw on the mailing list that just by removing the fields would do the trick: document.getDocumentCatalog().getAcroForm().getFields().clear();

Flattening annotations?

2010-10-21 Thread Michael David Pedersen
Hi folks, PDFBox is great and I have used it to programmatically create some annotations (TextMarkups and AnnotationLinks) in existing PDF files. However, not all PDF viewers support annotations. Is there any way to flatten the annotations programmatically using PDFBox, so that the full content w

Re: Flattening

2010-09-23 Thread Jason Stell
Hi Thomas Thanks for your reply! I'll experiment with that approach. Regards Jason Subject:Re: Flattening <http://markmail.org/message/w6tdf2hnimwx4uw3> [image: permalink] <http://markmail.org/message/w6tdf2hnimwx4uw3> From:Thomas Chojecki (in...@rayman2200.de) Date:Sep 22

Re: Flattening

2010-09-22 Thread Thomas Chojecki
Hi Jason, a quick way to do this, is to remove the fields from the acrofrom. For this you just need to get the document catalog, then the acroform and then remove all fields from this acroform. The graphical representation is linked with the annotation and stay in the document. Am 22.09.201

Flattening

2010-09-21 Thread Jason Stell
I'm looking for a way to "flatten" a pdf (basically, "merge" the interactive form fields directly into the pdf pages) , but haven't discovered how this can be done with PDFBox. Is this supported? Thanks much! Jason