- #281.
- #283.
- #282.
- #280.
- Find in selection would sometimes fail.
- Redraw optimizations.
- 7.4.12 deselection display regression.
- Header and index dropdown boxes with center aligned text made text spill out of the cell a little.
- Further minor redrawing performance improvements.
- Minor tree build performance improvement.
- Minor performance improvement for moving rows/columns.
- Edge case error with moving rows while using treeview mode.
- html documentation.
- #275.
- Fixes and improvements to treeview mode.
- Refactored adding/deleting rows/columns code, behavior should be unchanged.
- Removed redundant
self.tree
attribute from treeview mode. - Added
event_data: EventDataDict | None = None
parameter toset_data()
as the last parameter. - Added
undo
andemit_event
parameters toitem()
.
- Treeview function
tree_traverse()
.
- #274.
- Getting data using spans or
get_data()
withtdisp=True
and a"format"
typeSpan
would not result in formatted data. - Incorrect docstring in
get_data()
.
- Span data getting performance.
- Old data getting functions performance.
- Numerous fixes and improvements for using the find window with hidden rows/columns.
- Error on trying to resize row height when the row is empty.
- Rare minor issues with setting bindings using
set_options()
. - Some events were adding to the undo stack even if undo was disabled.
- Error on trying to sort rows by column when using the treeview.
- Error on using certain non-treeview row moving functionality while using the treeview.
enable_bindings()
with"all"
or no args will now also enable the find and replace window.- If you use
enable_bindings()
with"all"
or no args and your software has its own Ctrl/Cmd g/G/h/H binding you may need to make changes such as usingset_options()
to remove tksheets find window bindings. - The find window will no longer match displayed text in the table from checkboxes and dropdown boxes, only underlying cell data values. This is because the text values are not typically editable from the user end.
- Replace and replace all functionality in the find window.
- Using the find window without find within selection in treeview mode will show hidden rows if there's a cell match.
- The find window is now draggable horizontally.
- Ctrl/Cmd h/H binding for toggle replace.
**kwargs
toSheet()
initialization so that other settings can be changed such as bindings.
- Refactored
extra_bindings()
code, behavior should be unchanged. - Find window icons have been improved.
- Add
push_n
to tksheet namespace
- #267 as it was not fixed in version
7.4.5
- Bugs with treeview mode
item()
iid
parameter, used for changing item ids see()
function scrolls to wrong position if the row index auto-resized after scrolling
- In-built find window performance
- Issues since version
7.4.4
withget_cell_kwargs()
leading to cell options such as dropdowns sometimes not displaying
- Remove unused parameter
object
fromFormatter
class
- Functions which had mutable default arguments have been changed to either have:
- no default argument where appropriate OR
None
as the default and create an empty mutable ifNone
- #267
- Treeview mode: changed recursive functions to
while
functions to avoid recursion depth limit during tree traversal - Additional treeview function
move()
fixes
- Code for
see()
and arrow key functions
- !: Parameter for function
sort()
:boxes
is now*box: CreateSpanTypes
- More information
- Sorting algorithm wasn't sorting some items correctly
- Boxes in event data not being correct when
sort()
was used - Addressed some issues with treeview mode
move()
- New in-built sort keys and default
sort_key
initialization andset_options()
parameternatural_sort_key
version_sort_key
fast_sort_key
- Various minor performance improvements
- Functions bound using
extra_bindings()
were only called when a user performed an action, they're now always called when:- adding rows/columns
- deleting rows/columns
- Dropdown search fallback matching, performance
show_top_left
parameter now defaults toNone
to represent tksheet handling of top left visibility- Provide
natural_sort_key
as importable fromtksheet.natural_sort_key
dropdown_search_function
now uses an iterable of objects rather than an iterable of Sequences of objects- Rename internal parameter
restored_state
->from_undo
- Strings that started with numbers not being sorted in the correct order
- Add file paths to sort order using pathlib
- For better backwards compatibility use the usual "move_rows"/"move_columns" event names for sorting rows/columns events
- Issues with
7.4.0
sorting - #270
- Only add to index header when user adds rows/columns if index/header is populated
- Text now wraps by character by default, can also disable wrapping or wrap by word
- Significant changes to how text is rendered
- Removed mousewheel scrolling lines in header, replaced with vertical axis table scroll
- Resizing row height to text is now based on the existing column width for the cell/cells, includes double click resizing
- Treeview mode
Node
class now usesstr
for parent andlist[str]
for children attributes - Function
get_nodes()
renamed ->get_iids()
- Removed
data_indexes
parameter frommapping_move...
functions - Reduce default treeview indent
move()
function now returns the same as other move rows functions- All
Sheet()
functions with anundo
parameter have been set toTrue
by default - Using
Sheet.set_data()
orSpan
s to set an individual cell's data asNone
will now do so instead of returning - Setting
show_top_left
during Sheet() initialization will now make the top left rectangle always show
- Natural sorting functionality #238
- Treeview mode now works with all normal tksheet functions, including dragging and dropping rows
- Cell text overflow
allow_cell_overflow: bool = False
to adjacent cells for left and right alignments, disabled by default - Text wrap for table, header and index
# "" no wrap, "w" word wrap, "c" char wrap
table_wrap: Literal["", "w", "c"] = "c",
index_wrap: Literal["", "w", "c"] = "c",
header_wrap: Literal["", "w", "c"] = "c",
tree
parameter toinsert_rows()
function, used internally
- Index fonts now work correctly
- Functions
column_width()
androw_height()
work correctly for any parameters - Down sizing rows/columns when scrolled to the end of the axis would result in a rapid movement of row height/column width
- Address #269
- Minor performance improvements for:
item_displayed()
show_rows()
/show_columns()
move()
- Row insertion
- Error on find within selection without a selection
- Some canvas z fighting issues
- Refactored redrawing code
- rename Sheet() attr: dropdown_class -> _dropdown_cls
- Find within selection performance + memory
- Moving rows/columns performance
- Built-in find window, use
enable_bindings("find")
to enable - Escape binding which deselects
reverse
parameter toget_selected_cells()
function
- Not redrawing after Control-space, Shift-space bindings for selecting columns/rows
- Not redrawing after Home, Control/Command-Home bindings for selecting start of the row and start of the table
- Dropdown boxes not reseting y scroll
- Issues with arrow key down
- Arrow key up wrongly moving scroll at row 0
- Renamed
vars.py
->constants.py
- Add
_version.py
to.gitignore
enable_bindings()
with"find"
now enables an in-built find window which uses the following bindings:- Control/Command-f/F
- Control/Command-g/G
- Control/Command-Shift-g/G
- Escape
- Return (when the find window has focus)
- Alt/Option-L to find within selection
- Added Escape binding when cell selection is enabled. Pressing Escape will now close the find window if its open, if its not open it will close any open text editor/dropdown box and deselect all cells.
deselect()
also closes text editor / dropdown
- Mac OS Zoom in/out bindings
- Control-space, Shift-space bindings for selecting columns/rows if enabled
- Home, Control/Command-Home bindings for selecting start of the row and start of the table
bulk_insert()
: wrong example- Docstrings: return values for
insert()
,bulk_insert()
- Wrong type hinting for
Iterator
"end_edit_cell"
events for single cell edits e.g. for cell text editor, dropdown box and checkbox edits now have the value prior to the edit in the event under keyscells.table
- Variables default values in
Sheet()
init have changed from"inf"
->float("inf")
:max_column_width
max_row_height
max_index_width
max_header_height
- Moved variables from
Sheet.MT
->Sheet.ops
:max_column_width
max_row_height
max_index_width
max_header_height
- Lag on resize index width or header height
- Ability to set minimum column width:
min_column_width
inSheet()
init andset_options()
- Edit validation will now also be triggered for undo and redo 256
- Cell text editors and dropdowns have their own shared background and foreground colors 255
7.2.22
regression when using cell text editors and normal dropdown boxes7.2.22
regression"normal"
dropdown box withmodified_function
not being triggered upon non-key release events such as by right clicking in the text editor and pasting- Select events will no longer be emitted upon b1 release
- Options for changing table, index and header cell editor bg, fg 255
- Added
Sheet()
parameters:table_editor_bg
table_editor_fg
table_editor_select_bg
table_editor_select_fg
index_editor_bg
index_editor_fg
index_editor_select_bg
index_editor_select_fg
header_editor_bg
header_editor_fg
header_editor_select_bg
header_editor_select_fg
- Added
- Autocomplete for
"normal"
state dropdown boxes - Python
3.13
support badge "disabled"
state for dropdown boxes- docstrings for enable/disable bindings and extra bindings functions to help with arguments
- Alternate row colors no longer blend with clear single cell selection box
- Highlights and alternate row colors not blending with
show_selected_cells_border=False
- Tab key with
show_selected_cells_border=False
not updating selected colors when using highlights - Treeview
selection_set()
/selection_add()
now only use iids that are in the tree, will not generate an error if an iid is missing - Error on close text editor
- Code: minor type hinting
- Code: variable name clarity
- Storing functions in event data using
pickle
causes error 253
- Basic alternate row colors option
float_formatter()
by default will no longer accept inputs that end in"%"
percentage_formatter()
defaultformat_function
renamed:to_float()
->to_percentage()
- Events no longer emitted for cut, paste or delete if the sheet has not been edited, for example due to read only cells 249
__init__()
calls now usesuper()
- Options for percentage formatter:
format_function
optionto_percentage()
format_function
optionalt_to_percentage()
to_str_function
optionalt_percentage_to_str()
- Documentation for data formatting
- Error when pasting into empty sheet
- Potential error if using percentage formatter with more than just
int
,float
and wrong type hint 250 - Only show the selection box outline while the mouse is dragged if the control key is down
index
andheader
Span
parameters were not working with functionreadonly()
- Shift + arrowkey bindings for expanding/contracting a selection box
- Functions for getting cell properties (options) 249
- Ability to edit index in treeview mode, if the binding is enabled
- Very slight performance boost to treeview insert, inserting rows when rows are hidden
- Inserting rows/columns with hidden rows/columns sometimes resulted in incorrect rows/columns being displayed
- Treeview function
insert()
when using parameterindex
sometimes resulted in treeview items being displayed in the wrong locations
- Using function
set_currently_selected()
or any function/setter which does the same internally will now trigger a select event like creating selection boxes does - iids in Treeview mode are now case sensitive
- Treeview function
tree_build()
when parametersafety
isFalse
will no longer check for missing ids in the iid column - Treeview function
get_children()
now gets item ids from the row index which provides them in the same order as in the treeview - Add parameter
run_binding
to treeview functionsselection_add()
,selection_set()
- Slight color change for top left rectangle bars
- Initialization parameters
default_header
anddefault_row_index
can now optionally be set toNone
to not display anything in empty header cells / row index cells - Parameters
lower
andinclude_text_column
to treeview functiontree_build()
- Treeview function
bulk_insert()
- Treeview function
get_nodes()
behaves exactly the same asget_children()
except it retrieves item ids from the tree nodesdict
not the row index. - Treeview function
descendants()
which returns a generator - Treeview property
tree_selected
- Treeview mode slight appearance change
- Treeview mode documentation
- New option to address 247
- New options to address 246
- Redundant code causing potential redraw error
- Wrong version number in
__init__.py
- Moved variable
default_index
to sheet options asdefault_row_index
- Moved variable
default_header
to sheet options
- Documentation
- 235
- Error with
show_columns()
- Resizing rows/columns with mouse button motion now does so during the motion also
- Fix index width resizing regression
- Sheet no longer steals focus when using
set_sheet_data()
and similar functions, issue 233
- Don't show row index resize cursor when unnecessary
- Dropdown box arrows changed back to lines as polygon triangles had issues with outlines
- Possible slight changes to logic of
display_rows()
/display_columns()
displayed_rows.setter
/displayed_columns.setter
now reset row/column positions
- Minor flicker when selecting a row or column
- Top left rectangle sometimes not updating properly on change of dimensions
- Dropdown triangle visuals
- Top left rectangle colors
- Dropdown box outline in index/header
- 230
- Incorrect rows/columns after move with hidden rows/columns
- Event data for moving rows/columns with hidden rows/columns e.g. under
event.moved.rows.data
now returns not just the moved rows/columns but all new row/column indexes for the displayed rows/columns. e.g. Useevent.moved.rows.displayed
withSheet.data_r()
/Sheet.data_c()
to find only the originally moved rows/columns - Moving rows/columns with hidden rows/columns will only modify these indexes if
move_data
parameter isTrue
, default isTrue
- Drag and drop incorrect drop index
set_all_cell_sizes_to_text()
incorrect widths
- Functions that move rows/columns such as
move_rows()
/move_columns()
have had their move to indexes changed slightly, you may need to check yours still work as intended if using these functions
StopIteration
on drag and drop
gen_selected_cells()
functionis_contiguous
totksheet
namespace
- Progress bars
- Fix resizing cursor appearing at start of header/index and causing issues if clicked
- Fix add columns/add rows not inserting at correct index when index is larger than row or data len
- Fix add columns/add rows not undoing/redoing added heights/widths respectively
- Fix add columns/add rows regression
- Add functions to address 227:
get_column_text_width
get_row_text_height
visible_columns
-@property
visible_rows
-@property
- Internal parameter names:
only_set_if_too_small
->only_if_too_small
- Internal functions:
get_visible_rows
,get_visible_columns
->visible_text_rows
,visible_text_columns
, also changed to properties@property
- Internal function parameters:
set_col_width
set_row_height
- Regression since
7.2.0
: selection box borders not showing for rows/columns
- Slightly reduced minimum row height since
7.2.0
change
- Cells in index/header not having correct colors when columns/rows were selected
- 226
- A somewhat major change which warranted a significant version bump - the minimum row height has increased slightly to better accodomate the pipe character
|
- Error on paste into empty sheet with
expand_sheet_if_paste_too_big
- Data shape not being correct upon inserting a single column or row into an empty sheet
- Potential for
insert_columns()
to cause issues if provided columns are longer than current number of sheet rows - 225 Insert columns and insert rows not inserting blank cells into header/row index, issue seen with either:
- Right clicking and using the in-built insert functionality
- Using the
Sheet()
functions with anint
for first parameter
- Wrong sheet dimensions caused by a paste which expands the sheet
- Wrong new selection box dimensions after paste which expands the sheet
set_options()
withtable_font=
not working
expand_sheet_if_paste_too_big
replaced bypaste_can_expand_x
andpaste_can_expand_y
. To avoid compatibility issues usingexpand_sheet_if_paste_too_big
will set both new options
- Additional protection against issue 224 but with
auto_resize_row_index="empty"
which is the default setting
- Redrawing loop with
auto_resize_row_index=True
224
- Unfortunately in order to fix 224 while using
auto_resize_row_index=True
the x scroll bar will no longer be hidden if it is not needed
- Massive lag when pasting large amounts of data, caused by using Python
csv.Sniffer().sniff()
without setting sample size, now only samples 5000 characters max
- Added
widget
key to emitted eventdict
s which can be either the header, index or table canvas. If you're usingpickle
on tksheet eventdict
s then you may need to delete thewidget
key beforehand - Added
Highlight
,add_highlight
,new_tk_event
andget_csv_str_dialect
to tksheet namespace - Some old functions which used to return
None
now returnself
(Sheet
) - Re-add old highlighting functions to docs
- Event data from moving rows/columns while rows/columns are hidden no longer returns all displayed row/column indexes in the
dict
keys["moved"]["rows"]["data"]
/["moved"]["columns"]["data"]
but instead returns only the rows/columns which were originally moved. - Add
Shift-Return
to text editor newline bindings - Internal
close_text_editor()
function parameters - Function
close_text_editor()
now closes all text editors that are open
- New parameters to
dropdown()
:edit_data
to disable editing of data when creating the dropdownsset_values
so adict
of cell/column/row coordinates and values can be provided instead of usingset_value
for every cell in the span
- New emitted events - issue 223:
"<<Copy>>"
"<<Cut>>"
"<<Paste>>"
"<<Delete>>"
"<<Undo>>"
"<<Redo>>"
"<<SelectAll>>"
- Dropdown box scrollbars will only display when necessary
- Some themes colors
- Old function
highlight_cells()
slight performance boost when calling it thousands of times - Added parameters back to the functions
dropdown()
/checkbox()
for help when writing code
- Error with
equalize_data_row_lengths()
while displaying a row as the header
- Dropdown and treeview arrow appearance to triangles
- External right click popup menu being overwritten by internal when right clicking in empty table space
- Copying and pasting values from a single column not working correctly
- Mousewheel in header not working on
Linux
get_cell_options()
/get_row_options()
/get_column_options()
/get_index_options()
/get_header_options()
values not being requested option. These functions now return adict
where the values are the requested option, e.g. for"highlight"
the values will benamedtuple
s
- Functions
cut()
/copy()
/paste()
/delete()
/undo()
/redo()
now returnEventDataDict
and notself
/Sheet
get_cell_options()
/get_row_options()
/get_column_options()
/get_index_options()
/get_header_options()
, see above fix- Clipboard operations where there's a single cell which contains newlines will now be clipboarded surrounded by quotechars
- Functions
del_row_positions()
/del_column_positions()
validation
parameter tocut()
/paste()
/delete()
,False
disables any boundedit_validation()
function from runningrow
andcolumn
keys tocut()
/paste()
/delete()
events bound withedit_validation()
- Incorrect dropdown box opening coordinates following the opening of dropdown boxes on different sized rows
- Calling
grid_forget()
on a parent widget after opening a dropdown box would cause opened dropdown boxes to be hidden disable_bindings()
with right click menu options such as insert_columns would disable the whole right click menu- Removed old deprecated dropdown box
dict
values
- To disable the whole right click menu using
disable_bindings()
it must be called with the specific string"right_click_popup_menu"
- themes
dict
s nowDotDict
s
- Rare error when selecting header cell with an empty table and
auto_resize_columns
enabled
- Issue 221
- Flickering when scrolling by using mouse to drag scroll bars
- Custom bindings overwritten when using
enable_bindings()
- Rare situation where header/index is temporarily out of sync with table after setting xview/yview
- Potential error caused by moving rows/columns where:
- There exists a header but data is empty
- Data and index/header are all empty but displayed row/column lines exist
- Function
equalize_data_row_lengths
parameterinclude_header
nowTrue
by default - Right clicking with right click select enabled in empty space in the table will now deselect all
- Right clicking on a selected area in the main table will no longer select the cell under the pointer if popup menus are not enabled. Use mouse button 1 to select a cell within a selected area
- Functions:
has_focus()
ctrl_boxes
canvas_boxes
full_move_columns_idxs()
full_move_rows_idxs()
- Issue with setting sheet xview/yview immediately after initialization
- Visual selection box issue with boxes with 0 length or width
- Issue 220
- Functions:
boxes
setter for use withSheet.get_all_selection_boxes_with_types()
orSheet.boxes
propertyselected
setterall_rows
property to getall_rows_displayed
bool
all_columns
property to getall_columns_displayed
bool
all_rows
setter to setall_rows_displayed
bool
all_columns
setter to setall_columns_displayed
bool
displayed_rows
setter uses functionSheet.display_rows()
displayed_columns
setter uses functionSheet.display_columns()
- All parameters from function
Sheet.after_redraw()
- Warnings about version changes from
Sheet()
initialization within_range
parameters from internalget_selected_cells
/get_selected_rows
/get_selected_columns
functions
- Using a cell text editor followed by setting a dropdown box with a text editor would set the previously open cell to the dropdown value
- Selection boxes now have rounded corners
- Function
get_checkbox_points
renamedrounded_box_coords
rounded_boxes
Sheet option- WIP
ListBox
class
- Undo error
- Function
deselect_any()
for non specific selection box type deselections
set_all_cell_sizes_to_text()
not working correctly if table font is different to index font, resulting in dropdown box values not showing properly- Dropdown box colors and options not being updated after sheet color change
- Text editor alignments not working
- Dropdown box alignment now uses cell alignment
- Minor changes to arrow key cell selection
- When using
show_selected_cells_border=False
the colors fortable_selected_box_cells_fg
/table_selected_box_rows_fg
/table_selected_box_columns_fg
will be used for the currently selected cells background
- Fixed shift mouse click select rows/columns selecting cells instead of rows/columns
- Fixed
"<<SheetSelect>>"
event not being emitted after row/column select events
- Add new parameters to
cell_selected()
,row_selected()
,column_selected()
, no default behaviour change - Functions:
event_widget_is_sheet()
@property
functionboxes
, the same asget_all_selection_boxes()
drow()
,dcol()
functions the same asdisplayed_row_to_data()
/displayed_column_to_data()
- Error with
get_all_selection_boxes_with_types()
- Column selected detection bug
- Tagged cells/rows/columns not taken into account in max index detection, relevant for moving columns/rows
- Select all error
- Span widget attribute lost on delete rows/columns and undo
- Tagged cells/rows/columns lost on delete rows/columns and undo
- Event data key
"selected"
and functionget_currently_selected()
values have changed:type_
attribute has been changed from either"cell"
/"row"
/"column"
to"cells"
/"rows"
/"columns"
- The attributes in the latter indexes have also changed
- See the documentation for
get_currently_selected
for more information
- Rename class
TextEditor_
toTextEditorTkText
- Rename
TextEditor
attributetextedit
totktext
- Rename
namedtuple
CurrentlySelectedClass
toSelected
- Overhaul how selection boxes are handled internally.
Sheet
functions dealing with selection boxes should behave the same - Changed order of
Sheet()
init parameters
auto_resize_row_index
now has a different default value for its old behaviour:auto_resize_row_index: bool | Literal["empty"] = "empty"
- With
"empty"
it will only automatically resize if the row index is empty - With
True
it will always automatically resize False
it will never automatically resize
- With
- Scrollbar appearance
hide_rows()
/hide_columns()
functions now endeavour to save the row heights/column widths so that they may be reinserted when using new functionsshow_rows()
/show_columns()
- Internal Dropdown Box information
dict
s no longer have the keys"window"
and"canvas_id"
Span objects now have an additional two functions which link to the Sheet
functions of the same names:
span.tag()
span.untag()
- Parameters:
set_text_editor_value()
parametersr
andc
- Functions:
show_rows()
,show_columns()
which are designed to work alongside theirhide_rows()
/hide_columns()
counterpartsset_index_text_editor_value()
andset_header_text_editor_value()
xview()
,yview()
,xview_moveto()
,yview_moveto()
- Parameters:
data_indexes
bool
parameters to functions:hide_rows
,hide_columns
, default value isFalse
meaning there is no behavior changecreate_selections
bool
parameters to functions:insert_rows
,insert_columns
default value isTrue
meaning there is no behavior change
- New tksheet functionality:
- Treeview mode (still a work in progress - functions are inside
sheet.py
under # Treeview Mode) - Cell, row and column tagging functions, also added to
Span
s - Ability to change the appearance of both scroll bars
- New binding
"<<SheetSelect>>"
which encompasses all select events
- Treeview mode (still a work in progress - functions are inside
mapping_move_rows()
error- Potential issue with using
insert_rows
while also using anint
as the row index to display a specific column in the index - Potential error if a selection box ends up outside of rows/columns
- Pull request #214
- Issue 215
- Ctrl select now allows overlapping boxes which begin from within another box
- Ctrl click deselection
- The currently selected cell will no longer change after edits to individual cells in the main table which are not valid with a different value
- The following
MainTable
attributes are now simplyint
s orstr
s which represent either pixels or number of lines, instead oftuple
s:default_header_height
default_row_height
Sheet()
init keyword argumentdefault_row_index_width
now only acceptsint
s- Simplify internal use of
default_header_height
,default_row_height
,default_column_width
,default_row_index_width
- Move the following attribute locations from
MainTable
toSheet.ops
:default_header_height
default_row_height
default_column_width
default_row_index_width
- Removed some protections for setting default row heights, default column widths smaller than minimum heights/widths
- Functions to address issue #212:
get_text_editor_value
close_text_editor
- Issue #210
- Additional header cells being created when using
set_data()
or data setting using spans under certain circumstances - Additional index cells being created when using
set_data()
or data setting using spans under certain circumstances
Sheet.reset()
function
- Some classifiers in
pyproject.toml
-
Parameter
emit_event
to the functions:span
set_data
clear
insert_row
insert_column
insert_rows
insert_columns
del_row
del_column
del_rows
del_columns
move_rows
move_columns
mapping_move_rows
mapping_move_columns
-
Attribute
emit_event
to Span objects, default value isFalse
-
Functions
mapping_move_rows
andmapping_move_columns
to docs
- Functions renamed:
move_rows_using_mapping
->mapping_move_rows
move_columns_using_mapping
->mapping_move_columns
- Order of parameters for functions:
mapping_move_rows
mapping_move_columns
Sheet()
initialization parameterrow_index_width
renameddefault_row_index_width
set_options()
keyword argumentrow_index_width
renameddefault_row_index_width
- Move doc files to new docs folder
- Delete
version.py
file, move__version__
variable to__init__.py
- Add backwards compatibility for
Sheet()
initialization parameters:column_width
header_height
row_height
row_index_width
- Function
cell_edit_binding()
useenable_bindings()
instead - Function
edit_bindings()
useenable_bindings()
instead
- Error when closing a dropdown in the row index
- Menus modified for every binding for one call of enable/disable bindings with more than one binding
- Editing the index/header cells being allowed when using
enable_bindings("all")
/enable_bindings()
when it's not supposed to
Sheet()
initialization parametercolumn_width
renameddefault_column_width
set_options()
keyword argumentcolumn_width
renameddefault_column_width
Sheet()
initialization parameterheader_height
renameddefault_header_height
set_options()
keyword argumentheader_height
renameddefault_header_height
Sheet()
initialization parameterrow_height
renameddefault_row_height
set_options()
keyword argumentrow_height
renameddefault_row_height
Sheet()
initialization parameterauto_resize_default_row_index
renamedauto_resize_row_index
set_options()
keyword argumentauto_resize_default_row_index
renamedauto_resize_row_index
Sheet()
initialization parameterenable_edit_cell_auto_resize
renamedcell_auto_resize_enabled
set_options()
keyword argumentenable_edit_cell_auto_resize
renamedcell_auto_resize_enabled
- Moved most changable sheet attributes to a dict variable named
ops
(which has dot notation access) accessible from theSheet
object - The order of parameters has been changed for
Sheet()
initialization Sheet
attributeself.C
renamedself.PAR
- Various widget attributes named
self.parentframe
have been renamedself.PAR
- Return key on cell editor will move to the next cell regardless of whether the cell was edited
- Parameters for classes
TextEditor
,TextEditor_
, `Dropdown - Bindings for cut, copy, paste, delete, undo, redo no longer use both
Command
andControl
but either one depending on the users operating system - Internal arrow key binding methodology, if you were previously using this to change the arrow key bindings see here for info on adding arrow key bindings
- A way to change the in-built popup menu labels, info here
- A way to change the in-built bindings for cut, copy, paste, delete, undo, redo, select all, all the arrowkey bindings and page up/down, info here
-
edit_cell_validation
fromSheet()
initialization,set_options()
and everywhere else due to confusion. Use the new functionedit_validation()
instead. -
Functions (use spans instead for the same purpose):
header_checkbox
index_checkbox
format_sheet
delete_sheet_format
dropdown_sheet
delete_sheet_dropdown
checkbox_sheet
delete_sheet_checkbox
-
Parameters:
verify
from functionsset_column_widths
andset_row_heights
-
Old unused and deprecated parameters for:
get_cell_data()
,get_sheet_data()
,get_row_data()
,get_column_data()
,yield_sheet_rows()
- All checkbox and dropdown creation functions
- Grid lines now properly raised above highlighted rows/columns
- Deselect events firing when unnecessary
- Using
extra_bindings()
with"end_edit_cell"
/"edit_cell"
no longer requires a return value in your bound function to set the cell value to. For end user cell edit validation use the new functionedit_validation()
instead - Changed functions:
-
Parameters and behavior:
checkbox
now is used to create checkboxes and utilises spansdelete_header_dropdown
default argument changed to required argument and can no longer delete a header wide dropdowndelete_index_dropdown
default argument changed to required argument and can no longer delete an index wide dropdown
-
Parameters only:
move_columns
most parameters changedmove_rows
most parameters changedclick_checkbox
most parameters changedinsert_row
parameteridx
default argument changed toNone
insert_column
parameteridx
default argument changed toNone
insert_rows
parameteridx
default argument changed toNone
insert_columns
parameteridx
default argument changed toNone
-
Renamed:
align
->table_align
-
- Reorganised order of functions in
sheet.py
to match documentation
- Method
edit_validation(func: Callable | None = None) -> None
to replaceedit_cell_validation
- New methods for getting and setting data
bind
now also accepts"<<SheetModified>>"
and"<<SheetRedrawn>>"
arguments- Redo, which is enabled when undo is enabled, use by pressing ctrl/cmd + shift + z
- Named spans for sheet options such as highlight, format
- Ctrl/cmd click deselect
- Ability to make currently selected box border different color to selection box border
- Overhaul and totally change event data sent to functions bound by
extra_bindings()
- Deselect events are now labelled as "select" events, see the docs on
"selection_boxes"
for more information - Overhaul internal selection box workings
- Rename tksheet files
- Pressing escape on text editors no longer generates an edit cell/header/index event
- Error with function
set_currently_selected()
- Term searching improved when typing in a normal state dropdown box
bind_event()
function,bind()
to be used instead
- tksheet no longer supports Python 3.6, only versions 3.7+
Due to errors caused when using Python versions < 3.8 the following functions have been removed:
- bool
- len
- Sheet init error since version
6.3.0
when running Python 3.7
- Two
EditCellEvent
s being emitted, removed the one withNone
astext
attribute - Selection box and currently selected box in different places when tab key pressed with single cell selected
- Return key not working in dropdown box when mouse pointer is outside of dropdown
- Visual issue: Dropdown arrow staying up when clicking on same cell with readonly dropdown state
- Visual issue: Dropdown row/column all arrows in up position when one box is open
- Many parameters from internal functions dealing with text editor to simplify code
- Cell selection doesn't move on Return key when cell edit using text editor was invalid
- Events for
extra_bindings()
end cut, delete and paste are no longer emitted if no changes were made
- Term searching improved when typing in a normal state dropdown box
- Cell editor right click not working
- Cell editor select all not working
- Some methods to
Sheet
objects, see documentation for more information.- bool
- len
- iter
- reversed
- contains
- Incorrect row being targeted with hidden rows and text editor newline binding (potential error)
- #201
- The ends of grid lines were incorrectly displaying connections with one another when only showing horizontal or vertical grid
- When a cell dropdown and a row checkbox were in the same cell both would be drawn but only one would function, this has been changed to give dropdown boxes priority
- Index text overlapping checkbox when alignment is
"right"
/"e"
/"east"
and index is not wide enough
- Error when zooming or using
see()
with empty table - Add initialization option
zoom
which is anint
representing a percentage of the font size,100
being no change
- Some unnecessary internal variables
- Zoom in/out bindings control + mousewheel
- Zoom in bindings control + equals, control + plus
- Zoom out binding control + minus
- Bug with
format_row
using "all"
- 2 pixel misalignment of index/header and table when scrolling
- Undo cell edit not scrolling window
- Functionality to scroll multiple Sheets when scrolling one particular Sheet
- Editing header and overflowing text editor so text wraps while using
auto_resize_columns
causes text editor to be out of position insert_columns()
when using anint
for number of blank columns creates incorrect list layout
- Removed some type hinting that was only available to python versions >= 3.9
- Issues that follow selection boxes being recreated such as resizing columns/rows
extra_bindings()
not binding functions- #181
- Error with setting/getting header font
- Setting fonts with
set_options()
not working - Setting fonts after table initialization didn't refresh selection boxes or top left rectangle dimensions
- Replaced wildcard imports
- Format code with 120 line length
- Missing imports
- Bug with
delete_rows()
- Bug with hidden columns, cell options and deleting columns with the inbuilt right click menu
- Bug with a paste that expands the sheet where row lengths are uneven
- Poor box selection for cut and copy with multiple selected boxes
- Bug with
insert_columns()
with uneven row lengths - Bug with
insert_rows()
if new data contains row lengths that are longer than sheet data - Errors that occur when dragging and dropping rows/columns beyond the window
- Further potential issues with moving columns where row lengths are uneven
- Potential issues with using
move_rows()
where the provided index is larger than the number of rows dropdown_sheet()
causing error
- Error with using
None
to create a dropdown for the entire index when index is notint
- Bugs with using
None
to create dropdowns/checkboxes for entire header/index - Bug with creating dropdowns in row index
- Bug with opening dropdowns in row index
- Bug with
insert_rows()
ifrows
had more columns than existing sheet - Bug with
delete_column_dropdown()
- Bug with using external move rows/columns functions where
index_type
wasn't"displayed"
- Bug with hidden rows and cutting/copying
- Formatted code using
Black
- Bug with setting header height when header is set to
int
- Bug with clicking top left rectangle bars to reset header height / index width
- Wrong colors showing when having rows and columns selected at the same time
- Wrong colors showing for particular selection scenarios
- Control select enabled when using
enable_bindings("all")
when it should only be enabled if usingenable_bindings("ctrl_select")
- When control select was disabled holding control/command would disable basic sheet bindings
- Add additional binding for
sheet.bind_event()
."<<SheetModified>>"
and"<<SheetRedrawn>>"
are the two existing event options but currently only an empty dict is the associated data
disable_bindings()
disable all bindings not disabling edit header/index capability- Undo not recreating all former selection boxes with cell edits
- Undoing paste where sheet was expanded and rows were hidden didn't remove added rows
- Bug with hidden rows and index highlights
- Bug with hidden rows and text editor newline binding in main table
- Bug with hidden rows and drag and drop rows
- Issue where columns/rows that where selected already would not open dropdown boxes or toggle checkboxes
- External function
edit_cell()
, useopen_cell()
andset_currently_selected()
as alternative
- Control / Command selecting multiple non-consecutive boxes
- Functions
checkbox_cell
,checkbox_row
,checkbox_column
,checkbox_sheet
,dropdown_cell
,dropdown_row
,dropdown_column
,dropdown_sheet
and their related deletion functions
extra_bindings()
undo event type"insert_row"
renamed"insert_rows"
,"insert_col"
renamed"insert_cols"
extra_bindings()
undo event.storeddata
has changed for row/column drag drop undo events to("move_cols" or "move_rows", original_indexes, new_indexes)
- Initialization argument
max_rh
renamedmax_row_height
- Initialization argument
max_colwidth
renamedmax_column_width
- Initialization argument
max_row_width
renamedmax_index_width
header_dropdown_functions
/index_dropdown_functions
/dropdown_functions
now return dict- Rename internal function
create_text_editor()
- Select all now maintains existing currently selected cell when using Control/Command - a
- Renamed internal functions
check_views()
check_xview()
check_yview()
- Default argument
redraw
changed toTrue
for dropdown/checkbox creation functions - Internal function
open_text_editor()
keyword argumentset_data_on_close
defaulted toTrue
- Merge internal functions
edit_cell_()
andopen_text_editor()
, remove functionedit_cell_()
- Better graphical indicators for which columns/rows are being moved when dragging and dropping
- Better retainment of selection boxes after undo cell edits
- Right click delete rows bug PR#171
- Data getting with
get_displayed = True
not returning checkbox text and also in the main table dropdown box text - None being displayed on table instead of empty string
insert_columns()
/insert_rows()
with hidden columns/rows not working quite right
- Hidden rows capability use
display_rows()
/hide_rows()
and read the documentation for more info
- Some functions have had their
redraw
keyword argument defaulted toTrue
instead ofFalse
such ashighlight_cells()
hide_rows()
/hide_columns()
refresh
arg changed toredraw
hide_rows()
/hide_columns()
now uses displayed indexes not data
- Undo added to stack when no changes made with cut, paste, delete
- Using generator with
set_column_widths()
/set_row_heights()
would result in lost first width/height - Header/Index dropdown
modified_function
not sending modified event - Escape out of dropdown box doesn't reset arrow orientation
- Cell formatters, thanks to PR#158
format_cell()
,format_row()
,format_column()
,format_sheet()
- Options for changing output to clipboard delimiter, quotechar, lineterminator and option for setting paste delimiter detection
- Bindings
"up" "down" "left" "right" "prior" "next"
to enable arrowkey bindings individually use withenable_bindings()
/disable_bindings()
= Dropdowns now have a search feature which searches their values after the entry box is modified (if dropdown is statenormal
) - Dropdown kwargs
search_function
,validate_input
andtext
- Startup arg
ctrl_keys_over_dropdowns_enabled
, also removed inset_options()
set_copy
arg inset_cell_data()
return_copy
arg in data getting functions but will not generate error if used as keyword arg
index_border_fg
andheader_border_fg
no longer work, they now use the relevant grid foreground options"dark"
/"black"
themes- Dropdowns now default to state
"normal"
and validate input by default set_dropdown_values()
/set_index_dropdown_values()
/set_header_dropdown_values()
keyword argumentdisplayed
changed toset_value
for clarity- Checkbox click extra binding and edit cell extra binding (when associated with a checkbox click) return
bool
now, notstr
get_cell_data()
/get_row_data()
/get_column_data()
have had an overhaul and have different keyword arguments, see documentation for more information. They also now return empty string/s if index is out of bounds (instead ofNone
s)- Rename some internal functions for consistency
- Extra bindings delete key now returns dict instead of list for boxes
"dark"
theme now looks more appropriate for MacOS dark theme
Fixed:
- #157
- Double click row height resize not taking into account index checkbox text
Changed:
- Some internal variables local to redrawing functions for clarity
Fixed:
delete_rows()
/delete_columns()
incorrect row heights/column widths after use- Tab key not seeing cell if out of sight
- Row height / column width resizing with mouse incorrect by 1 pixel
- Row index not extending if too short when changing a specific index
- Selected rows/columns border fg not displaying in cell border
- Various minor text placements
- Edit index/header prematurely resizing height/width
Improved:
- Significant performance improvements in redrawing table, especially when simply selecting cells
- All themes
- Can now drag and drop columns and rows with or without shift being held down, mouse cursor changes to hand when over selected
Changed:
- Dropdown box colors now use popup menu colors
- Checkboxes no longer have X inside, instead simply a smaller more distinct rectangle to improve redrawing performance
Fixed:
Fixed:
set_row_heights()
/set_column_widths()
failing to set if iterable was emptydelete_rows()
/delete_columns()
failing to delete row heights, column widths if arg is empty- Edges of grid lines appearing when not meant to
Changed:
- Add
redraw
option forchange_theme()
Fixed:
- Dropdown boxes in main table not opening in certain circumstances
- Scrollbars not having correct column/rowspan
- Error when moving header height
- Resizing arrows still showing up when hiding header/index if height/width resizing enabled
Added:
header
startup argument, same asheaders
Changed:
- Increase default maximum undos from 20 to 30
- Removed dropdown box border, to get them back use
show_dropdown_borders = True
on startup or withset_options()
- Removed unnecessary variables and tidied
__init__
code
Fixed:
- #154
delete_column()
not working with hidden columnsinsert_column()
/insert_columns()
not working correctly with hidden columns
Added:
delete_columns()
,delete_rows()
Changed:
delete_column()
/delete_row()
now usedelete_columns()
/delete_rows()
internallyinsert_column()
now usesinsert_columns()
internally
Fixed:
Changed:
- Adjust dropdown arrow sizes for more consistency for varying fonts
Fixed:
- Issues and possible errors with dropdowns/checkboxes/cell edits
delete_dropdown()
/delete_checkbox()
issues
Changed:
- Deprecated external functions
create_text_editor()
/get_text_editor_value()
/bind_text_editor_set()
as they no longer worked both externally and internally, useopen_cell()
instead - Renamed internal function
get_text_editor_value()
toclose_text_editor()
Improved:
- Slightly boost performance if there are many cells onscreen and gridlines are showing
- You can now use the scroll wheel in the header to vertically scroll if there are multiple lines in the column headers
- Improvements to text editor
- Text now draws slightly closer to cell edges in certain scenarios
- Improved visibility of dropdown box against sheet background
- Improved dropdown window height
- black theme selected cells border color
- light green theme selected cells background color
Fixed:
- Error on start
Fixed:
- Row index missing itertools repeat
- Header checkbox, index checkbox bugs
- Row index editing errors
move_columns()
/move_rows()
redrawing when not supposed tomove_row()
/move_column()
errordelete_out_of_bounds_options()
errordehighlight_cells()
incorrectly wiping all cell options when"all"
is used
Changed:
set_column_widths()
/set_row_heights()
can now receive any iterable ifcanvas_positions
isFalse
- Tidied internal row/column moving code
Fixed:
display_columns()
no longer redraws ifdeselect_all
isTrue
even whenredraw
isFalse
extra_bindings()
cell editors carrying out cell edits even if validation function returnsNone
- Index and header alignments wrongly associated with column and row alignments if
align_header
/align_index
wereFalse
- Undo drag and drop wrong position if columns move back to higher index
- Error when shift b1 press in headers/index while using extra bindings
Changed:
- Internal variable name
data_ref
todata
get_currently_selected()
andcurrently_selected()
see documentation for more information- The way
extra_bindings()
+begin_edit_cell
works, now ifNone
is returned then the cell editor will not be opened - Paste repeats when selection box is larger than pasted items and is a multiple of pasted box
move_row()
/move_column()
now internally usemove_rows()
/move_columns()
black
theme text to be a lot brighter
Added:
- Spacebar to edit cell keys
- Function
open_cell()
which uses currently selected box and mouse event - Function
data
see the documentation for more info - Functions
get_cell_alignments()
,get_row_alignments()
,get_column_alignments()
,reset_all_options()
,delete_out_of_bounds_options()
- Functions
move_columns()
,move_rows()
- Deprecate functions
display_subset_of_columns()
,displayed_columns()
- Change
get_text_editor_value()
function argumentdestroy_tup
toeditor_info
- Change
display_columns()
function argumentindexes
tocolumns
- Change
display_columns()
function argumentenable
toall_columns_displayed
- Change some internal variable names
- Remove all calls to
update()
fromtksheet
- Fix row index
"e"
text alignment bug - Fix checkbox text not showing in main table when not using west alignment
- Fix
total_rows()
bug - Fix dropdown arrow being asymmetrical with different font sizes
- Fix incorrect default headers while using hidden columns
- Fix issue with
get_sheet_data()
if including index and header not putting a corner cell in the top left - Modify redrawing code, slightly improve redrawing efficiency in some scenarios
- Add dropdown boxes, check boxes and cell editing to index
- Add options
edit_cell_validation
which is an option forextra_bindings
, see the documentation for more info - Add function
yield_sheet_rows()
which includes default index and header values if using them - Add function
hide_columns()
which allows input of columns to hide, instead of columns to display - Add functions related to index editing, checkboxes and dropdown boxes
- Add default argument
show_default_index_for_empty
- Add
Edit header
option to in-built right click menu if both are enabled - Add
Edit index
option to in-built right click menu if both are enabled - Add
Edit cell
option to in-built right click menu if both are enabled - Documentation updates
- Fix bugs with functions
readonly_header()
,checkbox()
andheader_checkbox()
- Clarify table colors documentation
- Improve documentation a bit
- Fix bug with paste without anything selected
- Minor fix to highlight functions which could cause an error using certain args
- Fix
ctrl_keys_over_dropdowns_enabled
initialization arg not setting
- Fix focus out of table cell editor by clicking on header not setting cell
- Fix issue with
enable_bindings()
/disable_bindings()
no longer accept a tuple - Fix drag and drop bugs introduced in 5.3.6
- Fix bugs with header set to integer introduced in 5.3.6
- Editable and readonly dropdown boxes and checkboxes in the header
- Add readonly functions to header
- Editable header using `enable_bindings("edit_header")
- Display text next to checkboxes in cells using
text
argument (is not considered data just for display, the data is eitherTrue
orFalse
in a checkbox) - Move position of checkboxes and dropdown boxes to top left of cells
- Enable dragging and dropping columns when there are hidden columns, including undo
- Checkboxes no longer editable using
Delete
,Paste
orCut
- Dropdown boxes no longer editable using
Delete
,Paste
orCut
unless dropdown box has a value which matches, override this behaviour with new optionctrl_keys_over_dropdowns_enabled
- More logical behaviour around checkboxes and dropdown boxes and bindings
- Many improvements and bug fixes
- Fix control commands not working when top left has focus
- Fix bug when undoing paste where extra rows/columns were added during the paste (disabled by default)
- Unnecessary folder deletion
- Add new theme
dark
- Add
add
parameter to.bind()
function (only works for bindings which are not the following:"<ButtonPress-1>"
,"<ButtonMotion-1>"
,"<ButtonRelease-1>"
,"<Double-Button-1>"
,"<Motion>"
and lastly whichever is your operating systems right mouse click button)
- Fix Backspace binding in main table
- Fix minor issues with
startup_select
argument - Fix extra menus being created in memory
- Fix shift select error in main table when nothing else is selected
- Fix text editor not opening in highlighted cells
- Linux return key in cell editor fix
- Fix potential error with check box / dropdown
- Make dropdown box border consistent color
- Fix error with modifier key press on editable dropdown boxes
- Improve looks of dropdown arrows and fix slight overlapping with text
- Check boxes no longer show
Tr
andFa
when cell is too small for check box for large enough for text
- Fix issues with editable (
"normal"
) dropdown boxes and focus out bindings - Editable dropdown boxes now respond normally to character, backspace etc. key presses
- Fix bug with highlighted cells being readonly
- Fix user bound right click event not firing due to right click context menu
- Fix issues with hidden columns and right click insert columns
- Fix error on deleting row with dropdown box
- Fix issues with deleting columns with check boxes, dropdown boxes
- Improve looks for dropdown arrows
- Fix grid lines in certain drop down boxes
- Fix dropdown scroll bar showing up when not needed
- After resizing rows/columns if mouse is in same position cursor reacts accordingly again
- Remove
see
argument fromcreate_checkbox()
andcreate_dropdown()
because they rely on data indexes whereassee()
relies on displayed indexes - Fix undo not working with check box toggle
- Fix error on clicking sheet empty space
- Improve check box looks
- Fix bugs related to hidden columns and dropdowns/checkboxes
- Disable align from working with
create_dropdown()
because it was broken with anything except left alignment - Code cleanup
- Adjust dropdown box heights slightly
- Fix extra bindings begin edit cell making cell edit delete contents
- Make many events namedtuples for better clarity
- Add checkbox functionality
- Fix double button-1 not editing cell
- Fix error with edit cell extra bindings
- Fix dropdown box and checkbox triggering off of non-Return keypresses
- Fix issues with readonly cells and rows and control actions such as cut, delete, paste
- Begin to add checkbox code
- Some code cleanup
- Fix center, e text alignment with dropdowns
- Fix potential error when closing root Tk() window
- Fix error when hiding columns and creating dropdown boxes
- Fix dropdown box sizes
- Major fixes for dropdown boxes and possibly cell editor
- Fix mouse click outside cell edit window not setting cell value
- International characters should work to edit a cell by default
- Minor improvements
- Bugfixes and improvements related to
5.1.0
- Bugfixes and improvements related to
5.1.0
- Overhaul dropdowns
- Replace ttk dropdown widget
- Fix
None
returned withget_row_data()
whenget_copy
isFalse
- Add bindings for column width resize and row height resize
- Fix error with function
get_dropdowns()
- Add default argument
selection_function
tocreate_dropdown()
- Add sheet refreshing to delete_row(), delete_column()
- Fixed insert rows/columns below/left working incorrectly
- Fixed issue with cell editor stripping whitespace from the end of value
- Update documentation
insert_row
argumentadd_columns
nowFalse
by default for better performance
- Various minor improvements
- Internally set
all_columns_displayed
toTrue
when user chooses full list of columns as argument fordisplay_columns()
/display_subset_of_columns()
- Add option
expand_sheet_if_paste_too_big
in initialization andset_options()
which adds rows/columns if paste is too large for sheet, disabled by default
- Select all now needs to be enabled separately from
"drag_select"
using"select_all"
- Separate Control / Command bindings based on OS
- Fix documentation link
- Fix page up/down cell select event not being created if user has cell selected
- Put all begin extra functions inside try/except, returns on exception
- Attempt to fix PyPi version issue
set_sheet_data()
no longer verifies by default that data is list of lists (inbuilt functionality such as cell editing still requires list of lists though)- Initialization argument
data
allows tuple or list
- Scrolling with arrowkeys improvements
- Fix bug with hiding scrollbars not working
- Cell highlight tkinter colors no longer case sensitive
- Add additional items to
end_edit_cell
event responses
- Add function
default_column_width()
and addcolumn_width
to functionset_options()
- Add functions
get_dropdown_values()
andset_dropdown_values()
- Add row and column arguments to
get_dropdown_value()
to get a specific dropdown boxes value create_dropdown()
argumentsee
is nowFalse
by default
- Add functions
popup_menu_add_command()
andpopup_menu_del_command()
for extra commands on in-built right click popup menu - Update documentation
- Remove some unnecessary code (
preserve_other_selections
arguments in some functions) - Add documentation file, update readme file
- Add extra variable to undo event
- Edit cell no longer creates undo if cell is left unchanged
- Remove/add scrollbars depending on if window can be scrolled
- Fix bug with delete key
- Add default height and width if a height is used without a width or vice versa
- Add right (
e
) cell alignment for index and header
- Fix errors with
insert_column()
andinsert_columns()
- Fixed bugs with row copying where
list(repeat(list(repeat(
was used in code to create empty list of lists - Made cell resize to text (width only) take dropdown boxes into account
- Fix error with dropdown box close while showing all columns
- Fix bug with
delete_row()
anddelete_column()
functions when used with default arguments
- Fix bug with dragging scrollbar when columns are shorter than window
- Add startup argument
after_redraw_time_ms
default is100
- Fix bug with
insert_rows()
- Add
redraw
default argument to many functions, default isFalse
- Hopefully fix Linux mousewheel
- Fix auto resize issue
- Attempt to fix Linux mousewheel scrolling
- Add
enable_edit_cell_auto_resize
option to startup andset_options
default isTrue
- Fix potential issue with undo and dictionary copying
- Fix potential errors when moving/inserting/deleting rows/columns
- Add drop down position refresh to delete columns/rows on right click menu
- Various bug fixes and improvements
- Add readonly cells/columns/rows
- Fix bugs with
font()
functions - Fix edit cell bug when hiding columns
- Attempt to fix scrolling issues
- Make
display_subset_of_columns()
and other names of the same function always sort the showing columns - Make right click insert columns left shift data columns along
- Fix issues with
insert_column()
/insert_columns()
when hiding columns - Add default arguments
mod_column_positions
to functionsinsert_column()
/insert_columns()
which when set toFalse
only changes data, not number of showing columns - Add
"e"
aka right hand side text alignment for main table, have not added to header or index yet - Add functions
align_cells()
,align_rows()
,align_columns()
- Fix paste bug
- Fix mac os vertical scroll code
- Add mac OS command c, x, v, z bindings
- Make shift - mousewheel horizontal scroll
- Make alt tab windows maintain open cell edit box
- Fix bug in
insert_columns()
- Make functions
insert_row()
,insert_column()
,delete_row()
,delete_column()
adjust highlighted cells/rows/columns to maintain correct highlight indexes - Built in right click functions now also auto-update highlighted cells/rows/columns
- Add argument
reset_highlights
toset_sheet_data()
default isFalse
- Add function
dehighlight_all()
- Various bug fixes
- Right click insert column when hiding columns has been changed to always insert fresh new columns
- Fix bug with
highlight
functions wherefg
is set but notbg
- Fix delete key bug
- Change many values sent to functions set by
extra_bindings()
- begin is before action is taken, end is after
Binding | Response |
---|---|
"begin_ctrl_c" | ("begin_ctrl_c", boxes, currently_selected) |
"end_ctrl_c" | ("end_ctrl_c", boxes, currently_selected, rows) |
"begin_ctrl_x" | ("begin_ctrl_x", boxes, currently_selected) |
"end_ctrl_x" | ("end_ctrl_x", boxes, currently_selected, rows) |
"begin_ctrl_v" | ("begin_ctrl_v", currently_selected, rows) |
"end_ctrl_v" | ("end_ctrl_v", currently_selected, rows) |
"begin_delete_key" | ("begin_delete_key", boxes, currently_selected) |
"end_delete_key" | ("end_delete_key", boxes, currently_selected) |
"begin_ctrl_z" | ("begin_ctrl_z", change type) |
"end_ctrl_z" | ("end_ctrl_z", change type) |
"begin_insert_columns" | ("begin_insert_columns", stidx, posidx, numcols) |
"end_insert_columns" | ("end_insert_columns", stidx, posidx, numcols) |
"begin_insert_rows" | ("begin_insert_rows", stidx, posidx, numrows) |
"end_insert_rows" | ("end_insert_rows", stidx, posidx, numrows) |
"begin_row_index_drag_drop" | ("begin_row_index_drag_drop", orig_selected_rows, r) |
"end_row_index_drag_drop" | ("end_row_index_drag_drop", orig_selected_rows, new_selected, r) |
"begin_column_header_drag_drop" | ("begin_column_header_drag_drop", orig_selected_cols, c) |
"end_column_header_drag_drop" | ("end_column_header_drag_drop", orig_selected_cols, new_selected, c) |
boxes
are all selection box coordinates in the table, currently selected is cell coordinates
rows
(in ctrl_c, ctrl_x and ctrl_v) is a list of lists which represents the data which was worked on
- Right click insert columns/rows now inserts as many as selected or one if none selected
- Some minor improvements
- Fix line creation when click drag resizing index
- Improve looks of top left rectangle resizers when one is disabled
- Fix bug in
insert_row_positions()
- Make
enable_bindings()
anddisable_bindings()
without arguments do all bindings - Fix top left resizers not showing up if enabling/disabling all bindings
- Improve look and feel of drag and drop
- Fix bug in certain circumstances with
insert_row_positions()
- Fix
highlight_rows()
bug
- Fix old color name, credit
ministiy
- Make drag selection only redraw table when rectangle dimensions change instead of mouse moves
- Adjust light green theme colors slightly
- Changed all color option argument names for better clarity
Old Name | New Name |
---|---|
frame_background | frame_bg |
grid_color | table_grid_fg |
table_background | table_bg |
text_color | table_fg |
selected_cells_border_color | table_selected_cells_border_fg |
selected_cells_background | table_selected_cells_bg |
selected_cells_foreground | table_selected_cells_fg |
selected_rows_border_color | table_selected_rows_border_fg |
selected_rows_background | table_selected_rows_bg |
selected_rows_foreground | table_selected_rows_fg |
selected_columns_border_color | table_selected_columns_border_fg |
selected_columns_background | table_selected_columns_bg |
selected_columns_foreground | table_selected_columns_fg |
resizing_line_color | resizing_line_fg |
drag_and_drop_color | drag_and_drop_bg |
row_index_background | index_bg |
row_index_foreground | index_fg |
row_index_border_color | index_border_fg |
row_index_grid_color | index_grid_fg |
row_index_select_background | index_selected_cells_bg |
row_index_select_foreground | index_selected_cells_fg |
row_index_select_row_bg | index_selected_rows_bg |
row_index_select_row_fg | index_selected_rows_fg |
header_background | header_bg |
header_foreground | header_fg |
header_border_color | header_border_fg |
header_grid_color | header_grid_fg |
header_select_background | header_selected_cells_bg |
header_select_foreground | header_selected_cells_fg |
header_select_column_bg | header_selected_columns_bg |
header_select_column_fg | header_selected_columns_fg |
top_left_background | top_left_bg |
top_left_foreground | top_left_fg |
top_left_foreground_highlight | top_left_fg_highlight |
- Add option to use integer in
insert_row_positions()
andinsert_column_positions()
for how many columns to add - Fix error occurring in above functions when using python 3.6-3.7 due to itertools argument added in python 3.8
- Fix show_horizontal and show_vertical grid
- Reduce column minimum size even further
- Fix bug with highlights introduced in 4.7.6
- Make
startup_select
also see the chosen cell - Deprecated functions
is_cell_selected()
,is_row_selected()
,is_column_selected()
use the same functions but without theis_
in the name - Add functions
highlight_columns()
,highlight_rows()
, makehighlight_cells()
argumentcells
update dictionary rather than overwrite - Remove double click resizing of index
- Reduce minimum column width to 1 character
- Make arrowkey up and left not select column/row when at end, will add more shortcuts in a later update
- Adjust width of auto-resized index
- Hide header height/index width reset bars in top left if relevant options are disabled
- Add option
page_up_down_select_row
will select row when using page up/down, default isTrue
- Overhaul text, grid and highlight canvas item management, no longer deletes and redraws, keeps items using
"hidden"
and reuses them to prevent canvas item number getting high quickly - Edit cell resizing now only uses displayed rows/columns to fit to cell text
- Fix
see()
not being correct when using non-defaultempty_vertical
andempty_horizontal
- Fix flicker when row index auto resizes
- Rename
auto_resize_numerical_row_index
toauto_resize_default_row_index
- Add option
startup_focus
to giveSheet()
main table focus on initialization - Add startup argument
startup_select
use like so:
To create a cell selection box where cells 0,0 up to but not including 3,3 are selected:
startup_select = (0, 0, 3, 3, "cells"),
To create a row selection box where rows 0 up to but not including 3 are selected:
startup_select = (0, 3, "rows"),
To create a column selection box where columns 0 up to but not including 3 are selected:
startup_select = (0, 3, "columns"),
- Make
"begin_edit_cell"
and"end_edit_cell"
the only two edit cell bindings for use withextra_bindings()
function (although"edit_cell"
still works and is the equivalent of"end_edit_cell"
) - Make it so if
"begin_edit_cell"
binding returns anything other thanNone
the text in the cell edit window will be that return value otherwise it will be the relevant keypress - Prevent auto resize from firing two redraw commands in one go
- Fixed issue where clicking outside of cell edit window and Sheet would return focus to the Sheet widget anyway
- Fixed issues where row/column select highlight would be lower in canvas than cell selections
- Hopefully simplified cell edit code a bit
- Fix undo delete columns error for python versions < 3.8
- Adjustment to dark theme colors
- Clean up repetitions of code which had virtually no performance gain anyway
- Rename themes to "light blue", "light green", "dark blue", "dark green"
- Clean up theme and color settings code
- Add green theme
- Change font to calibri
- Minor fixes when using in-built ctrl functions
- Fix button-1-motion scrolling issues
- Many minor improvements
- Some minor improvements
- Fix minor display issue where sheet is empty and user clicks and drags upwards
- Added multiple new functions
- Many minor improvements
- Decreased size of area that resize cursors will show
- Much improved dark theme
- Resizing cells will now resize dropdown boxes, still have to add support for moving rows/columns
- Begin process of adding code to maintain multiple persistent dropdown boxes
- Add function
delete_dropdown()
(use argument"all"
for all dropdown boxes) - Add function
get_dropdowns()
to return locations and info for all boxes
- Fix
create_dropdown()
issues
- Fix github release
- Add startup and
set_options()
arguments:
empty_horizontal #empty space on the x axis in pixels
empty_vertical #empty space on the y axis in pixels
show_horizontal_grid #grid lines for main table
show_vertical_grid #grid lines for main table
- Fix scrollbar issues if hiding index or header
- Change
C
in startup arguments toparent
for clarity - Add Listbox using
Sheet()
recipe to tests
- Clean up menus
- Improve Dark theme
- Fix bug with column drag and drop and row index drag and drop
- Attempt made to remove cell editor window internal border, showing up on some platforms
- Add function
set_text_editor_value()
- Moved internal
begin_cell_edit
code slightly - Make Alt-Return on text editor only increase text window height if too small
- Fix download url in
setup.py
- Add
"begin_edit_cell"
to functionextra_bindings()
- Fix mouse motion binding in top left code not returning event object
- Add some extra demonstration code to
test_tksheet.py
- Fix typo in row index code leading to text not slicing properly with center alignment
- Improve text redraw slicing and positioning when cell size too small, especially for center alignments, very slight performance cost
- If a number of lines has been set by using a string e.g. "1" for default row or header heights then the heights will be updated when changing fonts
- Fix resize not taking into account header if header is set to a row in the sheet
- Fix bugs with
display_subset_of_columns()
, argumentset_col_positions
does nothing until reworked or removed
- Improve center alignment and auto resize widths issues
- Make
grid_propagate()
only occur internally if bothheight
andwidth
arguments are used, instead of just one - Fix bug in
get_sheet_data()
- Fix mismatch with scrollbars in
show
scrollbar options
- Add
header_height
argument toset_options()
- Make
header_height
arguments accept integer representing pixels as well as string representing number of lines - Make top left header height resize bar use
header_height
and not minimum height
- Fix readme python versions
- Fix readme python versions
- Fix Python version required
- Fix typo in header code
- Fix some issues with header and index not showing when values aren't string
- Fix row index width when starting with default index and then switching later
- Fix very minor issue with header text limit
- Fix some issues with right click insert column/row
- Fix error that occurs if row is too short on edit cell or not enough rows
- Add function
recreate_all_selection_boxes()
- Add function
bind_text_editor_set()
- Add function
get_text_editor_value()
- Removed internal
total_rows
andtotal_cols
variables, replaced with functions for better maintainability but at the cost of performance in some cases - Added
fix_data
argument to functiontotal_columns()
to even up all row lengths in sheet data - Removed
total_rows
andtotal_cols
arguments from functionsdata_reference()
andset_sheet_data()
- Fix issues with function
total_columns()
- Redo functions
insert_column()
andinsert_row()
, hopefully they work better - Add argument
equalize_data_row_lengths
to functioninsert_column()
default isTrue
- Add arguments
get_index
andget_header
to functionget_sheet_data()
defaults areFalse
- Change some argument names for functions involving inserting/setting rows and columns
display_subset_of_columns()
now tries to maintain some existing column widths- Add functions
sheet_data_dimensions()
,sheet_display_dimensions()
,set_sheet_data_and_display_dimensions()
- Fix bug with undo edit cell if displaying subset of columns
- Fix max undos issue
display_subset_of_columns()
now resets undo storage
- Potential fix for functions
headers()
androw_index()
whenshow...if_not_sheet
arguments are utilized
- Add argument
reset_col_positions
to functionheaders()
default isFalse
- Add argument
reset_row_positions
to functionrow_index()
default isFalse
- Add argument
show_headers_if_not_sheet
to functionheaders()
default isTrue
- Add argument
show_index_if_not_sheet
to functionrow_index()
default isTrue
- Adjust most
center
text draw positions slightly,center
alignment should now actually be center - Improve header resizing accuracy for set to text size
- Add
rc_insert_column
andrc_insert_row
strings to extra bindings - Fix errors with insert column/row that occur if data is empty list
- Fix resizing row index width/header height sometimes not working
- Fix select all creating event when sheet is empty
- Fix
create_current()
internal error if there are columns but no rows or rows but no columns - Add argument
get_cells_as_rows
to functionget_selected_rows()
to return selected cells as if they were selected rows - Add argument
get_cells_as_columns
to functionget_selected_columns()
to return selected cells as if they were selected columns - Add argument
return_tuple
to functionsget_selected_rows()
,get_selected_columns()
,get_selected_cells()
- Add function
set_currently_selected()
- Make
get_selected_min_max()
return(None, None, None, None)
if nothing selected to prevent error with tuple unpacking e.gr1, c1, r2, c2 = get_selected...
- Fix potential issue with internal function
set_col_width()
ifonly_set...
argument isTrue
- Fix typo in function
create_selection_box()
- Add
right_click_select
andrc_select
to functionenable_bindings()
, is enabled as well if other right click functionality is enabled - Add
"all_select_events"
as option in functionextra_bindings()
to quickly bind all selection events in the table, including deselection to a single function
- Make row height resize to text include row index values
- Fix bug with function
.set_all_cell_sizes_to_text()
where empty cells would result in minimum sizes - Fix typo error in function
.set_all_cell_sizes_to_text()
- Add function
get_currently_selected()
- Add functions
self.sheet_demo.set_all_column_widths()
,self.sheet_demo.set_all_row_heights()
,self.sheet_demo.set_all_cell_sizes_to_text()
- Add argument
set_all_heights_and_widths
to startup, useTrue
orFalse
- Improve performance of all resizing functions
- Make resizing detect text dimensions for full row/column, not just what is displayed
- Fix bug with
row_index()
function - Fix
headers
set toint
at start up not working ifheaders
is0
- Fix bug if
row_drag_and_drop_perform
orcolumn_drag_and_drop_perform
is False - Fix display issue with undo drag and drop rows/columns
- Add
"unbind_all"
as possible argument for functionextra_bindings()
- Add
"enable_all"
as possible argument for functionenable_bindings()
- Add
"disable_all"
as possible argument for functiondisable_bindings()
- Add function
set_sheet_data()
use argumentverify = False
to prevent verification of types - Add startup arguments
row_drag_and_drop_perform
andcolumn_drag_and_drop_perform
and add toset_options()
- Fix double selection with drag and drop rows
- Add
data
argument to startup arguments
- Fix some highlighted cells not being reset when displaying subset of columns
- Fix highlighted cells not blending with drag selection
- Fix basic bindings bug
- Fix typo in popup menu
- Improve performance of drag selection
- Improve
row_index()
andheaders()
functions, add examples - Add
"single_select"
and"toggle_select"
toenable_bindings()
- Fix bug with undo deletion
- Fix bug with insert row
- Deprecate
change_color()
useset_options()
instead - Fix display bug where resizing row index width or header height would result in small selection boxes
- Rework popup menus, use
enable_bindings()
with"right_click_popup_menu"
to make them work again - Allow additional binding of right click to a function alongside
Sheet()
popup menus - Add function
get_sheet_data()
- Add
x_scrollbar
andy_scrollbar
toshow()
,hide()
andSheet()
startup - Removed
show
argument from startup, addedshow_table
, default isTrue
- Add option to automatically resize row index width when user has not set new indexes, default is
True
- Rework the top left rectangle and add select all on left click if drag selection is enabled
- Change appearance of popup menus
- Change popup menu color for dark theme
- Fix wrong popup menu on right click with selected rows/columns
- Fix bug where highlighted background or foreground might not be in the correct column when displaying a subset of columns
- Change colors of selected rows and columns
- Add color options:
header_select_column_bg
header_select_column_fg
row_index_select_row_bg
row_index_select_row_fg
selected_rows_border_color
selected_rows_background
selected_rows_foreground
selected_columns_border_color
selected_columns_background
selected_columns_foreground
- Fix various issues with displaying correct colors in certain circumstances
- Change dark theme colors slightly
- Fix PyPi release version
- Fix bug with right click delete columns and undo
- Right click in main table when over selected columns/rows now brings up column/row menu
- Add internal cut, copy, paste, delete and undo to usable
Sheet()
functions
- Fix bug with center alignment and display subset of columns
- Fix bug with highlighted cells showing as selected when they're not
- Fix resize row height bug
- Fix deselect bug
- Improve and fix many bugs with toggle select mode
- Fix extra selection box drawing in certain circumstances
- Fix bug in Paste
- Remove some unnessecary code
- Fix bugs introduced with 4.1.8
- Overhaul internal selections variables and workings
- Replace functions
get_min
/get_max
selected
x
andy
withget_selected_min_max()
- Fix bugs with functions
total_columns()
andtotal_rows()
and set default argumentmod_data
toTrue
- Change drag and drop so that it modifies data with or without an extra binding set
- Add functions
set_cell_data()
,set_row_data()
,set_column_data()
- Remove bloat in
get_highlighted_cells()
- Prepare many functions for implementation of control + click
- Fix typo in
get_cell_data()
- Add function
height_and_width()
- Fix height and width in widget startup
- Fix cell selection after editing cell ending with mouse click
- Separate drag selection
extra_bindings()
into cells, rows and columns - Add shift select and separate it from left click and right click in
extra_bindings()
- Changed and hopefully made better all responses to
extra_bindings()
functions - Added selection box to selected rows/columns
- Fix bugs with drag and drop rows/columns
- Clean up drag and drop code
- Improve speed of
get_selected_cells()
- Add function
get_selection_boxes()
- Remove more unnessecary loops
- Added argument
show_selected_cells_border
to start up - Added function
set_options()
- Added undo to drag and drop rows/columns
- Fixed bug with drag and drop columns when displaying a subset of columns
- Move text up slightly inside cells
- Fix selected cells border not showing sometimes
- Replace some unnessecary loops
- Improve select all speed by 20x
- Shrink cell size slightly
- Added options to hide row index and header at start up
- Change looks of ctrl x border
- Fix minor issue where two borders would draw in the same place
- Added undo to insert row/column and delete rows/columns
- Changed the default looks
- Deprecated function
select()
and addedtoggle_select_cell()
,toggle_select_row()
andtoggle_select_column()
- Added functions
is_cell_selected()
,is_row_selected()
,is_column_selected()
,get_cell_data()
,get_row_data()
andget_column_data()
- Changed behavior of
deselect()
function slightly to now accept a cell from argumentsrow =
andcolumn =
as well ascell =
- Added cell selection borders and start up option
selected_cells_border_color
as well as to the functionchange_color()
- Removed the main table variable
selected_cells
and reduced memory use - Fixed a bug with editing a cell while displaying a subset of columns
- Renamed
RowIndexes
class toRowIndex
- Added separate test file
- Fixed import errors
- Added
frame_background
parameter toSheet()
startup andchange_color()
function - Added more keys to edit cell binding
- Separated
edit_bindings
for the functionenable_bindings()
into the following:"cut"
"copy"
"paste"
"delete"
"edit_cell"
"undo"
Note that the argument"edit_bindings"
still works
- Separated the tksheet classes and variables into different files
- Fixed bug with function
display_subset_of_columns()
- Fixed issues with row heights and column widths adjusting too small
- Improved dark theme
- Added top left rectangle to hide
- Added insert and delete row and column to right click menu
- Some general code improvements
- The function
display_columns()
has been changed todisplay_subset_of_columns()
and some paramaters have been changed - The variables
total_rows
andtotal_cols
have been reworked - Sheets can now be created with the parameters
total_rows
andtotal_columns
to create blank sheets of certain dimensions - The functions
total_rows()
andtotal_columns()
have been added to set or get the dimensions of the sheet "edit_bindings"
has been added as an input for the functionenable_bindings()
show()
andhide()
have been reworked to allow hiding of the header and/or row index
- delete_row() is now delete_row_position()
- insert_row() is now insert_row_position()
- move_row() is now move_row_position()
- delete_column() is now delete_column_position()
- insert_column() is now insert_column_position()
- move_column() is now move_column_position()
- The original functions have been changed to behave as they read and actually modify the table data