我试图在md
通过使用pandoc
.
首先我得到默认模板:
pandoc -D odt > template_odt.xml
我可以通过键入来绘制一条黑色水平线<text:p text:style-name="Horizontal_20_Line" />
,例如在以下位置template_odt.xml
:
...
$endif$
<text:p text:style-name="Horizontal_20_Line" />
$for(include-before)$
...
但是如何将颜色归因于这条线?样式Horizontal_20_line
在styles.xml
文件中定义:
<style:style style:name="Horizontal_20_Line"
style:display-name="Horizontal Line" style:family="paragraph"
style:parent-style-name="Standard"
style:next-style-name="Text_20_body" style:class="html">
<style:paragraph-properties fo:margin-top="0in"
fo:margin-bottom="0.1965in" style:contextual-spacing="false"
style:border-line-width-bottom="0.0008in 0.0138in 0.0008in"
fo:padding="0in" fo:border-left="none" fo:border-right="none"
fo:border-top="none" fo:border-bottom="1.11pt double #808080"
text:number-lines="false" text:line-number="0"
style:join-border="false" />
<style:text-properties fo:font-size="6pt"
style:font-size-asian="6pt" style:font-size-complex="6pt" />
</style:style>
所以 :
我可以在中添加一个属性
template_odt.xml
,例如:<text:p text:style-name="Horizontal_20_Line" line-color="red"?????/>
或者我应该修改样式
Horizontal_20_line
,如何修改?我不知道默认styles.xml
文件在哪里,也不知道如何定义样式template_odt.xml
(我所有的天真尝试都失败了)。