changeset 158:cc31ed821e35

text_x_arnica: removed whitespace lines
author Reimar Bauer <rb.proj AT googlemail DOT com>
date Sat, 12 Jul 2008 14:53:07 +0200
parents 0116eb3e1099
children 543c75e16a5b
files data/plugin/parser/text_x_arnica.py
diffstat 1 files changed, 0 insertions(+), 25 deletions(-) [+]
line wrap: on
line diff
--- a/data/plugin/parser/text_x_arnica.py	Sat Jul 12 14:42:22 2008 +0200
+++ b/data/plugin/parser/text_x_arnica.py	Sat Jul 12 14:53:07 2008 +0200
@@ -37,9 +37,7 @@
         becomes a nested form and this do raise lot's of strict html4.01 errors"""
     def format(self):
         fmt = self.request.formatter
-
         result = []
-
         havefilters = False
         for col in self.data.columns:
             if col.autofilter:
@@ -61,7 +59,6 @@
                 result.append(fmt.strong(1))
                 result.append(col.label or col.name)
                 result.append(fmt.strong(0))
-
                 if col.autofilter:
                     result.append(fmt.linebreak(False))
                     select = '<select %s onchange="dbw_update_search(\'%s\');">%s</select>' % (
@@ -69,7 +66,6 @@
                                       self.data_id,
                                       self._filteroptions(idx))
                     result.append(fmt.rawHTML(select))
-
                 result.append(fmt.table_cell(0))
             result.append(fmt.table_row(0))
 
@@ -78,7 +74,6 @@
         row = self.data.next()
         if row is not None:
             filters = [None] * len(row)
-
             if havefilters:
                 for idx in range(len(row)):
                     name = '%sfilter%d' % (self.data_id, idx)
@@ -86,10 +81,8 @@
                         filters[idx] = self.request.form[name][0]
                         if filters[idx] == self._all:
                             filters[idx] = None
-
         while row:
             hidden = False
-
             if havefilters:
                 # check if row needs to be hidden due to filtering
                 for idx in range(len(row)):
@@ -105,7 +98,6 @@
                         if data != filters[idx]:
                             hidden = True
                             break
-
             if not hidden:
                 result.append(fmt.table_row(1))
                 for idx in range(len(row)):
@@ -119,9 +111,7 @@
                         result.append(unicode(row[idx]))
                     result.append(fmt.table_cell(0))
                 result.append(fmt.table_row(0))
-
             row = self.data.next()
-
         result.append(fmt.table(0))
 
         return ''.join(result)
@@ -165,13 +155,11 @@
             thumbnail_width = '%dpx' % int(thumbnail_width[0])
         else:
             thumbnail_width = '%g%s' % thumbnail_width
-
     if webnail_width:
         if webnail_width[1] == 'px':
             webnail_width = '%dpx' % int(webnail_width[0])
         else:
             webnail_width = '%g%s' % webnail_width
-
     return locals()
 
 # ToDo may be move to wikiutil
@@ -194,7 +182,6 @@
 def _get_files(request, pagename):
     # get files dependent on isPicture and ignores tmp. files
     # ToDo remove tmp. files check later
-
     files = AttachFile._get_files(request, pagename)
     files = [fn for fn in files if wikiutil.isPicture(fn) and not fn.startswith('tmp.')]
     return files
@@ -233,7 +220,6 @@
 
         self.inner_table_style = ' style="border-style:none; margin:10px;"'
         self.td_style = ' align="center" style="padding:0; margin:2px 2px; border-style:none"'
-
         self.web = [] # array for webnails
         self.full = [] # array for  images
         self.thumb = [] # array for thumbnails
@@ -248,7 +234,6 @@
         """
         if not self.request.user.may.delete(self.pagename):
             return ''
-
         return '''
         <form action="%(url)s" method="POST" enctype="multipart/form-data">
             <div class="rotate-to-left">
@@ -440,10 +425,8 @@
         quotes = self.raw.split('\n')
         quotes = [quote.strip() for quote in quotes]
         quotes = [quote[2:] for quote in quotes if quote.startswith('* ')]
-
         image = []
         text = []
-
         for line in quotes:
             if line.startswith('[[') and line.endswith(']]'):
                 img, alias = line[2:-2].split('|', 1)
@@ -495,9 +478,7 @@
             keys = image_dict.keys()
             keys.sort()
             all_files = [image_dict[txt] for txt in keys]
-
         image_dict.clear()
-
         if self.reverse_sort:
             all_files.reverse()
         if all_files:
@@ -590,17 +571,13 @@
             self.request.write(self.formatter.preformatted(0))
             self.request.write(self.formatter.div(0))
             self.request.write(self.formatter.div(0))
-
         COLUMNS = min([self.columns, len(self.full)])
         if self.album:
             COLUMNS = 1
-
         data = TupleDataset()
         data.columns = []
-
         for dummy in range(COLUMNS):
             data.columns.extend([Column('', label=(''))])
-
         col_count = 1
         result = []
         for image in self.full:
@@ -637,13 +614,11 @@
                 text = _("""You can't use as album image: \
                          "%(album_image)s" because it does not exists or it is not listed \
                          in your item list!""") % {"album_image": album_image, }
-
             result.append(''.join(self.formatter.text(text)))
 
         # adds the last row if it is not filled up
         if result:
             data.addRow(tuple(result))
-
         browser = _DataBrowserWidget(self.request, show_header=False)
         browser.setData(data)
         return browser.format()