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 274f872 commit 9ab08daCopy full SHA for 9ab08da
1 file changed
examples/event_handling/legend_picking.py
@@ -31,11 +31,11 @@ def onpick(event):
31
# legend proxy line, and toggle the visibilit
32
legline = event.artist
33
origline = lined[legline]
34
- vis = origline.get_visible()
35
- origline.set_visible(not vis)
+ vis = not origline.get_visible()
+ origline.set_visible(vis)
36
# Change the alpha on the line in the legend so we can see what lines
37
# have been toggled
38
- if not vis:
+ if vis:
39
legline.set_alpha(1.0)
40
else:
41
legline.set_alpha(0.2)
0 commit comments