mwxlib 1.0.0__py3-none-any.whl → 1.7.13__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.
- mwx/__init__.py +6 -4
- mwx/bookshelf.py +133 -57
- mwx/controls.py +441 -375
- mwx/framework.py +531 -513
- mwx/graphman.py +683 -677
- mwx/images.py +16 -0
- mwx/matplot2.py +225 -216
- mwx/matplot2g.py +735 -652
- mwx/matplot2lg.py +192 -183
- mwx/mgplt.py +20 -22
- mwx/nutshell.py +1063 -939
- mwx/plugins/ffmpeg_view.py +74 -75
- mwx/plugins/fft_view.py +13 -15
- mwx/plugins/frame_listview.py +55 -52
- mwx/plugins/line_profile.py +1 -1
- mwx/py/filling.py +9 -8
- mwx/testsuite.py +38 -0
- mwx/utilus.py +273 -210
- mwx/wxmon.py +39 -38
- mwx/wxpdb.py +81 -83
- mwx/wxwil.py +18 -18
- mwx/wxwit.py +32 -35
- {mwxlib-1.0.0.dist-info → mwxlib-1.7.13.dist-info}/METADATA +12 -5
- mwxlib-1.7.13.dist-info/RECORD +28 -0
- {mwxlib-1.0.0.dist-info → mwxlib-1.7.13.dist-info}/WHEEL +1 -1
- mwxlib-1.0.0.dist-info/LICENSE +0 -21
- mwxlib-1.0.0.dist-info/RECORD +0 -28
- {mwxlib-1.0.0.dist-info → mwxlib-1.7.13.dist-info}/top_level.txt +0 -0
mwx/wxwit.py
CHANGED
|
@@ -8,15 +8,15 @@ import wx.lib.inspection as it
|
|
|
8
8
|
|
|
9
9
|
from .controls import Icon
|
|
10
10
|
from .utilus import typename
|
|
11
|
-
from .framework import CtrlInterface, Menu
|
|
11
|
+
from .framework import CtrlInterface, Menu
|
|
12
12
|
|
|
13
13
|
|
|
14
14
|
class Inspector(it.InspectionTree, CtrlInterface):
|
|
15
|
-
"""Widget inspection tool
|
|
15
|
+
"""Widget inspection tool.
|
|
16
16
|
|
|
17
17
|
Attributes:
|
|
18
|
-
parent
|
|
19
|
-
target
|
|
18
|
+
parent: shellframe
|
|
19
|
+
target: widget to inspect
|
|
20
20
|
"""
|
|
21
21
|
def __init__(self, parent, *args, **kwargs):
|
|
22
22
|
it.InspectionTree.__init__(self, parent, *args, **kwargs)
|
|
@@ -61,38 +61,35 @@ class Inspector(it.InspectionTree, CtrlInterface):
|
|
|
61
61
|
@self.handler.bind('f5 pressed')
|
|
62
62
|
def _refresh(evt):
|
|
63
63
|
self.BuildTree(self.target)
|
|
64
|
-
|
|
64
|
+
|
|
65
65
|
def OnDestroy(self, evt):
|
|
66
66
|
if evt.EventObject is self:
|
|
67
67
|
self.timer.Stop()
|
|
68
68
|
evt.Skip()
|
|
69
|
-
|
|
69
|
+
|
|
70
70
|
def OnSetFocus(self, evt):
|
|
71
71
|
title = self.__class__.__name__
|
|
72
72
|
self.parent.handler('title_window', title)
|
|
73
73
|
evt.Skip()
|
|
74
|
-
|
|
74
|
+
|
|
75
75
|
## --------------------------------
|
|
76
|
-
## InspectionTree
|
|
76
|
+
## InspectionTree interface.
|
|
77
77
|
## --------------------------------
|
|
78
|
-
|
|
78
|
+
|
|
79
79
|
def SetObj(self, obj):
|
|
80
|
-
"""Called from tree.toolFrame -> SetObj.
|
|
81
|
-
|
|
82
|
-
(override) Set target object.
|
|
83
|
-
"""
|
|
80
|
+
"""Called from tree.toolFrame -> SetObj."""
|
|
84
81
|
if self.target is obj:
|
|
85
82
|
return
|
|
86
83
|
self.target = obj
|
|
87
|
-
item = self.FindWidgetItem(obj)
|
|
84
|
+
item = self.FindWidgetItem(obj) # cf. it.InspectionTree.SelectObj
|
|
88
85
|
if item:
|
|
89
86
|
self.EnsureVisible(item)
|
|
90
87
|
self.SelectItem(item)
|
|
91
88
|
elif obj:
|
|
92
|
-
self.BuildTree(obj)
|
|
93
|
-
|
|
89
|
+
self.BuildTree(obj) # If the item for obj is missing, rebuild the tree.
|
|
90
|
+
|
|
94
91
|
def GetTextForWidget(self, obj):
|
|
95
|
-
"""
|
|
92
|
+
"""Return the string to be used in the tree for a widget.
|
|
96
93
|
|
|
97
94
|
(override) Make better object name and Id.
|
|
98
95
|
"""
|
|
@@ -100,7 +97,7 @@ class Inspector(it.InspectionTree, CtrlInterface):
|
|
|
100
97
|
if hasattr(obj, 'Name'):
|
|
101
98
|
return "{} ({!r} {})".format(clsname, obj.Name, obj.Id)
|
|
102
99
|
return clsname
|
|
103
|
-
|
|
100
|
+
|
|
104
101
|
def highlight(self, obj, msec=2000):
|
|
105
102
|
self.highlighter.highlightTime = msec
|
|
106
103
|
if isinstance(obj, wx.Window):
|
|
@@ -109,58 +106,58 @@ class Inspector(it.InspectionTree, CtrlInterface):
|
|
|
109
106
|
self.highlighter.HighlightSizer(obj)
|
|
110
107
|
elif isinstance(obj, wx.SizerItem):
|
|
111
108
|
self.highlighter.HighlightSizer(obj.Sizer)
|
|
112
|
-
|
|
109
|
+
|
|
113
110
|
def set_colour(self, obj, col):
|
|
114
111
|
item = self.FindWidgetItem(obj)
|
|
115
112
|
if item:
|
|
116
113
|
self.SetItemTextColour(item, col)
|
|
117
|
-
|
|
114
|
+
|
|
118
115
|
def watch(self, obj=None):
|
|
119
116
|
if obj is None:
|
|
120
117
|
item = self.Selection
|
|
121
118
|
if item:
|
|
122
|
-
obj = self.GetItemData(item)
|
|
123
|
-
|
|
124
|
-
if not isinstance(obj, wx.Window):
|
|
119
|
+
obj = self.GetItemData(item) # Restart
|
|
120
|
+
if not isinstance(obj, (wx.Window, type(None))):
|
|
125
121
|
wx.MessageBox("Cannot watch the widget.\n\n"
|
|
126
|
-
"- {!r} is not a wx.Object.".format(obj)
|
|
122
|
+
"- {!r} is not a wx.Object.".format(obj),
|
|
123
|
+
self.__module__)
|
|
127
124
|
return
|
|
128
125
|
self.SetObj(obj)
|
|
129
126
|
self.timer.Start(500)
|
|
130
|
-
|
|
127
|
+
|
|
131
128
|
def unwatch(self):
|
|
132
129
|
self.target = None
|
|
133
130
|
self.timer.Stop()
|
|
134
|
-
|
|
131
|
+
|
|
135
132
|
## --------------------------------
|
|
136
|
-
## Actions on tree items
|
|
133
|
+
## Actions on tree items.
|
|
137
134
|
## --------------------------------
|
|
138
|
-
|
|
135
|
+
|
|
139
136
|
def OnTimer(self, evt):
|
|
140
|
-
## wnd, pt = wx.FindWindowAtPointer()
|
|
137
|
+
## wnd, pt = wx.FindWindowAtPointer() # as HitTest
|
|
141
138
|
wnd = wx.Window.FindFocus()
|
|
142
139
|
if (wnd and wnd is not self.target
|
|
143
140
|
and wnd not in self._noWatchList):
|
|
144
141
|
self.SetObj(wnd)
|
|
145
142
|
evt.Skip()
|
|
146
|
-
|
|
143
|
+
|
|
147
144
|
def OnShow(self, evt):
|
|
148
145
|
if evt.IsShown():
|
|
149
146
|
if not self.built:
|
|
150
147
|
self.BuildTree(self.target)
|
|
151
148
|
self._noWatchList = [w for w in self._noWatchList if w]
|
|
152
149
|
evt.Skip()
|
|
153
|
-
|
|
150
|
+
|
|
154
151
|
def OnItemTooltip(self, evt):
|
|
155
152
|
item = evt.GetItem()
|
|
156
153
|
if item:
|
|
157
154
|
obj = self.GetItemData(item)
|
|
158
155
|
evt.SetToolTip("id=0x{:X}".format(id(obj)))
|
|
159
156
|
evt.Skip()
|
|
160
|
-
|
|
157
|
+
|
|
161
158
|
def OnRightDown(self, evt):
|
|
162
159
|
item, flags = self.HitTest(evt.Position)
|
|
163
|
-
if item:
|
|
160
|
+
if item: # and flags & (0x10 | 0x20 | 0x40 | 0x80):
|
|
164
161
|
self.SelectItem(item)
|
|
165
162
|
self.SetFocus()
|
|
166
163
|
obj = self.target
|
|
@@ -187,8 +184,8 @@ class Inspector(it.InspectionTree, CtrlInterface):
|
|
|
187
184
|
|
|
188
185
|
|
|
189
186
|
def miniIcon(key, size=(16,16)):
|
|
190
|
-
if key == 'ShowFilling':
|
|
191
|
-
|
|
187
|
+
# if key == 'ShowFilling':
|
|
188
|
+
# return wx.py.filling.images.getPyImage().Scale(16,16).ConvertToBitmap()
|
|
192
189
|
art = getattr(it, key)
|
|
193
190
|
return art.GetImage().Scale(*size).ConvertToBitmap()
|
|
194
191
|
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
2
|
Name: mwxlib
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.7.13
|
|
4
4
|
Summary: A wrapper of matplotlib and wxPython (phoenix)
|
|
5
5
|
Home-page: https://github.com/komoto48g/mwxlib
|
|
6
6
|
Author: Kazuya O'moto
|
|
7
7
|
Author-email: komoto@jeol.co.jp
|
|
8
8
|
License: MIT
|
|
9
|
-
Classifier: License :: OSI Approved :: MIT License
|
|
10
9
|
Classifier: Programming Language :: Python :: 3
|
|
11
10
|
Classifier: Programming Language :: Python :: 3.8
|
|
12
11
|
Classifier: Programming Language :: Python :: 3.9
|
|
@@ -16,11 +15,19 @@ Classifier: Programming Language :: Python :: 3.12
|
|
|
16
15
|
Classifier: Topic :: Scientific/Engineering :: Image Processing
|
|
17
16
|
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
18
17
|
Description-Content-Type: text/markdown
|
|
19
|
-
|
|
20
|
-
Requires-Dist: wxpython >=4.2.0
|
|
18
|
+
Requires-Dist: wxpython>=4.2.0
|
|
21
19
|
Requires-Dist: matplotlib
|
|
22
20
|
Requires-Dist: opencv-python
|
|
23
21
|
Requires-Dist: scipy
|
|
22
|
+
Dynamic: author
|
|
23
|
+
Dynamic: author-email
|
|
24
|
+
Dynamic: classifier
|
|
25
|
+
Dynamic: description
|
|
26
|
+
Dynamic: description-content-type
|
|
27
|
+
Dynamic: home-page
|
|
28
|
+
Dynamic: license
|
|
29
|
+
Dynamic: requires-dist
|
|
30
|
+
Dynamic: summary
|
|
24
31
|
|
|
25
32
|
# mwxlib
|
|
26
33
|
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
mwx/__init__.py,sha256=gfhefIJIV_RbXicmCLGsyX01thIZXwxQlzIH32lMtrc,715
|
|
2
|
+
mwx/bookshelf.py,sha256=edDdYtrwfk6xiimj-Mw4Wwfg-xlUkOKoDId515pbdQ0,8555
|
|
3
|
+
mwx/controls.py,sha256=aJpti8JSfm9eh57SZ3yWQqD4-hGzA2yAQD0YPc6RP84,49951
|
|
4
|
+
mwx/framework.py,sha256=ROmUTB1jAYv6sedjcvVrVYbWFS_pVp2SYyC1nw7spLI,76951
|
|
5
|
+
mwx/graphman.py,sha256=AXi8OtqWBokLGv2Q_oRkIzCzJnCRLlvVnntxTwyBimc,71538
|
|
6
|
+
mwx/images.py,sha256=Kkfy9QI_hMtwShSjUS4-ZpC_EkVuah_XhpBOR4wAKkM,49792
|
|
7
|
+
mwx/matplot2.py,sha256=5NWyBnkZmEKiAT2zwZrOnQwKvDs-rTxVVGaSQc4V2f4,32822
|
|
8
|
+
mwx/matplot2g.py,sha256=lHnjqGrpprq3egQdi448f6mp2ZS5nnkGw26edjM-qVo,65997
|
|
9
|
+
mwx/matplot2lg.py,sha256=m3oDmgE5phorTt0qWcOr6vueFHmQHJqlR4oTvJtte3E,27821
|
|
10
|
+
mwx/mgplt.py,sha256=wrBeK5neOi1tX9llKlKHhVVrSyoent7y6wIuW2fLZ5Y,5522
|
|
11
|
+
mwx/nutshell.py,sha256=BAvZzCG9rnFZFf1wtEMJsZjRoZhH2fRlfqih4tbPQ5U,147318
|
|
12
|
+
mwx/testsuite.py,sha256=pBB7ZNicI_thrg6LmNPgUOgfMWwRoAaYWN1nFy6t6S4,790
|
|
13
|
+
mwx/utilus.py,sha256=dABL7NYIr-oEp-QXFJyy919_Rv8eKbxJarpoQ47h794,39954
|
|
14
|
+
mwx/wxmon.py,sha256=1PtG1N72mPIU1EjHYGGiQQTrjvIDo-qJRcBFuVlZNdM,12738
|
|
15
|
+
mwx/wxpdb.py,sha256=miLf3tuufnyvow3xW5kUchpeSd77xN9O-eW9-sDmElg,18680
|
|
16
|
+
mwx/wxwil.py,sha256=z82sHqqkrIbtxmuDJkxOCkA9EAG8Yt_7AhMGr_MiAI0,5370
|
|
17
|
+
mwx/wxwit.py,sha256=WDv41JntE3vX4mbyk0Cu-75CNkRMOB8bNSS_r27DdEw,7286
|
|
18
|
+
mwx/plugins/__init__.py,sha256=jnJ-Sl9XJ_7BFDslD_r7dsbxsOT57q_IaEriV53XIGY,41
|
|
19
|
+
mwx/plugins/ffmpeg_view.py,sha256=GBtURfa-_kG_Osumi2qJLqIWdAp2cxizlgp0FMBYuZk,10913
|
|
20
|
+
mwx/plugins/fft_view.py,sha256=u2TMMM7rHlvvhU412fVUHcrGWslZcFL9y-iBbjIrhgQ,2728
|
|
21
|
+
mwx/plugins/frame_listview.py,sha256=jXMtyCJQVuSSmi5A4BKSmXDzPRJRAQiEtRgKN2NS37I,10527
|
|
22
|
+
mwx/plugins/line_profile.py,sha256=zT9p22YCkxjGtoLwVDcfqW9M80Xn2qBEt096qq7N9QQ,815
|
|
23
|
+
mwx/py/__init__.py,sha256=xykgfOytOwNuvXsfkLoumFZSTN-iBsHOjczYXngjmUE,12
|
|
24
|
+
mwx/py/filling.py,sha256=98AmfxCXuk-hOUPiG93oo-PAlVtZ-92wqFl67eDm_RA,16875
|
|
25
|
+
mwxlib-1.7.13.dist-info/METADATA,sha256=ggNj8WGipx4ImpbgArfUbn9AfRIgeG8NQCGrZQy1I3I,7382
|
|
26
|
+
mwxlib-1.7.13.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
27
|
+
mwxlib-1.7.13.dist-info/top_level.txt,sha256=SI1Mh118AstnUFGPNq5aMNKiAnVNmZk1S9Ij-OwAEpY,4
|
|
28
|
+
mwxlib-1.7.13.dist-info/RECORD,,
|
mwxlib-1.0.0.dist-info/LICENSE
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2021 Kazuya O'moto
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
mwxlib-1.0.0.dist-info/RECORD
DELETED
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
mwx/__init__.py,sha256=psabnAMei5VzB2TsB2qBNLrIZMX0LiqjlXCpNGmDejk,668
|
|
2
|
-
mwx/bookshelf.py,sha256=so-xSLq08sMlJBErTxOaDoKUAMa_g1CkIP2pNnff68c,5607
|
|
3
|
-
mwx/controls.py,sha256=LZqee9K8uPxs-Iqcp1zMMNBjFpGPrHbcMaIBuBOL7oo,47647
|
|
4
|
-
mwx/framework.py,sha256=vtufV2jjqdTr2CRhbJYY_NbJMtqft9uKCzZR12dfgk0,75809
|
|
5
|
-
mwx/graphman.py,sha256=1GGBk4kJYRQ7zkvO2rvHxHoINrIfHSB7cabQKWhTyaI,69669
|
|
6
|
-
mwx/images.py,sha256=oxCn0P-emiWujSS2gUgU5TUnr5cPjix2jBcjOBDr24I,48701
|
|
7
|
-
mwx/matplot2.py,sha256=zA56jIdRUdzu-wrmPai1PSOjzqV2Erqw2yFKW-jwdA8,32901
|
|
8
|
-
mwx/matplot2g.py,sha256=xQeHKHAZkLZ2tY-rlTXEIKue1Iw9Vo73l6z_3GSQVCQ,64422
|
|
9
|
-
mwx/matplot2lg.py,sha256=JRWjWnLJUytbSq6wxs4P0gbVUr3xoLSF6Wwqd5V_pJI,27404
|
|
10
|
-
mwx/mgplt.py,sha256=M5rt-H7Uq1OHnlFvMA4a3945UBvppbR9L_mw8NL_YZ0,5602
|
|
11
|
-
mwx/nutshell.py,sha256=pNGLBlVYz6D4LNjosCjXaopcITkQ2-qGVQ6zGmVJJYQ,141850
|
|
12
|
-
mwx/utilus.py,sha256=Yyw8L1f-ikhyd7wtFXYtsOswofWxmB4GAmLOZnhUXeU,37388
|
|
13
|
-
mwx/wxmon.py,sha256=yzWqrbY6LzpfRwQeytYUeqFhFuLVm_XEvrVAL_k0HBQ,12756
|
|
14
|
-
mwx/wxpdb.py,sha256=--TQr-_zs9dWPYV2V4s3Zr4abvN14o5wD8anT9frHUg,18875
|
|
15
|
-
mwx/wxwil.py,sha256=hhyB1lPrF9ixeObxCOKQv0Theu-B-kpJg_yVU3EGSNg,5406
|
|
16
|
-
mwx/wxwit.py,sha256=1hHtMi2YEy2T_LnUpwdmrIdtCuvxMOFyykqnbq6jLP0,7294
|
|
17
|
-
mwx/plugins/__init__.py,sha256=jnJ-Sl9XJ_7BFDslD_r7dsbxsOT57q_IaEriV53XIGY,41
|
|
18
|
-
mwx/plugins/ffmpeg_view.py,sha256=ZKkSLpyuzpVuRbaPib04rChzlwAifNp3pcgxABeqE4k,10693
|
|
19
|
-
mwx/plugins/fft_view.py,sha256=08A_Y73XirV7kXpwf-v0mUA0Hr0MOfdMXv3tvL1hvWA,2789
|
|
20
|
-
mwx/plugins/frame_listview.py,sha256=gowjQ-ARNonMkDSXkQgPKq4U9YBJ-vQ0jK2krBVOdCs,10420
|
|
21
|
-
mwx/plugins/line_profile.py,sha256=zzm6_7lnAnNepLbh07ordp3nRWDFQJtu719ZVjrVf8s,819
|
|
22
|
-
mwx/py/__init__.py,sha256=xykgfOytOwNuvXsfkLoumFZSTN-iBsHOjczYXngjmUE,12
|
|
23
|
-
mwx/py/filling.py,sha256=fumUG1F5M9TL-Dfqni4G85uk7TmvnUunTbdcPDV0vfo,16857
|
|
24
|
-
mwxlib-1.0.0.dist-info/LICENSE,sha256=PGtRKCaTkmUDlBQwpptJAxJtdqxIUtAmdBsaT9nUVkA,1091
|
|
25
|
-
mwxlib-1.0.0.dist-info/METADATA,sha256=IyWzRxDY-vYI_37c6GQ5WgZFAc93d5vfuqaGY8_s3dI,7259
|
|
26
|
-
mwxlib-1.0.0.dist-info/WHEEL,sha256=OVMc5UfuAQiSplgO0_WdW7vXVGAt9Hdd6qtN4HotdyA,91
|
|
27
|
-
mwxlib-1.0.0.dist-info/top_level.txt,sha256=SI1Mh118AstnUFGPNq5aMNKiAnVNmZk1S9Ij-OwAEpY,4
|
|
28
|
-
mwxlib-1.0.0.dist-info/RECORD,,
|
|
File without changes
|