Setting PDF export options...

421 views
Skip to first unread message

master_X

unread,
Aug 2, 2010, 3:30:06 AM8/2/10
to JODConverter
Can someone confirm that what I am doing below in trying to set PDF
export options in java code using JODConverter 3.0 makes sense. It
does not appear to working for me.

I am not able to get my Zoom factor or my document password to work,
even though the document is produced.

Thanks,

JC.
=============================


DocumentFormat outputFormat = new
DocumentFormatRegistry.getFormatByExtension("pdf");
Map<String, Object> properties = new HashMap<String, Object>();
properties.put("FilterName", "writer_pdf_Export");
Map<String, String> exportOptions = new HashMap<String, String>();
exportOptions.put("zoom", "75");
exportOptions.put("documentOpenPassword", "serv3usA11!");
properties.put("FilterData", exportOptions);
outputFormat.setStoreProperties(DocumentFamily.TEXT, properties);
...

Klemen Živkovič

unread,
Aug 2, 2010, 8:43:58 AM8/2/10
to jodcon...@googlegroups.com
Hi master_X,

have you checked following URL:
http://wiki.services.openoffice.org/wiki/API/Tutorials/PDF_export

Hope it helps,
Klemen
> --
> You received this message because you are subscribed to the Google Groups "JODConverter" group.
> To post to this group, send email to jodcon...@googlegroups.com.
> To unsubscribe from this group, send email to jodconverter...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/jodconverter?hl=en.
>
>

Master Xenon

unread,
Aug 2, 2010, 2:01:04 PM8/2/10
to jodcon...@googlegroups.com
I have. 
 
Are you suggesting that the API that is set up for UNO java programming is an exact match to the API that is set up in JODConverter for export/filter options and that I should simply follow what API does?

Klemen Živkovič

unread,
Aug 3, 2010, 3:19:28 AM8/3/10
to jodcon...@googlegroups.com
Seems to me that commands are extremely similar... :)

I was also trying zoom parameter and unfortunately it means only starting zoom in pdf reader - and as upper url says, it should be used with parameter magnify=4.

"If Magnify parameter =4 than reader opens with the zoom level specified in the Zoom property."

Best regards,
Klemen

Mirko Nasato

unread,
Aug 6, 2010, 8:32:52 AM8/6/10
to JODConverter
I confirm that JODConverter just passes the export options straight to
OpenOffice.org, so for option names and values please refer to the OOo
documentation (or, failing that, OOo source code).

Kind regards

Mirko

On Aug 3, 8:19 am, Klemen Živkovič <klemen.zivko...@gmail.com> wrote:
> Seems to me that commands are extremely similar... :)
>
> I was also trying zoom parameter and unfortunately it means only starting
> zoom in pdf reader - and as upper url says, it should be used with parameter
> magnify=4.
>
> "If Magnify parameter =4 than reader opens with the *zoom* *level* specified
> in the Zoom property."
>
> Best regards,
> Klemen
>
>
>
> On Mon, Aug 2, 2010 at 8:01 PM, Master Xenon <topsqu...@gmail.com> wrote:
> > I have.
>
> > Are you suggesting that the API that is set up for UNO java programming is
> > an exact match to the API that is set up in JODConverter for export/filter
> > options and that I should simply follow what API does?
>
> > On Mon, Aug 2, 2010 at 8:43 AM, Klemen Živkovič <klemen.zivko...@gmail.com
> > > wrote:
>
> >> Hi master_X,
>
> >> have you checked following URL:
> >>http://wiki.services.openoffice.org/wiki/API/Tutorials/PDF_export
>
> >> Hope it helps,
> >> Klemen
>
> >> On Mon, Aug 2, 2010 at 9:30 AM, master_X <topsqu...@gmail.com> wrote:
> >> > Can someone confirm that what I am doing below in trying to set PDF
> >> > export options in java code using JODConverter 3.0 makes sense.  It
> >> > does not appear to working for me.
>
> >> > I am not able to get my Zoom factor or my document password to work,
> >> > even though the document is produced.
>
> >> > Thanks,
>
> >> > JC.
> >> > =============================
>
> >> > DocumentFormat outputFormat = new
> >> > DocumentFormatRegistry.getFormatByExtension("pdf");
> >> > Map<String, Object> properties = new HashMap<String, Object>();
> >> > properties.put("FilterName", "writer_pdf_Export");
> >> > Map<String, String> exportOptions = new HashMap<String, String>();
> >> > exportOptions.put("zoom", "75");
> >> > exportOptions.put("documentOpenPassword", "serv3usA11!");
> >> > properties.put("FilterData", exportOptions);
> >> > outputFormat.setStoreProperties(DocumentFamily.TEXT, properties);
> >> > ...
>
> >> > --
> >> > You received this message because you are subscribed to the Google
> >> Groups "JODConverter" group.
> >> > To post to this group, send email to jodcon...@googlegroups.com.
> >> > To unsubscribe from this group, send email to
> >> jodconverter...@googlegroups.com<jodconverter%2Bunsubscribe@google groups.com>
> >> .
> >> > For more options, visit this group at
> >>http://groups.google.com/group/jodconverter?hl=en.
>
> >> --
> >> You received this message because you are subscribed to the Google Groups
> >> "JODConverter" group.
> >> To post to this group, send email to jodcon...@googlegroups.com.
> >> To unsubscribe from this group, send email to
> >> jodconverter...@googlegroups.com<jodconverter%2Bunsubscribe@google groups.com>
> >> .
> >> For more options, visit this group at
> >>http://groups.google.com/group/jodconverter?hl=en.
>
> >  --
> > You received this message because you are subscribed to the Google Groups
> > "JODConverter" group.
> > To post to this group, send email to jodcon...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > jodconverter...@googlegroups.com<jodconverter%2Bunsubscribe@google groups.com>
> > .

Master Xenon

unread,
Aug 6, 2010, 5:54:07 PM8/6/10
to jodcon...@googlegroups.com
Mirko,
        Can you confirm that the Java code that I wrote for performing the task in JODConverter is in the correct form required?  Thanks.


DocumentFormat outputFormat = new DocumentFormatRegistry.getFormatByExtension("pdf");
Map<String, Object> properties = new HashMap<String, Object>();
properties.put("FilterName", "writer_pdf_Export");
Map<String, String> exportOptions = new HashMap<String, String>();
exportOptions.put("documentOpenPassword", "serv3usA11!");
properties.put("FilterData", exportOptions);
outputFormat.setStoreProperties(DocumentFamily.TEXT, properties);

============================================================
To unsubscribe from this group, send email to jodconverter...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages