8000 Fixed bug affecting the initially selected button · matplotlib/matplotlib@e4842b2 · GitHub
[go: up one dir, main page]

Skip to content

Commit e4842b2

Browse files
authored
Fixed bug affecting the initially selected button
Fixed a bug th 8000 at was affecting the initially selected button (line 1038).
1 parent 8b20bb6 commit e4842b2

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

lib/matplotlib/widgets.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1035,6 +1035,7 @@ def __init__(self, ax, labels, active=0, activecolor='blue', orientation='vertic
10351035
# in case of horizontal buttons, write them left-to-right
10361036
if orientation == 'horizontal':
10371037
labels.reverse()
1038+
active = (len(labels) - 1) - active
10381039

10391040
self.labels = []
10401041
self.circles = []

0 commit comments

Comments
 (0)
0