Transformation scenario

Having trouble installing Oxygen? Got a bug to report? Post it all here.
julie
Posts: 61
Joined: Fri Jun 06, 2008 7:09 am

Transformation scenario

Post by julie »

Hi
I created a folder structure in Oxygen XML as follows:
Source: DITA files
Images: Image files
Utilities: main.css, commonltr.css, commonrtl.css, header.html and footer.html
Templates: Template files
Output: Automatically created the output while compiling
I customized the main.css file according to the requirements. When I compiled the file, I got the required output. My understanding about the process was that while compiling Oxygen XML picks the dita files from the source folder; images from the image folder according to the path given in the dita files in the Source folder; main.css, header.html, and footer.html files from the Utilities folder; creates templates in the template folder; and produce the output files in the output folder while compiling. But, to my surprise I found that Oxygen is not picking the files from the Utlities folder and I have to copy the header, footer, and main.css files to the output folder everytime I customize the main.css files. I think I am wrong in understanding the process. Please explain.

Also, while sending the files to a remote system, do I need to copy the header.html, footer.html, and main.css files in the output folder everytime to get the result.
Sorry to bother you with such a big mail....Please help.
Thanks in advance
Regards
Julie
Radu
Posts: 9018
Joined: Fri Jul 09, 2004 5:18 pm

Re: Transformation scenario

Post by Radu »

Hi Julie,

As far as I know you have to edit the XHTML scenario you are using and in the "Parameters" tab set parameters like:

args.copycss should be set to yes
args.css should be set to the path to your main.css
args.ftr should be set to the path to your footer.html
args.hdr should be set to the path to header.html

See this link for more information about the parameters:
http://dita-ot.sourceforge.net/doc/ot- ... arms.html

Oxygen just calls the DITA Open Toolkit ANT transformation with specified parameters so the transformation process is entirely controlled by the DITA Open Toolkit.

Regards,
Radu
--
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
julie
Posts: 61
Joined: Fri Jun 06, 2008 7:09 am

Re: Transformation scenario

Post by julie »

Hi
I am trying to transform the xml files to pdf. While transforming the files to xhtml, everything is working fine. But, when I transformed to pdf, the images are not appearing, the cross-reference links are still pointing to the .html files, and a blank page is there between the cover page and content page. How to avoid all these errors and create a proper output in pdf. How do I link the image folder to get it displayed in the output?

The tool also throwing the following error:
dita.fo2pdf.nouserconfig:
[fop] log4j:WARN No appenders could be found for logger (org.apache.fop.util.ContentHandlerFactoryRegistry).
[fop] log4j:WARN Please initialize the log4j system properly.
[fop] C:\Documents and Settings\jerinjer\Desktop\help\Source\out\Design_Portal.fo -> C:\Documents and Settings\jerinjer\Desktop\help\Source\out\Design_Portal.pdf

Please help
Regards
Julie
Radu
Posts: 9018
Joined: Fri Jul 09, 2004 5:18 pm

Re: Transformation scenario

Post by Radu »

Hi Julie,

Transforming to PDF should work OK.

Just open the DITA Map in the DITA Maps Manager, create a new "PDF - IDIOM FO Plugin" transformation (or choose the read-only one if available) and transform.
Did you customize your DITA Open Toolkit in any way?
Do you use the DITA Open Toolkit which comes with Oxygen.
Are you trying to transform an entire DITA Map or only a DITA topic to PDF?
What Oxygen version are you using?

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
julie
Posts: 61
Joined: Fri Jun 06, 2008 7:09 am

Re: Transformation scenario

Post by julie »

Hi Radu
Thanks for the reply. I transformed using the same PDF2-Idiom FO, but oxygen is generating the output without the images. I am using Oxygen XML 9.3 version. I am using the dita toolkit comes with Oxygen and trying to transform the entire DITA Map. Please help. it is very urgent.
regards
Julie
Radu
Posts: 9018
Joined: Fri Jul 09, 2004 5:18 pm

Re: Transformation scenario

Post by Radu »

Dear Julie,

Oxygen 9.3 was bundled with DITA OT 1.4.2.1 which indeed does not display the images in the PDF file.
A patch was later added for this in the Oxygen 10.x versions for correctly setting the base directory to Apache FOP.
You can add it for yourself by modifying the OXYGEN_INSTALL_DIR/frameworks/dita/DITA-OT/demo/fo/build.xml build file in Oxygen, search for the target:

Code: Select all


<target name="transform.fo2pdf.fop"
.....
then replace the whole target element with:

Code: Select all


<target name="transform.fo2pdf.fop" if="use.fop.pdf.formatter">
<taskdef name="fop" classname="org.apache.fop.tools.anttasks.Fop">
<classpath>
<!--Oxygen patch for EXM-10624, load FOP from the libraries Oxygen provides at runtime to ANT-->
<pathelement path="${java.class.path}"/>
</classpath>
</taskdef>
<!--Oxygen patch for EXM-12876, set basedir to FOP-->
<dirname file="${outputFile}" property="outputDir"/>
<fop format="application/pdf" fofile="${inputFile}"
outfile="${outputFile}" messagelevel="info" force="true" userConfig="${dita.dir}/fop_relax_validation.xml" basedir="${outputDir}">
</fop>
</target>
As an alternative, you can create a new "PDF-DITA OT" scenario which displays correctly the images.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
julie
Posts: 61
Joined: Fri Jun 06, 2008 7:09 am

Re: Transformation scenario

Post by julie »

Hi
I made the changes in the build.xml file as suggested. Still no change in the output. The build was succesful with the following message:
Executing:
"d:\program files\oxygen xml author 10\jre/bin/java" -classpath "D:\Program Files\Oxygen XML Author 10/tools/ant/lib/ant-launcher.jar" "-Dant.home=D:\Program Files\Oxygen XML Author 10/tools/ant" org.apache.tools.ant.launch.Launcher -lib "D:\Program Files\Oxygen XML Author 10\classes" -lib "D:\Program Files\Oxygen XML Author 10\lib\author.jar" -lib "D:\Program Files\Oxygen XML Author 10\lib\oxygen.jar" -lib "D:\Program Files\Oxygen XML Author 10\lib\oxygenEclipse.jar" -lib "D:\Program Files\Oxygen XML Author 10\lib\authorEclipse.jar" -lib "D:\Program Files\Oxygen XML Author 10\frameworks\dita\DITA-OT" -lib "D:\Program Files\Oxygen XML Author 10\lib\commons-io-1.3.1.jar" -lib "D:\Program Files\Oxygen XML Author 10\lib\commons-logging-1.0.4.jar" -lib "D:\Program Files\Oxygen XML Author 10\lib\log4j.jar" -lib "D:\Program Files\Oxygen XML Author 10\frameworks\dita\DITA-OT\lib\dost.jar" -lib "D:\Program Files\Oxygen XML Author 10\frameworks\dita\DITA-OT\lib\resolver.jar" -lib "D:\Program Files\Oxygen XML Author 10\lib\xercesImpl.jar" -lib "D:\Program Files\Oxygen XML Author 10\lib\saxon.jar" -lib "D:\Program Files\Oxygen XML Author 10\lib\xmlgraphics-commons-1.2.jar" -lib "D:\Program Files\Oxygen XML Author 10\lib\fop.jar" -lib "D:\Program Files\Oxygen XML Author 10\lib\batik-all-1.6.jar" -lib "D:\Program Files\Oxygen XML Author 10\lib\avalon-framework-4.2.0.jar" -f "D:\Program Files\Oxygen XML Author 10\frameworks\dita\DITA-OT\demo\fo\build.xml" "-Dtranstype=pdf" "-Dargs.fo.userconfig=D:\Program Files\Oxygen XML Author 10\frameworks/dita/DITA-OT/build_dita2pdf.xml" "-Dargs.xsl=D:\Program Files\Oxygen XML Author 10\frameworks/dita/DITA-OT/xsl/dita2fo-shell.xsl" "-Dargs.logdir=C:\Documents and Settings\jerinjer\Desktop\help\Output" "-Dbasedir=C:\Documents and Settings\jerinjer\Desktop\help\Source" "-Doutput.dir=C:\Documents and Settings\jerinjer\Desktop\help\Source/out" "-Ddita.dir=D:\Program Files\Oxygen XML Author 10\frameworks/dita/DITA-OT" "-Dargs.fo.img.ext=gif" "-Dargs.input=C:\Documents and Settings\jerinjer\Desktop\help\Source\Design_Portal.ditamap" "-Dargs.fo.output.rel.links=no" "-Ddita.temp.dir=C:\Documents and Settings\jerinjer\Desktop\help\Source/temp" "-Ddita.extname=.dita"

Buildfile: D:\Program Files\Oxygen XML Author 10\frameworks\dita\DITA-OT\demo\fo\build.xml

BUILD SUCCESSFUL
Total time: 0 seconds

Regards
Julie
Radu
Posts: 9018
Joined: Fri Jul 09, 2004 5:18 pm

Re: Transformation scenario

Post by Radu »

Hi Julie,

In a previous post you said you use Oxygen 9.3.
From the DITA Output I see you are actually using an Oxygen Author 10.x version.
Can you open from the Oxygen->Help the About dialog and tell me exactly the Oxygen version which appears there?
If the version is 10.1 or above then the issue should have already been fixed.
If the Oxygen Author version is 10.0 then you can get from our web site the Oxygen Author 10.3 which should also have this issue fixed:
http://www.oxygenxml.com/software_archive.html
Just make sure you install the Oxygen 10.3 to a different location if you have customizations in the DITA Open Toolkit folder from the old Oxygen installation directory.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
julie
Posts: 61
Joined: Fri Jun 06, 2008 7:09 am

Re: Transformation scenario

Post by julie »

Hi Radu
I am using Oxygen 9.3 only. We updated the version but as we did some customization, manager asked me to continue using the same version.

If it doesn't work in Oxygen 9.3, what else would be an easy option? This is very urgent and I do not have much time to work on it. please help.
Regards
Julie
Radu
Posts: 9018
Joined: Fri Jul 09, 2004 5:18 pm

Re: Transformation scenario

Post by Radu »

Hi Julie,

Please contact us at our email address:
support@oxygenxml.com
We will give you a 31-day trial license of Oxygen 11 which generated PDF using DITA OT 1.5 and also we'll give you the entire build.xml file which you should use to overwrite the equivalent build file in the 9.3 installation. One of these will definitely work.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
julie
Posts: 61
Joined: Fri Jun 06, 2008 7:09 am

Re: Transformation scenario

Post by julie »

Hi
I am able to produce the images in the pdf output now. But, now the <xref> links are not working in pdf. Also, everywhere there is an xref tag, pdf adds 'page on' without a page number. Please help.
Regards
Jullie
Radu
Posts: 9018
Joined: Fri Jul 09, 2004 5:18 pm

Re: Transformation scenario

Post by Radu »

Hi Julie,

Indeed the PDF IDIOM transformation was not very well integrated in the DITA Open Toolkit 1.4.2.1 which came with Oxygen 9.3. But there were a lot of changes in the toolkit since then so I cannot tell you exactly what to change in order to get XREF's working properly.
My suggestion for you is to:

1) Either install Oxygen 10.3 or 11.1 to another folder (without un-installing Oxygen 9) and run the PDF transformations from them (and the HTML transformations from Oxygen 9)

2) Or install a DITA Open Toolkit in a separate folder, install ANT and then run the transformation from the command line.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
julie
Posts: 61
Joined: Fri Jun 06, 2008 7:09 am

Re: Transformation scenario

Post by julie »

Hi
Thanks for the suggestions. I installed the DITA Open Toolkit in a separate folder and now everything is working fine :) .
But, the generated pdf is not displaying the bookmarks in the navigation pane. The View->Navigation also not displaying the bookmarks option. Please help.
Regards
Julie
Radu
Posts: 9018
Joined: Fri Jul 09, 2004 5:18 pm

Re: Transformation scenario

Post by Radu »

Hi Julie,

Exactly what version of DITA OT did you install?
Do you run the transformation from Oxygen or from the command line?
If running from the console, what transtype parameter value are you using?
If running from Oxygen, what scenario type did you choose?

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Post Reply