psiutils 0.2.14__py3-none-any.whl → 0.2.16__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.
psiutils/_version.py CHANGED
@@ -1 +1 @@
1
- __version__ = '0.2.14'
1
+ __version__ = '0.2.16'
psiutils/buttons.py CHANGED
@@ -217,6 +217,7 @@ def enable_buttons(buttons: list[Button], enable: bool = True):
217
217
 
218
218
 
219
219
  icon_buttons = {
220
+ 'backup': (txt.BACKUP, 'backup'),
220
221
  'build': (txt.BUILD, 'build'),
221
222
  'check': (txt.CHECK, 'check'),
222
223
  'clear': (txt.CLEAR, 'clear'),
@@ -243,6 +244,9 @@ icon_buttons = {
243
244
  'rename': (txt.RENAME, 'rename'),
244
245
  'report': (txt.REPORT, 'report'),
245
246
  'reset': (txt.RESET, 'reset'),
247
+ 'restore': (txt.RESTORE, 'restore'),
248
+ 'restore_database': (txt.RESTORE, 'restore_database'),
249
+ 'restore_page': (txt.RESTORE, 'restore_page'),
246
250
  'revert': (txt.REVERT, 'revert'),
247
251
  'run': (txt.RUN, 'start'),
248
252
  'save': (txt.SAVE, 'save'),
psiutils/constants.py CHANGED
@@ -1,29 +1,33 @@
1
1
  """Constants for the tkinter psiutils."""
2
2
  from enum import Enum, auto
3
3
 
4
- from .utilities import invert
4
+ # from .utilities import invert
5
5
  from .known_paths import get_documents_dir, get_downloads_dir
6
6
 
7
- DIALOG_STATUS: dict = {
8
- 'yes': True,
9
- 'no': False,
10
- 'cancel': None,
11
- 'null': 0,
12
- 'undefined': 0,
13
- 'exit': 1,
14
- 'ok': 2,
15
- 'updated': 3,
16
- 'error': 4,
17
- }
18
- DIALOG_STATUS = invert(DIALOG_STATUS)
19
-
20
- MODES: dict[int, str] | dict[str, int] = {
21
- 0: 'view',
22
- 1: 'new',
23
- 2: 'edit',
24
- 3: 'delete'
25
- }
26
- MODES = invert(MODES)
7
+ DEFAULT_GEOMETRY = '500x400'
8
+
9
+ # # TODO is this needed with Status?
10
+ # DIALOG_STATUS: dict = {
11
+ # 'yes': True,
12
+ # 'no': False,
13
+ # 'cancel': None,
14
+ # 'null': 0,
15
+ # 'undefined': 0,
16
+ # 'exit': 1,
17
+ # 'ok': 2,
18
+ # 'updated': 3,
19
+ # 'error': 4,
20
+ # }
21
+ # DIALOG_STATUS = invert(DIALOG_STATUS)
22
+
23
+ # # TODO is this needed with Mode?
24
+ # MODES: dict[int, str] | dict[str, int] = {
25
+ # 0: 'view',
26
+ # 1: 'new',
27
+ # 2: 'edit',
28
+ # 3: 'delete'
29
+ # }
30
+ # MODES = invert(MODES)
27
31
 
28
32
  # GUI
29
33
  PAD = 5
Binary file
Binary file
Binary file
Binary file
psiutils/text.py CHANGED
@@ -38,6 +38,7 @@ psi_strings = {
38
38
  'REPORT': 'Report',
39
39
  'RENAME': 'Rename',
40
40
  'RESET': 'Reset',
41
+ 'RESTORE': 'Restore',
41
42
  'REVERT': 'Revert',
42
43
  'RUN': 'Run',
43
44
  'SAVE': 'Save',
@@ -60,7 +61,7 @@ class Text():
60
61
  """Combines package level and psiutils strings."""
61
62
  def __init__(self) -> None:
62
63
  """
63
- Initialize the object with attributes based on the key-value pairs
64
+ Initialise the object with attributes based on the key-value pairs
64
65
  in the `strings` dictionary.
65
66
 
66
67
  Args:
psiutils/utilities.py CHANGED
@@ -9,11 +9,10 @@ import platform
9
9
  from psiconfig import TomlConfig
10
10
  from psiutils._logger import psi_logger
11
11
  from psiutils._notify import _notify as notify
12
- from psiconfig import TomlConfig
12
+ from psiutils.constants import DEFAULT_GEOMETRY
13
13
  from psiutils.text import Text
14
- txt = Text()
15
14
 
16
- DEFAULT_GEOMETRY = '500x400'
15
+ txt = Text()
17
16
 
18
17
 
19
18
  def display_icon(root: tk.Tk, icon_file_path: str,
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: psiutils
3
- Version: 0.2.14
3
+ Version: 0.2.16
4
4
  Summary: Various TKinter utilities.
5
5
  Author: Jeff
6
6
  Author-email: Jeff <<jeffwatkins2000@gmail.com>>
@@ -2,12 +2,13 @@ psiutils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
2
  psiutils/_about_frame.py,sha256=Ei9RMja36x2Xc9SecCXnqXd9EzDe1LIHq4ZDDbKtc_I,7656
3
3
  psiutils/_logger.py,sha256=9nXxKWUyu4xqIILjTSUKRAMOG4cFy_EGJTTo0FtUAGU,2859
4
4
  psiutils/_notify.py,sha256=rQfYxPxsSwAEJBNXaAZSNlRmZLWB1sah1E1Oja9y-mw,437
5
- psiutils/_version.py,sha256=r8iWhYU-gaJ9WVJc_-ZLY8sK6iebY4JbvDv_kfd67iA,22
6
- psiutils/buttons.py,sha256=oqTNg1IckV1sr5d4-jD3QZW4B_Tz5TWTQUoPnvpDTwU,8618
7
- psiutils/constants.py,sha256=jGSfi2tQaJ32RLSBuRocX3UFSpC28BzOGiND0jq9PVs,1399
5
+ psiutils/_version.py,sha256=fDC3n_zbWMf96Cvd7apYtjcrebh0WSOm6_8kmcC0fvo,22
6
+ psiutils/buttons.py,sha256=vj-RCKKl4_kYisrMqPi8w56eXfRkbx1zze8oqgS4GjM,8807
7
+ psiutils/constants.py,sha256=AJOw73GL9Rx9BEmfduTy32S3dM3Rp6iIOYALY0J7JSw,1541
8
8
  psiutils/drag_manager.py,sha256=L04GzKIinWXzGCawvTnn18F1AEt8PUPS1U-HqCVrh48,3470
9
9
  psiutils/errors.py,sha256=tAypFkpzpbeOppO9zKQimlnRVyr3sMPoiwh0yK3Yc88,562
10
10
  psiutils/icecream_init.py,sha256=ArKnRHGCyMfEwSykiHGdhBmX4JPhrgcpShii_GAPWLI,739
11
+ psiutils/icons/backup.png,sha256=kKL5xewG83RQMTr4piNf8SEPNlhHUUtqqcizBuwWU2U,717
11
12
  psiutils/icons/build.png,sha256=MgQS4yPxfa5EBXCF5gXu2S6vqjUsRBhR4S6vCzOtrzQ,1169
12
13
  psiutils/icons/cancel.png,sha256=O2YSv7wxSV5rhT1WiZ9McqO3pilCKNfZdJNwQceH87E,2168
13
14
  psiutils/icons/check.png,sha256=8KqO0lWJvhcbSx1KI8QKfCkwLsszzotL9iBrXfwyf1Q,748
@@ -33,6 +34,9 @@ psiutils/icons/refresh.png,sha256=r-WkScAbDbB15mXzZqEXgys-V1UkDDxRZHrssgTRh1c,21
33
34
  psiutils/icons/rename.png,sha256=nEBej5-3BaFi-y1oIgDXCVHkKXndwxu5RW-eCEgu5UY,549
34
35
  psiutils/icons/report.png,sha256=gyMzrZkl4QyVd9XsOpAdFZlw-al9J4PTpIBM3EssAyg,979
35
36
  psiutils/icons/reset.png,sha256=UJHvnseHeMJoPNCn-WydTnfX-Lrlp9tgSlcIq6jWUBg,1296
37
+ psiutils/icons/restore-database.png,sha256=ezBRAMVbAo9lbs_yPpWpdLxqUFOudiC7mlwNklOKR3A,625
38
+ psiutils/icons/restore-page.png,sha256=WiYVxAHFq0iV_PsCt_5meInbAGAOGOfoYsHM_bWILlY,621
39
+ psiutils/icons/restore.png,sha256=8XAPT_nD3yi5hUQG3OEW1QRQNKRKOdFV7nNIz4jO0RE,986
36
40
  psiutils/icons/revert.png,sha256=vWIyLx7dQfTOkI8igLmVtmV8hnBfIh089QmKRRobVmk,1268
37
41
  psiutils/icons/save.png,sha256=RSIfWkVE537tMgchS5VFmHughVQqkKMyjMLY0ccDy98,613
38
42
  psiutils/icons/script.png,sha256=CG5MYayO1X5O7q40byfMwya1_52rp8BYq-FWUDBG5fg,803
@@ -48,10 +52,10 @@ psiutils/images/icon-query.png,sha256=e18hqkew4eOxABvECKn7BGO2VTHTE-XLMWPSQfSW9d
48
52
  psiutils/known_paths.py,sha256=Ydhk-Ie_q827ti35Hru8YwUx5awdO2FEG845k1N0hPo,9543
49
53
  psiutils/menus.py,sha256=4pUHb3fEYzLnsftxdKB_NjlPryj_pu7WN5Iy5Quy9-M,1746
50
54
  psiutils/messagebox.py,sha256=ODFodaDahAm31A8M4MVp9FXdhI0zhW8PZdUbBqbVQEY,4973
51
- psiutils/text.py,sha256=2q4whK-DjZZNOlTLt811bbaNGhg0T3MafSSPU2c5PMg,3048
55
+ psiutils/text.py,sha256=x9-VR1iYgp28HD0wHYksf_4tPSkCStCY7_hh9TM_c-k,3074
52
56
  psiutils/treeview.py,sha256=jtSzLWrnFIBDWV5YhWNRoZwgW-Kj8_7XVqZyusr-riQ,2826
53
- psiutils/utilities.py,sha256=UMk0qIcdlZjp_fShZwIj_HuWXp5Ur8JzHg-h6W8Tq4o,3369
57
+ psiutils/utilities.py,sha256=hBntrigp7WiuzRoGGhS96QVE-7pF2OdYT882jwMTrlQ,3355
54
58
  psiutils/widgets.py,sha256=TOJKDEdYJetPZxFZohQGJsVX_k3E26-ChgSXqDeJ0Y4,11363
55
- psiutils-0.2.14.dist-info/WHEEL,sha256=DpNsHFUm_gffZe1FgzmqwuqiuPC6Y-uBCzibcJcdupM,78
56
- psiutils-0.2.14.dist-info/METADATA,sha256=WgNcA2uzkNkSieH2UQEbpGRsvpyAIe_IW7OTWFfVoEk,2109
57
- psiutils-0.2.14.dist-info/RECORD,,
59
+ psiutils-0.2.16.dist-info/WHEEL,sha256=YUH1mBqsx8Dh2cQG2rlcuRYUhJddG9iClegy4IgnHik,79
60
+ psiutils-0.2.16.dist-info/METADATA,sha256=5qKM-f47jAfITzt3mO93Jo9i7ZNnyc25HGosrvdeVWQ,2109
61
+ psiutils-0.2.16.dist-info/RECORD,,
@@ -1,4 +1,4 @@
1
1
  Wheel-Version: 1.0
2
- Generator: uv 0.9.8
2
+ Generator: uv 0.9.11
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any