这是用于纯印刷出版物的。我们使用的出版程序 SILE 接受 xml 输入。实际上它接受类似 TeX 的输入(即 USFM),但我合作的程序员更倾向于使用 xml。
我假设 USX 的格式对程序员来说完全没问题,所以这些其他问题是为了我自己的理解。
我想这仅仅是设计决策,但我在想为什么创建 USX 的人决定让 <chapter> 表示“章节开头的数字”而不是“章节”。我对 xml 的理解是,它通常使用这样的格式:
<tag attributes=“aaa”>content</tag>
目前的情况是
<chapter number=“1” style=“c” > 没有内容
而我预期的是
<chapter number=“1” style=“c”>the actual content of the chapter<\chapter>
也许我遗漏了什么,但我看不出这是由标记重叠问题引起的。
这是另一个问题——按照我们地区宗教书籍的风格,我们的项目计划在节末而不是节首标记节号。按照 <verse> 标记目前的工作方式,我们需要使用脚本来将该标签移动到纯文本 xml 文档中的不同位置,但如果 USX 使用我认为它应该使用的格式:
<verse number=“1” style=“v”>verse text</verse>
那么让读取 xml 的程序解释该行并说“将属性 ‘number’ 打印在 ‘verse text’ 的末尾而不是开头”就会非常简单。
This is for a print-only publication. The publishing program we’re using, SILE, takes xml inputs. It would actually take a TeX-like input (i.e. USFM), but the programmer I’m working with would prefer to use xml.
I’m assuming the format of USX will work perfectly fine for the programmer, so these other questions are for my own understanding.
I guess it’s just design decisions, but I’m wondering why whoever created USX decided that <chapter> meant “the number at the beginning of a chapter” and not “chapter”. My understand of xml is that it typically uses formatting like
<tag attributes=“aaa”>content</tag>
The way things currently are
<chapter number=“1” style=“c” > has no content
Where I would expect
<chapter number=“1” style=“c”>the actual content of the chapter<\chapter>
Maybe I’m missing something, but I don’t see how this is caused by overlapping markup issues.
Here’s another issue–following the style of religious books of our region our project plans to mark verse numbers at the end of verses, not the beginning. The way the <verse> marker currently works we’ll need to use scripting to move the tag to a different position in the plain text xml document, but if USX used the format I think it ought to:
<verse number=“1” style=“v”>verse text</verse>
then it would be quite simple to have the program reading the xml interpret that line and say “print out the attribute ‘number’ at the end of ‘verse text’ instead of the beginning”.
机器翻译自 English