# PDF Importer for Open Office - Solved with Evince



## JayArr (Feb 20, 2019)

Hi all

I was searching for a way to "form fill" government .pdf files and one of the older suggestions (on this site) was to install the 'pdf import extension' for Open Office. This sounds good to me but I can't seem to figure out how to get it done. I've tried all of the Linux and Mac files available on the Open Office extensions page but none of them will load. I also can't find them in my ports tree to compile them myself. Are these no longer available for FreeBSD or am I just not looking in the right place?

I'm running FreeBSD 11.2 and Open Office 4.1.6

JayArr


----------



## aragats (Feb 21, 2019)

The following is rather a work-around, but I like it better: even non-fillable documents become fillable. I use LibreOffice, and believe the same is possible with OpenOffice.
I convert .pdf files to .png and insert those pictures in Calc (spreadsheet application of LibreOffice). Then I select "To background" under "Arrange" of the context menu. I adjust the cells' size to fit the fillable fields and voilà. Then I add formulas as needed, e.g. in tax forms and so on.


----------



## JayArr (Feb 21, 2019)

What do you use to convert .pdf to .png?


----------



## aragats (Feb 21, 2019)

I use graphics/gimp since I already have it and use for other purposes.
The classical way is to use *ghostscript* (there are several ports/packages available):
	
	



```
gs -sDEVICE=png16m -dBATCH -dNOPAUSE -sOutputFile=file%02d.png -r300 file.pdf
```
It is also possible to use convert from *ImageMagick* (there are several ports/packages too):
	
	



```
convert -density 300 file.pdf file%02d.png
```
In both examples *300* is the density in DPI, you may want to adjust it to avoid rescaling the image in the the office application.


----------



## JayArr (Feb 21, 2019)

OK, gs changed a few of the fonts but it generated the file and I was able to `insert/picture` and then `Format/Arrange/ToBackground` but then what a nightmare lining up all the boxes, this is a customs form I want to fill out and it's got well over 100 boxes per page. I can load an OS onto a hard drive in less time than I could line up all the spreadsheet boxes to the form. Maybe this works with forms that only have a dozen or so boxes but not this one, there has to be an easier way.


----------



## rigoletto@ (Feb 21, 2019)

The only tool I know actually does that, because I already used it, is Adobe Acrobat Pro.


----------



## shkhln (Feb 21, 2019)

Evince supports PDF forms.


----------



## aragats (Feb 21, 2019)

aragats said:


> Maybe this works with forms that only have a dozen or so boxes but not this one, there has to be an easier way.


You can always open a PDF directly in a graphics editor like graphics/gimp and use the text tool.


----------



## JayArr (Feb 21, 2019)

Thanks all! 

Evince is the solution I'll use, it works perfectly, it allows input in all the boxes, it works with my xfce desktop and prints correctly on my old Xerox copier. 

Mission accomplished.


----------



## aragats (Feb 21, 2019)

JayArr said:


> Evince is the solution I'll use, it works perfectly


That's good, and there are two ports/packages available, I guess graphics/evince-lite is preferable, since the regular one (graphics/evince) pulls 300MB of GNOME dependencies.
I just discovered that Chromium browser does handle fillable PDF forms as well.


----------

