dita

Distinguish between odd and even page in xsl

≡放荡痞女 提交于 2021-02-11 12:34:57
问题 I have some table in my document and I want different margins for odd and even pages, so how can I distinguish a page is odd/even using when condition in xsl fo. 回答1: You want: Separate fo:simple-page-master for the odd and even pages An fo:layout-master-set that selects the correct page master for odd and even pages. E.g.: <fo:page-sequence-master master-name="PageMaster"> <fo:repeatable-page-master-alternatives> <fo:conditional-page-master-reference master-reference="OddPage" odd-or-even=

Distinguish between odd and even page in xsl

雨燕双飞 提交于 2021-02-11 12:34:04
问题 I have some table in my document and I want different margins for odd and even pages, so how can I distinguish a page is odd/even using when condition in xsl fo. 回答1: You want: Separate fo:simple-page-master for the odd and even pages An fo:layout-master-set that selects the correct page master for odd and even pages. E.g.: <fo:page-sequence-master master-name="PageMaster"> <fo:repeatable-page-master-alternatives> <fo:conditional-page-master-reference master-reference="OddPage" odd-or-even=

DITA 已死

末鹿安然 提交于 2021-01-18 22:53:01
最近在整理历史的研究文档的时候发现了还保有了一些有关 DITA 的文档。 随着技术的发展,DITA 显得非常臃肿了,并且编译处理并不是非常友好。 查询了下官方的版本历史: 已经有差不多 2 年没有更新了,由此看来 DITA 作为文档交付应该已经是日薄西山了。应该没有什么人通过写 XML 的方式来写文档了。 相反,MD 和 AsciiDoc 格式的文档却大行其道。 其主要原因是能够随意部署,并且文档结构少,约束少,更加容易写作和阅读。 作为文档来说,内容是最主要的,格式相对来说没有那么重要,如果有漂亮的格式,但是内容一团糟,又怎么会有人去看和使用呢。 回想一下曾经用过的 DITA,编译太复杂,PDF 生成问题太多,CHM 格式的文档很多时候大家都不愿意用,更多的都在使用 Github 上来写 MD 格式。 DITA 已死,就此留念。 超级复杂的文档格式。 因为是基于 XML 的,每一个段落的创作都非常复杂,你还需要考虑复杂的 XML 标签。让写作不是一种享受,简直是一种折磨。 相对 MD 格式就让人舒服多了,你只需要关注一些常用的标记,其他的都是以内容为主。 比如说 Discourse 这个社区使用的 MD 格式就非常简单,能够让所有人更多的关注内容而不是标记。 不管怎么样, DITA 也代表了人类文明出版中的小缩影。 https://www.ossez.com/t/dita

XSLT fails to transform DITA into new type

若如初见. 提交于 2020-04-30 10:32:36
问题 I have an xml as following: <?xml version="1.0" encoding="utf-8"?> <!DOCTYPE concept SYSTEM "aimlDomain.dtd"> <?xml-stylesheet type="text/xsl" href="aimlTest.xsl"?> <concept> <category> <pattern>_ TOPIC ELEMENT ATTRIBUTE</pattern> <template><srai>REQUIRED TOPIC AND MAP ELEMENT ATTRIBUTES</srai> </template> </category> <category> <pattern>TOPIC ELEMENT ATTRIBUTE _</pattern> <template><srai>REQUIRED TOPIC AND MAP ELEMENT ATTRIBUTES</srai> </template> </category> </concept> The element category

Is it possible that a directory copied and pasted to a particular directory using XHTML plugin in DITA OT 1.8.5

怎甘沉沦 提交于 2020-01-06 15:17:33
问题 Is it possible that a directory or a file copying from 'resource' folder in org.dita.xhtml to out put folder generated by the XHTML DITA OT transform. If its possible using xsl changes in plugin its possible means provide me the code. Any other way is there means please guide me the steps to do. Please assist me. 回答1: You should use the depend.preprocess.post extension point, or another one that fits your needs, to call a new Ant target. plugin.xml <plugin id="com.example.extendchunk">

Create Composed Documents with XSLT (@href)

会有一股神秘感。 提交于 2019-12-24 03:32:32
问题 How can I create a node-tree for all my referenced documents and store it into a variable with XSLT? (I´m using XSLT 2.0) This is my file structure: Root Document .XML contains all language specific documents as ditamaps <map> <navref mapref="de-DE/A.2+X000263.ditamap"/> <navref mapref="en-US/A.2+X000263.ditamap"/> <navref mapref="es-ES/A.2+X000263.ditamap"/> </map> Language specific manuals (.ditamap) - multiple documents possible <bookmap id="X000263" xml:lang="de-DE"> <chapter href="A.2

Is it possible to pass custom ANT parameters into custom plugin with DITA-OT?

一笑奈何 提交于 2019-12-23 04:09:43
问题 I have created DITA-OT PDF plugin that works good and like it should. Next step is to pass ANT parameters into my custom plugin's overriding XSLT files. As you can see this extends pdf2 plugin processing and I have custom stylesheets which are working. Here is documentation about how to do this. This works for default plugins (pdf2, xhtml. etc) http://dita-ot.github.io/1.8/dev_ref/plugin-xsltparams.html But when I try to do the same trick for my own plugin I never can run integration through.

In Oxygen XML Editor, can I automatically xcopy a folder to my Transformation's output folder?

瘦欲@ 提交于 2019-12-13 03:36:52
问题 I am using version 21 of the Oxygen XML Editor and the DITA Map WebHelp Classic (deprecated) Transformation Scenario. I have a folder that contains HTML files I want to open in a new window/tab, so that are xref'd in my XML file such as: [<b><xref href="External/aFile.html" format="html" scope="external">Some Text</xref></b>] I have a PostProcess batch script that I manually run that does an xcopy of the External folder to Oxygen's out/webhelp folder, and I would like to instead run it

xslt moving child attribute to parent

半腔热情 提交于 2019-12-11 19:38:02
问题 Input: <book> <chapter href=".."> <topicref chunk="to-content" href".."> </topicref> <topicref chunk="to-content" href".."> </topicref> </chapter> </book> Output: <book> <chapter chunk="to-content" href=".."> <topicref href".."> </topicref> <topicref href".."> </topicref> </chapter> </book> I cannot use xsl:attribute name="chunk">to-content</xsl:attribute> because it throws "creating an attribute here will fail if previous instructions create any children." warning and then error. I

Copyright statement not building

时光总嘲笑我的痴心妄想 提交于 2019-12-11 09:36:10
问题 For me, this builds the preface content, but no copyright matter. The file location is correct. From my ditamap: <frontmatter> <notices format="dita" href="preface/src/c_copyright.xml" linking="none" navtitle="Copyright and disclaimer" scope="local" toc="no" type="concept"> </notices> <booklists> <toc/> </booklists> <preface navtitle="nested Preface inside"> <topicref format="ditamap" href="maps/GSGettingStarted_preface.ditamap" navtitle="GSGettingStarted_preface"> </topicref> </preface> Am I