Page 1 of 1

Using the PI MOD standard

Posted: Thu Mar 15, 2012 4:14 pm
by SSC
Hello,

Some of our Customers use the PI MOD standard for their documents.
-> http://www.pi-mod.de/index.php?lang=en

This XML document standard uses a different tag element for their images than others like DITA.

Code: Select all

 <inlinemediaobject objectname="Variant-B.jpg"/>
Compared with DITA an inlinemediaobject tag element in PI MOD is an image tag element in DITA and the objectname attribute in PI MOD is similar to the href attribute in DITA.

My question concerning this is if there is some kind of mapping for those media in the WYSIWYG Auhor mode in the Oxygen XML Editor.
Can I somehow define that those inlinemediaobjects are shown like DITA images in the WYSIWYG Auhor mode?
Or am I forced to use a CSS hack to show the inlinemediaobject images?

Best regards,

Simon

Re: Using the PI MOD standard

Posted: Thu Mar 15, 2012 4:39 pm
by Radu
Hi Simon,

PI MOD is an XML vocabulary for which Oxygen has no out-of-the-box support.

Oxygen has out-of-the-box support for DITA, Docbook, TEI, XHTML but this support is not hard coded, it is based on an implementation of a Document Type:
http://www.oxygenxml.com/doc/ug-oxygen/ ... intro.html

In order to have a minimal visual editing support in the Author page for a certain XML you need to write a CSS which defines styles for each element.
For example the CSS for editing DITA is located here:
OXYGEN_PLUGIN_INSTALL_DIR/frameworks/dita/css_classed/dita.css

and in order to display an image for a certain element the CSS selector is like this:

Code: Select all

*[class~="topic/image"] {
display: inline;
content: attr(href, url);
width:attr(width, length);
height:attr(height, length);
}
The most important part of the selector is this one:

Code: Select all

content: attr(href, url);
Regards,
Radu