-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
BUG: Update Styler.clear method to clear all #40664
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 9 commits
5169f5c
7037920
d8df1fc
45f5221
46d8994
35fbd61
6d9f406
28c3d0f
0408898
cc80c07
8afdc33
8c76581
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -119,3 +119,4 @@ doc/build/html/index.html | |
doc/tmp.sv | ||
env/ | ||
doc/source/savefig/ | ||
virtualenvs/ | ||
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -145,6 +145,7 @@ Other enhancements | |
- :class:`RangeIndex` can now be constructed by passing a ``range`` object directly e.g. ``pd.RangeIndex(range(3))`` (:issue:`12067`) | ||
- :meth:`round` being enabled for the nullable integer and floating dtypes (:issue:`38844`) | ||
- :meth:`pandas.read_csv` and :meth:`pandas.read_json` expose the argument ``encoding_errors`` to control how encoding errors are handled (:issue:`39450`) | ||
- :meth:`.Styler.clear` now clears :attr:`Styler.hidden_index`, :attr:`Styler.hidden_columns` and :attr:`Styler.tooltips` as well (:issue:`40484`) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. remove There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. is this user visible at all? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this is a user visible change only if:
prior to this PR the hidden items would still be hidden, after this PR the styler resets so nothing is hidden. |
||
|
||
.. --------------------------------------------------------------------------- | ||
|
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -882,7 +882,13 @@ def clear(self) -> None: | |
self.ctx.clear() | ||
self.tooltips = None | ||
self.cell_context.clear() | ||
self._todo = [] | ||
self._todo.clear() | ||
|
||
self.hidden_index = False | ||
self.hidden_columns = [] | ||
self.tooltips = None | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
# self.format and self.table_styles may be dependent on user | ||
# input in self.__init__() | ||
|
||
def _compute(self): | ||
""" | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
revert this addition to the gitignore. it is effective only for your environment.