| Server IP : 35.80.110.71 / Your IP : 216.73.216.221 Web Server : Apache/2.4.58 (Ubuntu) System : Linux ip-172-31-21-44 6.17.0-1019-aws #19~24.04.1-Ubuntu SMP Tue Jun 23 18:53:06 UTC 2026 x86_64 User : ubuntu ( 1000) PHP Version : 8.3.31 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /usr/lib/python3/dist-packages/matplotlib/__pycache__/ |
Upload File : |
�
G8�cks � � � d Z ddlmZ ddlmZ ddlZddlmZm Z ddl
mZ ddlm
Z
ddlmZ d� Z G d � d
� Z G d� de� Z G d
� de� Z G d� de� Z G d� de� Z G d� de� Z G d� de� Z G d� de� Z G d� de� Z G d� de� Z G d� de� Z G d� d e� Z G d!� d"e� Z G d#� d$e� Z G d%� d&e� Z G d'� d(e� Z!y))a
Default legend handlers.
.. important::
This is a low-level legend API, which most end users do not need.
We recommend that you are familiar with the :doc:`legend guide
</tutorials/intermediate/legend_guide>` before reading this documentation.
Legend handlers are expected to be a callable object with a following
signature. ::
legend_handler(legend, orig_handle, fontsize, handlebox)
Where *legend* is the legend itself, *orig_handle* is the original
plot, *fontsize* is the fontsize in pixels, and *handlebox* is a
OffsetBox instance. Within the call, you should create relevant
artists (using relevant properties from the *legend* and/or
*orig_handle*) and add them into the handlebox. The artists needs to
be scaled according to the fontsize (note that the size is in pixel,
i.e., this is dpi-scaled value).
This module includes definition of several legend handler classes
derived from the base class (HandlerBase) with the following method::
def legend_artist(self, legend, orig_handle, fontsize, handlebox)
� )�Sequence)�cycleN)�_api�cbook)�Line2D)� Rectanglec �r � t t |j � � d � }|�| j |� y y �N)�next�iter�get_children�update_from)�tgt�src�first_childs �;/usr/lib/python3/dist-packages/matplotlib/legend_handler.py�update_from_first_childr ) s3 � ��t�C�,�,�.�/��6�K�������$� � c �<