+
    i
                     2    R t ^ RIHtHtHt RR ltRR ltR# )zE
Helper module for the *bbox_inches* parameter in `.Figure.savefig`.
)BboxTransformedBboxAffine2DNc                  a aaaaaa S P                   oS P                  oS P                  P                  o. o. o\	        4       oS P
                   F  pVP                  4       pVe   VP                  V! VR4      4       SP                  V4       VP                  RR7      P                  4       pVP                  V3R l4       RVP                  9   d   SP                  VP                  4       MSP                  S4       RR lVn        K  	  VV VVVVV3R lpVf   S P                  p\        4       P                  V4      pVS P                  ,          p\         P"                  ! ^ ^ .VP$                  O5!  S n        VP'                  VP(                  4      w  rS P                   P$                  V,          w  r\         P"                  ! V	) V
) W4      S P                  n        S P                  P+                  4        \-        S P                  V4      S n         S P.                  P1                  W,          W,          S P                   P2                  V,          S P                   P4                  V,          4       V# )	a3  
Temporarily adjust the figure so that only the specified area
(bbox_inches) is saved.

It modifies fig.bbox, fig.bbox_inches,
fig.transFigure._boxout, and fig.patch.  While the figure size
changes, the scale of the original figure is conserved.  A
function which restores the original values are returned.
NF)originalc                     V# N )ar_poss   &&&v/Users/tonyclaw/.openclaw/workspace/skills/math-calculator/venv/lib/python3.14/site-packages/matplotlib/_tight_bbox.py<lambda>adjust_bbox.<locals>.<lambda>   s    4    apply_aspectc                     R # r   r	   )poss   &r   r   r   %   s    4r   c                  :  < \        SP                  SS4       F'  w  rpV P                  V4       VS	J d   V =K!  W n        K)  	  SSn        SSn        SSP                  n        SP                  P                  4        SP                  P                  ^ ^ ^^4       R# )    N)zipaxesset_axes_locatorr   bboxbbox_inchestransFigure_boxout
invalidatepatch
set_bounds)
axlocaspectr   figlocator_list
old_aspectorigBboxorigBboxInchessentinels
      r   restore_bbox!adjust_bbox.<locals>.restore_bbox'   s    "388\:FOBV$!O"(  G (")""$		Q1a(r   r   )r   r   r   r   objectr   get_axes_locatorr   appendget_positionfrozenr   __dict__dpir   scaler   from_boundssize	transformp0r   r   r   r   widthheight)r#   r   	fixed_dpir    locatorcurrent_posr)   tr	dpi_scalex0y0w1h1r   r$   r%   r&   r'   r(   s   f&&          @@@@@@r   adjust_bboxrB      s    xxH__Noo%%GJLxHhh%%'OOGB-.G$oouo5<<>
k?@R[[(boo.h'/ ) ) GG				)	$BCGG#I&&q!?k.>.>?CO\\+..)FBXX]]Y&FB"..sRC@COOOO s3CHII"'",chhoo.BD r   c                6    Vw  r4V! 4        \        WV4      pW53# )z
A function that needs to be called when figure dpi changes during the
drawing (e.g., rasterizing).  It recovers the bbox and re-adjust it with
the new dpi.
)rB   )r#   bbox_inches_restorer9   r   r)   r   s   &&&   r   process_figure_for_rasterizingrE   I   s%     !4KNCi0A>r   r   )__doc__matplotlib.transformsr   r   r   rB   rE   r	   r   r   <module>rH      s    B A>Br   