o
    ¡:´a  ã                   @   sT   d dl Zd dlZd dlmZ d dlmZmZ	m
Z ej d¡edgddd„ ƒƒZdS )	é    N)Úcheck_figures_equal)ÚcollectionsÚpatchesÚpathZcairoZpng)Ú
extensionsc                 C   s
  t j d¡}t j ¡ }t |j|jddd… g¡}t |j|jg¡}t  ||¡}t  |d |¡}| ¡ }| 	ddg¡ | 
ddg¡ tj|dddd	d
}	| |	¡ tj|dddd	d
}	| |	¡ |  ¡ }| 	ddg¡ | 
ddg¡ tj||gdddd	d}
| |
¡ dS )z†
    Test checks that the patch and collection are rendered with the specified
    alpha values in their facecolor and edgecolor.
    é   Néÿÿÿÿé   é   é   Zdashdot)r	   r   r   g      à?)r   r   r	   g      è?)Ú	linewidthZ	linestyleÚ	facecolorÚ	edgecolor)r   Z
linestylesr   r   )ÚmpathZPathZunit_regular_starZunit_circleÚnpZconcatenateZverticesÚcodesZsubplotsZset_xlimZset_ylimÚmpatchesZ	PathPatchZ	add_patchÚmcollectionsZPathCollectionZadd_collection)Zfig_testZfig_refZstarZcircleZvertsr   Z	cut_star1Z	cut_star2ZaxZpatchÚcol© r   úE/usr/lib/python3/dist-packages/matplotlib/tests/test_backend_cairo.pyÚtest_patch_alpha_coloring
   s<   
ý
ý

ýr   )Znumpyr   ZpytestZmatplotlib.testing.decoratorsr   Z
matplotlibr   r   r   r   r   r   ZmarkZbackendr   r   r   r   r   Ú<module>   s    

