Re: [docbook-apps] adding customization layers to Oxygen XML author
Hi Carlos, If by customization layers you meant XSLT customizations, the folder where the Docbook XSLs which come bundled with Oxygen are located is this one: [Oxygen-install-dir]\frameworks\docbook\xsl A similar Docbook XSL customization in Oxygen discussion can be found on our forum: http://www.oxygenxml.com/forum/topic8795.html If you also want to make changes to the Docbook editing functionality (add actions, behaviors, change the way in which the content looks in the visual Author editing mode): Jan's link is a good starting point to see what features our Docbook editing customization currently contains. You can also contact us directly using supp...@oxygenxml.com and ask us particular questions. Our Author developer guide is located here: http://www.oxygenxml.com/doc/ug-oxygen/#topics/author-devel-guide-intro.html Regards, Radu Radu Coravu oXygen/ XML Editor, Schema Editor and XSLT Editor/Debugger http://www.oxygenxml.com On 3/29/2014 8:35 AM, Jan Tosovsky wrote: On 2014-03-28 Carlos Araya wrote: I've downloaded XML author and after looking at resources I'm drawing a blank as to how to add my customization layers to the editor's workflow. Does anyone have a guide or can point me to resources to get this accomplished? All Docbook related stuff is stored in the Frameworkd folder in the Oxygen installation directory. Browsing this content you'll get a rought idea what can be changed. You can place there your document templates, stylesheetes, customized DTDs, customized CSS for displaying the content when editing, customized toolbars, context menus etc. A good starting point is e.g. here: http://oxygenxml.com/doc/ug-author/#topics/author-docbook4-doc-type.html hth, Jan - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org -- - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org
[docbook-apps] link to entry tag of the table
Hi, I have to make an internal and external link to an entry tag of a table in the document. What i am seeing currently is that the link goes to the beginning of the page that contains the table (table is actually at the bottom of that page) but not to the entry tag of the table directly. How should i go about this issue? Thanks and Regards, Anmol
Re: [docbook-apps] link to entry tag of the table
Hi Anmol, Are we talking about HTML output here? If so, have you set the stylesheet param 'generate.id.attributes' to nonzero? What version of the stylesheets? Can you peek in the output and see if the entry id values from the DocBook source are getting into the output? Bob Stayton Sagehill Enterprises b...@sagehill.net On 3/31/2014 6:10 AM, anmol gupta wrote: Hi, I have to make an internal and external link to an entry tag of a table in the document. What i am seeing currently is that the link goes to the beginning of the page that contains the table (table is actually at the bottom of that page) but not to the entry tag of the table directly. How should i go about this issue? Thanks and Regards, Anmol - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org
[docbook-apps] setting note(admonition) property.
Hi, Points 1,2 and 3 mentioned below were used to set properties of note I found xsl customization for note on the link: http://www.sagehill.net/docbookxsl/CustomAdmonitions.html 1. xsl:template name=nongraphical.admonition xsl:variable name=id xsl:call-template name=object.id/ /xsl:variable fo:block space-before.minimum=0.8em space-before.optimum=1em space-before.maximum=1.2em start-indent=0.25in end-indent=0.25in *border-top=0.5pt solid black border-bottom=0.5pt solid black padding-top=4pt padding-bottom=4pt* id={$id} xsl:if test=$admon.textlabel != 0 or title fo:block keep-with-next='always' xsl:use-attribute-sets=admonition.title.properties xsl:apply-templates select=. mode=object.title.markup/ /fo:block /xsl:if fo:block xsl:use-attribute-sets=admonition.properties xsl:apply-templates/ /fo:block /fo:block /xsl:template Questions: what does this the text in the xsl:if test=$admon.textlabel... imply? What properties of the admonition.tittle.properties and admonition,properties are taken? i mean what does this syntax about them explain? 2. Then i had written following code note title: xsl:attribute-set name=admonition.title.properties xsl:attribute name=font-size13pt/xsl:attribute xsl:attribute name=color#ec/xsl:attribute xsl:attribute name=font-weightbold/xsl:attribute xsl:attribute name=hyphenatetrue/xsl:attribute xsl:attribute name=keep-with-next.within-columnalways/xsl:attribute /xsl:attribute-set Question: What if i want the title to be bold and italics both? What does hyphenate and keep-with-next.within-column do? 3. for note body: xsl:attribute-set name=admonition.properties xsl:attribute name=background-color#ec/xsl:attribute xsl:attribute name=text-indent1em/xsl:attribute /xsl:attribute-set Finally, I want to use points 2 and 3 in point 1 itself. And define all the properties in just one single block i.e. point 1 Please help me understand this. Thanks and Regards, Anmol
[docbook-apps] Alternate color of table rows.
Hi, i used following syntax as follows: xsl:template name=table.row.properties xsl:variable name=tabstyle xsl:call-template name=tabstyle/ /xsl:variable xsl:variable name=bgcolor xsl:call-template name=dbfo-attribute xsl:with-param name=pis select=processing-instruction('dbfo')/ xsl:with-param name=attribute select='bgcolor'/ /xsl:call-template /xsl:variable xsl:variable name=rownum xsl:number from=d:tgroup count=d:row/ /xsl:variable xsl:choose xsl:when test=$bgcolor != '' xsl:attribute name=background-color xsl:value-of select=$bgcolor/ /xsl:attribute /xsl:when !--xsl:when test=$tabstyle = 'striped'-- xsl:when test=$rownum mod 2 != 0 xsl:attribute name=background-color#EE/xsl:attribute /xsl:when /xsl:when !--/xsl:when-- /xsl:choose /xsl:template The problem that i am facing is that the *above code is setting the background color of the entry of the thead also* which i don't want*. * I think $rownum mod 2 != 0 is treating row 1 of thead also and coloring it. How can i prevent this? Thanks and Regards, Anmol
Re: [docbook-apps] link to entry tag of the table
Hi Bob, I am using 1.78.1 version for docbook 5 for generating pdf. I didnt quite understand where to look for entry id in output. Could you please elaborate little bit more. Thanks and Regards, Anmol On Mon, Mar 31, 2014 at 9:38 PM, Bob Stayton b...@sagehill.net wrote: Hi Anmol, Are we talking about HTML output here? If so, have you set the stylesheet param 'generate.id.attributes' to nonzero? What version of the stylesheets? Can you peek in the output and see if the entry id values from the DocBook source are getting into the output? Bob Stayton Sagehill Enterprises b...@sagehill.net On 3/31/2014 6:10 AM, anmol gupta wrote: Hi, I have to make an internal and external link to an entry tag of a table in the document. What i am seeing currently is that the link goes to the beginning of the page that contains the table (table is actually at the bottom of that page) but not to the entry tag of the table directly. How should i go about this issue? Thanks and Regards, Anmol
[docbook-apps] Fwd: setting note(admonition) property.
Hi, Points 1,2 and 3 mentioned below were used to set properties of note I found xsl customization for note on the link: http://www.sagehill.net/docbookxsl/CustomAdmonitions.html 1. xsl:template name=nongraphical.admonition xsl:variable name=id xsl:call-template name=object.id/ /xsl:variable fo:block space-before.minimum=0.8em space-before.optimum=1em space-before.maximum=1.2em start-indent=0.25in end-indent=0.25in *border-top=0.5pt solid black border-bottom=0.5pt solid black padding-top=4pt padding-bottom=4pt* id={$id} xsl:if test=$admon.textlabel != 0 or title fo:block keep-with-next='always' xsl:use-attribute-sets=admonition.title.properties xsl:apply-templates select=. mode=object.title.markup/ /fo:block /xsl:if fo:block xsl:use-attribute-sets=admonition.properties xsl:apply-templates/ /fo:block /fo:block /xsl:template Questions: what does this the text in the xsl:if test=$admon.textlabel... imply? What properties of the admonition.tittle.properties and admonition,properties are taken? i mean what does this syntax about them explain? 2. Then i had written following code note title: xsl:attribute-set name=admonition.title.properties xsl:attribute name=font-size13pt/xsl:attribute xsl:attribute name=color#ec/xsl:attribute xsl:attribute name=font-weightbold/xsl:attribute xsl:attribute name=hyphenatetrue/xsl:attribute xsl:attribute name=keep-with-next.within-columnalways/xsl:attribute /xsl:attribute-set Question: What if i want the title to be bold and italics both? What does hyphenate and keep-with-next.within-column do? 3. for note body: xsl:attribute-set name=admonition.properties xsl:attribute name=background-color#ec/xsl:attribute xsl:attribute name=text-indent1em/xsl:attribute /xsl:attribute-set Finally, I want to use points 2 and 3 in point 1 itself. And define all the properties in just one single block i.e. point 1 Please help me understand this. Thanks and Regards, Anmol
Re: [docbook-apps] link to entry tag of the table
Hi Anmol, In the case of PDF output, I meant to look in the .fo file for the id attributes from the entry elements. If you are using FOP to apply the stylesheet, it will not generate a separate .fo file, though. I went ahead and confirmed that the id attributes on an entry element are indeed output to the .fo file, and the FOP internal destination code is being properly generated. But a PDF generated by FOP does not scroll down to the location of the table cell on the page. I tested the same file with XEP, and it does, so I think this is a limitation of FOP. Bob Stayton Sagehill Enterprises b...@sagehill.net On 3/31/2014 11:17 AM, anmol gupta wrote: Hi Bob, I am using 1.78.1 version for docbook 5 for generating pdf. I didnt quite understand where to look for entry id in output. Could you please elaborate little bit more. Thanks and Regards, Anmol On Mon, Mar 31, 2014 at 9:38 PM, Bob Stayton b...@sagehill.net wrote: Hi Anmol, Are we talking about HTML output here? If so, have you set the stylesheet param 'generate.id.attributes' to nonzero? What version of the stylesheets? Can you peek in the output and see if the entry id values from the DocBook source are getting into the output? Bob Stayton Sagehill Enterprises b...@sagehill.net On 3/31/2014 6:10 AM, anmol gupta wrote: Hi, I have to make an internal and external link to an entry tag of a table in the document. What i am seeing currently is that the link goes to the beginning of the page that contains the table (table is actually at the bottom of that page) but not to the entry tag of the table directly. How should i go about this issue? Thanks and Regards, Anmol - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org
Re: [docbook-apps] Alternate color of table rows.
Hi Anmol, In the xsl:number element, change d:tgroup to d:tbody, and add a new clause to the xsl:choose before the 'striped' test: xsl:choose ... xsl:when test=ancestor::d:thead !-- do nothing in thead -- /xsl:when ... Bob Stayton Sagehill Enterprises b...@sagehill.net On 3/31/2014 11:08 AM, anmol gupta wrote: Hi, i used following syntax as follows: xsl:template name=table.row.properties xsl:variable name=tabstyle xsl:call-template name=tabstyle/ /xsl:variable xsl:variable name=bgcolor xsl:call-template name=dbfo-attribute xsl:with-param name=pis select=processing-instruction('dbfo')/ xsl:with-param name=attribute select='bgcolor'/ /xsl:call-template /xsl:variable xsl:variable name=rownum xsl:number from=d:tgroup count=d:row/ /xsl:variable xsl:choose xsl:when test=$bgcolor != '' xsl:attribute name=background-color xsl:value-of select=$bgcolor/ /xsl:attribute /xsl:when !--xsl:when test=$tabstyle = 'striped'-- xsl:when test=$rownum mod 2 != 0 xsl:attribute name=background-color#EE/xsl:attribute /xsl:when /xsl:when !--/xsl:when-- /xsl:choose /xsl:template The problem that i am facing is that the *above code is setting the background color of the entry of the thead also* which i don't want*. * I think $rownum mod 2 != 0 is treating row 1 of thead also and coloring it. How can i prevent this? Thanks and Regards, Anmol - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org
Re: [docbook-apps] xslt for imageobject link
Hi Fredrik, I think you could replace the risky $object.index+1 with @condition='original' in the predicate for $link. The extra namespace declaration can probably be eliminated by making sure your customization layer adds d to the list of namespace prefixes in the exclude-result-prefixes attribute of the xsl:stylesheet element. Bob Stayton Sagehill Enterprises b...@sagehill.net On 3/27/2014 5:02 AM, Fredrik Unger wrote: Hi, I figured out that the select.mediaobject was not involved but the HTML template : xsl:template match=d:mediaobject|d:mediaobjectco With the below script[1] I get what I want. The variable selection link = object.index+1 is not very nice but works for now. Just that an extra xmlns:d=http://docbook.org/ns/docbook; is added. div xmlns:d=http://docbook.org/ns/docbook; class=mediaobjectimg src=./IMG-500.JPG/ (a href=IMG.JPGspanOriginal/span/a)div class=captionp This is a picture /p/div/div More tests are needed to find bugs.. :) Fredrik Unger [1] xsl:template match=d:mediaobject|d:mediaobjectco xsl:variable name=olist select=d:imageobject|d:imageobjectco |d:videoobject|d:audioobject |d:textobject/ xsl:variable name=object.index xsl:call-template name=select.mediaobject.index xsl:with-param name=olist select=$olist/ xsl:with-param name=count select=1/ /xsl:call-template /xsl:variable xsl:variable name=object select=$olist[position() = $object.index]/ xsl:variable name=link select=$olist[position() = $object.index+1]/ xsl:variable name=align xsl:value-of select=$object/descendant::d:imagedata[@align][1]/@align/ /xsl:variable div xsl:apply-templates select=. mode=common.html.attributes/ xsl:if test=$align != '' xsl:attribute name=align xsl:value-of select=$align/ /xsl:attribute /xsl:if xsl:call-template name=id.attribute/ xsl:call-template name=anchor/ xsl:apply-templates select=$object/ xsl:apply-templates select=$link/ xsl:apply-templates select=d:caption/ /div /xsl:template xsl:template match=d:imageobject[@condition='original'] xsl:text (/xsl:text xsl:element name=a xsl:attribute name=href xsl:value-of select=d:imagedata/@fileref/ /xsl:attribute spanOriginal/span /xsl:element xsl:text)/xsl:text /xsl:template On 2014-03-26 19:17, Fredrik Unger wrote: Hi, I have the following snippet : mediaobject imageobject imagedata fileref=IMG-500.JPG/ /imageobject imageobject condition=original imagedata fileref=IMG.JPG/ /imageobject caption para This is a picture /para /caption /mediaobject I would like to produce this html or some version there of : .. img src=IMG-500.JPG / a href=IMG.JPGOriginal/a p This is a picture/p .. - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org
Re: [docbook-apps] setting note(admonition) property.
Hi Anmol, If you want to better understand how attribute-sets work, I would suggest you read this section: http://www.sagehill.net/docbookxsl/AttributeSets.html To better understand what XSL-FO properties are available and what they do, you need a good XSL-FO reference. See Appendix D of the standard, for example: http://www.w3.org/TR/xsl/ or the W3C Schools reference: http://www.w3schools.com/xslfo/xslfo_reference.asp Bob Stayton Sagehill Enterprises b...@sagehill.net On 3/31/2014 11:02 AM, anmol gupta wrote: Hi, Points 1,2 and 3 mentioned below were used to set properties of note I found xsl customization for note on the link: http://www.sagehill.net/docbookxsl/CustomAdmonitions.html 1. xsl:template name=nongraphical.admonition xsl:variable name=id xsl:call-template name=object.id/ /xsl:variable fo:block space-before.minimum=0.8em space-before.optimum=1em space-before.maximum=1.2em start-indent=0.25in end-indent=0.25in *border-top=0.5pt solid black border-bottom=0.5pt solid black padding-top=4pt padding-bottom=4pt* id={$id} xsl:if test=$admon.textlabel != 0 or title fo:block keep-with-next='always' xsl:use-attribute-sets=admonition.title.properties xsl:apply-templates select=. mode=object.title.markup/ /fo:block /xsl:if fo:block xsl:use-attribute-sets=admonition.properties xsl:apply-templates/ /fo:block /fo:block /xsl:template Questions: what does this the text in the xsl:if test=$admon.textlabel... imply? What properties of the admonition.tittle.properties and admonition,properties are taken? i mean what does this syntax about them explain? 2. Then i had written following code note title: xsl:attribute-set name=admonition.title.properties xsl:attribute name=font-size13pt/xsl:attribute xsl:attribute name=color#ec/xsl:attribute xsl:attribute name=font-weightbold/xsl:attribute xsl:attribute name=hyphenatetrue/xsl:attribute xsl:attribute name=keep-with-next.within-columnalways/xsl:attribute /xsl:attribute-set Question: What if i want the title to be bold and italics both? What does hyphenate and keep-with-next.within-column do? 3. for note body: xsl:attribute-set name=admonition.properties xsl:attribute name=background-color#ec/xsl:attribute xsl:attribute name=text-indent1em/xsl:attribute /xsl:attribute-set Finally, I want to use points 2 and 3 in point 1 itself. And define all the properties in just one single block i.e. point 1 Please help me understand this. Thanks and Regards, Anmol - To unsubscribe, e-mail: docbook-apps-unsubscr...@lists.oasis-open.org For additional commands, e-mail: docbook-apps-h...@lists.oasis-open.org