%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /lib/python3/dist-packages/reportlab/lib/__pycache__/
Upload File :
Create Path :
Current File : //lib/python3/dist-packages/reportlab/lib/__pycache__/rl_accel.cpython-312.pyc

�

׸�e�4�
��iZiZeeddj	���ZddlZeedd�Z[eD]!Z	iZ
	ede	ze
�e
dee	<erdee	<[
�#erddl
mZmZmZmZmZddlmZdd	lmZd
evr%eed�fd�Zd
Zd�Zded�vreZd�Zeed
<devrd�Zeed<devr	d>d�Zeed<devr	d?d�Zeed<devrd�Zeed<devrd�Z e ed<devrd�Z!e!ed<devr^iZ"e#d�D]HZ$e$d kse$d!k\r	d"e$ze"e$<�e$e%d#�e%d$�e%d%�fvrd#e&e$�ze"e$<�>e&e$�e"e$<�J[$d&�Z'e'ed<d'evrd(�Z(e(ed'<d)evrd*�Z)e)ed)<d+evrd,�Z*e*ed+<e+�Z,eD]"Z	e	evree	nee	Z-e-se.d-e	z��e-e,e	<�$[	[-[,e/d.k(r�ddl0Z0ddl1Z1djed/j	��Z3d0D]o\Z4Z5d1D]eZ6d2jed3d4d5e6�d6e3��fe5z�Z7e6d7k7rd8e7zZ7e8d9e6�d:e4���e#d;�D]#Z9e1jte0jvd<d=e7e4g��%�g�qyy#e$r	dee	<Y���wxYw)@Nz�
        fp_str
        unicode2T1
        instanceStringWidthT1
        instanceStringWidthTTF
        asciiBase85Encode
        asciiBase85Decode
        escapePDF
        sameFrag
        calcChecksum
        add32
        hex32
        ��_rl_testingFzfrom _rl_accel import %s as f�f)�	isUnicode�isSeq�rawBytes�asNative�asBytes)�log)�unpack�fp_strg$@c��||�|zS�N�)�xr
�	_log_e_10s   �8/usr/lib/python3/dist-packages/reportlab/lib/rl_accel.py�<lambda>r's��C��F�9�4D��)z%.0fz%.1fz%.2fz%.3fz%.4fz%.5fz%.6fc��t|�dk(rt|d�r|d}g}|j}|D]�}t|�}|dkr	|d��|dkxrdxs+t	tddt
t|��z
�d�}t||z}|r0t|�}|r|dz}||dk7r||dk7r|dz
}n|r�|d|}||ddk7xst|�dk(xr|xs|dd���dj|�S)	zXconvert separate arguments (or single sequence arg) into space separated numeric strings�rgH�����z>�0��.N� )
�lenr�append�abs�min�max�int�_log_10�_fp_fmts�join)�a�s�A�i�sa�l�n�js        rrr)s���q�6�1�9��q��t��!�A�$�a���
�H�H���	;�A��A��B��4�x��3����E�K�a�E�3�s�1�a��G�B�K�0@�.@�'B�1�#E���Q�K��M����A��A���Q����Q�4��9� ��t�S�y�!�q�&�!�!�	�
�"�1��A��1�Q�4��9�)��A���	�0�q�9�A�a�b�E�:�	;��x�x��{�r�,g�?c�2�t|�jdd�S)Nr,r)�_FP_STR�replace)r$s r�_fp_strr0Bs���A�;�&�&�s�3�/�/r�
unicode2T1c��g}|d|dd}}|j}d|vrd}|r6	t|�r|j|�}n|}|j||f�	|S|S#t$r�}|j
dd\}}|r%|j||d|j|�f�|r|j
t||||��n-|j|j|j||z
zf�||d}Yd}~nd}~wwxYw|r�݌�)zBreturn a list of (font,string) pairs representing the unicode textrrNzUCS-2�UTF16��)
�encNamer�encoder�UnicodeEncodeError�args�extendr1�_notdefFont�_notdefChar)	�utext�fonts�R�font�encr%�e�i0�ils	         rr1r1Gs
�����A�h��a�b�	�e���l�l���c�>��C��
#��U�#����S�)�A��A����$�q��"����q���&�
#�����!����B���H�H�d�5��"�:�#4�#4�S�#9�:�;���H�H�Z��b���U�;�<��H�H�d�.�.�t�/?�/?��B��/G�H�I��b�c�
���
#���s�2A�	C8�"BC3�3C8�instanceStringWidthT1c��t|�s|j|�}td�t||g|jz�D��dz|zS)z&This is the "purist" approach to widthc3�tK�|]0\}}tt|jj|�����2y�wr)�sum�map�widths�__getitem__)�.0r�ts   r�	<genexpr>z(instanceStringWidthT1.<locals>.<genexpr>fs*����p���A�C��A�H�H�0�0��3�4�p�s�68���MbP?)r�decoderHr1�substitutionFonts)�self�text�size�encodings    rrErEcsJ�����t�{�{�8�'<���p��D�RV�QW�X\�Xn�Xn�Qn�Ao�p�q�rw�w�x|�|�|r�instanceStringWidthTTFc�����t|�s|j|xsd�}|jjj�|jj
�d|zt
��fd�|D��zS)zCalculate text width�utf-8rOc3�B�K�|]}�t|������y�wr)�ord)rL�u�dw�gs  ��rrNz)instanceStringWidthTTF.<locals>.<genexpr>ps�����:��q��Q���|�:�s�)rrP�face�
charWidths�get�defaultWidthrH)rRrSrTrUr\r]s    @@rrVrVjs[�������;�;�x�2�7�3�D��I�I� � �$�$��
�Y�Y�
#�
#���T�z�#�:�T�:�;�;�;r�hex32c�$�dt|�dzzS)Nz0X%8.8X���)r )r's rrbrbts���C��F�:�-�.�.r�add32c��||zdzS)zCalculate (x + y) modulo 2**32rdr)r�ys  rrereys���!��z�!�!r�calcChecksumc��t|�}t|�dzr|dt|�dzz
dzz}ttdt|�dz	z|��dzS)zCalculates TTF-style checksums�r5�z>%dlr4rd)rrrHr)�datas rrhrhsT����~���t�9�Q�;�t�q�#�d�)�A�+���&=�=���6�&�C��I�q�L�1�4�8�9�J�F�Fr�	escapePDF�� �z\%03o�\�(�)c��g}|D]6}t|�turt|�}|jt|��8dj|�S)N�)�typer rZr�_ESCAPEDICTr#)r%�r�cs   rrmrm�sJ�����	%�A���7�c�>���F��
�H�H�[��^�$�	%��w�w�q�z�r�asciiBase85Encodec��t|�}tt|�d�\}}d|z}|d|||d}}gj}t	|�D�]S}|dz}	||	}
||	dz}||	dz}||	dz}
|r,t|
�}
t|�}t|�}t|
�}
|
dkr|
dz|zdz|zdz|
z}nd	|
zd
|zzd|zz|
z}|dk(r	|d���t|d
�\}}t|d
�\}}t|d
�\}}t|d
�\}}d|zd|zzd|zzd
|zz|z|k(sJd��|t
|dz��|t
|dz��|t
|dz��|t
|dz��|t
|dz����V|dkD�r|dt|�z
|rdndzz
}|d}
|d}|d}|d}
|r,t|
�}
t|�}t|�}t|
�}
d	|
zd
|zzd|zz|
z}t|d
�\}}t|d
�\}}t|d
�\}}t|d
�\}}t
|dz�t
|dz�zt
|dz�zt
|dz�zt
|dz�z}||d|dz�|d�dj|j�S)z�Encodes input using ASCII-Base85 coding.

        This is a compact encoding used for binary data within
        a PDF file.  Four bytes of binary data become five bytes of
        ASCII.  This is the default method used for encoding images.r5rNrr4rj����rn�z�U鱄��^	�9�dodgy code!�!�rk�~>ru)	r�divmodrr�rangerZ�chrr#�__self__)�input�doOrd�whole_word_count�remainder_size�cut�body�lastbit�outr'�offset�b1�b2�b3�b4�num�temp�c5�c4�c3�c1�c2�lastwords                      rrzrz�s#���5�!��+1�#�e�*�a�+@�(��.��"�"���a���e�C�D�k�g���i�i���'�(�	 �A��q�S�F��f��B��f�Q�h��B��f�Q�h��B��f�Q�h��B����W����W����W����W���#�v��q�5�"�*�q��"�,�q�0�"�4����m�e�b�j�0�3��8�;�b�@���a�x��C��"�#�r�?���b�!�$��+���b�!�$��+���b���b�)���B��"��%�2��6�5�B�,�G�2�b�5�Q�TV�V�Z]�]�l�_l�l�]��C��2��J���C��2��J���C��2��J���C��2��J���C��2��J��?	 �L�A����#�g�,����G�D�D�G����B����B����B����B����W����W����W����W���R�-�%�"�*�,�s�R�x�7�"�<�C��c�2��H�D�"��d�B�'�H�D�"��d�B�'�H�D�"��D�"�%�F�B���2�b�5�z�C��2��J�.��R��U��;�c�"�R�%�j�H�3�r�RT�u�:�U�H����>�A�-�.�/�	�D�	��w�w�s�|�|�$�$r�asciiBase85Decodec�(�djt|�j��}|dddk(sJd��|dd}|jdd�}t	t|�d�\}}d|z}|d	|||d}}gj}t|�D�]}|dz}	t||	�d
z
}
t||	dz�d
z
}t||	dz�d
z
}t||	d
z�d
z
}
t||	dz�d
z
}d|
zd|zzd|zzd|
zz|z}t	|d�\}}t	|d�\}}t	|d�\}}|d|zd|zzd|zz|zk(sJd��|t|��|t|��|t|��|t|����|d	kD�rCt|�dkr|dz}t|�dkr�t|d	�d
z
}
t|d�d
z
}t|d�d
z
}t|d
�d
z
}
t|d�d
z
}d|
z|zdz|zdz|
zdz|d|zz}t	|d�\}}t	|d�\}}t	|d�\}}|d|zd|zzd|zz|zk(sJd��|dk(rt|�}nH|d
k(rt|�t|�z}n+|dk(r$t|�t|�zt|�z}nd}||�dj|j�}t|d��S)z�Decodes input using ASCII-Base85 coding.

        This is not normally used - Acrobat Reader decodes for you
        - but a round trip is essential for testing.ru���Nr�z+Invalid terminator for Ascii Base 85 Streamr�z!!!!!�rr�rr4rjr5r�r�r�r�rnr~rr��!)rri���i����latin1)rA)r#r�splitr/r�rrr�rZr�r�r	)r��strippedr�r�r�r�r�r�r'r�r�r�r�r�r�r�r�r�r�r�r�r�rxs                       rr�r��sr���7�7�8�E�?�0�0�2�3�����}��$�S�&S�S�$��C�R�=���#�#�C��0��+1�#�h�-��+C�(��.��"�"�� ��3���#�$��g���i�i���'�(�	�A��q�S�F��T�&�\�"�R�'�B��T�&��(�^�$�r�)�B��T�&��(�^�$�r�)�B��T�&��(�^�$�r�)�B��T�&��(�^�$�r�)�B��R�<�U�b�L�1�e�r�\�B�b��e�L�r�Q�C��c�#��H�D�"��d�3�'�H�D�"��D�#�&�F�B���8�b�=�5�2�:�5��b��@�2�E�E�T�}�T�E���B��L���B��L���B��L���B��L�%	�*�A���g�,��"�!�C�-���g�,��"��W�Q�Z��2�%�B��W�Q�Z��2�%�B��W�Q�Z��2�%�B��W�Q�Z��2�%�B��W�Q�Z��2�%�B���U�2�X�r�M�"�$�b�(��+�R�/�2�0��@�4A�B�C��c�#��H�D�"��d�3�'�H�D�"��D�#�&�F�B���8�b�=�5�2�:�5��b��@�2�E�E�T�}�T�E���"��r�7���1�$��r�7�S��W�,���1�$��r�7�S��W�,�s�2�w�6������M��G�G�C�L�L�!���q�X�&�&r�sameFragc��t|d�s$t|d�st|d�st|d�rydD]}t||d�t||d�k7s�yy)z+returns 1 if two ParaFrags map out the same�cbDefn�	lineBreakr)�fontName�fontSize�	textColor�rise�us_lines�link�	backColor�nobrNr)�hasattr�getattr)rr]r$s   rr�r�;sX���A�h��7�1�X�#6��1�[�)�W�Q�{�-C�Q�g�	>�A��q��4� �'�!�A�d�"3�3�A�	>�rz#function %s is not properly defined�__main__z�add32 asciiBase85Decode asciiBase85Encode
                    calcChecksum escapePDF fp_str hex32
                    instanceStringWidthT1 instanceStringWidthTTF
                    sameFrag unicode2T1)	)z$instanceStringWidthTTF(font,text,10))zfont=TTFont('Vera','Vera.ttf')�text='abcde fghi . jkl ; mno')z7instanceStringWidthT1(font,'abcde fghi . jkl ; mno',10))zCfonts=[getFont('Helvetica')]+getFont('Helvetica').substitutionFontsz
font=fonts[0]r�)zescapePDF(text))utext='abcdefghijkló')z!fp_str(1.23456,2.7891666,2,13,11)r)zcalcChecksum(text))z.text=5*' abcdefgiijklMnoPQrstuvwxyz1234567890')zhex32(0x12345678)r)zadd32(0x12345678,123456789)r)zasciiBase85Encode(src))z-src=5*' abcdefgiijklMnoPQrstuvwxyz1234567890')zasciiBase85Decode(_85text))zD_85text=asciiBase85Encode(5*' abcdefgiijklMnoPQrstuvwxyz1234567890'))�	_rl_accelzreportlab.lib.rl_accel�;z0from reportlab.pdfbase.pdfmetrics import getFontz,from reportlab.pdfbase.ttfonts import TTFontzfrom z import r�z)import sys;sys.modules['_rl_accel']=None;ztiming rr4z-mtimeitz-s)�utf8)rX)<�_c_funcs�	_py_funcs�list�filterr��__all__�	reportlabr��testing�fn�D�exec�ImportError�reportlab.lib.utilsrrrrr	�mathr
�structrr!r"rr0r.r1rErVrbrerhrwr�ryrZr�rmrzr�r��globals�Gr�RuntimeError�__name__�sys�
subprocessr#�funclist�cmd�xs�modnamer%�printr'�
check_call�
executablerrr�<module>r�s���
���	��v�d��
�E�G�����
�)�M�%�
0��
�
�
�B��A���
,�r�
1�!�4���v�����D�I�b�M�	
�
�
�Q�Q����y����T��D�G�E�H��.�f�T�l����	0� �I�h���9���2)�I�l���i�'�}�*?�I�%�&��y�(�<�+A�I�&�'�
�i��/��I�g��
�i��"��I�g���Y��G�
!-�I�n���)���K�
�3�Z�$���R�4�1�c�6�$�q�L�K��N�
�3�t�9�S��X�c�#�h�/�
/�!�#�a�&�[�K��N� ��V�K��N�
$�	
��'�I�k���)�#�O%�`&7�I�!�"��)�#�I'�T&7�I�!�"�
����%�I�j��	�)��
��B��h�����I�b�M�A���@�2�E�F�F�
�A�b�E�	�
��1��Z����x�x�+�,1�5�7�4�H��N���B�<�
	N�G����B�>���y���
�3���	��A�
��#�?��A���G�G�9�A�c�U�+�,��1�X�
N��%�
�%�%�s�~�~�j��a��&L�M�
N�
	N�N�
��_	���	�"�
��s�H?�?
I
�I


Zerion Mini Shell 1.0