+
    i@                     V   R t ^ RIHt ^ RIt^ RIt^ RIt^ RIt^ RIHt ^ RI	H
t
HtHt ^ RIHt ^ RIHt ^ RIHtHtHt ^RIHtHtHt ^R	IHtHt R
 tRRRRRRRRRRRRRR/t ! R R]4      t ! R R]4      t ! R R]4      t ! R R4      t ]PB                   ! R R ]4      4       t"R# )!z,Interactive figures in the IPython notebook.)	b64encodeN)Comm)display
JavascriptHTML)is_interactiveGcf)_Backend
CloseEventNavigationToolbar2)FigureCanvasWebAggCoreFigureManagerWebAggNavigationToolbar2WebAgg)TimerTornadoTimerAsyncioc                    \         P                  ! 4        U u. uFY  p RP                  V P                  P                  P                  4       ;'       g    RV P                   2V P                  R7      NK[  	  pp \        4       '       g,   VP                  R\        \         P                  4       24       RP                  V4      # u up i )z
Return a string showing the figure and connection status for the backend.

This is intended as a diagnostic tool, and not for general use.
z{fig} - {socket}zFigure )figsocketzFigures pending show: 
)r	   get_all_fig_managersformatcanvasfigure	get_labelnumweb_socketsr   appendlenfigsjoin)managerresults     ځ/Users/tonyclaw/.openclaw/workspace/skills/math-calculator/venv/lib/python3.14/site-packages/matplotlib/backends/backend_nbagg.pyconnection_infor$      s     //1
 2G	 	!!&&002 , ,gkk]+&& 	" 	( 2   .s388}o>?99Vs   :C$Chomez
fa fa-homebackzfa fa-arrow-leftforwardzfa fa-arrow-rightzoom_to_rectzfa fa-square-omovezfa fa-arrowsdownloadzfa fa-floppy-oc            
           ] tR t^5t]P
                  R,            U UUUu. uF#  w  rr#V\        9   g   K  W\        V,          V3NK%  	  upppp tRtR# u upppp i )NavigationIPy N))DownloadzDownload plotr*   r*   )__name__
__module____qualname____firstlineno__r   	toolitems_FONT_AWESOME_CLASSES__static_attributes__)texttooltip_text
image_filename_of_methods   0000r#   r,   r,   5   sa     (11MN9N DT "77E$'
3^EN9I 9s
   A
A
r,   c                      a a ] tR t^@t o];ttV 3R lt]R 4       t	R t
R tR t]R 4       t]RV 3R ll4       tR tR	 tR
 tR tRtVtV ;t# )FigureManagerNbAggc                4   < R V n         \        SV `	  W4       R# )FN)_shownsuper__init__)selfr   r   	__class__s   &&&r#   r?   FigureManagerNbAgg.__init__C   s    %    c                   aaa V! V4      oV ! SV4      o\        4       '       d!   SP                  4        SP                  4        VVV3R  lpSP                  RV4      oS# )c                 V   < SP                  S4       \        P                  ! S4       R # N)mpl_disconnectr	   destroy)eventr   cidr!   s   &r#   rH   6FigureManagerNbAgg.create_with_canvas.<locals>.destroyO   s    !!#&KK rC   close_event)r   show	draw_idlempl_connect)clscanvas_classr   r   rH   r   rJ   r!   s   &&&& @@@r#   create_with_canvas%FigureManagerNbAgg.create_with_canvasG   sU    f%fc"LLN	!   8rC   c                R    \        \        \        P                  4       4      4       R # rF   )r   r   r;   get_javascriptr@   s   &r#   
display_jsFigureManagerNbAgg.display_jsV   s     	
-<<>?@rC   c                   V P                   '       g"   V P                  4        V P                  4        MV P                  P	                  4        R V n         \        V R4      '       d&   V P                  P                  V P                  4       \        4       '       g/   ^ RI	H
p VP                  P                  V P                  R4       R# R# )T_cidgcfr   N)r=   rW   _create_commr   rN   hasattrrG   rZ   r   matplotlib._pylab_helpersr	   r   popr   )r@   r	   s   & r#   rM   FigureManagerNbAgg.show\   s    {{{OOKK!!#
 4##KK&&t||45HHLL4(  rC   c                4    RV n         V P                  4        R# )z:
A special method to re-show the figure in the notebook.

FN)r=   rM   rV   s   &r#   reshowFigureManagerNbAgg.reshowm   s    
 		rC   c                ,    \        V P                  4      # rF   )boolr   rV   s   &r#   	connectedFigureManagerNbAgg.connectedu   s    D$$%%rC   c                  < Vf   \         P                  ! 4       pMTp\        SV `  VR7       VP	                  \
        P                  ! \        4      P                  R,          P                  RR7      4       Vf   VP                  4       # R # )N)streamzweb_backend/js/nbagg_mpl.jszutf-8)encoding)ioStringIOr>   rU   writepathlibPath__file__parent	read_textgetvalue)rP   rh   outputrA   s   && r#   rU   !FigureManagerNbAgg.get_javascripty   sr    >[[]FFf-gll8,3356ii1	3 >??$$ rC   c                >    \        V 4      pV P                  V4       V# rF   )
CommSocketadd_web_socketr@   comms   & r#   r[   FigureManagerNbAgg._create_comm   s    $D!rC   c                    V P                  R 4       \        V P                  4       F  pVP                  4        K  	  V P	                  4        R# )closeN)_send_eventlistr   on_closeclearup_closedrx   s   & r#   rH   FigureManagerNbAgg.destroy   s:    !))*DMMO +rC   c                   V P                    Uu0 uF  pVP                  4       '       g   K  VkK  	  upV n         \        V P                   4      ^ 8X  d'   \        RV P                  4      P                  4        R# R# u upi )zClear up any closed Comms.rL   N)r   is_openr   r   r   _process)r@   r   s   & r#   r   !FigureManagerNbAgg.clearup_closed   sj    151A1A 11Av%~~/ #F1A 1 t A%}dkk2;;= &1s
   A<A<c                    V P                    Uu0 uF"  pVP                  P                  V8w  g   K   VkK$  	  upV n         R # u upi rF   )r   ry   comm_id)r@   r   r   s   && r#   remove_commFigureManagerNbAgg.remove_comm   sA    151A1A ?1Av%{{22g= #F1A ? ?s
   AA)r=   r   rF   )r/   r0   r1   r2   r,   _toolbar2_class
ToolbarClsr?   classmethodrR   rW   rM   ra   propertyre   rU   r[   rH   r   r   r5   __classdictcell____classcell__)rA   __classdict__s   @@r#   r;   r;   @   sy     #00Oj&  A)" & & 
% 
%
>? ?rC   r;   c                       ] tR t^t]tRtR# )FigureCanvasNbAggr-   N)r/   r0   r1   r2   r;   manager_classr5   r-   rC   r#   r   r      s    &MrC   r   c                   H   a  ] tR t^t o RtR tR tR tR tR t	R t
RtV tR	# )
rv   a4  
Manages the Comm connection between IPython and the browser (client).

Comms are 2 way, with the CommSocket being able to publish a message
via the send_json method, and handle a message with on_message. On the
JS side figure.send_message and figure.ws.onmessage do the sending and
receiving respectively.

c                  a a R S n         SS n        \        \        P                  ! 4       4      S n        \        \        RS P                  ,          4      4        \        RRS P                  /R7      S n        S P                  P                  S P                  4       S P                  oRS n        TT 3R lpS P                  P                  T4       R #   \         d   p\        R4      ThR p?ii ; i)Nz<div id=%r></div>
matplotlibid)datazTUnable to create an IPython notebook Comm instance. Are you in the IPython notebook?Fc                 t   < R Sn         SP                  V R,          R,          4       SP                  4        R# )Tcontentr   N)
_ext_closer   r   )close_messager!   r@   s   &r#   	_on_close&CommSocket.__init__.<locals>._on_close   s.    "DOi 8 CD""$rC   )supports_binaryr!   struuiduuid4r   r   r   ry   AttributeErrorRuntimeErroron_msg
on_messager   r   )r@   r!   errr   s   ff  r#   r?   CommSocket.__init__   s    #

%	 	(499456	5\tyy0ABDI
 			),,	%
 			9%  	5  + ,145	5s   C C0C++C0c                `    V P                   ;'       g    V P                  P                  '       * # rF   )r   ry   _closedrV   s   &r#   r   CommSocket.is_open   s!    OO88tyy'8'899rC   c                    V P                  4       '       d    V P                  P                  4        R # R #   \         d     R # i ; irF   )r   ry   r|   KeyErrorrV   s   &r#   r   CommSocket.on_close   s;     <<>>		!   s   6 AAc                h    V P                   P                  R \        P                  ! V4      /4       R# )r   N)ry   sendjsondumps)r@   r   s   &&r#   	send_jsonCommSocket.send_json   s     		

7 345rC   c                    V P                   '       d#   V P                  P                  R R/V.R7       R# \        V4      P	                  R4      pRV 2pV P                  P                  RV/4       R# )blobz	image/png)buffersasciizdata:image/png;base64,r   N)r   ry   r   r   decode)r@   r   r   data_uris   &&  r#   send_binaryCommSocket.send_binary   s`    IINNFK04&NA T?))'2D/v6HIINNFH-.rC   c                4   \         P                  ! VR ,          R,          4      pVR,          R8X  d-   V P                  4        V P                  P	                  4        R# VR,          R8X  d   VR,          V n        R# V P                  P                  V4       R# )r   r   typeclosingr   valueN)r   loadsr   r!   r   r   handle_json)r@   messages   &&r#   r   CommSocket.on_message   sm     **WY/786?i'MMOLL'')V_ 11#*7#3D LL$$W-rC   )r   ry   r!   r   r   N)r/   r0   r1   r2   __doc__r?   r   r   r   r   r   r5   r   )r   s   @r#   rv   rv      s-     &2:6/. .rC   rv   c                       ] tR t^t]t]tRtR# )_BackendNbAggr-   N)	r/   r0   r1   r2   r   FigureCanvasr;   FigureManagerr5   r-   rC   r#   r   r      s    $L&MrC   r   )#r   base64r   rj   r   rm   r   ipykernel.commr   IPython.displayr   r   r   r   r   r]   r	   matplotlib.backend_basesr
   r   r   backend_webagg_corer   r   r   r   r   r$   r4   r,   r;   r   rv   exportr   r-   rC   r#   <module>r      s    2
  	     5 5 % ) M MK K & L
"$
N $ 9, 9\?, \?~'. 'J. J.Z 
'H ' 'rC   