summaryrefslogtreecommitdiffstats
path: root/examples2/splitter.py
diff options
context:
space:
mode:
Diffstat (limited to 'examples2/splitter.py')
-rwxr-xr-xexamples2/splitter.py26
1 files changed, 13 insertions, 13 deletions
diff --git a/examples2/splitter.py b/examples2/splitter.py
index 1c2fef7..b2e30cc 100755
--- a/examples2/splitter.py
+++ b/examples2/splitter.py
@@ -3,12 +3,12 @@
import sys
from qt import *
-class Test(QWidget):
+class Test(TQWidget):
def __init__(self, parent=None, name='Test', f=0):
- QWidget.__init__(self, parent, name, f)
+ TQWidget.__init__(self, parent, name, f)
def paintEvent(self, e):
- p = QPainter(self)
+ p = TQPainter(self)
p.setClipRect(e.rect())
d = 1000
x1 = 0
@@ -30,31 +30,31 @@ class Test(QWidget):
if __name__=="__main__":
- a = QApplication(sys.argv)
+ a = TQApplication(sys.argv)
- s1 = QSplitter(Qt.Vertical, None, "main")
- s2 = QSplitter(Qt.Horizontal, s1, "top")
+ s1 = TQSplitter(TQt.Vertical, None, "main")
+ s2 = TQSplitter(TQt.Horizontal, s1, "top")
t1 = Test(s2)
- t1.setBackgroundColor(Qt.blue.light(180))
+ t1.setBackgroundColor(TQt.blue.light(180))
t1.setMinimumSize(50,0)
t2 = Test(s2)
- t2.setBackgroundColor(Qt.green.light(180))
- s2.setResizeMode(t2, QSplitter.KeepSize)
+ t2.setBackgroundColor(TQt.green.light(180))
+ s2.setResizeMode(t2, TQSplitter.KeepSize)
s2.moveToFirst(t2)
- s3 = QSplitter(Qt.Horizontal, s1, "bottom")
+ s3 = TQSplitter(TQt.Horizontal, s1, "bottom")
t3 = Test(s3)
- t3.setBackgroundColor(Qt.red)
+ t3.setBackgroundColor(TQt.red)
t4 = Test(s3)
- t4.setBackgroundColor(Qt.white)
+ t4.setBackgroundColor(TQt.white)
t5 = Test(s3)
t5.setMaximumHeight(250)
t5.setMinimumSize(80,50)
- t5.setBackgroundColor(Qt.yellow)
+ t5.setBackgroundColor(TQt.yellow)
s1.setOpaqueResize(1)
s2.setOpaqueResize(1)