author | Radek Brich <radek.brich@devl.cz> |
Mon, 16 Feb 2015 21:17:43 +0100 | |
changeset 117 | 8680c2333546 |
permissions | -rwxr-xr-x |
117
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
1 |
#!/usr/bin/env python3 |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
2 |
|
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
3 |
from tuikit.core.application import Application |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
4 |
from tuikit.widgets.button import Button |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
5 |
|
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
6 |
app = Application() |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
7 |
app.add(Button('left=0'), left=0) |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
8 |
app.add(Button('left=5'), left=5, top=2) |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
9 |
app.add(Button('right=0'), right=0) |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
10 |
app.add(Button('right=5'), right=5, top=2) |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
11 |
app.add(Button('center=x'), center='x', top=3) |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
12 |
app.add(Button('center=x, left=5'), center='x', left=5, top=5) |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
13 |
app.add(Button('center=x, right=5'), center='x', right=5, top=7) |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
14 |
app.add(Button('center=xy'), center='xy') |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
15 |
app.add(Button('fill=x'), fill='x', top=9) |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
16 |
app.add(Button('fill=x, left=5'), fill='x', left=5, top=11) |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
17 |
app.add(Button('fill=x, right=5'), fill='x', right=5, top=13) |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
18 |
app.add(Button('fill=x, left=5, right=5'), fill='x', left=5, right=5, top=15) |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
19 |
|
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
20 |
app.window_manager.sig_keypress.connect(lambda ev: app.stop()) |
8680c2333546
Update FixedLayout. Add demo launcher.
Radek Brich <radek.brich@devl.cz>
parents:
diff
changeset
|
21 |
app.start() |