pyvguicom 1.0.0__py3-none-any.whl → 1.0.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of pyvguicom might be problematic. Click here for more details.
- pyvguicom/__init__.py +1 -0
- pyvguicom/custwidg.py +110 -0
- pyvguicom/pgbox.py +59 -118
- pyvguicom/pgbutt.py +3 -2
- pyvguicom/pgentry.py +114 -19
- pyvguicom/pggui.py +99 -14
- pyvguicom/pgsel.py +439 -0
- pyvguicom/pgsimp.py +34 -265
- pyvguicom/pgtextview.py +0 -1
- pyvguicom/pgutils.py +495 -157
- pyvguicom/testbutt.py +26 -24
- pyvguicom/testcust.py +49 -0
- pyvguicom/testentry.py +93 -0
- pyvguicom/testlettsel.py +98 -0
- pyvguicom/testnums.py +6 -11
- pyvguicom/testroot.py +7 -6
- pyvguicom/testsimple.py +22 -28
- pyvguicom/testtextv.py +3 -12
- {pyvguicom-1.0.0.dist-info → pyvguicom-1.0.1.dist-info}/METADATA +11 -5
- pyvguicom-1.0.1.dist-info/RECORD +27 -0
- pyvguicom/sutil.py +0 -344
- pyvguicom-1.0.0.dist-info/RECORD +0 -23
- {pyvguicom-1.0.0.dist-info → pyvguicom-1.0.1.dist-info}/WHEEL +0 -0
- {pyvguicom-1.0.0.dist-info → pyvguicom-1.0.1.dist-info}/top_level.txt +0 -0
pyvguicom/testbutt.py
CHANGED
|
@@ -14,8 +14,8 @@ from gi.repository import Pango
|
|
|
14
14
|
gi.require_version('WebKit2', '4.0')
|
|
15
15
|
from gi.repository import WebKit2
|
|
16
16
|
|
|
17
|
-
|
|
18
|
-
|
|
17
|
+
import pgbutt
|
|
18
|
+
import pggui
|
|
19
19
|
|
|
20
20
|
class testWin(Gtk.Window):
|
|
21
21
|
|
|
@@ -26,49 +26,51 @@ class testWin(Gtk.Window):
|
|
|
26
26
|
|
|
27
27
|
vbox13 = Gtk.VBox()
|
|
28
28
|
|
|
29
|
-
vbox13.pack_start(
|
|
30
|
-
vbox13.pack_start(Gtk.Label.new("
|
|
31
|
-
#vbox13.pack_start(
|
|
29
|
+
vbox13.pack_start(pggui.ySpacer(), 0, 0, 0)
|
|
30
|
+
vbox13.pack_start(Gtk.Label.new("Smallbutt TEST implementation"), 1, 1, 0)
|
|
31
|
+
#vbox13.pack_start(pggui.ySpacer(), 1, 1, 0)
|
|
32
32
|
|
|
33
33
|
hbox13 = Gtk.HBox()
|
|
34
|
-
hbox13.pack_start(
|
|
35
|
-
butt3x = smallbutt(" _Find in Text ", self.findx, "")
|
|
34
|
+
hbox13.pack_start(pggui.ySpacer(), 1, 1, 0)
|
|
35
|
+
butt3x = pgbutt.smallbutt(" _Find in Text ", self.findx, "")
|
|
36
36
|
hbox13.pack_start(butt3x, 0, 0, 0)
|
|
37
|
-
hbox13.pack_start(
|
|
38
|
-
butt3z = smallbutt(" _Search All ", self.findx, "")
|
|
37
|
+
hbox13.pack_start(pggui.ySpacer(), 0, 0, 0)
|
|
38
|
+
butt3z = pgbutt.smallbutt(" _Search All ", self.findx, "")
|
|
39
39
|
hbox13.pack_start(butt3z, 0, 0, 0)
|
|
40
|
-
hbox13.pack_start(
|
|
40
|
+
hbox13.pack_start(pggui.ySpacer(), 1, 1, 0)
|
|
41
41
|
|
|
42
42
|
hbox16 = Gtk.HBox()
|
|
43
|
-
hbox16.pack_start(
|
|
44
|
-
butt3x = smallbutt("_Align in Text", self.findx, "")
|
|
43
|
+
hbox16.pack_start(pggui.ySpacer(), 1, 1, 0)
|
|
44
|
+
butt3x = pgbutt.smallbutt("_Align in Text", self.findx, "")
|
|
45
45
|
hbox16.pack_start(butt3x, 0, 0, 0)
|
|
46
|
-
hbox16.pack_start(
|
|
47
|
-
butt3z = smallbutt("_Delete All", self.delx, "")
|
|
46
|
+
hbox16.pack_start(pggui.ySpacer(), 0, 0, 0)
|
|
47
|
+
butt3z = pgbutt.smallbutt("_Delete All", self.delx, "")
|
|
48
48
|
hbox16.pack_start(butt3z, 0, 0, 0)
|
|
49
|
-
hbox16.pack_start(
|
|
49
|
+
hbox16.pack_start(pggui.ySpacer(), 1, 1, 0)
|
|
50
50
|
|
|
51
51
|
hbox14 = Gtk.HBox()
|
|
52
|
-
hbox14.pack_start(
|
|
53
|
-
butt3y = smallbutt("E_xit", self.exit_prog, "Exit program")
|
|
52
|
+
hbox14.pack_start(pggui.ySpacer(), 1, 1, 0)
|
|
53
|
+
butt3y = pgbutt.smallbutt("E_xit", self.exit_prog, "Exit program")
|
|
54
54
|
hbox14.pack_start(butt3y, 0, 0, 0)
|
|
55
|
-
hbox14.pack_start(
|
|
55
|
+
hbox14.pack_start(pggui.ySpacer(), 1, 1, 0)
|
|
56
56
|
|
|
57
57
|
hbox15 = Gtk.HBox()
|
|
58
|
-
hbox15.pack_start(
|
|
59
|
-
butt3z = Gtk.Button.new_with_mnemonic("Regular _Button")
|
|
58
|
+
hbox15.pack_start(pggui.ySpacer(), 1, 1, 0)
|
|
59
|
+
butt3z = Gtk.Button.new_with_mnemonic("Regular small _Button")
|
|
60
60
|
butt3z.set_relief(Gtk.ReliefStyle.NONE)
|
|
61
61
|
butt3z.connect("clicked", self.regbutt)
|
|
62
62
|
hbox15.pack_start(butt3z, 0, 0, 0)
|
|
63
|
-
hbox15.pack_start(
|
|
63
|
+
hbox15.pack_start(pggui.ySpacer(), 1, 1, 0)
|
|
64
|
+
|
|
64
65
|
|
|
65
66
|
vbox13.pack_start(hbox13, 0, 0, 0)
|
|
66
67
|
vbox13.pack_start(hbox16, 0, 0, 0)
|
|
67
|
-
#vbox13.pack_start(hbox15, 0, 0, 0)
|
|
68
68
|
vbox13.pack_start(hbox14, 0, 0, 0)
|
|
69
|
-
vbox13.pack_start(
|
|
69
|
+
vbox13.pack_start(hbox15, 0, 0, 0)
|
|
70
|
+
|
|
71
|
+
vbox13.pack_start(pggui.ySpacer(), 1, 1, 0)
|
|
70
72
|
|
|
71
|
-
self.set_size_request(
|
|
73
|
+
self.set_size_request(400, 300)
|
|
72
74
|
self.add(vbox13)
|
|
73
75
|
self.show_all()
|
|
74
76
|
|
pyvguicom/testcust.py
ADDED
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
#!/usr/bin/env python
|
|
2
|
+
|
|
3
|
+
import os, sys, getopt, signal, select, string, time
|
|
4
|
+
import struct, stat, base64, random, zlib
|
|
5
|
+
|
|
6
|
+
import gi
|
|
7
|
+
gi.require_version("Gtk", "3.0")
|
|
8
|
+
from gi.repository import Gtk
|
|
9
|
+
from gi.repository import Gdk
|
|
10
|
+
from gi.repository import GObject
|
|
11
|
+
from gi.repository import GLib
|
|
12
|
+
from gi.repository import Pango
|
|
13
|
+
|
|
14
|
+
gi.require_version('PangoCairo', '1.0')
|
|
15
|
+
from gi.repository import PangoCairo
|
|
16
|
+
|
|
17
|
+
import custwidg
|
|
18
|
+
|
|
19
|
+
if __name__ == "__main__":
|
|
20
|
+
|
|
21
|
+
w = Gtk.Window()
|
|
22
|
+
w.set_size_request(400, 300)
|
|
23
|
+
w.connect("destroy", Gtk.main_quit)
|
|
24
|
+
|
|
25
|
+
vbox = Gtk.VBox()
|
|
26
|
+
hbox = Gtk.HBox()
|
|
27
|
+
|
|
28
|
+
sw = custwidg.SimpleWidget()
|
|
29
|
+
|
|
30
|
+
hbox.pack_start(Gtk.Label(label=" b "), 0, 0, 0)
|
|
31
|
+
hbox.pack_start(sw, 1, 1, 0)
|
|
32
|
+
hbox.pack_start(Gtk.Label(label=" e "), 0, 0, 0)
|
|
33
|
+
|
|
34
|
+
vbox.pack_start(Gtk.Label(label=" t "), 0, 0, 0)
|
|
35
|
+
vbox.pack_start(hbox, 1, 1, 0)
|
|
36
|
+
vbox.pack_start(Gtk.Label(label=" b "), 0, 0, 0)
|
|
37
|
+
|
|
38
|
+
butt = Gtk.Button.new_with_mnemonic("E_xit")
|
|
39
|
+
butt.connect("clicked", Gtk.main_quit)
|
|
40
|
+
vbox.pack_start(butt, 0, 0, 2)
|
|
41
|
+
|
|
42
|
+
w.add(vbox)
|
|
43
|
+
w.show_all()
|
|
44
|
+
#w.present()
|
|
45
|
+
|
|
46
|
+
#signal.signal(signal.SIGINT, signal.SIG_DFL)
|
|
47
|
+
Gtk.main()
|
|
48
|
+
|
|
49
|
+
|
pyvguicom/testentry.py
ADDED
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
#!/usr/bin/env python
|
|
2
|
+
|
|
3
|
+
from __future__ import print_function
|
|
4
|
+
|
|
5
|
+
import os, sys, getopt, signal, select, string, time
|
|
6
|
+
import struct, stat, base64, random, zlib
|
|
7
|
+
|
|
8
|
+
import gi
|
|
9
|
+
gi.require_version("Gtk", "3.0")
|
|
10
|
+
from gi.repository import Gtk
|
|
11
|
+
from gi.repository import Gdk
|
|
12
|
+
from gi.repository import GObject
|
|
13
|
+
from gi.repository import GLib
|
|
14
|
+
|
|
15
|
+
import pgentry
|
|
16
|
+
import pgutils
|
|
17
|
+
import pggui
|
|
18
|
+
|
|
19
|
+
# ------------------------------------------------------------------------
|
|
20
|
+
class testwin(Gtk.Window):
|
|
21
|
+
|
|
22
|
+
def __init__(self):
|
|
23
|
+
Gtk.Window.__init__(self)
|
|
24
|
+
#self.set_default_size(800, 600)
|
|
25
|
+
self.set_position(Gtk.WindowPosition.CENTER)
|
|
26
|
+
self.connect("unmap", Gtk.main_quit)
|
|
27
|
+
|
|
28
|
+
# ------------------------------------------------------------------------
|
|
29
|
+
|
|
30
|
+
class pgtestwin(testwin):
|
|
31
|
+
|
|
32
|
+
def __init__(self):
|
|
33
|
+
|
|
34
|
+
testwin.__init__(self)
|
|
35
|
+
|
|
36
|
+
hbox5 = Gtk.HBox()
|
|
37
|
+
|
|
38
|
+
self.label = Gtk.Label.new("Test strings here")
|
|
39
|
+
hbox5.pack_start(self.label, 1, 1, 2)
|
|
40
|
+
|
|
41
|
+
gridx = Gtk.Grid()
|
|
42
|
+
gridx.set_column_spacing(6)
|
|
43
|
+
gridx.set_row_spacing(6)
|
|
44
|
+
|
|
45
|
+
vbox = Gtk.VBox()
|
|
46
|
+
|
|
47
|
+
rowcnt = 0
|
|
48
|
+
self.dat_dict = {}
|
|
49
|
+
sumx = Gtk.HBox()
|
|
50
|
+
buttx2 = Gtk.Button.new_with_mnemonic("Sele_ct Date")
|
|
51
|
+
tp1 =("Full Nam_e: ", "name", "Enter full name (TAB to advance)", None)
|
|
52
|
+
tp2 = ("Date o_f birth: ", "dob", "Date of birth, YYYY/MM/DD", None)
|
|
53
|
+
lab1, lab2 = pgentry.gridquad(gridx, rowcnt, 0, tp1, tp2, buttx2)
|
|
54
|
+
#buttx2.connect("clicked", self.pressed_dob, lab2)
|
|
55
|
+
self.dat_dict['name'] = lab1
|
|
56
|
+
self.dat_dict['dob'] = lab2
|
|
57
|
+
rowcnt += 1
|
|
58
|
+
|
|
59
|
+
#gridx.attach(pggui.vspacer(8), 0, rowcnt, 1, 1)
|
|
60
|
+
|
|
61
|
+
tp3 = ("Location of birth: ", "lob", "Location: City / Country", None)
|
|
62
|
+
tp4 = ("Nick Name: ", "nick", "Enter nick name / Alias if available", None)
|
|
63
|
+
lab3, lab4 = pgentry.gridquad(gridx, 0, rowcnt, tp3, tp4)
|
|
64
|
+
self.dat_dict['lob'] = lab3
|
|
65
|
+
self.dat_dict['nick'] = lab4
|
|
66
|
+
rowcnt += 1
|
|
67
|
+
|
|
68
|
+
tp6x = ("Notes: ", "", "Text for Notes. Press Shift Enter to advance", None)
|
|
69
|
+
lab6x = pgentry.gridsingle(gridx, 0, rowcnt, tp6x)
|
|
70
|
+
self.dat_dict['notes'] = lab6x
|
|
71
|
+
rowcnt += 1
|
|
72
|
+
|
|
73
|
+
#gridx.attach(pggui.vspacer(8), 0, rowcnt, 1, 1)
|
|
74
|
+
#rowcnt += 1
|
|
75
|
+
|
|
76
|
+
hbox2 = Gtk.HBox()
|
|
77
|
+
hbox2.pack_start(gridx, 1, 1, 2)
|
|
78
|
+
|
|
79
|
+
vbox.pack_start(hbox2, 0, 0, 2)
|
|
80
|
+
vbox.pack_start(hbox5, 0, 0, 2)
|
|
81
|
+
|
|
82
|
+
butt = Gtk.Button.new_with_mnemonic("E_xit")
|
|
83
|
+
butt.connect("clicked", Gtk.main_quit)
|
|
84
|
+
vbox.pack_start(butt, 0, 0, 2)
|
|
85
|
+
|
|
86
|
+
self.add(vbox)
|
|
87
|
+
self.show_all()
|
|
88
|
+
|
|
89
|
+
tw = pgtestwin()
|
|
90
|
+
#print("test")
|
|
91
|
+
Gtk.main()
|
|
92
|
+
|
|
93
|
+
# EOF
|
pyvguicom/testlettsel.py
ADDED
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
#!/usr/bin/env python
|
|
2
|
+
|
|
3
|
+
from __future__ import print_function
|
|
4
|
+
|
|
5
|
+
import os, sys, getopt, signal, select, string, time
|
|
6
|
+
import struct, stat, base64, random, zlib
|
|
7
|
+
|
|
8
|
+
from pgsel import *
|
|
9
|
+
from pgutils import *
|
|
10
|
+
|
|
11
|
+
# ------------------------------------------------------------------------
|
|
12
|
+
class testwin(Gtk.Window):
|
|
13
|
+
|
|
14
|
+
def __init__(self):
|
|
15
|
+
Gtk.Window.__init__(self)
|
|
16
|
+
#self.set_default_size(1024, 768)
|
|
17
|
+
#self.set_default_size(800, 600)
|
|
18
|
+
self.set_position(Gtk.WindowPosition.CENTER)
|
|
19
|
+
self.connect("unmap", Gtk.main_quit)
|
|
20
|
+
|
|
21
|
+
def wrapscroll(what):
|
|
22
|
+
|
|
23
|
+
scroll2 = Gtk.ScrolledWindow()
|
|
24
|
+
scroll2.add(what)
|
|
25
|
+
frame2 = Gtk.Frame()
|
|
26
|
+
frame2.add(scroll2)
|
|
27
|
+
return frame2
|
|
28
|
+
|
|
29
|
+
# ------------------------------------------------------------------------
|
|
30
|
+
|
|
31
|
+
class pgtestwin(testwin):
|
|
32
|
+
|
|
33
|
+
def __init__(self):
|
|
34
|
+
|
|
35
|
+
testwin.__init__(self)
|
|
36
|
+
|
|
37
|
+
#hbox = Gtk.HBox();
|
|
38
|
+
|
|
39
|
+
vbox = Gtk.VBox()
|
|
40
|
+
|
|
41
|
+
self.selector = LetterNumberSel(self.letterfilter, "Mono 16", " ")
|
|
42
|
+
self.selector.set_tooltip_text("Arrow key to navigate, enter / space key to filter")
|
|
43
|
+
|
|
44
|
+
hbox2 = Gtk.HBox();
|
|
45
|
+
hbox2.pack_start(Gtk.Label.new(" "), 0, 0, 2)
|
|
46
|
+
hbox2.pack_start(self.selector , 1, 1, 2)
|
|
47
|
+
hbox2.pack_start(Gtk.Label.new(" "), 0, 0, 2)
|
|
48
|
+
vbox.pack_start(hbox2, 0, 0, 2)
|
|
49
|
+
|
|
50
|
+
hbox3 = Gtk.HBox();
|
|
51
|
+
self.num = NumberSel("1 2 3 4 5 6 7 8 9", self.letterfilter, "Mono 16")
|
|
52
|
+
self.num.set_tooltip_text("Arrow key to navigate, enter / space key to filter")
|
|
53
|
+
hbox3.pack_start(Gtk.Label.new(" "), 1, 1, 2)
|
|
54
|
+
hbox3.pack_start(self.num, 0, 0, 2)
|
|
55
|
+
hbox3.pack_start(Gtk.Label.new(" "), 1, 1, 2)
|
|
56
|
+
vbox.pack_start(hbox3, 0, 0, 2)
|
|
57
|
+
|
|
58
|
+
hbox4 = Gtk.HBox();
|
|
59
|
+
self.num = HourSel(self.letterfilter)
|
|
60
|
+
self.num.set_tooltip_text("Arrow key to navigate, enter / space key to filter")
|
|
61
|
+
hbox4.pack_start(Gtk.Label.new(" "), 1, 1, 2)
|
|
62
|
+
hbox4.pack_start(self.num, 0, 0, 2)
|
|
63
|
+
hbox4.pack_start(Gtk.Label.new(" "), 1, 1, 2)
|
|
64
|
+
vbox.pack_start(hbox4, 0, 0, 2)
|
|
65
|
+
|
|
66
|
+
hbox4a = Gtk.HBox();
|
|
67
|
+
self.minx = MinSel(self.letterfilter)
|
|
68
|
+
self.minx.set_tooltip_text("Arrow key to navigate, enter / space key to filter")
|
|
69
|
+
hbox4a.pack_start(Gtk.Label.new(" "), 1, 1, 2)
|
|
70
|
+
hbox4a.pack_start(self.minx, 0, 0, 2)
|
|
71
|
+
hbox4a.pack_start(Gtk.Label.new(" "), 1, 1, 2)
|
|
72
|
+
vbox.pack_start(hbox4a, 0, 0, 2)
|
|
73
|
+
|
|
74
|
+
#vbox.pack_start(hbox, 1, 1, 2)
|
|
75
|
+
|
|
76
|
+
hbox5 = Gtk.HBox()
|
|
77
|
+
self.label = Gtk.Label.new("Test callback strings here.")
|
|
78
|
+
hbox5.pack_start(self.label, 1, 1, 2)
|
|
79
|
+
vbox.pack_start(hbox5, 0, 0, 2)
|
|
80
|
+
|
|
81
|
+
butt = Gtk.Button.new_with_mnemonic("E_xit")
|
|
82
|
+
butt.connect("clicked", Gtk.main_quit)
|
|
83
|
+
vbox.pack_start(butt, 0, 0, 2)
|
|
84
|
+
|
|
85
|
+
self.add(vbox)
|
|
86
|
+
self.show_all()
|
|
87
|
+
|
|
88
|
+
def letterfilter(self, letter):
|
|
89
|
+
print("letterfilter '%s'" % letter)
|
|
90
|
+
self.label.set_text("Callback: '%s'" % letter)
|
|
91
|
+
|
|
92
|
+
tw = pgtestwin()
|
|
93
|
+
|
|
94
|
+
#print("test")
|
|
95
|
+
|
|
96
|
+
Gtk.main()
|
|
97
|
+
|
|
98
|
+
# EOF
|
pyvguicom/testnums.py
CHANGED
|
@@ -12,7 +12,7 @@ from gi.repository import Gdk
|
|
|
12
12
|
from gi.repository import GObject
|
|
13
13
|
from gi.repository import GLib
|
|
14
14
|
|
|
15
|
-
from
|
|
15
|
+
from pgsel import *
|
|
16
16
|
from pgutils import *
|
|
17
17
|
from pggui import *
|
|
18
18
|
from pgbox import *
|
|
@@ -26,19 +26,11 @@ class testwin(Gtk.Window):
|
|
|
26
26
|
|
|
27
27
|
def __init__(self):
|
|
28
28
|
Gtk.Window.__init__(self)
|
|
29
|
-
self.set_default_size(1024, 768)
|
|
29
|
+
#self.set_default_size(1024, 768)
|
|
30
30
|
#self.set_default_size(800, 600)
|
|
31
31
|
self.set_position(Gtk.WindowPosition.CENTER)
|
|
32
32
|
self.connect("unmap", Gtk.main_quit)
|
|
33
33
|
|
|
34
|
-
def wrapscroll(what):
|
|
35
|
-
|
|
36
|
-
scroll2 = Gtk.ScrolledWindow()
|
|
37
|
-
scroll2.add(what)
|
|
38
|
-
frame2 = Gtk.Frame()
|
|
39
|
-
frame2.add(scroll2)
|
|
40
|
-
return frame2
|
|
41
|
-
|
|
42
34
|
# ------------------------------------------------------------------------
|
|
43
35
|
|
|
44
36
|
class pgtestwin(testwin):
|
|
@@ -82,6 +74,10 @@ class pgtestwin(testwin):
|
|
|
82
74
|
vbox.pack_start(hbox, 1, 1, 2)
|
|
83
75
|
vbox.pack_start(hbox5, 0, 0, 2)
|
|
84
76
|
|
|
77
|
+
butt = Gtk.Button.new_with_mnemonic("E_xit")
|
|
78
|
+
butt.connect("clicked", Gtk.main_quit)
|
|
79
|
+
vbox.pack_start(butt, 0, 0, 2)
|
|
80
|
+
|
|
85
81
|
self.add(vbox)
|
|
86
82
|
self.show_all()
|
|
87
83
|
|
|
@@ -110,7 +106,6 @@ class pgtestwin(testwin):
|
|
|
110
106
|
pass
|
|
111
107
|
|
|
112
108
|
tw = pgtestwin()
|
|
113
|
-
|
|
114
109
|
cnt = 0;
|
|
115
110
|
|
|
116
111
|
def handler_tick(ww):
|
pyvguicom/testroot.py
CHANGED
|
@@ -15,7 +15,7 @@ from gi.repository import Pango
|
|
|
15
15
|
#from gi.repository import WebKit2
|
|
16
16
|
|
|
17
17
|
from pgbutt import *
|
|
18
|
-
|
|
18
|
+
import pggui
|
|
19
19
|
|
|
20
20
|
# Allow the core to search pydbase
|
|
21
21
|
#fff = os.path.realpath(os.path.dirname(__file__) + os.sep + "../pydbase/")
|
|
@@ -100,7 +100,7 @@ class testWin(Gtk.Window):
|
|
|
100
100
|
|
|
101
101
|
vbox13 = Gtk.VBox()
|
|
102
102
|
|
|
103
|
-
#vbox13.pack_start(
|
|
103
|
+
#vbox13.pack_start(pggui.ySpacer(), 0, 0, 0)
|
|
104
104
|
vbox13.pack_start(Gtk.Label.new(" Test root entry window implementation "), 1, 1, 0)
|
|
105
105
|
|
|
106
106
|
#popup.set_titlebar(Gtk.Button())
|
|
@@ -109,16 +109,17 @@ class testWin(Gtk.Window):
|
|
|
109
109
|
self.arr = []
|
|
110
110
|
for aa in range(3):
|
|
111
111
|
self.arr.append(PopWin())
|
|
112
|
-
|
|
112
|
+
|
|
113
|
+
vbox13.pack_start(pggui.ySpacer(), 1, 1, 0)
|
|
113
114
|
|
|
114
115
|
hbox14 = Gtk.HBox()
|
|
115
|
-
hbox14.pack_start(
|
|
116
|
+
hbox14.pack_start(pggui.ySpacer(), 1, 1, 0)
|
|
116
117
|
butt3y = smallbutt("E_xit", self.exit_prog, "Exit program")
|
|
117
118
|
hbox14.pack_start(butt3y, 0, 0, 0)
|
|
118
|
-
hbox14.pack_start(
|
|
119
|
+
hbox14.pack_start(pggui.ySpacer(), 1, 1, 0)
|
|
119
120
|
|
|
120
121
|
vbox13.pack_start(hbox14, 0, 0, 0)
|
|
121
|
-
vbox13.pack_start(
|
|
122
|
+
vbox13.pack_start(pggui.ySpacer(12), 0, 0, 0)
|
|
122
123
|
|
|
123
124
|
self.set_size_request(300, 200)
|
|
124
125
|
self.add(vbox13)
|
pyvguicom/testsimple.py
CHANGED
|
@@ -5,32 +5,27 @@ from __future__ import print_function
|
|
|
5
5
|
import os, sys, getopt, signal, select, string, time
|
|
6
6
|
import struct, stat, base64, random, zlib
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
import gi
|
|
9
|
+
gi.require_version("Gtk", "3.0")
|
|
10
|
+
from gi.repository import Gtk
|
|
11
|
+
from gi.repository import Gdk
|
|
12
|
+
from gi.repository import GLib
|
|
13
|
+
from gi.repository import GObject
|
|
14
|
+
from gi.repository import Pango
|
|
10
15
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
# Gtk.main_quit()
|
|
16
|
+
import pgsimp
|
|
17
|
+
import pgutils
|
|
14
18
|
|
|
15
19
|
# ------------------------------------------------------------------------
|
|
16
20
|
class testwin(Gtk.Window):
|
|
17
21
|
|
|
18
22
|
def __init__(self):
|
|
19
23
|
Gtk.Window.__init__(self)
|
|
20
|
-
self.set_default_size(1024, 768)
|
|
21
|
-
|
|
24
|
+
#self.set_default_size(1024, 768)
|
|
25
|
+
self.set_default_size(800, 600)
|
|
22
26
|
self.set_position(Gtk.WindowPosition.CENTER)
|
|
23
27
|
self.connect("unmap", Gtk.main_quit)
|
|
24
28
|
|
|
25
|
-
|
|
26
|
-
def wrapscroll(what):
|
|
27
|
-
|
|
28
|
-
scroll2 = Gtk.ScrolledWindow()
|
|
29
|
-
scroll2.add(what)
|
|
30
|
-
frame2 = Gtk.Frame()
|
|
31
|
-
frame2.add(scroll2)
|
|
32
|
-
return frame2
|
|
33
|
-
|
|
34
29
|
# ------------------------------------------------------------------------
|
|
35
30
|
|
|
36
31
|
class pgtestwin(testwin):
|
|
@@ -48,30 +43,27 @@ class pgtestwin(testwin):
|
|
|
48
43
|
|
|
49
44
|
vbox = Gtk.VBox()
|
|
50
45
|
|
|
51
|
-
self.treeview = SimpleTree(("Hour", "Subject", "Alarm", "Notes"))
|
|
52
|
-
frame2 = wrapscroll(self.treeview)
|
|
46
|
+
self.treeview = pgsimp.SimpleTree(("Hour", "Subject", "Alarm", "Notes"))
|
|
47
|
+
frame2 = pgutils.wrapscroll(self.treeview)
|
|
53
48
|
hbox.pack_start(frame2, 1, 1, 2)
|
|
54
49
|
|
|
55
|
-
self.editor = SimpleEdit()
|
|
56
|
-
frame3 = wrapscroll(self.editor)
|
|
50
|
+
self.editor = pgsimp.SimpleEdit()
|
|
51
|
+
frame3 = pgutils.wrapscroll(self.editor)
|
|
57
52
|
hbox.pack_start(frame3, 1, 1, 2)
|
|
58
53
|
|
|
59
|
-
self.selector = LetterNumberSel(self.letterfilter, "Mono 16")
|
|
60
|
-
hbox2.pack_start(self.selector , 1, 1, 2)
|
|
61
|
-
|
|
62
54
|
vbox.pack_start(hbox3, 0, 0, 2)
|
|
63
55
|
vbox.pack_start(hbox2, 0, 0, 2)
|
|
64
56
|
vbox.pack_start(hbox4, 0, 0, 2)
|
|
65
57
|
vbox.pack_start(hbox, 1, 1, 2)
|
|
66
58
|
vbox.pack_start(hbox5, 0, 0, 2)
|
|
67
59
|
|
|
60
|
+
butt = Gtk.Button.new_with_mnemonic("E_xit")
|
|
61
|
+
butt.connect("clicked", Gtk.main_quit)
|
|
62
|
+
vbox.pack_start(butt, 0, 0, 2)
|
|
63
|
+
|
|
68
64
|
self.add(vbox)
|
|
69
65
|
self.show_all()
|
|
70
66
|
|
|
71
|
-
def letterfilter(self, letter):
|
|
72
|
-
#print("letterfilter", letter)
|
|
73
|
-
self.label.set_text(letter)
|
|
74
|
-
|
|
75
67
|
tw = pgtestwin()
|
|
76
68
|
|
|
77
69
|
#print("test")
|
|
@@ -79,7 +71,8 @@ tw = pgtestwin()
|
|
|
79
71
|
def fillrand():
|
|
80
72
|
aaa = []
|
|
81
73
|
for aa in range(10):
|
|
82
|
-
aaa.append( (randstr(12), randstr(12),
|
|
74
|
+
aaa.append( (pgutils.randstr(12), pgutils.randstr(12),
|
|
75
|
+
pgutils.randstr(12), pgutils.randstr(12)) )
|
|
83
76
|
return aaa
|
|
84
77
|
|
|
85
78
|
aaa = fillrand()
|
|
@@ -101,3 +94,4 @@ for aa in aaa:
|
|
|
101
94
|
|
|
102
95
|
Gtk.main()
|
|
103
96
|
|
|
97
|
+
# EOF
|
pyvguicom/testtextv.py
CHANGED
|
@@ -1,20 +1,11 @@
|
|
|
1
1
|
#!/usr/bin/env python
|
|
2
2
|
|
|
3
3
|
'''
|
|
4
|
-
|
|
5
4
|
This is a test application for driving the pgTextView control;
|
|
6
5
|
It has load / save functionality.
|
|
7
|
-
|
|
8
6
|
'''
|
|
9
|
-
|
|
10
7
|
import os, sys, getopt, signal, random, time, warnings
|
|
11
8
|
|
|
12
|
-
#from pgutil import *
|
|
13
|
-
#from pgui import *
|
|
14
|
-
|
|
15
|
-
import pgutils
|
|
16
|
-
import pgtextview
|
|
17
|
-
|
|
18
9
|
import gi
|
|
19
10
|
gi.require_version("Gtk", "3.0")
|
|
20
11
|
from gi.repository import Gtk
|
|
@@ -23,12 +14,12 @@ from gi.repository import GLib
|
|
|
23
14
|
from gi.repository import GObject
|
|
24
15
|
from gi.repository import Pango
|
|
25
16
|
|
|
26
|
-
import
|
|
27
|
-
import
|
|
17
|
+
import pgutils
|
|
18
|
+
import pgtextview
|
|
28
19
|
|
|
29
20
|
#deftext = "It puzzles me when I see a person lacking fundamentals is \
|
|
30
21
|
# able to amass a fortune to the tune of billions. What is even more \
|
|
31
|
-
#puzziling is that they beleive their 'BS' and
|
|
22
|
+
#puzziling is that they beleive their own 'BS' and openly flout all."
|
|
32
23
|
|
|
33
24
|
# The pango example text
|
|
34
25
|
|
|
@@ -1,13 +1,19 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: pyvguicom
|
|
3
|
-
Version: 1.0.
|
|
3
|
+
Version: 1.0.1
|
|
4
4
|
Summary: High power secure server GUI utility helpers.
|
|
5
|
-
Home-page: https://github.com/pglen/
|
|
5
|
+
Home-page: https://github.com/pglen/pyguicom.git
|
|
6
6
|
Author: Peter Glen
|
|
7
7
|
Author-email: peterglen99@gmail.com
|
|
8
|
-
Classifier:
|
|
9
|
-
Classifier:
|
|
10
|
-
Classifier:
|
|
8
|
+
Classifier: Development Status :: 6 - Mature
|
|
9
|
+
Classifier: Intended Audience :: End Users/Desktop
|
|
10
|
+
Classifier: Intended Audience :: Developers
|
|
11
|
+
Classifier: Intended Audience :: System Administrators
|
|
12
|
+
Classifier: License :: OSI Approved :: Python Software Foundation License
|
|
13
|
+
Classifier: Operating System :: Microsoft :: Windows
|
|
14
|
+
Classifier: Operating System :: POSIX
|
|
15
|
+
Classifier: Programming Language :: Python
|
|
16
|
+
Classifier: Topic :: Software Development :: Libraries
|
|
11
17
|
Requires-Python: >=3
|
|
12
18
|
Description-Content-Type: text/markdown
|
|
13
19
|
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
pyvguicom/__init__.py,sha256=2k_ZeqU7FvqZMFqGm-EYRiV98uxUxmiy5wXygvIobPU,13
|
|
2
|
+
pyvguicom/browsewin.py,sha256=ylzec-uvankcsA_2LqlEVcl0C8FjDvXA2KY-0AQBrFw,7530
|
|
3
|
+
pyvguicom/custwidg.py,sha256=oaBg9ZeYORcBklXxZjN6jdeaQaisdLDZllshYy-w9QM,3693
|
|
4
|
+
pyvguicom/htmledit.py,sha256=gSxabFFGFxgaNvYtWOsXaaHCzYB-r6i7J5dhVLriQ94,10064
|
|
5
|
+
pyvguicom/pgbox.py,sha256=kI25mzT1o0PP-q6DT1Tg32geHKslnxIN5FjqVYe77Fc,20271
|
|
6
|
+
pyvguicom/pgbutt.py,sha256=GP_to9fMGuQXmAlYlHcvCYLHaCOb76mTt-SFvYS5BwY,6723
|
|
7
|
+
pyvguicom/pgentry.py,sha256=4-V2MylX5yw3_71z-bb80vlNuOy8NZsC20yDkY9kMlY,7882
|
|
8
|
+
pyvguicom/pggui.py,sha256=I7dUfap2dP_e4LEL3Nk5SGMyqq-1Knt0RhusaKk26HE,43189
|
|
9
|
+
pyvguicom/pgsel.py,sha256=6XAY9q-d1TmJLZk4NQ3roO76QLFSqP8hu1dmw5Z8EkM,13185
|
|
10
|
+
pyvguicom/pgsimp.py,sha256=CrdyTrvtii3KCS-HAJ1W6WDnfRqmkHyI_dRHHzRrTBU,7628
|
|
11
|
+
pyvguicom/pgtextview.py,sha256=aAlmJX4UISI3MQtUI-_OoFacVLFIhcNIILzezC_x0DI,29341
|
|
12
|
+
pyvguicom/pgutils.py,sha256=m2pbKP_6GE1xoJw7KTFouQAr8Hu7zvYD-uyw11u8Ejc,41430
|
|
13
|
+
pyvguicom/pgwkit.py,sha256=4xpEzZtPiimDcR1Zer4Sej9u08L0JrgfV9g67rnwyZQ,25820
|
|
14
|
+
pyvguicom/plug.py,sha256=qyoJtpEWCBwyp5DG9fwzrcJL-SqTjL9KzZ418YSaPwc,1017
|
|
15
|
+
pyvguicom/testbutt.py,sha256=rB0rN_NimuJD-oxpoR0Qw1aZHVSTpCw7ercfHlY1-jI,2901
|
|
16
|
+
pyvguicom/testcust.py,sha256=P7bkAZtzc7q1h--feX_wxUMTXJTPuVv1NawpEE32J0Q,1149
|
|
17
|
+
pyvguicom/testentry.py,sha256=FcHEVmtIM_ohb9LQFu8xaPaLX9kaztuvKBYFbu2Gdw0,2658
|
|
18
|
+
pyvguicom/testicons.py,sha256=5Wd7Rk3vIyv61K4tvwCDVh_NclVrvf30ALsvfEhyQnQ,8947
|
|
19
|
+
pyvguicom/testlettsel.py,sha256=E6wS__jz4K3aiJHdKSVEbNnYtnuT1sTrTe_LknpOva8,3018
|
|
20
|
+
pyvguicom/testnums.py,sha256=o4q0fVi2C7sQLJu_FK8-IcEHYcBTY-y3QcqbculL0FA,3213
|
|
21
|
+
pyvguicom/testroot.py,sha256=MwGooMkNczSAQOj5aJbNnfPjSLsPmQrHk5OWY68rI3A,4082
|
|
22
|
+
pyvguicom/testsimple.py,sha256=Pdw3w9xuPdtXhvXaA7bGIPqIqhb68uRQqGb6fRZhUKQ,2355
|
|
23
|
+
pyvguicom/testtextv.py,sha256=viqkfwApr8OwCRgW4c1iACp8Z81R0EYmK17EK7K8Qe8,7124
|
|
24
|
+
pyvguicom-1.0.1.dist-info/METADATA,sha256=NeX0Hz1sakproe-FlkTvepc9BauMeTvj_NqQrTvFF4s,3109
|
|
25
|
+
pyvguicom-1.0.1.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
|
|
26
|
+
pyvguicom-1.0.1.dist-info/top_level.txt,sha256=TWIDRa6pMhB1Y4N_lGT1aO6tLoV7ZSUMlj0IaAHjm38,10
|
|
27
|
+
pyvguicom-1.0.1.dist-info/RECORD,,
|