The dreaded changebar topic

Post here questions and problems related to editing and publishing DITA content.
gwhite
Posts: 70
Joined: Fri Jul 27, 2012 1:46 am

The dreaded changebar topic

Post by gwhite »

I'm interested in printing changebars using the DITA-OT. In the org.dita.pdf2 plugin, there are three xsl files that seem to promise the ability to do this, particularly "flagging.xsl", which has actual changebar language in it. But it's not clear from a day's worth of research how to use these files to get the desired result. I want to output changebars for any element in a topic whose status attribute is set to either "new" or "updated". There is no specific information in the DITA-OT documentation, or in the discussions on the Yahoo dita-users usergroup about how to actually make this work.

In oXygen, does this require setting up a ditaval file, or can it be handled in profiling/conditional text processing? If so :D , how?

Gary
gwhite
Posts: 70
Joined: Fri Jul 27, 2012 1:46 am

Re: The dreaded changebar topic

Post by gwhite »

I understand better, after further research, how this is supposed to work, however I haven't gotten a good result yet.

Here is what I've done.

I've created a ditaval file:

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<val>
<style-conflict foreground-conflict-color="blue" background-conflict-color="gray"/>
<revprop val="10.2" action="flag" color="orange" backcolor="gray" changebar="style:solid;width=3pt;offset=5pt"></revprop>
</val>
I referred to this ditaval file in a PDF transformation, citing the file in the Use DITAVAL file option, on the Filters tab.

Previously, in one topic in the ditamap to print, I set some elements' rev attribute to 10.2.

Then I ran the transformation on the ditamap.

The transformation ran successfully, but no PDF file was created!

Do you see anything wrong in my ditaval file or elsewhere that would result in no output?

Thanks,

Gary
gwhite
Posts: 70
Joined: Fri Jul 27, 2012 1:46 am

Re: The dreaded changebar topic

Post by gwhite »

Since the last post I have tweaked the ditaval file, and I find that my setup works when the output is Webhelp--to the extent of changing the text color and background color of changed text. In addition, I at least get PDF output now, but no changebars, and the text color doesn't change, with the net result for PDF being no indication of changes.

If I could figure out how to actually get a changebar character to print in the margin, I could do without the change in text color or background.

Here is the updated ditaval file contents:

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<val>
<style-conflict foreground-conflict-color="green" />
<revprop val="10.2" action="flag" color="blue" changebar="style:dotted;width:3pt;offset:5pt"></revprop>
</val>
Any thoughts about how to get the actual changebar character in the margin would be welcomed.
Radu
Posts: 9018
Joined: Fri Jul 09, 2004 5:18 pm

Re: The dreaded changebar topic

Post by Radu »

Hi,

From what I read, the support for change bars based on the @rev attribute was contributed to the DITA OT by the company Suite Solutions:

http://ditadocs.content-lifecycle.com/w ... en-toolkit

From what they say, the change bars support does not work when publishing with Apache FOP. But it should work when publishing using the commercial RenderX XEP PDF processor.
If you open the XSL:

OXYGEN_INSTALL_DIR/frameworks/dita/DITA-OT/plugins/org.dita.pdf2/xsl/fo/flagging-preprocess.xsl

you will see there are a number of templates from which the template:

Code: Select all

 <xsl:apply-templates select="." mode="changebar">
gets called. None of those templates match directly the topic root element name. Actually in the same XSL there is an XML comment like:

Code: Select all

Don't flag topics, just like in the HTML output
I tested using your posted DITAVAL with a DITA topic which had a definition list like:

Code: Select all

<dl rev="10.2">
<dlentry>
<dt>DT</dt>
<dd>DD</dd>
</dlentry>
</dl>
I used RenderX XEP as the PDF processor and the PDF contained the change bars for that particular definition list.

You should also ask around on the DITA Users List which is watched by a couple of the developers from Suite Solutions.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
gwhite
Posts: 70
Joined: Fri Jul 27, 2012 1:46 am

Re: The dreaded changebar topic

Post by gwhite »

Thanks, Radu.
Post Reply