+
    i!                     P   ^ RI t ^ RIHt ^ RIt^ RIHt ^ RIH	t	 ^ RI
HtHt ^ RIHtHt ^ RIHt ^ RIHt R t]! R.R	R
7      R 4       t]! R.4      R 4       t]! R.RR7      R 4       tR t]! R.4      R 4       tR t]! R.R7      R 4       t]! R.R7      R 4       tR tR tR# )    N)Mock)Path)
CustomCellTable)image_comparisoncheck_figures_equal)Bboxc                  <    R R.p \         P                  ! V R7       R# )br)cellColoursN)plttable)
cellcolorss    {/Users/tonyclaw/.openclaw/workspace/skills/math-calculator/venv/lib/python3.14/site-packages/matplotlib/tests/test_table.pytest_non_squarer      s    sJII*%    ztable_zorder.pngT)remove_textc            	         R R.RR..p RpR Uu. uF  pRV,          NK  	  pp. p\         P                  ! \        V4      4      p\        V 4       F:  pWV,          pTP	                  V Uu. uF  pRVR,          ,          NK  	  up4       K<  	  \         P
                  ! ^ ^\         P                  ,          ^d4      p\        P                  ! V\         P                  ! V4      ^^R7       \        P                  ! VVVRRR	7       \        P                  ! VVVR
^R	7       \        P                  ! . 4       R# u upi u upi )iR iب iv  i z%d yearz%1.1fg     @@)lwzordercenter)cellText	rowLabels	colLabelslocr   zupper centerN)FreezeWind)d   2   )npzeroslenreversedappendlinspacepir   plotcosr   yticks)datar   xr   r   yoffrowts           r   test_zorderr1      s   FOFOD #I(12	1Q	I2H88C	N#D~t<t!AfH--t<=  	Aqw$AHHQq	a*IIx!!	 IIx!! 	 JJrN1 3 =s   D6)D;
ztable_labels.pngc                     ^p \         P                  ! ^ ^V 4      p\        P                  P	                  V4      pR.V ,          .V ,          p\        P
                  ! 4       pVP                  ^^^4      pVP                  R4       VP                  VVRR7       VP                  ^^^4      pVP                  R4       VP                  VVR.V ,          RR7       VP                  ^^^4      pVP                  R4       VP                  VVRR7       VP                  ^^^4      pVP                  R4       VP                  VVR.V ,          RR7       R	# )
   1offbest)r   
rowColoursr   Header)r   r7   r   r   )r   
colColoursr   )r   r9   r   r   N)	r"   r'   r   cmRdYlGnfigureadd_subplotaxisr   )	dimccoloursr   figax1ax2ax3ax4s	            r   test_label_coloursrG   5   s:   
C
Aq#AffmmAG}s"H
**,C
//!Q
"CHHUOIIx    //!Q
"CHHUOIIx !
S(  
 //!Q
"CHHUOIIx    //!Q
"CHHUOIIx !
S(  r   ztable_cell_manipulation.pngmpl20)stylec                 F   R	pR.\        V4      ,          .^,          pR.\        V4      ,          p\        P                  ! \        V4      ^\        V4      ^,           3RR7      w  rE\        WQ4       F+  w  rgVP	                  VVRVR7       VP                  R4       K-  	  R# )

horizontalr4   皙?tight)nrowsfigsizelayoutr   )	colWidthsr   r   edgesr5   NrK   verticalopenclosedTRBL)r$   r   subplotszipr   r>   )text_placeholderscellsr   rQ   _axsaxcells   &       r   test_diff_cell_tablerc   Z   s    LEE
"#a'HE
"I\\E
QE
14EgVFAO
#!	 	 	 	 $r   c                     Rp \         P                  \         P                  \         P                  \         P                  \         P                  3\         P                  \         P                  \         P                  \         P                  \         P                  3\         P                  \         P                  \         P                  \         P                  \         P                  3\         P                  \         P                  \         P                  \         P                  \         P                  3\         P                  \         P                  \         P                  \         P                  \         P                  3\         P                  \         P                  \         P                  \         P                  \         P                  3\         P                  \         P                  \         P                  \         P                  \         P                  3\         P                  \         P                  \         P                  \         P                  \         P                  33p\	        W4       F  w  r#\        RV^^R7      p\        ;QJ d0    . R VP                  4       P                  4        4       F  NK  	  5M)! R VP                  4       P                  4        4       4      pW58X  d   K  Q h	  R# )rK   )visible_edgeswidthheightc              3   *   "   T F	  w  rVx  K  	  R # 5iN ).0r_   ss   &  r   	<genexpr>"test_customcell.<locals>.<genexpr>z   s     C#B41Q#Bs   NrS   r   r   )	r   MOVETOLINETO	CLOSEPOLYr\   r   tupleget_pathiter_segments)typescodesr0   r@   rb   codes         r   test_customcellry   k   s   LE	dkk4;;T[[I	dkk4;;T[[I	dkk4;;T[[I	dkk4;;T^^L	dkk4;;T[[I	dkk4;;T[[I	dkk4;;T[[I	dkk4;;T[[I	
E E!&1EuC4==?#@#@#BCuuC4==?#@#@#BCCyy "r   ztable_auto_column.pngc                  ~   \         P                  ! ^^4      w  p w  rr4VP                  R4       VP                  R^.R^..RR.RR.RR	7      pVP	                  R
4       VP                  ^4       VP                  . RO4       VP                  R4       VP                  R^.R^..RR.RR.RR	7      pVP	                  R
4       VP                  ^4       VP                  R4       VP                  R4       VP                  R^.R^..RR.RR.RR	7      pVP	                  R
4       VP                  ^4       VP                  R4       VP                  ^ 4       VP                  ^4       VP                  R4       VP                  R^.R^..RR.RR.RR	7      pVP	                  R
4       VP                  ^4       R# )   r5   zFit Textz-very long long text, Longer text than defaultArY   Col1Col2r   )r   r   r   r   FN)r   r      )r   r[   r>   r   auto_set_font_sizeset_fontsizeauto_set_column_width)	rB   rC   rD   rE   rF   tb1tb2tb3tb4s	            r   test_auto_columnr   ~   s    #Q 2C	#C HHUO
))q/BAFH*6"  C 5!Rj) HHUO
))q/BAFH*6"  C 5!Rj) HHUO
))q/BAFH*6"  C 5!Rb!a a  HHUO
))q/BAFH*6"  C 5!Rr   c                  N   \         P                  ! 4       w  r\        V4      pVP                  ^^^^4      p\	        V\
        4      '       g   Q hW2R,          J g   Q h\        R^^RR7      pWBR&   VR,          VJ g   Q hVP                  4        \         P                  ! V4       R# )r   N)re   )r      ro   )r   r   )r   r[   r   add_cell
isinstancer   
propertiessetp)rB   ra   r   rb   cell2s        r   test_table_cellsr      s    llnGC"IE>>!Q1%DdJ'''';vq!48E$K;% 
HHUOr   png)
extensionsc                 B   ^^.^^..pRpR	pV UUu. uF  qU Uu. uF  qf NK  	  upNK  	  pppV P                  4       pVP                  VVVR. R
OR7       VP                  4       p	V	P                  VVVR\        P                  ! RRRR4      R7       R# u upi u uppi )r   r   rL   皙?皙?)r   r   r   r   bboxg?N)FooBar)AdaBob)rL   r   r   g333333?)r[   r   r	   from_extents)
fig_testfig_refr,   
col_labels
row_labelsr/   r-   	cell_textax_listax_bboxs
   &&        r   test_table_bboxr      s    FFD  JJ267$3#&#QC&#&$I7!GMM9&&+	    GMM9&&((c3<	   '7s   BBBBc                     ! R  R4      p\         P                  ! 4       p\        R R7      Vn        \        R R7      Vn        \        R R7      Vn        V\         P                  V&   V! R4      V! ^*4      .V! \        P                  ! R^^4      4      V! R4      ..pV P                  4       P                  V4       VP                  4       P                  R	R	.R	R	..4       V P                  P                  4        VP                  P                  4        \         P                  P                  V4       \         P                  P                  V4      '       d   Q hR
# )c                   ,   a  ] tR t^t o R tR tRtV tR# )!test_table_unit.<locals>.FakeUnitc                    R # ri   rj   )selfthings   &&r   __init__*test_table_unit.<locals>.FakeUnit.__init__   s    r   c                    R # )Hellorj   )r   s   &r   __repr__*test_table_unit.<locals>.FakeUnit.__repr__   s    r   rj   N)__name__
__module____qualname____firstlineno__r   r   __static_attributes____classdictcell__)__classdict__s   @r   FakeUnitr      s     		 	r   r   c                     ^ # )r   rj   )vuas   &&&r   <lambda>!test_table_unit.<locals>.<lambda>   s    ar   )side_effectc                     R # ri   rj   )r   r   s   &&r   r   r      s    r   c                 ,    \         P                  ! 4       # ri   )munitsAxisInfo)r   r   s   &&r   r   r      s    FOO<Mr   yellowi  Tr   N)r   ConversionInterfacer   convertdefault_unitsaxisinforegistrydatetimer[   r   canvasdrawassert_not_calledpopget_converter)r   r   r   fake_convertorr,   s   &&   r   test_table_unitr      s     //1N!.?@N#'4E#FN "/MNN .FOOHh".h''a34htnEGD d#w07G2DEFOO,,.
OO!,,X66666r   c                    R . ROR. RO/pV P                  V4      p\        P                  ! 4       w  r4VP                  VRR7      p\	        VP                  4       4       F  w  pw  rx\	        V^ 8X  d   VP                  MVP                  4       FK  w  rYV^ 8X  d   TMV^,           V	3,          P                  4       P                  4       \        V
4      8X  d   KK  Q h	  K  	  R# )LetterNumberr   )r   N)r|   rY   C)r      i,  )
	DataFramer   r[   r   	enumerateiterrowscolumnsvaluesget_textstr)pdr,   dfrB   ra   r   r   indexr/   r@   cols   &          r   test_table_dataframer     s     	//D
 
d	BllnGCHHRXH&E$R[[]3<Ea1f

#**EFA1f!A#q01::<EEG3s8SSS F 4r   c                     R ^.R^..p \         P                  ! 4       w  r^pVP                  V RVR7      pVR,          P                  4       pWS8X  g   Q RV RV 24       hVR,          P                  4       pWS8X  g   Q RV RV 24       hR# )	r   r   top)r   r   fontsizezActual:z,got:Nro   )r   r   )r   r[   r   get_fontsize)	tableDatarB   ra   test_fontsizer0   cell_fontsizes         r   test_table_fontsizer     s    qC8$IllnGCM
)GAfI**,M)XW]O5+XX)fI**,M)XW]O5+XX)r   ) r   unittest.mockr   numpyr"   matplotlib.pyplotpyplotr   matplotlib.pathr   matplotlib.tabler   r   matplotlib.testing.decoratorsr   r   matplotlib.transformsr	   matplotlib.unitsunitsr   r   r1   rG   rc   ry   r   r   r   r   r   r   rj   r   r   <module>r      s          . O & !& %&D9 :@ %&'! (!H 01A B & *+,3 -3l$ ( )4 (7 )7<T"	Yr   