diff -r 82bfc75bcd9d -r 105c20fdeb19 editors/TextViewer.py --- a/editors/TextViewer.py Fri Oct 05 13:48:54 2018 +0300 +++ b/editors/TextViewer.py Fri Oct 05 14:22:01 2018 +0300 @@ -24,6 +24,7 @@ from __future__ import absolute_import +from __future__ import division import re from types import * @@ -893,7 +894,7 @@ if self.TextSyntax in ["ST", "ALL"]: indent = self.Editor.GetLineIndentation(line) if LineStartswith(lineText.strip(), self.BlockStartKeywords): - indent = (indent / 2 + 1) * 2 + indent = (indent // 2 + 1) * 2 self.Editor.AddText("\n" + " " * indent) key_handled = True elif key == wx.WXK_BACK: @@ -902,7 +903,7 @@ indent = self.Editor.GetColumn(self.Editor.GetCurrentPos()) if lineText.strip() == "" and len(lineText) > 0 and indent > 0: self.Editor.DelLineLeft() - self.Editor.AddText(" " * ((max(0, indent - 1) / 2) * 2)) + self.Editor.AddText(" " * ((max(0, indent - 1) // 2) * 2)) key_handled = True if not key_handled: event.Skip()