DITA Map EPUB args.copycss is not working
Having trouble installing Oxygen? Got a bug to report? Post it all here.
-
- Posts: 9
- Joined: Thu Jul 28, 2016 10:09 am
DITA Map EPUB args.copycss is not working
Hello <Oxygen/> team,
I am using Oxygen version 21.0 for my project. DITA-OT 3.x working great to transform my project DITA map .ditamap to HTML5 website using DITA Map HTML5, It work perfectly, which included a customize CSS file.
I am currently trying to transform the same project to ePub version, using build in DITA Map EPUB scenario type, but face some problem. This DITA Map EPUB scenario type fail to copy the custom CSS file to the ePub package even args.copycss, args.css setting are set correctly (same setting for DITA Map HTML5).
For example, if i have a custom CSS file proj_01.css in the directory c:\projects\proj_01\css and i wish to include this CSS file in the EPUB,
This is what I specify to these Ant parameter args.css with the value like:
Thank you very much.
I am using Oxygen version 21.0 for my project. DITA-OT 3.x working great to transform my project DITA map .ditamap to HTML5 website using DITA Map HTML5, It work perfectly, which included a customize CSS file.
I am currently trying to transform the same project to ePub version, using build in DITA Map EPUB scenario type, but face some problem. This DITA Map EPUB scenario type fail to copy the custom CSS file to the ePub package even args.copycss, args.css setting are set correctly (same setting for DITA Map HTML5).
For example, if i have a custom CSS file proj_01.css in the directory c:\projects\proj_01\css and i wish to include this CSS file in the EPUB,
This is what I specify to these Ant parameter args.css with the value like:
- args.copycss as "yes"
- args.cssroot as "c:\projects\proj_01\css"
- args.css as "proj_01.css"
- args.csspath as "css"
Thank you very much.
-
- Posts: 9451
- Joined: Fri Jul 09, 2004 5:18 pm
Re: DITA Map EPUB args.copycss is not working
Hi,
Try to remove the "args.cssroot" and "args.csspath" parameters and set the "args.css" parameter to "c:\projects\proj_01\css\proj_01.css".
If this still will not work I will try to take a look at it.
Regards,
Radu
Try to remove the "args.cssroot" and "args.csspath" parameters and set the "args.css" parameter to "c:\projects\proj_01\css\proj_01.css".
If this still will not work I will try to take a look at it.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 9
- Joined: Thu Jul 28, 2016 10:09 am
Re: DITA Map EPUB args.copycss is not working
Hi Radu,
Thank you for your reply. I tried your suggestion to remove remove the "args.cssroot" and "args.csspath" parameters and set the "args.css" parameter to "c:\projects\proj_01\css\proj_01.css", but the result still the same DiTA-OT does not copy the customize CSS file into to the ePub package.
Best regards,
Gevin
Thank you for your reply. I tried your suggestion to remove remove the "args.cssroot" and "args.csspath" parameters and set the "args.css" parameter to "c:\projects\proj_01\css\proj_01.css", but the result still the same DiTA-OT does not copy the customize CSS file into to the ePub package.
Best regards,
Gevin
-
- Posts: 9451
- Joined: Fri Jul 09, 2004 5:18 pm
Re: DITA Map EPUB args.copycss is not working
Hi Gevin,
I reproduced the problem on my side and added an internal issue to fix it.
As a workaround if you open the ANT build file:
OXYGEN_INSTALL_DIR\frameworks\dita\DITA-OT3.x\plugins\org.dita4publishers.epub\build_transtype-epub.xml
it has there a target which looks like this:
You can try to remove the if="isOT2" attribute from it and try to publish again.
Regards,
Radu
I reproduced the problem on my side and added an internal issue to fix it.
As a workaround if you open the ANT build file:
OXYGEN_INSTALL_DIR\frameworks\dita\DITA-OT3.x\plugins\org.dita4publishers.epub\build_transtype-epub.xml
it has there a target which looks like this:
Code: Select all
<target name="epub.xhtml.init" if="isOT2">
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 9
- Joined: Thu Jul 28, 2016 10:09 am
Re: DITA Map EPUB args.copycss is not working
Hi Radu,
Thank you for the temporary fix. I removed the if="isOT2" attribute from it and publish again, and this fixed the args.copycss issue.
Everything working perefectly now!
Best regards,
Gevin
Thank you for the temporary fix. I removed the if="isOT2" attribute from it and publish again, and this fixed the args.copycss issue.
Everything working perefectly now!
Good job, i am very appreciated for your help.Radu wrote: ↑Mon Oct 21, 2019 12:06 pm ....
As a workaround if you open the ANT build file:
OXYGEN_INSTALL_DIR\frameworks\dita\DITA-OT3.x\plugins\org.dita4publishers.epub\build_transtype-epub.xml
it has there a target which looks like this:
Code: Select all
<target name="epub.xhtml.init" if="isOT2">
Best regards,
Gevin
-
- Posts: 9
- Joined: Thu Jul 28, 2016 10:09 am
Re: DITA Map EPUB args.copycss is not working
Hi Radu,
another question,
In the ePub 3 package have a file named "nav.xhtml" that is used for a Reading Systems to retrieve navigational information. DITA-OT ePub generated content.opf which listed "nav.xhtml" as 1st item in <spine> section, this result an extra/duplicated Content page appear before actual contents.
Is there any way to remove <itemref idref="nav"/> from <spine toc="ncx"> section using DITA-OT parameter?
Thank you.
Best regards,
Gevin
another question,
In the ePub 3 package have a file named "nav.xhtml" that is used for a Reading Systems to retrieve navigational information. DITA-OT ePub generated content.opf which listed "nav.xhtml" as 1st item in <spine> section, this result an extra/duplicated Content page appear before actual contents.
Is there any way to remove <itemref idref="nav"/> from <spine toc="ncx"> section using DITA-OT parameter?
Thank you.
Best regards,
Gevin
-
- Posts: 9451
- Joined: Fri Jul 09, 2004 5:18 pm
Re: DITA Map EPUB args.copycss is not working
Hi Gevin,
I do not see a parameter to control this. There is an XSLT template:
OXYGEN_INSTALL_DIR\frameworks\dita\DITA-OT3.x\plugins\org.dita4publishers.epub\xsl\map2epubOpfImpl.xsl
which has a template which outputs it:
so commenting that xsl:if should accomplish what you want. But I saw that the table of contents seems to disappear completely from the book so I'm not sure this is what you want.
Regards,
Radu
I do not see a parameter to control this. There is an XSLT template:
OXYGEN_INSTALL_DIR\frameworks\dita\DITA-OT3.x\plugins\org.dita4publishers.epub\xsl\map2epubOpfImpl.xsl
which has a template which outputs it:
Code: Select all
<xsl:template match="*[df:class(., 'map/map')]" mode="spine">
<xsl:param name="doDebug" as="xs:boolean" tunnel="yes" select="false()"/>
<!-- Generate entries for each of the navigation files to be generated. -->
<xsl:if test="$epubtrans:isEpub3">
<itemref idref="{epubtrans:getNavId('toc')}"/>
</xsl:if>
</xsl:template>
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 9
- Joined: Thu Jul 28, 2016 10:09 am
Re: DITA Map EPUB args.copycss is not working
Hi Radu,
Thank you for your "hack" to modify the XSLT to meet my need. For my case, the ePub reader like iBook, Adobe Digital Edition or Vital Source will genarate their own version of Table of contents based on nav.xhtml, but don't need use as page in the book.
That mean, nav.xhtml is needed in the ePub package, but do not need to be display as content page or list as part of the book spine.
Thank you very much for your help again.
Best regards,
Gevin
Thank you for your "hack" to modify the XSLT to meet my need. For my case, the ePub reader like iBook, Adobe Digital Edition or Vital Source will genarate their own version of Table of contents based on nav.xhtml, but don't need use as page in the book.
That mean, nav.xhtml is needed in the ePub package, but do not need to be display as content page or list as part of the book spine.
Thank you very much for your help again.
Best regards,
Gevin
-
- Posts: 9451
- Joined: Fri Jul 09, 2004 5:18 pm
Re: DITA Map EPUB args.copycss is not working
Hi,
As an update we released Oxygen version 22 and it should have the fix for the first reported problem included.
Regards,
Radu
As an update we released Oxygen version 22 and it should have the fix for the first reported problem included.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ Artificial Intelligence (AI Positron Assistant add-on)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service