summaryrefslogtreecommitdiffstats
path: root/Tools/idle/EditorWindow.py
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2002-01-23 15:15:13 (GMT)
committerGuido van Rossum <guido@python.org>2002-01-23 15:15:13 (GMT)
commit64e9d61a1e863d489edbc42a3c5d58d9c1eaa671 (patch)
tree8fee5c73946af3fca5ed662d6de7691a379e7164 /Tools/idle/EditorWindow.py
parentaf14289c5426743015dbbe0567e2c2677f1bff0c (diff)
downloadcpython-64e9d61a1e863d489edbc42a3c5d58d9c1eaa671.zip
cpython-64e9d61a1e863d489edbc42a3c5d58d9c1eaa671.tar.gz
cpython-64e9d61a1e863d489edbc42a3c5d58d9c1eaa671.tar.bz2
Properly fix SF bug #507298 (Gregor Lingl): shellpython2.2 -Qnew smart
indent error Use // where int division is intended. (This breaks IDLE for use with previous Python versions -- I don't care.)
Diffstat (limited to 'Tools/idle/EditorWindow.py')
-rw-r--r--Tools/idle/EditorWindow.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Tools/idle/EditorWindow.py b/Tools/idle/EditorWindow.py
index bb69a5b..f924c45 100644
--- a/Tools/idle/EditorWindow.py
+++ b/Tools/idle/EditorWindow.py
@@ -465,7 +465,7 @@ class EditorWindow:
top, bot = self.getwindowlines()
lineno = self.getlineno(mark)
height = bot - top
- newtop = max(1, lineno - height/2)
+ newtop = max(1, lineno - height//2)
text.yview(float(newtop))
def getwindowlines(self):