# HG changeset patch # User Andrey Skvortsov # Date 1503090672 -10800 # Node ID f68a105000be09dbe3d888c2cb5e3c5b871b45b8 # Parent 449fd504a71140e6392e7c6f4a4c702b25cf1ccf clean-up: fix PEP8 E211 whitespace before '[' or '(' diff -r 449fd504a711 -r f68a105000be controls/CustomToolTip.py --- a/controls/CustomToolTip.py Sat Aug 19 00:04:33 2017 +0300 +++ b/controls/CustomToolTip.py Sat Aug 19 00:11:12 2017 +0300 @@ -106,8 +106,8 @@ if len(self.Tip[-1]) < TOOLTIP_MAX_CHARACTERS - 3: self.Tip[-1] += "..." else: - self.Tip[-1] = self.Tip[-1]\ - [:TOOLTIP_MAX_CHARACTERS - 3] + "..." + self.Tip[-1] = self.Tip[-1][:TOOLTIP_MAX_CHARACTERS - 3] + \ + "..." else: self.Tip = tip.splitlines() diff -r 449fd504a711 -r f68a105000be controls/TextCtrlAutoComplete.py --- a/controls/TextCtrlAutoComplete.py Sat Aug 19 00:04:33 2017 +0300 +++ b/controls/TextCtrlAutoComplete.py Sat Aug 19 00:11:12 2017 +0300 @@ -110,8 +110,8 @@ class TextCtrlAutoComplete(wx.TextCtrl): - def __init__ (self, parent, choices=None, dropDownClick=True, - element_path=None, **therest): + def __init__(self, parent, choices=None, dropDownClick=True, + element_path=None, **therest): """ Constructor works just like wx.TextCtrl except you can pass in a list of choices. You can also change the choice list at any time diff -r 449fd504a711 -r f68a105000be svgui/pyjs/build.py --- a/svgui/pyjs/build.py Sat Aug 19 00:04:33 2017 +0300 +++ b/svgui/pyjs/build.py Sat Aug 19 00:11:12 2017 +0300 @@ -143,7 +143,7 @@ file_name = os.path.join(dest_path, mod_name + '.html') # if html file in output directory exists, leave it alone. - if os.path.exists (file_name): + if os.path.exists(file_name): return 0 if os.path.exists(os.path.join(dest_path, mod_name + '.css')): @@ -158,9 +158,9 @@ base_html = base_html % {'modulename': mod_name, 'title': title, 'css': css} - fh = open (file_name, 'w') - fh.write (base_html) - fh.close () + fh = open(file_name, 'w') + fh.write(base_html) + fh.close() return 1 diff -r 449fd504a711 -r f68a105000be svgui/pyjs/pyjs.py --- a/svgui/pyjs/pyjs.py Sat Aug 19 00:04:33 2017 +0300 +++ b/svgui/pyjs/pyjs.py Sat Aug 19 00:11:12 2017 +0300 @@ -588,9 +588,9 @@ k = [] if isinstance(expr, ast.Tuple): for x in expr.nodes: - k.append("(%(err)s.__name__ == %(expr)s.__name__)" % dict (err=errName, expr=self.expr(x, current_klass))) - else: - k = [" (%(err)s.__name__ == %(expr)s.__name__) " % dict (err=errName, expr=self.expr(expr, current_klass))] + k.append("(%(err)s.__name__ == %(expr)s.__name__)" % dict(err=errName, expr=self.expr(x, current_klass))) + else: + k = [" (%(err)s.__name__ == %(expr)s.__name__) " % dict(err=errName, expr=self.expr(expr, current_klass))] print >> self.output, " if(%s) {" % '||\n\t\t'.join(k) for stmt in node.handlers[0][2]: self._stmt(stmt, current_klass)