+
     ]i81  c                   sN   ^ RI Ht ^ RIHt ^ RIt^ RIt^ RIt^ RIt^ RI	t	^ RI
HtHtHtHt ^ RIHt ^ RIHt ^ RIHtHt ^ RIHtHt ^ RI
t^ RIH t ^ RIHt ^ RI H!t" ]	PF                  PI                  ^R	7      ]	PF                  PK                  R
RR.4      ]	PF                  PK                  RRR.4      ]	PF                  PK                  RRR/ 3RRRR/3RRRR/3RRRR/3RR/ 3RRRR/3RRRR/3.. RHOR7      R 4       4       4       4       t&R t']]R 4       4       t(]! R.4      R 4       t)]]! R.4      R  4       4       t*R! t+]R" 4       t,]R# 4       t-]R$ 4       t.]! R%.4      R& 4       t/]! R'.4      R( 4       t0]! R).4      R* 4       t1]! R.R+7      R, 4       t2]R- 4       t3]! R..R/R07      R1 4       t4]	PF                  PK                  R2R3R4.4      R5 4       t5R6 t6R7 t7R8 t8]! R9.R:R;7      R< 4       t9]! R=.R>R;7      R? 4       t:]! R@.4      RA 4       t;]! RB.RCRD/R/RE7      RF 4       t<RG t=R# )I    )Counter)PathN)cbookpathpatheffectsfont_manager)Figure)Ellipse)needs_ghostscriptneeds_usetex)check_figures_equalimage_comparison)Zreruns	papersizeZletterfigureorientationZportrait	landscapezformat, use_log, rcParamspsFps.usedistillerghostscriptxpdftext.usetexTeps	ps.useafm)Zidsc                 s   \         P                  P                  V4       \         P                  R ,          R8X  d    \         P                  ! R4       MI\         P                  R ,          R8X  d.    \         P                  ! R4       \         P                  ! R4       \        P                  ! 4       w  rg\        P                  ! 4       ;_uu_ 4       p\        P                  ! 4       ;_uu_ 4       p	V'       d   VP                  R4       VP                  ^^.^^.4       Rp
\         P                  R,          '       g
   V
R	,          p
VP                  V
4       . p\         P                  R,          '       d   VP!                  \"        4       \         P                  R
,          '       d    VP!                  \         P$                  4        VP'                  WVVR7       VP'                  WVVR7       VP*                  '       d   Q hV	P*                  '       d   Q hVP-                  4       P/                  R4      pV	P-                  4       pV R8X  d   \         P                  R ,          R8X  d8   VR8X  d   RVP1                  4       9  g   Q hMRVP1                  4       9   g   Q hMz\         P                  R ,          '       g   \         P                  R,          '       d'   VR8X  d   RMRpVR8X  d
   RV,           MRpW9   g   Q hMVR8X  d   RV9  g   Q hM	RV9   g   Q h\2        P4                  ! RRV4      p\2        P4                  ! RRV4      pWP7                  RR4      8X  g   Q h RRR4       RRR4       R#   \         P                   d+   p\
        P                  ! \        T4      4        Rp?ELRp?ii ; i  \         P                   d+   p\
        P                  ! \        T4      4        Rp?ELVRp?ii ; i  \)        T4       d+   p\
        P                  ! \        T4      4        Rp?EL?Rp?ii ; i  + '       g   i     L; i  + '       g   i     R# ; i)r   r   ZgsNr   ZpdftopsZlogu	   Déjà vur   u    −€r   )formatr   	papertypeZasciir   r   s   letterr   s   432.0s   576.0s   -dDEVICEWIDTHPOINTS=s   -sPAPERSIZEs   %%DocumentPaperSizess   (?<=
%%CreationDate: ).*    s   
s   
)mplrcParamsupdateZ_get_executable_infoZExecutableNotFoundErrorpytestskipstrpltsubplotsioStringIOBytesIOZ
set_yscaleplotZ	set_titleZappendRuntimeErrorZMatplotlibDeprecationWarningsavefigZtupleZclosedgetvalueZencodeZlowerreZsubZreplace)r   Zuse_logr   r   r   ZexcfigaxZs_bufZb_bufZtitleZallowable_exceptionsZs_valZb_valZwidthZwanteds   &&&&&           G/usr/lib64/python3.14/site-packages/matplotlib/tests/test_backend_ps.pytest_savefig_to_stringior.      s<   * LL!
||%&-7	"$$T* 
'	(F	2	"$$T*$$Y/ llnGC	%MM% 
AA||M**33E
U!<<&& ''5<<$$ ''(H(HI	"KK+"+  -KK+"+  -
 <<<<<< ''0 T> ||-.&8 ($EKKM999$555/00CLL4O4O$/;$>H=F(=R1E9- &(2%???2e;;;
 3S%@3S%@gu5555o ". ** 	"KKC!!	" ** 	"KKC!!	"2 )* 	"KKC!!	") ".s   M7 1,N9 Q/AP8	>8P8	71P8	)P8		(O;1P8	P8	B'P8	?P8	BP8	%Q7N6N11N69O8O33O8;P5P0*P8	0P55P8	8QQQ	c                  sH   \         P                  ! ^RR7      .\        P                  R&   \        P
                  ! 4       w  rVP                  . RO4       \        P                  ! 4       ;_uu_ 4       pV P                  VRR7       RRR4       R#   + '       g   i     R# ; i)   Zw)	linewidthZ
foregroundzpath.effectsr   r   N)         )
r   Z
withStroker   r   r!   r"   r&   r#   r%   r(   )r+   r,   r         r-   test_patheffectsr6   t   sd    s;$=CLL llnGCGGI	Bt$ 
s   2BB!	c                 s   V R ,          pVP                  4        \        P                  ! \        \	        V4      R7      ;_uu_ 4        R\
        P                  R&   \        P                  ! . R	O4       \        P                  ! R4       \        P                  ! VR,          RR7       RRR4       R#   + '       g   i     R# ; i)
zshort-1)ZtempdirTr   z\textbf{time} (s)ztex_demo.epsr   r1   N)r2   r3   r4   r/   )Zmkdirr   Z_setattr_cmtempfiler    r   r   r!   r&   xlabelr(   )tmp_pathZbase_tempdir   & r-   test_tilde_in_tempfilenamer;   }   s~     i'L 
		8S->	?	?&*]#

'(L>1$? 
@	?	?	?s   A!B22C	z	empty.epsc                  s    \         P                  ! 4       w  rVP                  4        VP                  ^ ^.R^ R7       VP	                  RRRR^ R7       R# )r    rZcolorZalpha      ?fooN)r!   r"   set_axis_offr&   textr+   r,        r-   test_transparencyrD      sE    llnGCOOGGQF#QG'GGBEAG.r   c                  s    R \         P                  R&   \        P                  ! 4       w  rVP	                  4        VP                  ^ ^.R^ R7       VP                  RRRR^ R7       R# )Tr   r<   r=   r>   r?   N)r   r   r!   r"   r@   r&   rA   rB   rC   r-   test_transparency_texrE      sU     #'CLLllnGCOOGGQF#QG'GGBEAG.r   c            	      s   \         P                  ! 4       w  r\        P                  ! 4       ;_uu_ 4       pV P	                  VR R7       VP                  4       pRRR4       \        P                  ! RX\        P                  4      pV'       g   Q h\        P                  ! RV\        P                  4      pV'       g   Q h\        ^^4       Fi  pRVP                  V4      9  g   Q h\        VP                  V4      4      \        P                  ! \        VP                  V4      4      ^4      8X  d   Ki  Q h	  R#   + '       g   i     L; i)r   r1   Ns$   ^%%BoundingBox: (.+) (.+) (.+) (.+)$s)   ^%%HiResBoundingBox: (.+) (.+) (.+) (.+)$s   .)r!   r"   r#   r%   r(   r)   r*   search	MULTILINErangeZgroupZintr   ZapproxZfloat)r+   r,   bufZbbZhibbi         r-   	test_bboxrL      s    llnGC	C&lln 
 
:C	NBI299A3\\#DK41a[288A;&&&288A;6==tzz!}1Eq#IIII  
s   $D<<E	c                 s,   R\         P                  R&   \        P                  ! R4       \        P
                  ! \        4      ;_uu_ 4        \        P                  ! \        P                  ! 4       RR7       RRR4       R#   + '       g   i     R# ; i)z"Test failing latex subprocess callTr   z$22_2_2$r   r1   N)
r   r   r!   r8   r   raisesr'   r(   r#   r%    r   r-   test_failing_latexrO      sP     #'CLLJJz	|	$	$BJJL. 
%	$	$	$s   ,BB	c                 s0   V P                  R 4       \        P                  ! RRRRR7       \        P                  ! RRRRR7       \        P                  ! \        P
                  ! 4       RR7       V P                  w  pR	VP                  4       9   g   Q hR
# )ZWARNING皙?r?   T)Zusetex皙?Zbarr   r1   zas if usetex=FalseN)Z	set_levelr!   figtextr(   r#   r%   ZrecordsZ
getMessage)caplogZrecordr:   r-   test_partial_usetexrT      sj    
YKKBd+KKBd+KK

T*nnGF6#4#4#6666r   c                 s    \         P                  P                  R RRR/4       \        P                  ! RRR4       \        P
                  ! \        P                  ! 4       RR7       R# )	r   Tztext.latex.preamblez$\usepackage{color,graphicx,textcomp}r>   r?   r   r1   N)r   r   r   r!   rR   r(   r#   r%   )rS   s   &r-   test_usetex_preamblerU      sJ    LLtF 
 KKBKK

T*r   z
useafm.epsc                  s    R \         P                  R&   \        P                  ! 4       w  rVP	                  4        VP                  R4       VP                  RRR4       R# )Tr   r>   ZqkN)r   r   r!   r"   r@   ZaxhlinerA   rB   rC   r-   test_useafmrV      sB     $CLLllnGCOOJJrNGGBDr   z	type3.epsc                  s6    \         P                  ! R R R4       R# )r>   zI/JN)r!   rR   rN   r   r-   test_type3_fontrW      s    KKBr   zcoloredhatcheszerolw.epsc                  s   \         P                  ! 4       p V P                  \        R^^RRR^ R7      4       V P                  \        RRRRRRRR7      4       V P                  \        RR	R
RRR^ R7      4       V P	                  4        R# )r    /Znoner<   )ZhatchZ	facecolor	edgecolorr0   r>   Z+grQ   g333333?g?Z\bN)r    r    )r>   r>   )r2   r2   )r!   ZgcaZ	add_patchr   r@   )r,       r-   !test_colored_hatch_zero_linewidthr]      s}    	BLLASF#&!5 6LLS#SF#&#7 8LLc#&!5 6OOr   )Z
extensionsc                 s    V P                  4       pVP                  ^ ^ RV P                  RR7       VP                  4        R# )r    ZhelloT)Z	transformZclip_onN)Zadd_subplotrA   ZtransFigure)Zfig_testZfig_refr,   s   && r-   test_text_clipr^      s8    				BGGAq'X%9%94GHr   c                 s    \         P                  ! 4       pVP                  R R R4       V R,          pVP                  V4       \        P
                  P                  P                  VRR7       R# )r>   Zdefztest.epsF)ZcacheN)r!   r   rA   r(   r   ZtestingZcompareZconvert)r9   r+   Zout   &  r-   test_d_glyphr`      sR     **,CHHRU
Z
CKKKK51r   ztype42_without_prep.epsZmpl20)stylec                  s    ^*\         P                  R&   R\         P                  R&   \        P                  ! RRR4       R# )i*   ps.fonttypeZstixzmathtext.fontsetr>   zMass $m$N)r   r   r!   rR   rN   r   r-   test_type42_font_without_preprc      s1     #%CLL'-CLL#$KKS*%r   fonttypeZ3Z42c                 s~   V \         P                  R &   \        P                  ! 4       w  rVP	                  RRR4       \
        P                  ! 4       pVP                  VRR7       R\        V  RR7      ,           R	,           p\        P                  ! WCP                  4       \        P                  4      '       g   Q hR
# )rb   g      ?r>   z&Forty-two is the answer to everything!r   r1   s
   /FontType zutf-8)Zencodings    defN)r   r   r!   r"   rA   r#   r%   r(   Zbytesr*   rF   r)   rG   )rd   r+   r,   rI   Ztests   &    r-   test_fonttypere   	  s    "*CLLllnGCGGD#?@
**,CKKDK!5H:AAGKD99T<<>2<<8888r   c                 s    \         P                  ! 4       w  rVP                  ^ ^.RR7       \        P                  ! 4       pV P                  VRR7       VP                  4       ^ 8  g   Q hR# )z-Test that dashed lines do not break PS outputz--)Z	linestyler   r1   N)r!   r"   r&   r#   r%   r(   Ztell)r+   r,   rI   r5   r-   test_linedashrf     sP    llnGCGGQFdG#
**,CKKDK!88:>>r   c                  s    \        4       p V P                  R R R4       \        P                  ! 4       pV P	                  VRR7       V P	                  VRR7       R# )r>   z
foo

r   r1   r   N)r   rA   r#   r%   r(   )r   rI   rC   r-   test_empty_linerg   $  sD    XF
KKS+&
**,C
NN3uN%
NN3tN$r   c                  sT   \        4       p V P                  ^^\        RR7      R7      pVP                   F)  pVP	                  . . R7       VP                  ^^.4       K+  	  V P                  R4       \        P                  ! 4       pV P                  VRR7       VP                  ^ 4       VP                  4        Uu. uF4  pVP                  R4      '       g   K  VP                  R	4      ^ ,          NK6  	  pp\        \        V4      P!                  4       4      ^8X  g   Q hR
# u upi )r/   Zpolar)Z
projection)Z
subplot_kw)ZxticksZytickszhello, worldr   r1   rX   Z N)r   r"   ZdictZflatZsetr&   Zsuptitler#   r$   r(   ZseekZ	readlinesZ
startswithZ	partitionZmaxr   Zvalues)r+   Zaxsr,   rI   ZlnZwdsrK   r-   test_no_duplicate_definitionrh   -  s    
(C
,,q!(@,
AChh
b$
A  LL 
++-CKKEK"HHQK " 2mmC   2<<Q   " ws|""$%***	"s   >D%D%zmulti_font_type3.epsgRQ?)Ztolc                  st   \         P                  ! R .R7      p \        \         P                  ! V 4      4      P                  R8w  d   \
        P                  ! R4       \        P                  ! RRR .^R7       \        P                  ! R^R7       \        P                  ! 4       pVP                  R	R
R4       R# zWenQuanYi Zen Hei)familyzwqy-zenhei.ttczFont may be missingZfontzDejaVu Sans)rj   Zsizer   )rd   g333333?gffffff?u"   There are 几个汉字 in between!NfmZFontPropertiesr   ZfindfontZnamer   r   r!   Zrcr   rA   Zfpr+   rC   r-   test_multi_font_type3rn   A  s    			#6"7	8BBKKO!!%55)*FF6=*=>RHFF4!
**,CHHT5>?r   zmulti_font_type42.epsg?c                  st   \         P                  ! R .R7      p \        \         P                  ! V 4      4      P                  R8w  d   \
        P                  ! R4       \        P                  ! RRR .^R7       \        P                  ! R^*R7       \        P                  ! 4       pVP                  R	R
R4       R# ri   rk   rm   rC   r-   test_multi_font_type42ro   N  s    			#6"7	8BBKKO!!%55)*FF6=*=>RHFF4"
**,CHHT5>?r   zscatter.epsc                  st   \         P                  P                  R 4      p V P                  ^ ^^
4      pV P                  ^ ^^
4      pV P                  ^^d^
4      p\        P
                  ! 4       w  rEVP                  WV. RORR7       VP                  4        \        ^^4       Uu. uF"  p\        P                  P                  V4      NK$  	  ppV P                  ^ ^^4      P                  ^
^4      pRR.p\        P                  ! WsR	RVR7      p	VP                  V	4       VP!                  ^ ^4       R# u upi )
i!N,Z<)rY   Zmarkerg{Gz?g{Gz?Zyellow)ZzorderZ
facecolorsoffsetsN)g?rQ   rP   )npZrandomZdefault_rngZuniformr!   r"   scatterr@   rH   r   r   Zunit_regular_polygonZreshapemcollectionsZPathCollectionZadd_collectionZset_xlim)
ZrngZxvalsZyvalsZsizesr+   r,   rJ   Zpathsrp   Zpcs
             r-   test_path_collectionru   [  s   
))


)CKK1b!EKK1b!EKKC$EllnGCJJuUocJJOO8=aD1TYY++A.EDkk!S"%--b!4G4LE		$	$U"08'
KBbKK1 Es   %(D5zcolorbar_shift.epsZbbox_inchesZtight)Zsavefig_kwargra   c                 s    \         P                  ! . RO4      p\         P                  ! . ROVP                  4      p\        P
                  ! ^ ^.^^.^ ^.WR7       \        P                  ! 4        R# )r<   )ZccmapnormN)r<   rZ   r[   )rq   g      r>   r2   )mcolorsZListedColormapZBoundaryNormZNr!   rs   Zcolorbar)r9   rv   rw   r_   r-   test_colorbar_shiftry   m  sR     !!/2D 2DFF;DKKAA1a&t?LLNr   c                  s   \         P                  ! 4       p \        P                  ! \        R R7      ;_uu_ 4        V P                  \        P                  ! 4       RRR7       RRR4       \        P                  ! \        R R7      ;_uu_ 4        R\        P                  R&   RRR4       R#   + '       g   i     LR; i  + '       g   i     R# ; i)z'auto' is not a valid value)Zmatchr   Zauto)r   r   Nzps.papersize)
r!   r   r   rM   Z
ValueErrorr(   r#   r%   r   r   )r+   r\   r-   test_auto_papersize_removalrz   v  s    
**,C	z)F	G	GBJJL&A 
H 
z)F	G	G'-^$ 
H	G 
H	G 
H	G	Gs   (B,B?,B<	?C	)r   zps with distiller=ghostscriptzps with distiller=xpdfzps with usetexr   zeps afmzeps with usetex)>Zcollectionsr   Zpathlibr   r#   r*   r7   Znumpyrr   r   Z
matplotlibr   r   r   r   rl   Zmatplotlib.figurer   Zmatplotlib.patchesr   Zmatplotlib.testing._markersr	   r
   Zmatplotlib.testing.decoratorsr   r   r   Zmatplotlib.collectionsrt   Zmatplotlib.colorsZcolorsrx   Zmatplotlib.pyplotZpyplotr!   ZmarkZflakyZparametrizer.   r6   r;   rD   rE   rL   rO   rT   rU   rV   rW   r]   r^   r`   rc   re   rf   rg   rh   rn   ro   ru   ry   rz   rN   r   r-   <module>r{      s/     	 	    C C $ & G O  - #  !x&:;[(AB4	5"	5$m45	5$f-.	5=$'(
E2
D;%&
EM4()7  "G6# C < (G6T% @  @" ;- / !/ ;- / ! /J$ / / 7 7 + + <.! " ;-  ! -./ 0 ( ) 2 2 ,-W=& >& c4[19 29	%+( )*5	@ 6	@ *+5	@ 6	@ =/" #" '(8P!!.r   