pyvguicom 1.0.1__py3-none-any.whl → 1.1.2__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/testutils.py ADDED
@@ -0,0 +1,139 @@
1
+ #!/usr/bin/env python3
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 GLib
13
+ from gi.repository import GObject
14
+ from gi.repository import Pango
15
+
16
+ import pgsimp
17
+ import pggui
18
+ import pgutils
19
+
20
+ def subdialog(arg2):
21
+
22
+ def pressed(arg2, arg3):
23
+ #print("pressed")
24
+ pggui.message("From sub", parent=arg3)
25
+ def pressed2(arg2, arg3):
26
+ #print("pressed2", arg2, arg3)
27
+ arg3.response(Gtk.ResponseType.OK)
28
+ arg3.destroy()
29
+
30
+ dialog = Gtk.Dialog()
31
+ dialog.set_size_request(200, 100)
32
+ dialog.add_button = (Gtk.ButtonsType.CLOSE, Gtk.ResponseType.OK)
33
+ bbb = Gtk.Button("Message")
34
+ dialog.vbox.pack_start(bbb, 0, 0, 0)
35
+ bbb.connect("pressed", pressed, dialog)
36
+ #buttons=Gtk.ButtonsType.CLOSE)
37
+ bbb = Gtk.Button.new_with_mnemonic("E_xit Sub")
38
+ dialog.vbox.pack_start(bbb, 0, 0, 0)
39
+ bbb.connect("pressed", pressed2, dialog)
40
+ dialog.show_all()
41
+ dialog.run()
42
+
43
+ # ------------------------------------------------------------------------
44
+ class testwin(Gtk.Window):
45
+
46
+ def __init__(self):
47
+ Gtk.Window.__init__(self)
48
+ #self.set_default_size(800, 600)
49
+ self.set_position(Gtk.WindowPosition.CENTER)
50
+ self.connect("unmap", Gtk.main_quit)
51
+
52
+ # ------------------------------------------------------------------------
53
+
54
+ class pgtestwin(testwin):
55
+
56
+ def __init__(self):
57
+
58
+ testwin.__init__(self)
59
+
60
+ hbox = Gtk.HBox(); hbox3 = Gtk.HBox()
61
+ hbox2 = Gtk.HBox(); hbox4 = Gtk.HBox()
62
+ hbox5 = Gtk.HBox()
63
+
64
+ self.label = Gtk.Label.new("Test strings here")
65
+ hbox5.pack_start(self.label, 0, 0, 2)
66
+
67
+ vbox = Gtk.VBox()
68
+
69
+ #vbox.pack_start(Gtk.Label(label="hello"), 1, 1, 2)
70
+
71
+ butt = Gtk.Button.new_with_mnemonic("Test about")
72
+ butt.connect("clicked", self.test_about)
73
+ vbox.pack_start(butt, 0, 0, 2)
74
+
75
+ #butt = Gtk.Button.new_with_mnemonic("Test Yes_no _cancel2")
76
+ #butt.connect("clicked", self.test_yes_no_cancel2)
77
+ #vbox.pack_start(butt, 0, 0, 2)
78
+
79
+ butt = Gtk.Button.new_with_mnemonic("Test Yes_no _cancel")
80
+ butt.connect("clicked", self.test_yes_no_cancel)
81
+ vbox.pack_start(butt, 0, 0, 2)
82
+
83
+ butt = Gtk.Button.new_with_mnemonic("Test Yes_no")
84
+ butt.connect("clicked", self.test_yes_no)
85
+ vbox.pack_start(butt, 0, 0, 2)
86
+
87
+ #butt = Gtk.Button.new_with_mnemonic("Test Yes_no2")
88
+ #butt.connect("clicked", self.test_yes_no2)
89
+ #vbox.pack_start(butt, 0, 0, 2)
90
+ #
91
+ #butt = Gtk.Button.new_with_mnemonic("Test M_essage2")
92
+ #butt.connect("clicked", self.test_message2)
93
+ #vbox.pack_start(butt, 0, 0, 2)
94
+
95
+ butt = Gtk.Button.new_with_mnemonic("Test M_essage")
96
+ butt.connect("clicked", self.test_message)
97
+ vbox.pack_start(butt, 0, 0, 2)
98
+
99
+ butt = Gtk.Button.new_with_mnemonic("Test Sub Dialog")
100
+ butt.connect("clicked", subdialog)
101
+ vbox.pack_start(butt, 0, 0, 2)
102
+
103
+
104
+ butt = Gtk.Button.new_with_mnemonic("E_xit")
105
+ butt.connect("clicked", Gtk.main_quit)
106
+ vbox.pack_start(butt, 0, 0, 2)
107
+
108
+ self.add(vbox)
109
+ self.show_all()
110
+
111
+ def test_about(self, arg2):
112
+ print(pgutils.about("Tester"))
113
+
114
+ def test_yes_no_cancel2(self, arg2):
115
+ print(pggui.yes_no_cancel2("Yes No Message"))
116
+
117
+ def test_yes_no_cancel(self, arg2):
118
+ print(pggui.yes_no_cancel("Yes No Message"))
119
+
120
+ def test_yes_no(self, arg2):
121
+ print(pggui.yes_no("Yes No Message"))
122
+
123
+ def test_yes_no2(self, arg2):
124
+ print(pggui.yes_no2("Yes No Message"))
125
+
126
+ def test_message2(self, arg2):
127
+ pggui.message2("Hello Message")
128
+
129
+ def test_message(self, arg2):
130
+ pggui.message("Hello Message")
131
+
132
+
133
+ tw = pgtestwin()
134
+
135
+ #print("test")
136
+
137
+ Gtk.main()
138
+
139
+ # EOF
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: pyvguicom
3
- Version: 1.0.1
3
+ Version: 1.1.2
4
4
  Summary: High power secure server GUI utility helpers.
5
5
  Home-page: https://github.com/pglen/pyguicom.git
6
6
  Author: Peter Glen
@@ -23,7 +23,7 @@ Description-Content-Type: text/markdown
23
23
 
24
24
  These classes are for python PyGobject (Gtk) development. They are used in
25
25
  several projects. They act as a simplification front end for the PyGtk / PyGobject
26
- classes.
26
+ classes.
27
27
 
28
28
  A sampler of what is in there (pasted from code, in no particular order):
29
29
 
@@ -38,20 +38,15 @@ A sampler of what is in there (pasted from code, in no particular order):
38
38
  class Lights(Gtk.Frame):
39
39
  class WideButt(Gtk.Button):
40
40
  class ScrollListBox(Gtk.Frame):
41
- class TextRow(Gtk.HBox):
42
- class RadioGroup(Gtk.Frame):
43
- class Led(Gtk.DrawingArea):
44
- class Lights(Gtk.Frame):
45
41
  class FrameTextView(Gtk.TextView):
46
42
  class Label(Gtk.Label):
47
43
  class Logo(Gtk.VBox):
48
44
  class xSpacer(Gtk.HBox):
49
- class ScrollListBox(Gtk.Frame):
50
45
  class ListBox(Gtk.TreeView):
51
46
 
52
47
  ... and a lot more ...
53
48
 
54
- ## Also includes python / Gtk primitives:
49
+ ## Also includes Some Python / Gtk primitives:
55
50
 
56
51
  def get_screen_wh():
57
52
  def get_screen_xy():
@@ -72,12 +67,12 @@ A sampler of what is in there (pasted from code, in no particular order):
72
67
 
73
68
  ## Example:
74
69
 
75
- The Label Button (smallbutt) takes a constructor, and feeds
70
+ The Label Button (SmallButt) takes a constructor, and feeds
76
71
  the arguments with defaults as one would expect.
77
72
 
78
73
  def __init__(self, textm="", widget=None, tooltip=None, font=None):
79
74
 
80
- The simplification effect allows one to create a smallbutt with no arguments,
75
+ The simplification effect allows one to create a Label Button with no arguments,
81
76
  and still have a somewhat reasonable outcome. The label example is trivial,
82
77
  the simplification takes a new dimension with classes like SimpleTree.
83
78
 
@@ -88,8 +83,10 @@ set on one line. This makes the code look more compact and maintainable.
88
83
 
89
84
  The test utilities can confirm correct operation; however being a visual
90
85
  set of classes, the real test is seeing the generated UI.
86
+ The test utilities can also be found in the project install directory,
87
+ starting with the text* prefix.
91
88
 
92
- See descendent projects for more examples. (pyedpro; pycal; pggui; ...)
89
+ See descendent projects for more examples. (pyedpro; pycal; pyvserv; ...)
93
90
 
94
91
  Peter Glen
95
92
 
@@ -0,0 +1,45 @@
1
+ pyvguicom/__init__.py,sha256=2k_ZeqU7FvqZMFqGm-EYRiV98uxUxmiy5wXygvIobPU,13
2
+ pyvguicom/browsewin.py,sha256=gGSkwzkzFgQpZ2TvCfBH7uENnNL4d5uHhx9rkm-4938,7590
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=GJj7hHeSO_p6nVtExOy98TZwtOn-mahuBHC8t-K6xrM,10486
8
+ pyvguicom/pggui.py,sha256=H7rN9VgHIYopgHYa2CMR-a9SRLELESqkaiqzWLq7yVc,46488
9
+ pyvguicom/pgsel.py,sha256=VTmyeXB83sLxR5vbgLKcpPQlaVi8A4GdNCRdP4G3A5c,13350
10
+ pyvguicom/pgsimp.py,sha256=CrdyTrvtii3KCS-HAJ1W6WDnfRqmkHyI_dRHHzRrTBU,7628
11
+ pyvguicom/pgtests.py,sha256=ndlTMnRd4ECHziOixJcgT1KtCJxIXTJfnMGZhajKoYI,3228
12
+ pyvguicom/pgtextview.py,sha256=aAlmJX4UISI3MQtUI-_OoFacVLFIhcNIILzezC_x0DI,29341
13
+ pyvguicom/pgutils.py,sha256=t0HQNQCFWLA7mc0GPRs5tIL95FWfEsTnXKZ8jijm07M,31329
14
+ pyvguicom/pgwkit.py,sha256=bCyGJA5ILCLmHZGQEDkIu38NRhYFa8nxdYu30eBqK_Y,26237
15
+ pyvguicom/plug.py,sha256=qyoJtpEWCBwyp5DG9fwzrcJL-SqTjL9KzZ418YSaPwc,1017
16
+ pyvguicom/testbutt.py,sha256=6Bee05gI46Bw2EfWaZDH9PbIbtw5FKJbLd66HDelXmg,2902
17
+ pyvguicom/testcust.py,sha256=KKQLArvostu2uTKNEMyDFRF2rFU0h32fc1Y7hywnDq4,1150
18
+ pyvguicom/testentry.py,sha256=Rt5Q6dXb6Asfhg2fgxyyGR-Q1eUoL48IRcsKJV572nI,3091
19
+ pyvguicom/testgui.py,sha256=JLf3d5Kze7nglAquvqi_D0btxTY7us8OTtk-cEeP5nA,3624
20
+ pyvguicom/testicons.py,sha256=5Wd7Rk3vIyv61K4tvwCDVh_NclVrvf30ALsvfEhyQnQ,8947
21
+ pyvguicom/testlettsel.py,sha256=ZZMNUqaabZjd0RQdDUZ1hkuRqQxhurrg8FkuRrSKLhU,3019
22
+ pyvguicom/testmsgs.py,sha256=VhGRO5WZFDtloAMlw773hpXlmWCjRQI2jSqIoZLgLRU,4067
23
+ pyvguicom/testnums.py,sha256=T8NQFAviRv7Wx5IbBgEHfmthwXixuj6XgbGd8oUrq-o,3214
24
+ pyvguicom/testroot.py,sha256=MwGooMkNczSAQOj5aJbNnfPjSLsPmQrHk5OWY68rI3A,4082
25
+ pyvguicom/testsimple.py,sha256=IB5_5AKVpxeXHCYDc2pZxI0iA8b8Ps4mwiBitBajiq8,2371
26
+ pyvguicom/testtests.py,sha256=U3LGeByhFRBD4tc56uqM69xX3UY24efukMEWfro8ZOA,1883
27
+ pyvguicom/testtextv.py,sha256=3BkdjE5nLL3ZFLHQqeP2eAhO31BKjQO8SwHfBEMffdU,7126
28
+ pyvguicom/testutils.py,sha256=2mznZUNREo-tiOs1OWDPDNWBcMSq1kOYNvlTG0TsZ_s,3965
29
+ pyvguicom/docs/__index__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
30
+ pyvguicom/docs/browsewin.html,sha256=Kh1Q7Nz_NlxXM6bWCFTaieLnNTZlYvHjTVTED1kUW0Y,35939
31
+ pyvguicom/docs/htmledit.html,sha256=PFwdGF16CNNMi-CihUUEFoGWwl3LeZ1RJFzu3CVmdYo,44251
32
+ pyvguicom/docs/pgbox.html,sha256=6OhMHeR_KnNxh3ww0s2Ocv7XMjbAUvJx4f11PNAtWIk,81647
33
+ pyvguicom/docs/pgbutt.html,sha256=ROkE0IFdTzWBHf9KK6QxvYIWh32VQkw3CvElWvmBfDo,27700
34
+ pyvguicom/docs/pgentry.html,sha256=4X-xEyL0LW37lEdx0gB2O6FmkfnXDZicpggoOmI9gac,39527
35
+ pyvguicom/docs/pggui.html,sha256=7IfXdAqnebIeY87N3pExKUgzjQ7KmtOfKsNaqKTptzI,181257
36
+ pyvguicom/docs/pgsel.html,sha256=mOYoZFTD5v_NVAZ_5E6J_DSbV12rA0OvJsSWKhCD8cs,54919
37
+ pyvguicom/docs/pgsimp.html,sha256=rv1TIl5Jh_023tFru9ByFrT9QYnOv9ZEJB8AtAOyPcU,38344
38
+ pyvguicom/docs/pgtextview.html,sha256=LRKU-oapE_lV92qvUgljtb1rbIHlHtj6owd_0Wb1Yek,95560
39
+ pyvguicom/docs/pgutils.html,sha256=hgfyub2-7m1CtsUCC1VnJGsoW4bS6tDKo1kikG2wO4A,89497
40
+ pyvguicom/docs/pgwkit.html,sha256=XGWQsse_GDQvscmHKf0p8UPc9oL5SCr9JPhdoyz5gVM,93952
41
+ pyvguicom/docs/sutil.html,sha256=ZyFED9I34c5hUmAS-HRnSGlIri5no4xZ6Jz8h0Gf0JY,32044
42
+ pyvguicom-1.1.2.dist-info/METADATA,sha256=uUBE4fVQnKhy1WT0CibEJmD_qAELb5wbzNMNJdW3rHU,3062
43
+ pyvguicom-1.1.2.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
44
+ pyvguicom-1.1.2.dist-info/top_level.txt,sha256=TWIDRa6pMhB1Y4N_lGT1aO6tLoV7ZSUMlj0IaAHjm38,10
45
+ pyvguicom-1.1.2.dist-info/RECORD,,
@@ -1,27 +0,0 @@
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,,