@@ -608,10 +608,10 @@ def _set_star(self):
608
608
else :
609
609
verts = polypath .vertices
610
610
611
- top = Path (np .vstack (( verts [0 :4 , : ], verts [7 :10 , : ], verts [0 ]) ))
612
- bottom = Path (np .vstack (( verts [3 :8 , : ], verts [3 ]) ))
613
- left = Path (np .vstack (( verts [0 :6 , : ], verts [0 ]) ))
614
- right = Path (np .vstack (( verts [0 ], verts [5 :10 , : ], verts [0 ]) ))
611
+ top = Path (np .concatenate ([ verts [0 :4 ], verts [7 :10 ], verts [0 : 1 ]] ))
612
+ bottom = Path (np .concatenate ([ verts [3 :8 ], verts [3 : 4 ]] ))
613
+ left = Path (np .concatenate ([ verts [0 :6 ], verts [0 : 1 ]] ))
614
+ right = Path (np .concatenate ([ verts [0 : 1 ], verts [5 :10 ], verts [0 : 1 ]] ))
615
615
616
616
if fs == 'top' :
617
617
mpath , mpath_alt = top , bottom
@@ -641,10 +641,10 @@ def _set_hexagon1(self):
641
641
642
642
# not drawing inside lines
643
643
x = np .abs (np .cos (5 * np .pi / 6. ))
644
- top = Path (np .vstack (([ - x , 0 ], verts [( 1 , 0 , 5 ), :] , [x , 0 ]) ))
645
- bottom = Path (np .vstack (([ - x , 0 ], verts [2 :5 , : ], [x , 0 ]) ))
646
- left = Path (verts [( 0 , 1 , 2 , 3 ), : ])
647
- right = Path (verts [( 0 , 5 , 4 , 3 ), : ])
644
+ top = Path (np .concatenate ([[( - x , 0 ) ], verts [[ 1 , 0 , 5 ]] , [( x , 0 )]] ))
645
+ bottom = Path (np .concatenate ([[( - x , 0 ) ], verts [2 :5 ], [( x , 0 )]] ))
646
+ left = Path (verts [0 : 4 ])
647
+ right = Path (verts [[ 0 , 5 , 4 , 3 ] ])
648
648
649
649
if fs == 'top' :
650
650
mpath , mpath_alt = top , bottom
@@ -675,11 +675,12 @@ def _set_hexagon2(self):
675
675
676
676
# not drawing inside lines
677
677
x , y = np .sqrt (3 ) / 4 , 3 / 4.
678
- top = Path (verts [(1 , 0 , 5 , 4 , 1 ), :])
679
- bottom = Path (verts [(1 , 2 , 3 , 4 ), :])
680
- left = Path (np .vstack (([x , y ], verts [(0 , 1 , 2 ), :],
681
- [- x , - y ], [x , y ])))
682
- right = Path (np .vstack (([x , y ], verts [(5 , 4 , 3 ), :], [- x , - y ])))
678
+ top = Path (verts [[1 , 0 , 5 , 4 , 1 ]])
679
+ bottom = Path (verts [1 :5 ])
680
+ left = Path (np .concatenate ([
681
+ [(x , y )], verts [:3 ], [(- x , - y ), (x , y )]]))
682
+ right = Path (np .concatenate ([
683
+ [(x , y )], verts [5 :2 :- 1 ], [(- x , - y )]]))
683
684
684
685
if fs == 'top' :
685
686
mpath , mpath_alt = top , bottom
0 commit comments