tksheet 7.2.22__py3-none-any.whl → 7.3.0__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.
- tksheet/__init__.py +1 -1
- tksheet/column_headers.py +48 -62
- tksheet/functions.py +22 -4
- tksheet/main_table.py +118 -93
- tksheet/other_classes.py +14 -13
- tksheet/row_index.py +46 -62
- tksheet/sheet.py +84 -43
- tksheet/sheet_options.py +6 -72
- tksheet/text_editor.py +11 -0
- tksheet/themes.py +366 -296
- tksheet/top_left_rectangle.py +14 -7
- tksheet/vars.py +4 -1
- {tksheet-7.2.22.dist-info → tksheet-7.3.0.dist-info}/METADATA +36 -12
- tksheet-7.3.0.dist-info/RECORD +20 -0
- {tksheet-7.2.22.dist-info → tksheet-7.3.0.dist-info}/WHEEL +1 -1
- tksheet-7.2.22.dist-info/RECORD +0 -20
- {tksheet-7.2.22.dist-info → tksheet-7.3.0.dist-info}/LICENSE.txt +0 -0
- {tksheet-7.2.22.dist-info → tksheet-7.3.0.dist-info}/top_level.txt +0 -0
tksheet/top_left_rectangle.py
CHANGED
@@ -160,21 +160,30 @@ class TopLeftRectangle(tk.Canvas):
|
|
160
160
|
self,
|
161
161
|
new_w: None | int = None,
|
162
162
|
new_h: None | int = None,
|
163
|
-
recreate_selection_boxes: bool = True,
|
164
163
|
) -> None:
|
165
164
|
try:
|
166
|
-
if isinstance(new_h, int):
|
165
|
+
if isinstance(new_h, int) and isinstance(new_w, int):
|
167
166
|
h = new_h
|
168
|
-
|
169
|
-
|
167
|
+
w = new_w
|
168
|
+
self.config(width=w, height=h)
|
169
|
+
|
170
|
+
elif isinstance(new_w, int) and new_h is None:
|
170
171
|
h = self.CH.current_height
|
171
|
-
if isinstance(new_w, int):
|
172
172
|
w = new_w
|
173
173
|
self.config(width=w)
|
174
|
+
|
175
|
+
elif isinstance(new_h, int) and new_w is None:
|
176
|
+
h = new_h
|
177
|
+
w = self.RI.current_width
|
178
|
+
self.config(height=h)
|
179
|
+
|
174
180
|
else:
|
181
|
+
h = self.CH.current_height
|
175
182
|
w = self.RI.current_width
|
183
|
+
|
176
184
|
except Exception:
|
177
185
|
return
|
186
|
+
|
178
187
|
self.coords(self.rw_box, 0, h - 5, w, h)
|
179
188
|
self.coords(self.rh_box, w - 5, 0, w, h)
|
180
189
|
self.coords(
|
@@ -187,8 +196,6 @@ class TopLeftRectangle(tk.Canvas):
|
|
187
196
|
h - 7,
|
188
197
|
)
|
189
198
|
self.coords(self.select_all_box, 0, 0, w - 5, h - 5)
|
190
|
-
if recreate_selection_boxes:
|
191
|
-
self.MT.recreate_all_selection_boxes()
|
192
199
|
|
193
200
|
def mouse_motion(self, event: object = None) -> None:
|
194
201
|
self.MT.reset_mouse_motion_creations()
|
tksheet/vars.py
CHANGED
@@ -42,6 +42,7 @@ text_editor_newline_bindings: set[str] = {
|
|
42
42
|
"<Alt-Return>",
|
43
43
|
"<Alt-KP_Enter>",
|
44
44
|
"<Shift-Return>",
|
45
|
+
f"<{ctrl_key}-Return>",
|
45
46
|
}
|
46
47
|
if USER_OS == "darwin":
|
47
48
|
text_editor_newline_bindings.add("<Option-Return>")
|
@@ -53,7 +54,9 @@ text_editor_close_bindings: dict[str, str] = {
|
|
53
54
|
"<Escape>": "Escape",
|
54
55
|
}
|
55
56
|
|
56
|
-
text_editor_to_unbind: set[str] =
|
57
|
+
text_editor_to_unbind: set[str] = (
|
58
|
+
text_editor_newline_bindings | set(text_editor_close_bindings) | {"<FocusOut>", "<KeyRelease>"}
|
59
|
+
)
|
57
60
|
|
58
61
|
scrollbar_options_keys: set[str] = {
|
59
62
|
"vertical_scroll_background",
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: tksheet
|
3
|
-
Version: 7.
|
3
|
+
Version: 7.3.0
|
4
4
|
Summary: Tkinter table / sheet widget
|
5
5
|
Author-email: ragardner <github@ragardner.simplelogin.com>
|
6
6
|
License: Copyright (c) 2019 ragardner and open source contributors
|
@@ -36,12 +36,14 @@ Classifier: Programming Language :: Python :: 3.9
|
|
36
36
|
Classifier: Programming Language :: Python :: 3.10
|
37
37
|
Classifier: Programming Language :: Python :: 3.11
|
38
38
|
Classifier: Programming Language :: Python :: 3.12
|
39
|
+
Classifier: Programming Language :: Python :: 3.13
|
39
40
|
Requires-Python: >=3.8
|
40
41
|
Description-Content-Type: text/markdown
|
41
42
|
License-File: LICENSE.txt
|
42
43
|
|
43
44
|
<p align="center" width="100%">
|
44
|
-
<img width="
|
45
|
+
<img width="45%" src="https://github.com/user-attachments/assets/4afc1783-6461-4b98-93cb-b2a2a7f35169" alt="tksheet table">
|
46
|
+
<img width="45%"src="https://github.com/user-attachments/assets/08e77e89-00ea-4c52-9222-9bd421284360" alt="tksheet treeview">
|
45
47
|
</p>
|
46
48
|
|
47
49
|
# <div align="center">tksheet - python tkinter table widget</div>
|
@@ -50,14 +52,35 @@ License-File: LICENSE.txt
|
|
50
52
|
|
51
53
|
[](https://github.com/ragardner/tksheet/releases) [](https://pypi.org/project/tksheet/)
|
52
54
|
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
55
|
+
<table>
|
56
|
+
<thead>
|
57
|
+
<tr>
|
58
|
+
<th style="color: lightgreen" colspan=2><strong>Help</strong></th>
|
59
|
+
</tr>
|
60
|
+
</thead>
|
61
|
+
<tbody>
|
62
|
+
<tr>
|
63
|
+
<td style="color: LightCoral">Versions 6.x.x →</td>
|
64
|
+
<td><a href="https://github.com/ragardner/tksheet/wiki/Version-6">Documentation Wiki</a></td>
|
65
|
+
</tr>
|
66
|
+
<tr>
|
67
|
+
<td style="color: lightgreen">Versions 7.x.x →</td>
|
68
|
+
<td><a href="https://github.com/ragardner/tksheet/wiki/Version-7">Documentation Wiki</a></td>
|
69
|
+
</tr>
|
70
|
+
<tr>
|
71
|
+
<td align="right" colspan="2"><a href="https://github.com/ragardner/tksheet/blob/master/docs/CHANGELOG.md">Changelog</a></td>
|
72
|
+
</tr>
|
73
|
+
<tr>
|
74
|
+
<td align="right" colspan="2"><a href="https://github.com/ragardner/tksheet/wiki/Version-7#asking-questions">Questions</a></td>
|
75
|
+
</tr>
|
76
|
+
<tr>
|
77
|
+
<td align="right" colspan="2"><a href="https://github.com/ragardner/tksheet/wiki/Version-7#issues">Issues</a></td>
|
78
|
+
</tr>
|
79
|
+
<tr>
|
80
|
+
<td align="right" colspan="2"><a href="https://github.com/ragardner/tksheet/wiki/Version-7#enhancements-or-suggestions">Suggestions</a></td>
|
81
|
+
</tr>
|
82
|
+
</tbody>
|
83
|
+
</table>
|
61
84
|
|
62
85
|
This library is maintained with the help of **[others](https://github.com/ragardner/tksheet/graphs/contributors)**. If you would like to contribute please read this [help section](https://github.com/ragardner/tksheet/wiki/Version-7#contributing).
|
63
86
|
|
@@ -82,8 +105,10 @@ This library is maintained with the help of **[others](https://github.com/ragard
|
|
82
105
|
- Expand row heights and column widths
|
83
106
|
- Change fonts and font size (not for individual cells)
|
84
107
|
- Change any colors in the sheet
|
85
|
-
- Dropdowns, check boxes, progress bars
|
86
108
|
- [Treeview mode](https://github.com/ragardner/tksheet/wiki/Version-7#treeview-mode)
|
109
|
+
- [Dropdown boxes](https://github.com/ragardner/tksheet/wiki/Version-7#dropdown-boxes)
|
110
|
+
- [Check boxes](https://github.com/ragardner/tksheet/wiki/Version-7#check-boxes)
|
111
|
+
- [Progress bars](https://github.com/ragardner/tksheet/wiki/Version-7#progress-bars)
|
87
112
|
- [Hide rows and/or columns](https://github.com/ragardner/tksheet/wiki/Version-7#example-header-dropdown-boxes-and-row-filtering)
|
88
113
|
- Left `"w"`, Center `"center"` or Right `"e"` text alignment for any cell/row/column
|
89
114
|
|
@@ -117,4 +142,3 @@ sheet.delete_columns(columns=[0, 3], undo=True)
|
|
117
142
|

|
118
143
|
|
119
144
|
|
120
|
-
|
@@ -0,0 +1,20 @@
|
|
1
|
+
tksheet/__init__.py,sha256=og5YQbRL0wYfgixmKn9svO5aBxbujfvRhBsWlhmOtVs,2236
|
2
|
+
tksheet/colors.py,sha256=1k06VorynLmnC4FdJg8H4reIA6rXaeXBpdMwXLhN8oc,51594
|
3
|
+
tksheet/column_headers.py,sha256=qNDoJoERLKs9hG9rVgclIk-HAZkmJ6Y6qwvdlCa2-l8,102502
|
4
|
+
tksheet/formatters.py,sha256=_exO2KnjtcnE_MVWLG1ngOZ-wmrXZhuh7uEi2iPs1Tk,10546
|
5
|
+
tksheet/functions.py,sha256=v9_YH1-6cQ-tixl-P2ZR0bGNOsOa6FyYMwBsAl1YLrQ,43224
|
6
|
+
tksheet/main_table.py,sha256=6rhc4RtK4s8Mh5bhq_hyVlX56l-1B7a2D1WWd3nfacI,334819
|
7
|
+
tksheet/other_classes.py,sha256=cYcu8TYgGdsJ6ZGG51AQFVrzj7Lu0LwAn62V7iUh_mc,16488
|
8
|
+
tksheet/row_index.py,sha256=oe71E_Y3nj5dhbRTw5DhYDgqxPlL0mGYmaZaMu8AP5w,111295
|
9
|
+
tksheet/sheet.py,sha256=vMsZdciGrNvg0xcDaVAbadlHhCDj_XAy3HgXIz63FPw,288653
|
10
|
+
tksheet/sheet_options.py,sha256=j2e0ij8Pf9ey85GKuMXoCDMkFGJVcDk3t_NNVlBGbuI,6991
|
11
|
+
tksheet/text_editor.py,sha256=zrBdURBFNBbnl8GmZ4vQMFZ3UmvAvfBZ7KSJi_WtrNI,7449
|
12
|
+
tksheet/themes.py,sha256=AoNAxibnQi04MN0Zpbn9-kyDnkiiV8TDNWP9FYjpuf0,18473
|
13
|
+
tksheet/top_left_rectangle.py,sha256=0vzhYK7oGe9M_v7mlxFLh595XuXuXDOjooCDuR5sqnM,8593
|
14
|
+
tksheet/types.py,sha256=IgoEHMbceKpakcZtanxKaKJ4RdCq7UW6EoEIIz5O59k,340
|
15
|
+
tksheet/vars.py,sha256=-NWaHEEpcQ0YHn4yGDf8SSffjceiEOayGqnEYw6VwPM,3507
|
16
|
+
tksheet-7.3.0.dist-info/LICENSE.txt,sha256=ndbcCPe9SlHfweE_W2RAueWUe2k7yudyxYLq6WjFdn4,1101
|
17
|
+
tksheet-7.3.0.dist-info/METADATA,sha256=Fheob3WhJC4xXiBM01uelrZdxT0pVu-p_t6JQmziReI,7282
|
18
|
+
tksheet-7.3.0.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
|
19
|
+
tksheet-7.3.0.dist-info/top_level.txt,sha256=my61PXCcck_HHAc9cq3NAlyAr3A3FXxCy9gptEOaCN8,8
|
20
|
+
tksheet-7.3.0.dist-info/RECORD,,
|
tksheet-7.2.22.dist-info/RECORD
DELETED
@@ -1,20 +0,0 @@
|
|
1
|
-
tksheet/__init__.py,sha256=KfgSwnegxJiSsth7RbsdT2_7OOroneLct14yf_m1uc8,2237
|
2
|
-
tksheet/colors.py,sha256=1k06VorynLmnC4FdJg8H4reIA6rXaeXBpdMwXLhN8oc,51594
|
3
|
-
tksheet/column_headers.py,sha256=PybWCaMxHj0b-M3JOKu44yr9jGfHjxdKaKEGo9ZmwGg,102963
|
4
|
-
tksheet/formatters.py,sha256=_exO2KnjtcnE_MVWLG1ngOZ-wmrXZhuh7uEi2iPs1Tk,10546
|
5
|
-
tksheet/functions.py,sha256=REgBYkogJYxJ4TiNf9i_l_qExfizpWDwxdSxRB-6TbU,42770
|
6
|
-
tksheet/main_table.py,sha256=n6k1sU-lSb_xSHYUl4w13vBcqw1opFAZ9Gimn1jRq8s,334147
|
7
|
-
tksheet/other_classes.py,sha256=MRwF4YJMEZUDTk6xOTBFwR7jT3bMbbNlp4dZSpEdIfU,16406
|
8
|
-
tksheet/row_index.py,sha256=0nIlQY6q8iiWROp3mjBCNrZwoY1NUtG30tjBO_zJMcI,111854
|
9
|
-
tksheet/sheet.py,sha256=jD2fdRHRgWF49f5Pm674BmAaiSZDeEW7tK_xjD-41WA,287546
|
10
|
-
tksheet/sheet_options.py,sha256=XM3XSWWVnAOctP2z2_WkkXonoIT8_brXwJaSO0sFZbE,12788
|
11
|
-
tksheet/text_editor.py,sha256=pf9o3JuRI6cbr7ZoVfaookCBJsmRBgGDubdtShLZXBA,7064
|
12
|
-
tksheet/themes.py,sha256=OhUzZL4JH0YPhb2f1F62CcJFzhVsEvNxF-ObC9zVb44,14474
|
13
|
-
tksheet/top_left_rectangle.py,sha256=ri7hb9CC5l37ynmxceprq11UuWWRpWEI_0AI42wzv0A,8444
|
14
|
-
tksheet/types.py,sha256=IgoEHMbceKpakcZtanxKaKJ4RdCq7UW6EoEIIz5O59k,340
|
15
|
-
tksheet/vars.py,sha256=86ubZZElsnQuC6Lv6bW2lt2NhD9wAp6PxtkK7ufKqq0,3452
|
16
|
-
tksheet-7.2.22.dist-info/LICENSE.txt,sha256=ndbcCPe9SlHfweE_W2RAueWUe2k7yudyxYLq6WjFdn4,1101
|
17
|
-
tksheet-7.2.22.dist-info/METADATA,sha256=FZI4xYr6n5uq1HbYuac8PR1vq2u_zEm95gPoY9VE4og,6481
|
18
|
-
tksheet-7.2.22.dist-info/WHEEL,sha256=R06PA3UVYHThwHvxuRWMqaGcr-PuniXahwjmQRFMEkY,91
|
19
|
-
tksheet-7.2.22.dist-info/top_level.txt,sha256=my61PXCcck_HHAc9cq3NAlyAr3A3FXxCy9gptEOaCN8,8
|
20
|
-
tksheet-7.2.22.dist-info/RECORD,,
|
File without changes
|
File without changes
|