Page 1 of 1

Help Customizing xsd Documentation

Posted: Wed Dec 13, 2017 5:12 pm
by Chris89
Hello Everyone,

we are searching for a tool to create a custom .xsd documenation (in PDF form) and I started evaluating oxygen.
The generated xsd-documentation is really nice i have to say, but i need to customize the layout a bit, to fit our needs.
Currently im trying to customize my .xsd documentation.

My Goal is to have a custom frontpage(text and image) and a custom footer (text and image) on every other page.

Since i dont have any experience in this field, im have some difficulties. Im trying to follow these steps https://www.oxygenxml.com/doc/versions/19.1/ug-developer/topics/customizing-xml-schema-documentation.html but without much success for now.

Sadly im already failing to understand step 1. I found the file and the needed location in it, but I have no idea what i'll need to enter here...
Can anyone explain the needed steps a bit more in depth?

Your help is very much appreciated!!


Best Regards
Christian

Re: Help Customizing xsd Documentation

Posted: Thu Dec 14, 2017 9:12 am
by Radu
Hi Christian,

As a pre-requisite you will need some knowledge of XSLT and XSL-FO.
Let's try this approach:
When you generate XML Schema documentation you can choose to generate it in a ""Docbook" format.
After this, open the generated Docbook file. Docbook is an XML vocabulary for which Oxygen has default editing and publishing support.
If you open a Docbook file in Oxygen, there is a "Configure Transformation Scenarios" dialog which allows you to publish it to various output formats.
The Docbook to PDF output takes Docbook, converts it using XSLT stylesheets to an XSL-FO file and then applies a PDF processor to obtain the final PDF.
The Docbook XSLs for generating the XSL-FO are located in:

OXYGEN_INSTALL_DIR\frameworks\docbook\xsl\fo

and there is free documentation available online about customizing the Docbook PDF:

http://www.sagehill.net/docbookxsl/PrintHeaders.html

Regards,
Radu

Re: Help Customizing xsd Documentation

Posted: Fri Dec 15, 2017 2:03 pm
by Chris89
Hi Radu,

thanks for your quick reply!

Ok that seems like a route to go. But when i create a docbook from the xsd and use this docbook (without any customization) to transform it to a pdf (with the default docbook->pdf transformation) i get some malformed tables in my resulting pdf (See below)
Image

Do I have to adjust some settings here, or what is going on?
Just to mention it, I do not have these malformed tables, when i directly generate a pdf from the xsd.

Best Regards
Christian

Re: Help Customizing xsd Documentation

Posted: Mon Dec 18, 2017 11:54 am
by alex_jitianu
Hi Christian,

We are applying a customized version of the Docbook-FO stylesheet. You can find it at {oxygenInstallDir}/frameworks/docbook/oxygen/xsdDocDocbookCustomizationFO.xsl. To use it, duplicate the Docbook PDF scenario and change the XSL URL to point to previously mentioned path.

Best regards,
Alex