summaryrefslogtreecommitdiffstats
path: root/examples2/table.py
diff options
context:
space:
mode:
Diffstat (limited to 'examples2/table.py')
-rwxr-xr-xexamples2/table.py22
1 files changed, 11 insertions, 11 deletions
diff --git a/examples2/table.py b/examples2/table.py
index 36e2cf9..f9db886 100755
--- a/examples2/table.py
+++ b/examples2/table.py
@@ -14,8 +14,8 @@ class Table(TQTableView):
self.setCellWidth(100)
self.setCellHeight(30)
self.setTableFlags(Tbl_vScrollBar |
- Tbl_hScrollBar |
- Tbl_clipCellPainting)
+ Tbl_hScrollBar |
+ Tbl_clipCellPainting)
self.resize(400,200)
self.contents = [''] * (numRows * numCols)
@@ -64,27 +64,27 @@ class Table(TQTableView):
if key == Key_Left:
if self.curCol > 0:
self.curCol = self.curCol - 1
- edge = self.leftCell()
+ edge = self.leftCell()
if self.curCol < edge:
- self.setLeftCell(edge-1)
+ self.setLeftCell(edge-1)
elif key == Key_Right:
if self.curCol < self.numCols()-1:
self.curCol = self.curCol + 1
- edge = self.lastColVisible()
+ edge = self.lastColVisible()
if self.curCol >= edge:
- self.setLeftCell(self.leftCell()+1)
+ self.setLeftCell(self.leftCell()+1)
elif key == Key_Up:
if self.curRow > 0:
self.curRow = self.curRow - 1
- edge = self.topCell()
+ edge = self.topCell()
if self.curRow < edge:
- self.setTopCell(edge-1)
+ self.setTopCell(edge-1)
elif key == Key_Down:
if self.curRow < self.numRows()-1:
self.curRow = self.curRow + 1
- edge = self.lastRowVisible()
- if self.curRow >= edge:
- self.setTopCell(self.topCell()+1)
+ edge = self.lastRowVisible()
+ if self.curRow >= edge:
+ self.setTopCell(self.topCell()+1)
else:
ke.ignore()
return