Ë
    £ehW	  ã                   óR   — d dl mZmZ d dlmZ d dlmZ d dlmZm	Z	  G d„ de«      Z
y)é    )ÚotRoundÚ	roundFunc)ÚT2CharString)ÚBasePen)ÚspecializeCommandsÚcommandsToProgramc                   óP   ‡ — e Zd ZdZd
ˆ fd„	Zd„ Zd„ Zd„ Zd„ Zd„ Z	d„ Z
dd	„Zˆ xZS )ÚT2CharStringPenaÉ  Pen to draw Type 2 CharStrings.

    The 'roundTolerance' argument controls the rounding of point coordinates.
    It is defined as the maximum absolute difference between the original
    float and the rounded integer value.
    The default tolerance of 0.5 means that all floats are rounded to integer;
    a value of 0 disables rounding; values in between will only round floats
    which are close to their integral part within the tolerated range.
    c                 ó„   •— t         t        | �  |«       t        |«      | _        || _        || _        g | _        d| _        y )N)r   r   )	Úsuperr
   Ú__init__r   ÚroundÚ_CFF2Ú_widthÚ	_commandsÚ_p0)ÚselfÚwidthÚglyphSetÚroundToleranceÚCFF2Ú	__class__s        €ú\/var/www/skyplay_api_hub/venv/lib/python3.12/site-packages/fontTools/pens/t2CharStringPen.pyr   zT2CharStringPen.__init__   s:   ø€ ÜŒo˜tÑ-¨hÔ7Ü˜~Ó.ˆŒ
ØˆŒ
ØˆŒØˆŒØˆ�ó    c                 ó¤   — | j                   }| j                  |d   «      | j                  |d   «      fx}| _         |d   |d   z
  |d   |d   z
  gS )Nr   é   )r   r   )r   ÚptÚp0s      r   Ú_pzT2CharStringPen._p   sY   € Ø�X‰XˆØŸ™ B q¡EÓ*¨D¯J©J°r¸!±uÓ,=Ð>Ð>ˆˆTŒXØ�1‘˜˜1™‘˜r !™u r¨!¡u™}Ð-Ð-r   c                 ó\   — | j                   j                  d| j                  |«      f«       y )NÚrmoveto©r   Úappendr   ©r   r   s     r   Ú_moveTozT2CharStringPen._moveTo"   ó!   € Ø�‰×Ñ˜y¨$¯'©'°"«+Ð6Õ7r   c                 ó\   — | j                   j                  d| j                  |«      f«       y )NÚrlinetor"   r$   s     r   Ú_lineTozT2CharStringPen._lineTo%   r&   r   c                 ó†   — | j                   }| j                  j                  d ||«       ||«      z    ||«      z   f«       y )NÚ	rrcurveto)r   r   r#   )r   Úpt1Úpt2Úpt3r   s        r   Ú_curveToOnezT2CharStringPen._curveToOne(   s8   € Ø�W‰WˆØ�‰×Ñ˜{©B¨s«G±b¸³gÑ,=ÁÀ3ÃÑ,GÐHÕIr   c                  ó   — y ©N© ©r   s    r   Ú
_closePathzT2CharStringPen._closePath,   ó   € Ør   c                  ó   — y r1   r2   r3   s    r   Ú_endPathzT2CharStringPen._endPath/   r5   r   c                 óR  — | j                   }|r| j                  sdnd}t        |d|¬«      }t        |«      }| j                  �8| j                  rJ d«       ‚|j                  dt        | j                  «      «       | j                  s|j                  d«       t        |||¬«      }|S )	Né0   i  F)ÚgeneralizeFirstÚmaxstackz7CFF2 does not allow encoding glyph width in CharString.r   Úendchar)ÚprogramÚprivateÚglobalSubrs)	r   r   r   r   r   Úinsertr   r#   r   )r   r>   r?   ÚoptimizeÚcommandsr;   r=   Ú
charStrings           r   ÚgetCharStringzT2CharStringPen.getCharString2   sž   € Ø—>‘>ˆÙØ!%§¢‘r°ˆHÜ)Ø¨%¸(ôˆHô $ HÓ-ˆØ�;‰;Ð"à—J’JðIàHóIØà�N‰N˜1œg d§k¡kÓ2Ô3Ø�zŠzØ�N‰N˜9Ô%Ü!Ø W¸+ô
ˆ
ð Ðr   )g      à?F)NNT)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r   r%   r)   r/   r4   r7   rD   Ú__classcell__)r   s   @r   r
   r
   
   s1   ø„ ñõò.ò
8ò8òJòò÷r   r
   N)ÚfontTools.misc.roundToolsr   r   ÚfontTools.misc.psCharStringsr   ÚfontTools.pens.basePenr   ÚfontTools.cffLib.specializerr   r   r
   r2   r   r   ú<module>rN      s   ð÷ 9Ý 5Ý *ß Nô:�gõ :r   