comparison MoinMoin/converter/text_html_text_moin_wiki.py @ 1724:40345ea89a70

text_html_text_moin_wiki: converts now images on subpages, http images independend from ImageLink
author Reimar Bauer <rb.proj AT googlemail DOT com>
date Tue, 09 Jan 2007 00:00:17 +0100
parents 366650d8772b
children ef67391ffced
comparison
equal deleted inserted replaced
1723:4916528e1cd7 1724:40345ea89a70
1189 if node.attributes.has_key("target"): 1189 if node.attributes.has_key("target"):
1190 target = node.attributes.get("target").nodeValue 1190 target = node.attributes.get("target").nodeValue
1191 1191
1192 # Attachment image 1192 # Attachment image
1193 if (title and title.startswith("attachment:") and 1193 if (title and title.startswith("attachment:") and
1194 wikiutil.isPicture(wikiutil.url_unquote(title[len("attachment:"):]))): 1194 wikiutil.isPicture(wikiutil.url_unquote(title[len("attachment:"):]))) or title is None or src.startswith('http'):
1195 if height is None and width is None and target is None: 1195 if height is None and width is None and target is None and alt is None:
1196 self.text.extend([self.white_space, 1196 self.text.extend([self.white_space,
1197 wikiutil.url_unquote(title), 1197 wikiutil.url_unquote(title),
1198 self.white_space]) 1198 self.white_space])
1199 else: 1199 else:
1200 # use ImageLink for resized images 1200 # use ImageLink for resized images
1201 il_parms = "%s" % wikiutil.url_unquote(title[len("attachment:"):]) 1201 if title is None:
1202 il_parms = "%s" % wikiutil.url_unquote(src)
1203 else:
1204 if src.startswith('http'):
1205 il_parms = "%s" % wikiutil.url_unquote(src)
1206 else:
1207 il_parms = "%s" % wikiutil.url_unquote(title[len("attachment:"):])
1202 if target is not None: 1208 if target is not None:
1203 il_parms += ",%s" % target 1209 il_parms += ",%s" % target
1204 if width is not None: 1210 if width is not None:
1205 il_parms += ",width=%s" % width 1211 il_parms += ",width=%s" % width
1206 if height is not None: 1212 if height is not None: