summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKohei Yoshida <kyoshida@novell.com>2009-12-24 00:17:57 -0500
committerKohei Yoshida <kyoshida@novell.com>2009-12-24 00:17:57 -0500
commit8bebd7371adb7f67e5ba6caecf085f221e6c4731 (patch)
tree5cd91297911a642587cb614b4700c1654d0c1295
parent3e3884cd3193f8b01ce22332a27ecb49ce4714d7 (diff)
Handle switchline and item elements.
-rw-r--r--source/docbook.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/source/docbook.py b/source/docbook.py
index 2f86f5e..d97dbd5 100644
--- a/source/docbook.py
+++ b/source/docbook.py
@@ -180,6 +180,17 @@ class DocBookConverter:
dest.appendElement('warning').appendContent('take embedded content from ' + href)
else:
dest = self.__walkXHP(embed, dest)
+
+ elif src.name == 'switchinline':
+ # For now, always select the <defaultinline> child element.
+ content = src.firstChildByName('defaultinline').getContent()
+ dest.appendContent(content)
+
+ elif src.name == 'item':
+ # an <item> element has a 'type' attribute that specifies how this
+ # text span should be formatted.
+ dest.appendContent(src.getContent())
+
elif src.name == 'link':
for child in src.getChildNodes():
self.__walkXHP(child, dest)