
    P/Ph,                     D    d dl mZ d dlmZ d dlZd Zd Zd Zd Z	d Z
dS )    Nc                      t          j        dd          } | d         | d         k    sJ | d d df         | d d df         k    sJ d S )N      )r   r   r   )gridspecGridSpec)gss    ^/var/www/html/test/jupyter/venv/lib/python3.11/site-packages/matplotlib/tests/test_gridspec.py
test_equalr
      s\    		1a	 	 Bd8r$xaaad8r!!!Q$x    c                      t          j        t                    5  t          j        ddg d           ddd           dS # 1 swxY w Y   dS )a
    Addresses issue #5835.
    See at https://github.com/matplotlib/matplotlib/issues/5835.
    r   r   r      )width_ratiosNpytestraises
ValueErrorr   r    r   r	   test_width_ratiosr      s    
 
z	"	" 8 8!QYYY77778 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8   AAAc                      t          j        t                    5  t          j        ddg d           ddd           dS # 1 swxY w Y   dS )r   r   r   )height_ratiosNr   r   r   r	   test_height_ratiosr      s    
 
z	"	" 9 9!Qiii88889 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9r   c                      t          j        dd          dddf         } t          |           dk    sJ t          j        dddd          } t          |           dk    sJ d S )	Nr   r   r   zGridSpec(3, 3)[2:3, 1:3])r   r   )r   r   )r   r   z9GridSpec(2, 2, height_ratios=(3, 1), width_ratios=(1, 3)))r   r   repr)sss    r	   	test_reprr      s    		1a	 	 AaC	(B8811111		1a)/(.
0 
0 
0B 88CD D D D D Dr   c                  .   t          j        dd          \  } }t          j        dd|d                                                   }|                                |d                                         k    sJ t          j        t          d          5  t          j        dd|d                   }d d d            n# 1 swxY w Y   t          j        t          d          5  t          j        dd|          }d d d            d S # 1 swxY w Y   d S )Nr   r   r   )subplot_specz%subplot_spec must be type SubplotSpec)match)	pltsubplotsr   GridSpecFromSubplotSpecget_subplotspecget_topmost_subplotspecr   r   	TypeError)figaxsr   s      r	   test_subplotspec_argsr*   )   s   |Aq!!HC		)!Q7:1v7M7M7O7O
Q 
Q 
QB%%''3q6+A+A+C+CCCCC	y(O	P	P	P I I-aQHHHI I I I I I I I I I I I I I I	y(O	P	P	P F F-aEEEF F F F F F F F F F F F F F F F F Fs$   B??CC%D

DD)matplotlib.gridspecr   matplotlib.pyplotpyplotr"   r   r
   r   r   r   r*   r   r   r	   <module>r.      s    & & & & & &            8 8 89 9 9D D D	F 	F 	F 	F 	Fr   