@@ -386,7 +386,7 @@ def __init__(self, ax, label, valmin, valmax, valinit=0.5, valfmt=None,
386
386
further styling via the *track* attribute.
387
387
388
388
handle_style : dict
389
- Properties of the slider handle. Supported values are
389
+ Properties of the slider handle. Default values are
390
390
391
391
========= ===== ======= ========================================
392
392
Key Value Default Description
@@ -396,6 +396,10 @@ def __init__(self, ax, label, valmin, valmax, valinit=0.5, valfmt=None,
396
396
size int 10 The size of the slider handle in points.
397
397
========= ===== ======= ========================================
398
398
399
+ Other values will be transformed as marker{foo} and passed to the
400
+ `~.Line2D` constructor. e.g. ``handle_style = {'style'='x'}`` will
401
+ result in ``markerstyle = 'x'``.
402
+
399
403
Notes
400
404
-----
401
405
Additional kwargs are passed on to ``self.poly`` which is the
@@ -420,8 +424,10 @@ def __init__(self, ax, label, valmin, valmax, valinit=0.5, valfmt=None,
420
424
self .val = valinit
421
425
self .valinit = valinit
422
426
423
- defaults = {'facecolor' :'white' , 'edgecolor' :'.75' , 'size' :10 }
424
- marker_props = {f'marker{ k } ' : v for k , v in {** defaults , ** handle_style }}
427
+ defaults = {'facecolor' : 'white' , 'edgecolor' : '.75' , 'size' : 10 }
428
+ marker_props = {
429
+ f'marker{ k } ' : v for k , v in {** defaults , ** handle_style }
430
+ }
425
431
426
432
if orientation == 'vertical' :
427
433
self .track = Rectangle (
@@ -647,7 +653,7 @@ def __init__(
647
653
further styling via the *track* attribute.
648
654
649
655
handle_style : dict
650
- Properties of the slider handles. Supported values are
656
+ Properties of the slider handles. Default values are
651
657
652
658
========= ===== ======= =========================================
653
659
Key Value Default Description
@@ -657,6 +663,10 @@ def __init__(
657
663
size int 10 The size of the slider handles in points.
658
664
========= ===== ======= =========================================
659
665
666
+ Other values will be transformed as marker{foo} and passed to the
667
+ `~.Line2D` constructor. e.g. ``handle_style = {'style'='x'}`` will
668
+ result in ``markerstyle = 'x'``.
669
+
660
670
Notes
661
671
-----
662
672
Additional kwargs are passed on to ``self.poly`` which is the
@@ -679,13 +689,10 @@ def __init__(
679
689
self .val = valinit
680
690
self .valinit = valinit
681
691
682
- marker_props = {}
683
- defaults = {'facecolor' :'white' , 'edgecolor' :'.75' , 'size' :10 }
684
- if handle_style is not None :
685
- for k in ['facecolor' , 'edgecolor' , 'size' ]:
686
- marker_props [f'marker{ k } ' ] = handle_style .get (k , defaults [k ])
687
- else :
688
- marker_props = {f'marker{ k } ' : v for k , v in defaults .items ()}
692
+ defaults = {'facecolor' : 'white' , 'edgecolor' : '.75' , 'size' : 10 }
693
+ marker_props = {
694
+ f'marker{ k } ' : v for k , v in {** defaults , ** handle_style }
695
+ }
689
696
690
697
if orientation == "vertical" :
691
698
self .track = Rectangle (
0 commit comments