comparison data/plugin/macro/Image.py @ 275:2a92ddf8a7c8

Image._get_description: strip whitespae from image name
author Reimar Bauer <rb.proj AT googlemail DOT com>
date Tue, 16 Sep 2008 11:48:52 +0200
parents 1e3e876e38fb
children 03071c3569d8
comparison
equal deleted inserted replaced
274:c633f1c988e3 275:2a92ddf8a7c8
71 quotes = [quote[2:] for quote in quotes if quote.startswith('* ')] 71 quotes = [quote[2:] for quote in quotes if quote.startswith('* ')]
72 image_alias = self.attachname 72 image_alias = self.attachname
73 for line in quotes: 73 for line in quotes:
74 if line.startswith('[[') and line.endswith(']]'): 74 if line.startswith('[[') and line.endswith(']]'):
75 img, alias = line[2:-2].split('|', 1) 75 img, alias = line[2:-2].split('|', 1)
76 if img == self.attachname: 76 if img.strip() == self.attachname:
77 self.__description = alias.strip() 77 self.__description = alias.strip()
78 break 78 break
79 return self.__description 79 return self.__description
80 description = property(_get_description) 80 description = property(_get_description)
81 81