Attachment 'text_moin_wiki.diff'
Download 1 --- text_moin_wiki_old.py 2007-02-18 17:00:12.000000000 +0100
2 +++ text_moin_wiki.py 2007-02-18 21:05:12.000000000 +0100
3 @@ -209,12 +209,27 @@
4 if scheme == 'drawing':
5 return self.formatter.attachment_drawing(fname, text)
6
7 - # check for image, and possibly return IMG tag (images are always inlined)
8 - if not kw.get('pretty_url', 0) and wikiutil.isPicture(fname):
9 - return self.formatter.attachment_image(fname)
10 + # check if AccessibleMoin is wanted. In AccessibleMoin we don't want to confuse
11 + # attachment of images with inline of images anymore. It's like IE confusing alt
12 + # with title.
13 + accessible_moin = False
14 + if hasattr(self.request.cfg, 'accessible_moin'):
15 + accessible_moin = self.request.cfg.accessible_moin
16 + if not accessible_moin:
17 + # check for image, and possibly return IMG tag (images are always inlined)
18 + if not kw.get('pretty_url', 0) and wikiutil.isPicture(fname):
19 + return self.formatter.attachment_image(fname)
20
21 # inline the attachment
22 if scheme == 'inline':
23 + # in AccessibleMoin pictures are inlined as other stuff is inlined. For proper
24 + # picture display use ImageLink or Image macro
25 + if accessible_moin:
26 + if not kw.get('pretty_url', 0) and wikiutil.isPicture(fname):
27 + return (self.formatter.preformatted(1) +
28 + self.formatter.attachment_image(fname) +
29 + self.formatter.preformatted(0) +
30 + self.formatter.attachment_link(fname, text))
31 return self.formatter.attachment_inlined(fname, text)
32
33 return self.formatter.attachment_link(fname, text)
Attached Files
To refer to attachments on a page, use attachment:filename, as shown below in the list of files. Do NOT use the URL of the [get] link, since this is subject to change and can break easily.You are not allowed to attach a file to this page.