Commit 050c0b1
committed
lines.py: fix bugs in marker alpha and edge colors
Two bugs are fixed:
1) plt.plot(np.arange(3),'ro', mec='none')
was not plotting anything because 'none' was setting the
edgecolor alpha to 0, and that alpha was being propagated
to gc, overriding the face color. The 'none' case needs to
be trapped, not passed on to the GraphicsContext.
2) plt.plot(np.arange(3), 'r.')
was drawing a black edge around the point; same for 'r,';
the markers.py refactoring turned the point and pixel markers
into filled markers, with their default black borders. The
solution here was to special-case them in Line2D. They do
need to be filled, with edges of the same color; otherwise
the pixel can end up nearly invisible, and the point could
end up as a donut.1 parent aa07d18 commit 050c0b1
1 file changed
Lines changed: 15 additions & 11 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
508 | 508 | | |
509 | 509 | | |
510 | 510 | | |
511 | | - | |
512 | | - | |
| 511 | + | |
| 512 | + | |
| 513 | + | |
| 514 | + | |
| 515 | + | |
| 516 | + | |
| 517 | + | |
| 518 | + | |
| 519 | + | |
513 | 520 | | |
514 | 521 | | |
515 | 522 | | |
| |||
539 | 546 | | |
540 | 547 | | |
541 | 548 | | |
542 | | - | |
543 | 549 | | |
544 | 550 | | |
545 | 551 | | |
546 | 552 | | |
547 | 553 | | |
548 | 554 | | |
549 | 555 | | |
550 | | - | |
551 | 556 | | |
552 | 557 | | |
553 | | - | |
| 558 | + | |
554 | 559 | | |
555 | 560 | | |
556 | 561 | | |
| |||
567 | 572 | | |
568 | 573 | | |
569 | 574 | | |
570 | | - | |
| 575 | + | |
| 576 | + | |
| 577 | + | |
571 | 578 | | |
572 | | - | |
| 579 | + | |
573 | 580 | | |
574 | 581 | | |
575 | | - | |
576 | | - | |
577 | | - | |
578 | | - | |
579 | 582 | | |
| 583 | + | |
580 | 584 | | |
581 | 585 | | |
582 | 586 | | |
| |||
0 commit comments