Skip to content

Commit

Permalink
fix: don't reuse text in qcollapsible (#204)
Browse files Browse the repository at this point in the history
  • Loading branch information
tlambert03 authored Sep 24, 2023
1 parent 50bff8e commit 0b984c2
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/superqt/collapsible/_collapsible.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,7 @@ def __init__(

def setText(self, text: str) -> None:
"""Set the text of the toggle button."""
current = self._toggle_btn.text()
self._toggle_btn.setText(current + text)
self._toggle_btn.setText(text)

def text(self) -> str:
"""Return the text of the toggle button."""
Expand Down

0 comments on commit 0b984c2

Please sign in to comment.