Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 13ff1f7 commit 0ee87e6Copy full SHA for 0ee87e6
1 file changed
examples/widgets/check_buttons.py
@@ -21,8 +21,10 @@
21
visibility = [line.get_visible() for line in lines]
22
check = CheckButtons(rax, labels, visibility)
23
24
+
25
def func(label):
- lines[labels.index(label)].set_visible(not lines[labels.index(label)].get_visible())
26
+ index = labels.index(label)
27
+ lines[index].set_visible(not lines[index].get_visible())
28
plt.draw()
29
30
check.on_clicked(func)
0 commit comments