[oXygen-user] Default folder for images
George Cristian Bina
george at oxygenxml.com
Thu Dec 19 10:25:41 CST 2013
Wendell's suggestion should not be too hard in this case, as you mention
you use DITA.
1. there are no entities
2. the default attributes are only @class and @domains
3. if you have the topics, tasks, references, etc. in different folders
then you may apply the right stylesheet for each folder, generating the
corresponding DOCTYPE declaration
In the not so distant future, once DITA 1.3 is available, you should be
able to use Relax NG with DITA and thus you will not have the DOCTYPE
One possibility for handling 3 is to generate the output in a different
place - and that is even a better practice because you can then compare
the two folders. In this case then you can generate the DOCTYPE
declaration based on the root element name, for example:
if applied in a document with the root element "dita".
George Cristian Bina
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
On 12/19/13, 6:08 PM, Wendell Piez wrote:
> I agree with Mark that one approach is to implement a completely
> different policy with respect to the link management, and work around
> the problem that way.
> On the other hand I'm also sympathetic with the requirement, which
> indeed is very general, not just a matter of your links.
> I think I'd prefer the XSLT route. Radu points out that you lose the
> DOCTYPE declaration and that you gain (what might be) unwanted
> assignment of default values to attributes from your DTD.
> 1. While an XSLT cannot ordinarily or properly retain a DOCTYPE
> declaration, it can assign one to the serialized results using
> xsl:output, and this is often just as good or better.
> 2. Similarly, a near-identity transformation can be configured to
> remove attributes from the results when their values correspond to
> default values assigned elsewhere.
> Writing this stylesheet does entail some homework (DTD analysis to
> find your attribute defaults), and potentially maintenance to keep it
> in alignment with your schema(s) and policies. For example, you may
> need to address your requirements for the use of parsed entities and
> whether these can also be kept (or rather, remade) the way you want
> However, a near-identity transformation that would normalize a
> document along these lines could be imported into another XSLT to
> perform whatever surgery you needed on its tagging (in this case or in
> later cases). As such, it would be a valuable resource to have in your
> For example, it can also serve as the basis of an XSLT for whitespace
> normalization and cleanup, a task that raises the same issues.
> Cheers, Wendell
> Wendell Piez | http://www.wendellpiez.com
> XML | XSLT | electronic publishing
> Eat Your Vegetables
> On Thu, Dec 19, 2013 at 3:59 AM, Oxygen XML Editor Support
> <support at oxygenxml.com> wrote:
>> Hi Nathan,
>> I answered you here:
>> But if anybody else has a better idea, possibly without using our Java
>> API, please contribute.
>> Applying an XSLT stylesheet to make changes is an idea but it removed
>> the DOCTYPE declaration and also adds default attributes to the
>> processed XML content.
>> Radu Coravu
>> <oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
>> On 12/19/2013 1:20 AM, Nathan wrote:
>>> I am currently moving from Arbortext to Oxygen and I have a bunch of
>>> DITA XMLs which have a fixed path for img src attributes (Arbortext
>>> allows one to set such folder locations in the preferences for inline
>>> display). These paths are not valid (what can I say, I used Arbortext
>>> ;-)) and I am trying to move away from this practice by converting it in
>>> to relative paths.
>>> In the meantime, is there any thing I can do to make this valid. I
>>> have looked at some options including:
>>> * Change path using the ChangeAttribute Author default operation
>>> (Question, is there any the operation can be triggered on document
>>> open in OxygenXML Author).
>>> * Using the Java API (Again, any way this trigger this on document open)
>>> Is there a better way to do this?
>>> PS: I am using Oxygen 15
>>> oXygen-user mailing list
>>> oXygen-user at oxygenxml.com
>> oXygen-user mailing list
>> oXygen-user at oxygenxml.com
> oXygen-user mailing list
> oXygen-user at oxygenxml.com
More information about the oXygen-user