Accessing a transformation scenario parameter in a plugin bu
Posted: Wed Apr 23, 2014 6:02 pm
I've added the following parameter to a transformation scenario:
args.page.size with two possible values: A4 and letter.
I then added the following to C:\Program Files (x86)\Oxygen XML Editor 15\frameworks\dita\DITA-OT\plugins\org.dita.pdf2\build_template.xml:
And this:
This allows me to use the antArgsPageSize parameter in my plug-in. However, I would prefer to be able to do so without altering the org.dita.pdf2\build_template.xml file. Is there some way I can make similar changes to my build template file, which imports the org.dita.pdf2\buildxml file. My build file currently is as follows:
Regards
Rodrik
args.page.size with two possible values: A4 and letter.
I then added the following to C:\Program Files (x86)\Oxygen XML Editor 15\frameworks\dita\DITA-OT\plugins\org.dita.pdf2\build_template.xml:
Code: Select all
<target name="transform.topic2fo.init">
...
<condition property="args.page.size" value="">
<not><isset property="args.page.size"/></not>
</condition>
...
</target>
Code: Select all
<target name="transform.topic2fo.main">
...
<param name="antArgsPageSize" expression="${args.page.size}"/>
...
</target>
Code: Select all
<?xml version='1.0' encoding='UTF-8'?>
<project xmlns:dita="http://dita-ot.sourceforge.net" name="com.xxx.pdf-entersekt">
<import file="${dita.plugin.org.dita.pdf2.dir}/build.xml"/>
<target name="dita2pdf-entersekt.init">
<property name="customization.dir" location="${dita.plugin.com.xxx.pdf-xxx.dir}/cfg"/>
<property name="args.chapter.layout" value="BASIC" />
<property name="args.bookmark.style" value="COLLAPSED" />
<property name="args.gen.task.lbl" value="true" />
</target>
<target depends="dita2pdf-xxx.init, dita2pdf2" name="dita2pdf-xxx" />
</project>
Rodrik