+
     ]i  c                   s   R t ^ RIHt ^ RIt^ RIt^ RIHt ^ RIH	t	 ^ RI
Ht ^ RIHt ^ RIHt ^ RIHt ^ RIHt ^ RIHt  ! R R]P2                  4      t ! R R	]P6                  4      t ! R
 R]P:                  4      t ! R R]4      t]! ]4       ]	! R.RR7      R 4       t ]	! R.R]PB                  ! 4       R8X  d   ^ MRR7      R 4       t"R# )z)
Testing that skewed Axes properly work.
)	ExitStackN)image_comparison)Axes)register_projectionc                   s8   a a ] tR t^t oV 3R ltR tRtVtV ;t# )	SkewXTickc                s$  < \        4       ;_uu_ 4       pV P                  V P                  V P                  V P                  V P
                  3 F-  pVP                  VP                  VP                  4       4       K/  	  \        P                  ! V P                  P                  V P                  4       4      p\        P                  ! V P                  P                  V P                  4       4      pV P                  P                  V P                  P                  4       ;'       d    T4       V P                  P                  V P                  P                  4       ;'       d    T4       V P                  P                  V P                  P                  4       ;'       d    T4       V P
                  P                  V P
                  P                  4       ;'       d    T4       \        SV `A  V4       R R R 4       R #   + '       g   i     R # ; iN)r    ZgridlineZ	tick1lineZ	tick2lineZlabel1Zlabel2ZcallbackZset_visibleZget_visible
transformsZinterval_containsaxes
lower_xlimZget_loc
upper_xlimsuperdraw)selfZrendererZstackZartistZneeds_lowerZneeds_upper	__class__s   &&    A/usr/lib64/python3.14/site-packages/matplotlib/tests/test_skew.pyr   ZSkewXTick.draw   sa   [[E==$..$..;;5v1163E3E3GH5 %66		$$dlln6K$66		$$dlln6KNN&&**,<<>KK##'')99k;NN&&**,<<>KK##'')99k;GL"! [[[s$   DG>'<G>$<G>!<G>G>>H	c                sJ    V P                   P                  P                  4       # r   )r   xaxisget_view_intervalr      &r   r   ZSkewXTick.get_view_interval*   s    yy0022     )	__name__
__module____qualname____firstlineno__r   r   __static_attributes____classdictcell____classcell__r   __classdict__   @@r   r   r      s     #&3 3r   r   c                   s,   a  ] tR t^0t o R tR tRtV tR# )	SkewXAxisc                s2    \        V P                  R VR7      # )N)major)r   r   )r   r    s   &&r   	_get_tickZSkewXAxis._get_tick1   s    D66r   c                sv    V P                   P                  ^ ,          V P                   P                  ^,          3# )    )r   r	   r   r   r   r   r   ZSkewXAxis.get_view_interval4   s+    yy##A&		(<(<Q(???r   r   N)r   r   r   r   r!   r   r   r   r      @r   r   r   0   s     7@ @r   r   c                   s&   a  ] tR t^;t o R tRtV tR# )	SkewSpinec                s    V P                   P                  pV P                  R 8X  d   V P                  P                  VR&   R# V P                  P
                  VR&   R# )topN:NNNr"   )Z_pathZverticesZ
spine_typer   r	   r   r   Zpts   & r   _adjust_locationZSkewSpine._adjust_location<   sC    jj!!??e#		,,CI		,,CIr   r   N)r   r   r   r   r*   r   r   r#   r$   r   r%   r%   ;   s     - -r   r%   c                   sb   a a ] tR t^Gt oRtR tR tV 3R lt]R 4       t	]R 4       t
RtVtV ;t# )	SkewXAxesskewxc                s   \        V 4      V n        V P                  P                  P	                  V P                  4       V P                  P
                  P	                  V P                  4       \        P                  ! V 4      V n        V P                  P                  P	                  V P                  4       V P                  P                  P	                  V P                  4       R # r   )r   r   spinesr&   Zregister_axisbottommaxisZYAxisyaxisleftrightr   r   r   
_init_axisZSkewXAxes._init_axisL   s    t_
%%djj1((4[[&
&&tzz2''

3r   c                s    R \         P                  V R 4      R\        P                  P                  V R4      R\        P                  P                  V R4      R\        P                  P                  V R4      /pV# )r&   r.   r1   r2   )r%   Zlinear_spinemspinesSpine)r   r-   r)   r   _gen_axes_spinesZSkewXAxes._gen_axes_spinesU   se    //e<GMM66tXF'--44T6B7==55dGDF r   c                s  < ^p\         SV `  4        V P                  V P                  \        P
                  ! 4       P                  V^ 4      ,           ,           V n        V P                  V P                  ,           V n	        \        P                  ! V P                  V P                  ,           \        P                  ! 4       4      \        P
                  ! 4       P                  V^ 4      ,           V P                  ,           V n        R# )zi
This is called once when the plot is created to set up all the
transforms for the data, text and grids.
N)r
   _set_lim_and_transformsZ
transScaleZtransLimitsr   Affine2Dskew_degtransDataToAxesZ	transAxes	transDataZblended_transform_factoryZIdentityTransform_xaxis_transform)r   Zrotr   s   & r   r7   Z!SkewXAxes._set_lim_and_transforms\   s    
  	') !%!%!1!1!+!4!4!6!?!?Q!G"H!I
 --> ",!E!EOOd...((*", !**32"3 7;nn!Er   c                sB    V P                   P                  P                  # r   )r   ZviewLimZ	intervalxr   r   r   r   ZSkewXAxes.lower_xlimy   s    yy  ***r   c                sr    R R.RR..pV P                   P                  4       P                  V4      R,          # )g        g      ?r'   )r:   Zinverted	transformr(   r)   r   r	   ZSkewXAxes.upper_xlim}   s9    Bx"b"##,,.88=dCCr   )r<   r;   r:   r   r0   )r   r   r   r   Znamer3   r6   r7   Zpropertyr   r	   r   r   r   r   r   r   r+   r+   G   sL      D4E: + + D D Dr   r+   zskew_axes.pngT)remove_textc                  s    \         P                  ! 4       p V P                  ^^^RR7      pVP                  R^24       VP	                  ^2R4       VP                  R4       VP                  ^ RR7       R# )   r,   )Z
projectionTZb)ZcolorNi)pltZfigureZadd_subplotset_xlimset_ylimZgridZaxvline)Zfigaxs     r   test_set_line_coll_dash_imagerD      s\    
**,C	AqW	5BKKRKKCGGDM JJqJr   zskew_rects.pngZx86_64g;On?)r>   Ztolc                  s   \         P                  ! ^^RRRR7      w  rVP                  p\        \        P
                  ! . RO^R7      4      pV^ ,          P                  R^.4       V^ ,          P                  R^.4       V^ ,          P                  RRR7       \        W4       F  w  pw  rE^-V,          ^-V,          rv\        P                  ! 4       P                  Wg4      pVP                  RV RV R24       VP                  \        P                   ! RR.^^WP"                  ,           R	R
R7      4       K  	  \         P$                  ! ^ RRRRR7       R# )i   T)ZsharexZshareyZfigsize)ZrepeatZequal)ZsharezSkew of z
 in X and z in Yg      ?Zcoral)r=   ZalphaZ	facecolorg{Gz?gGz?)Zwspacer1   r2   r.   r&   N)   rE   )rF   rG   r"   r?   i   )r@   ZsubplotsZflatZlist	itertoolsZproductrA   rB   Z
set_aspectZzipr   r8   r9   Z	set_titleZ	add_patchmpatchZ	Rectangler;   Zsubplots_adjust)	Zfixr   Z	rotationsrC   ZxrotsZyrotsZxdegZydegZts	            r   test_skew_rectanglerJ      s%    Q$tVLIC99DY&&'8CDIGb!WGb!WGwd+!$2NU%Zed!**46
xvZvU;<
V%%r2h101LL0@,/7D 	E 3 qt4$Or   )#Z__doc__Z
contextlibr    rH   ZplatformZmatplotlib.pyplotZpyplotr@   Zmatplotlib.testing.decoratorsr   Zmatplotlib.axesr   Zmatplotlib.transformsr   Zmatplotlib.axisZaxisr/   Zmatplotlib.spinesr-   r4   Zmatplotlib.patchesZpatchesrI   Zmatplotlib.projectionsr   ZXTickr   ZXAxisr   r5   r%   r+   rD   ZmachinerJ   r   r   r   <module>rK      s    !    :   *  # # 6
3 34@ @- -9D 9D| I  ?#6 7 #$$#++-9auFPFPr   