%PDF- %PDF-
Direktori : /lib/python3/dist-packages/reportlab/lib/__pycache__/ |
Current File : //lib/python3/dist-packages/reportlab/lib/__pycache__/formatters.cpython-312.pyc |
� ��e� � � � d Z dZdZddlZ G d� d� Z ej d� Z ej d� Z G d � d e� Ze dk( r�d!d�Z e d ddd�� e dddd�� e dddd�� e d ddd�� e d dd� e ddd� e ddd� e d dd� e ddd� e ddd� e ddd� e dd d� yy)")� Formatter�DecimalFormatterz3.3.0z] These help format numbers and dates in a user friendly way. Used by the graphics framework. � Nc �( � e Zd ZdZd� Zd� Zd� Zd� Zy)r z5Base formatter - simply applies python format stringsc � � || _ y �N��pattern)�selfr s �:/usr/lib/python3/dist-packages/reportlab/lib/formatters.py�__init__zFormatter.__init__ s � ���� c � � | j |z S r r )r �objs r �formatzFormatter.format s � ��|�|�c�!�!r c �N � | j j �d| j �d�S )Nz('z'))� __class__�__name__r �r s r �__repr__zFormatter.__repr__ s � �!�^�^�4�4�d�l�l�C�Cr c �$ � | j |� S r )r )r �xs r �__call__zFormatter.__call__ s � ��{�{�1�~�r N)r � __module__�__qualname__�__doc__r r r r � r r r r s � �;��"�D�r r z^\d*\.z0+$c �* � e Zd ZdZdd�Zd� Zd� Zd� Zy)r z�lets you specify how to build a decimal. A future NumberFormatter class will take Microsoft-style patterns instead - "$#,##0.00" is WAY easier than this.Nc �x � |dk( r| j | _ n|| _ || _ || _ || _ || _ y )N�auto)�_calcPlaces� calcPlaces�places�dot�comma�prefix�suffix)r r"