8000 Whitespace adjustments for PEP8 compliance · matplotlib/matplotlib@507b6a4 · GitHub
[go: up one dir, main page]

Skip to content

Commit 507b6a4

Browse files
committed
Whitespace adjustments for PEP8 compliance
1 parent 1f37c22 commit 507b6a4

File tree

1 file changed

+5
-14
lines changed

1 file changed

+5
-14
lines changed

lib/matplotlib/widgets.py

Lines changed: 5 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -678,10 +678,6 @@ def __init__(self, ax, label, initial = '',
678678
self.params_to_disable += [key]
679679

680680
self.text = initial
681-
682-
683-
684-
685681
self.label = ax.text(0.0,0.5, label,
686682
verticalalignment='center',
687683
horizontalalignment='right',
@@ -699,7 +695,6 @@ def __init__(self, ax, label, initial = '',
699695
self.cursor = self.ax.vlines(0, 0, 0) #because this is initialized, _render_cursor
700696
self.cursor.set_visible(False) #can assume that cursor exists
701697

702-
703698
self.connect_event('button_press_event', self._click)
704699
self.connect_event('button_release_event', self._release)
705700
self.connect_event('motion_notify_event', self._motion)
@@ -714,10 +709,7 @@ def __init__(self, ax, label, initial = '',
714709
self._lastcolor = color
715710

716711
self.capturekeystrokes = False
717-
718-
719-
720-
712+
721713
def _make_text_disp(self, string):
722714
return self.ax.text(self.DIST_FROM_LEFT, 0.5, string,
723715
verticalalignment='center',
@@ -733,8 +725,7 @@ def _rendercursor(self):
733725
no_text = False
734726
if(widthtext == "" or widthtext == " " or widthtext == " "):
735727
no_text = widthtext == ""
736-
widthtext = ","
737-
728+
widthtext = ","
738729

739730
wt_disp = self._make_text_disp(widthtext)
740731

@@ -746,8 +737,7 @@ def _rendercursor(self):
746737
if no_text:
747738
bb[1, 0] = bb[0, 0]
748739
#hack done
749-
self.cursor.set_visible(False)
750-
740+
self.cursor.set_visible(False)
751741

752742
self.cursor = self.ax.vlines(bb[1, 0], bb[0, 1], bb[1, 1])
753743
self.ax.figure.canvas.draw()
@@ -832,7 +822,6 @@ def _click(self, event):
832822
self.cursor_index = len(self.text)
833823
self._rendercursor()
834824

835-
836825
def _motion(self, event):
837826
if self.ignore(event):
838827
return
@@ -856,6 +845,7 @@ def on_text_change(self, func):
856845
self.change_observers[cid] = func
857846
self.cnt += 1
858847
return cid
848+
859849
def on_submit(self, func):
860850
"""
861851
When the user hits enter or leaves the submision box, call this *func* with event
@@ -866,6 +856,7 @@ def on_submit(self, func):
866856
self.submit_observers[cid] = func
867857
self.cnt += 1
868858
return cid
859+
869860
def disconnect(self, cid):
870861
"""remove the observer with connection id *cid*"""
871862
try:

0 commit comments

Comments
 (0)
0