wiki-archive/twiki/pub/TWiki/KupuContrib/_kupu/silva/xmlconfig.kupu

149 lines
3.2 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<kupu:feature
name="xmlconfig"
implementation="silva"
xmlns="http://www.w3.org/1999/xhtml"
xmlns:kupu="http://kupu.oscom.org/namespaces/dist"
>
<!-- Silva specific configuration -->
<kupu:part name="defaultconfig">
<dst>..</dst>
<use_css>0</use_css>
<reload_after_save>1</reload_after_save>
<strict_output>1</strict_output>
<content_type>application/xhtml+xml</content_type>
<compatible_singletons>1</compatible_singletons>
<cleanup_expressions>
<set>
<name>Convert single quotes to curly ones</name>
<expression>
<reg>
(\W)'
</reg>
<replacement>
\1
</replacement>
</expression>
<expression>
<reg>
'
</reg>
<replacement>
</replacement>
</expression>
</set>
<set>
<name>Convert double quotes to curly ones</name>
<expression>
<reg>
(\W)"
</reg>
<replacement>
\1“
</replacement>
</expression>
<expression>
<reg>
"
</reg>
<replacement>
</replacement>
</expression>
</set>
<set>
<name>Convert single dashes to n-dashes</name>
<expression>
<reg>
([^\-])\-([^\-])
</reg>
<replacement>
\1\2
</replacement>
</expression>
<expression>
<reg>
([^\-])\-$
</reg>
<replacement>
\1
</replacement>
</expression>
<expression>
<reg>
^\-([^\-])
</reg>
<replacement>
\1
</replacement>
</expression>
<expression>
<reg>
^\-$
</reg>
<replacement>
</replacement>
</expression>
</set>
<set>
<name>Convert double dashes to m-dashes</name>
<expression>
<reg>
([^\-])\-\-([^\-])
</reg>
<replacement>
\1—\2
</replacement>
</expression>
<expression>
<reg>
([^\-])\-\-$
</reg>
<replacement>
\1—
</replacement>
</expression>
<expression>
<reg>
^\-\-([^\-])
</reg>
<replacement>
—\1
</replacement>
</expression>
<expression>
<reg>
^\-\-$
</reg>
<replacement>
</replacement>
</expression>
</set>
<set>
<name>Reduce whitespace in source</name>
<expression>
<reg>
[\n\r\t]
</reg>
<replacement>
\x20
</replacement>
</expression>
<expression>
<reg>
[ ]{2}
</reg>
<replacement>
\x20
</replacement>
</expression>
</set>
</cleanup_expressions>
</kupu:part>
</kupu:feature>