ó
    oñ:i…^  ã                  ó€  • S r SSKJr  SSKrSSKJrJrJrJrJ	r	  SSK
Jr  SSKJr  SSKJrJr  SSKJrJrJr  / S	Qr\	\\4   r\\   r\\	\\   \\\4      r\\   r\\	\\4      r " S
 S\5      r " S S5      r " S S\5      r  " S S\ 5      r! " S S\5      r" " S S\5      r# " S S\5      r$ " S S\\5      r%g)aË  
=========
PointPens
=========

Where **SegmentPens** have an intuitive approach to drawing
(if you're familiar with postscript anyway), the **PointPen**
is geared towards accessing all the data in the contours of
the glyph. A PointPen has a very simple interface, it just
steps through all the points in a call from glyph.drawPoints().
This allows the caller to provide more data for each point.
For instance, whether or not a point is smooth, and its name.
é    )ÚannotationsN)ÚAnyÚDictÚListÚOptionalÚTuple)ÚStrEnum)ÚLogMixin)ÚDecomposedTransformÚIdentity)ÚAbstractPenÚMissingComponentErrorÚPenError)ÚAbstractPointPenÚBasePointToSegmentPenÚPointToSegmentPenÚSegmentToPointPenÚGuessSmoothPointPenÚReverseContourPointPenÚReverseFlippedc                  ó$   • \ rS rSrSrSrSrSrSrg)r   é,   zòHow to handle flipped components during decomposition.

NO: Don't reverse flipped components
KEEP_START: Reverse flipped components, keeping original starting point
ON_CURVE_FIRST: Reverse flipped components, ensuring first point is on-curve
ÚnoÚ
keep_startÚon_curve_first© N)	Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__ÚNOÚ
KEEP_STARTÚON_CURVE_FIRSTÚ__static_attributes__r   ó    ÚZ/srv/projetos/modelo_ml_acdoc/venv/lib/python3.13/site-packages/fontTools/pens/pointPen.pyr   r   ,   s   † ñð 
€BØ€JØ%ƒNr&   r   c                  ó¨   • \ rS rSrSrS
SS jjrSS jr    S             SS jjr S
         SS jjr S
           SS jjr	S	r
g)r   é9   zBaseclass for all PointPens.Nc                ó   • [         e)zStart a new sub path.©ÚNotImplementedError©ÚselfÚ
identifierÚkwargss      r'   Ú	beginPathÚAbstractPointPen.beginPath<   ó   € ä!Ð!r&   c                ó   • [         e)zEnd the current sub path.r+   ©r.   s    r'   ÚendPathÚAbstractPointPen.endPath@   r3   r&   c                ó   • [         e)z$Add a point to the current sub path.r+   ©r.   ÚptÚsegmentTypeÚsmoothÚnamer/   r0   s          r'   ÚaddPointÚAbstractPointPen.addPointD   s
   € ô "Ð!r&   c                ó   • [         e)zAdd a sub glyph.r+   )r.   ÚbaseGlyphNameÚtransformationr/   r0   s        r'   ÚaddComponentÚAbstractPointPen.addComponentP   s
   € ô "Ð!r&   c                ó   • [         e)zÛAdd a VarComponent sub glyph. The 'transformation' argument
must be a DecomposedTransform from the fontTools.misc.transform module,
and the 'location' argument must be a dictionary mapping axis tags
to their locations.
)ÚAttributeError©r.   Ú	glyphNamerB   Úlocationr/   r0   s         r'   ÚaddVarComponentÚ AbstractPointPen.addVarComponentZ   s
   € ô Ðr&   r   ©N)r/   úOptional[str]r0   r   ÚreturnÚNone©rN   rO   ©NFNN)r:   zTuple[float, float]r;   rM   r<   Úboolr=   rM   r/   rM   r0   r   rN   rO   )
rA   ÚstrrB   z/Tuple[float, float, float, float, float, float]r/   rM   r0   r   rN   rO   )rH   rS   rB   r   rI   zDict[str, float]r/   rM   r0   r   rN   rO   )r   r   r   r    r!   r1   r6   r>   rC   rJ   r%   r   r&   r'   r   r   9   sê   † Ù&ö"ô"ð &*ØØ"Ø$(ð
"àð
"ð #ð
"ð ð	
"ð
 ð
"ð "ð
"ð ð
"ð 
õ
"ð  %)ð	"àð"ð Hð"ð "ð	"ð
 ð"ð 
õ"ð %)ðàðð ,ðð #ð	ð
 "ðð ðð 
÷ð r&   r   c                  óL   • \ rS rSrSrS
S jrSS jrSS jrS
S jr SS jr	S	r
g)r   ék   a  
Base class for retrieving the outline in a segment-oriented
way. The PointPen protocol is simple yet also a little tricky,
so when you need an outline presented as segments but you have
as points, do use this base implementation as it properly takes
care of all the edge cases.
c                ó   • S U l         g rL   ©ÚcurrentPathr5   s    r'   Ú__init__ÚBasePointToSegmentPen.__init__t   s
   € ØˆÕr&   Nc                óB   • U R                   b  [        S5      e/ U l         g )NzPath already begun.)rX   r   r-   s      r'   r1   ÚBasePointToSegmentPen.beginPathw   s"   € Ø×ÑÑ'ÜÐ0Ó1Ð1ØˆÕr&   c                ó   • [         e)a)  Override this method.

It will be called for each non-empty sub path with a list
of segments: the 'segments' argument.

The segments list contains tuples of length 2:
        (segmentType, points)

segmentType is one of "move", "line", "curve" or "qcurve".
"move" may only occur as the first segment, and it signifies
an OPEN path. A CLOSED path does NOT start with a "move", in
fact it will not contain a "move" at ALL.

The 'points' field in the 2-tuple is a list of point info
tuples. The list has 1 or more items, a point tuple has
four items:
        (point, smooth, name, kwargs)
'point' is an (x, y) coordinate pair.

For a closed path, the initial moveTo point is defined as
the last point of the last segment.

The 'points' list of "move" and "line" segments always contains
exactly one point tuple.
r+   )r.   Úsegmentss     r'   Ú_flushContourÚ#BasePointToSegmentPen._flushContour|   s
   € ô4 "Ð!r&   c                ó„  • U R                   c  [        S5      eU R                   nS U l         U(       d  g [        U5      S:X  a#  US   u  p#pEnSX$XV4/4/nU R                  U5        g / nUS   S   S:X  a1  US   u  p#pEnUR	                  SX$XV4/45        UR                  S5        OPS n[        [        U5      5       H  n	X   S   nUc  M  U	n  O   Uc  UR	                  S5        OXS-   S  US US-    -   n/ n
U H3  u  p#pEnU
R	                  X$XV45        Uc  M  UR	                  X:45        / n
M5     U R                  U5        g )NzPath not begun.é   r   Úmove)NÚqcurveNNN)rX   r   Úlenr_   ÚappendÚpopÚrange)r.   Úpointsr:   r;   r<   r=   r0   r^   ÚfirstOnCurveÚiÚcurrentSegments              r'   r6   ÚBasePointToSegmentPen.endPath˜   s‚  € Ø×ÑÑ#ÜÐ,Ó-Ð-Ø×!Ñ!ˆØˆÔÞØÜˆv‹;˜!Óà4:¸1±IÑ1ˆB˜V¨6Ø&,°¸DÐ/IÐ.JÐ%KÐ$LˆHØ×Ñ˜xÔ(ØØˆØ�!‰9�Q‰<˜6Ó!ð 5;¸1±IÑ1ˆB˜V¨6Ø�O‰O˜V r°4Ð&@Ð%AÐBÔCØ�J‰J�q�Mð
  ˆLÜœ3˜v›;Ö'�Ø$™i¨™l�ØÓ*Ø#$�LÙñ	 (ð
 Ñ#ð —‘Ð@ÕAà¨qÑ 0Ð 2Ð3°fÐ=O¸|ÈaÑ?OÐ6PÑP�à+-ˆÛ5;Ñ1ˆB˜V¨6Ø×!Ñ! 2¨tÐ"<Ô=ØÑ"ÙØ�O‰O˜[Ð9Ô:ØŠNñ 6<ð 	×Ñ˜8Õ$r&   c                óp   • U R                   c  [        S5      eU R                   R                  XX4U45        g ©NúPath not begun)rX   r   rf   r9   s          r'   r>   ÚBasePointToSegmentPen.addPointÈ   s7   € ð ×ÑÑ#ÜÐ+Ó,Ð,Ø×Ñ×Ñ °&ÀÐ GÕHr&   rW   rP   rL   )r^   ÚSegmentListrN   rO   rQ   )r   r   r   r    r!   rY   r1   r_   r6   r>   r%   r   r&   r'   r   r   k   s)   † ñô ôô
"ô8.%ðb IM÷Ir&   r   c                  ó6   • \ rS rSrSrSS	S jjrS rS
S jrSrg)r   éÐ   z¬
Adapter class that converts the PointPen protocol to the
(Segment)Pen protocol.

NOTE: The segment pen does not support and will drop point names, identifiers
and kwargs.
c                óF   • [         R                  U 5        Xl        X l        g rL   )r   rY   ÚpenÚoutputImpliedClosingLine)r.   Ú
segmentPenrw   s      r'   rY   ÚPointToSegmentPen.__init__Ù   s   € Ü×&Ñ& tÔ,ØŒØ(@Õ%r&   c           	     ób  • U(       d  [        S5      eU R                  nUS   S   S:X  a>  SnUS   S   n[        U5      S:w  a  [        S[        U5       35      eUS   u  n    nUS	 OSnUS   u  ptUS   u  n    nUc  OUR                  U5        U R                  n[        U5      n	Un
[        U	5       HÉ  nX   u  ptU VVs/ s H	  u  n    olPM     nnnUS	:X  a^  [        U5      S:w  a  [        S
[        U5       35      eUS   nUS-   U	:w  d  U(       d  U(       a  XÊ:X  a  UR                  U5        Un
Mƒ  M…  US:X  a  UR                  " U6   US   n
M¡  US:X  a  UR                  " U6   US   n
M½  [        SU 35      e   U(       a  UR                  5         g UR                  5         g s  snnf )NzMust have at least one segment.r   rc   Frb   z"Illegal move segment point count: TéÿÿÿÿÚlinez"Illegal line segment point count: Úcurverd   zIllegal segmentType: )r   rv   re   ÚmoveTorw   rh   ÚlineToÚcurveToÚqCurveToÚ	closePathr6   )r.   r^   rv   Úclosedri   ÚmovePtÚ_r;   rw   Ú	nSegmentsÚlastPtrk   r:   s                r'   r_   ÚPointToSegmentPen._flushContourÞ   sÏ  € ÞÜÐ<Ó=Ð=Ø�h‰hˆØ�A‰;�q‰>˜VÓ#àˆFØ˜a‘[ ‘^ˆFÜ�6‹{˜aÓÜÐ!CÄCÈÃKÀ=ÐQÓRÐRØ$ Q™i‰OˆF�A�q˜!Ø˜‘ð ˆFØ"*¨2¡,ÑˆKØ$ R™j‰OˆF�A�q˜!Ø‰>ð à�J‰J�vÔØ#'×#@Ñ#@Ð Ü˜“Mˆ	ØˆÜ�yÖ!ˆAØ"*¡+ÑˆKÙ,2Ô3ªF™[˜R  A q’b©FˆFÑ3Ø˜fÓ$Ü�v“; !Ó#Ü"Ð%GÌÈFËÀ}Ð#UÓVÐVØ˜A‘Y�ð ˜‘E˜YÓ&Þ/Þ!Ø“|à—J‘J˜r”NØ’Fñ $ð  Ó'Ø—’˜VÑ$Ø ™’Ø Ó(Ø—’˜fÑ%Ø ™’äÐ!6°{°mÐDÓEÐEñ? "ö@ Ø�M‰M�Oà�K‰K�MùóC 4s   ÃF+Nc                ó>   • AAU R                   R                  X5        g rL   )rv   rC   ©r.   rH   Ú	transformr/   r0   s        r'   rC   ÚPointToSegmentPen.addComponent  s   € ØØØ�‰×Ñ˜iÕ3r&   )rw   rv   )F)rw   rR   rN   rO   rL   )	r   r   r   r    r!   rY   r_   rC   r%   r   r&   r'   r   r   Ð   s   † ñöAò
?÷B4r&   r   c                  óZ   • \ rS rSrSrSSS jjrSS jrS rS rS r	S r
S	 rS
 rS rSrg)r   i%  zQ
Adapter class that converts the (Segment)Pen protocol to the
PointPen protocol.
c                óN   • U(       a  [        U5      U l        OXl        S U l        g rL   )r   rv   Úcontour)r.   ÚpointPenÚguessSmooths      r'   rY   ÚSegmentToPointPen.__init__+  s   € ÞÜ*¨8Ó4ˆD�HàŒHØBFˆ�r&   c                ó¤   • U R                   nUR                  5         U R                   H  u  p#UR                  X#S9  M     UR	                  5         g )N)r;   )rv   r1   r�   r>   r6   )r.   rv   r:   r;   s       r'   r_   ÚSegmentToPointPen._flushContour2  s;   € Ø�h‰hˆØ�‰ŒØ#Ÿ|œ|‰OˆBØ�L‰L˜ˆLÓ5ñ  ,à�‰�r&   c                óL   • / U l         U R                   R                  US45        g )Nrc   )r�   rf   ©r.   r:   s     r'   r~   ÚSegmentToPointPen.moveTo9  s   € ØˆŒØ�‰×Ñ˜R ˜LÕ)r&   c                ón   • U R                   c  [        S5      eU R                   R                  US45        g )Nú'Contour missing required initial moveTor|   )r�   r   rf   r–   s     r'   r   ÚSegmentToPointPen.lineTo=  s.   € Ø�<‰<ÑÜÐDÓEÐEØ�‰×Ñ˜R ˜LÕ)r&   c                óê   • U(       d  [        S5      eU R                  c  [        S5      eUS S  H   nU R                  R                  US 45        M"     U R                  R                  US   S45        g )NúMust pass in at least one pointr™   r{   r}   ©Ú	TypeErrorr�   r   rf   ©r.   Úptsr:   s      r'   r€   ÚSegmentToPointPen.curveToB  sh   € ÞÜÐ=Ó>Ð>Ø�<‰<ÑÜÐDÓEÐEØ�c�r“(ˆBØ�L‰L×Ñ  T 
Ö+ñ à�‰×Ñ˜S ™W gÐ.Õ/r&   c                ó  • U(       d  [        S5      eUS   c  / U l        OU R                  c  [        S5      eUS S  H   nU R                  R                  US 45        M"     US   b!  U R                  R                  US   S45        g g )Nrœ   r{   r™   rd   r�   rŸ   s      r'   r�   ÚSegmentToPointPen.qCurveToK  s‡   € ÞÜÐ=Ó>Ð>Øˆr‰7‰?ØˆD�Là�|‰|Ñ#ÜÐHÓIÐIØ�c�r“(ˆBØ�L‰L×Ñ  T 
Ö+ñ àˆr‰7ÑØ�L‰L×Ñ  R¡¨(Ð 3Õ4ð r&   c                ó„  • U R                   c  [        S5      e[        U R                   5      S:”  aP  U R                   S   S   U R                   S   S   :X  a*  U R                   S   U R                   S'   U R                   S	 O(U R                   S   u  pUS:X  a  US4U R                   S'   U R                  5         S U l         g )Nr™   rb   r   r{   rc   r|   )r�   r   re   r_   )r.   r:   Útps      r'   r‚   ÚSegmentToPointPen.closePathX  s©   € Ø�<‰<ÑÜÐDÓEÐEÜˆt�|‰|Ó˜qÓ  T§\¡\°!¡_°QÑ%7¸4¿<¹<ÈÑ;KÈAÑ;NÓ%NØ"Ÿl™l¨2Ñ.ˆD�L‰L˜‰OØ—‘˜RÑ ð —\‘\ !‘_‰FˆBØ�V‹|Ø"$ f *�—‘˜Q‘Ø×ÑÔØˆ�r&   c                ób   • U R                   c  [        S5      eU R                  5         S U l         g )Nr™   )r�   r   r_   r5   s    r'   r6   ÚSegmentToPointPen.endPathg  s+   € Ø�<‰<ÑÜÐDÓEÐEØ×ÑÔØˆ�r&   c                ój   • U R                   b  [        S5      eU R                  R                  X5        g )Nú1Components must be added before or after contours)r�   r   rv   rC   )r.   rH   r‹   s      r'   rC   ÚSegmentToPointPen.addComponentm  s*   € Ø�<‰<Ñ#ÜÐNÓOÐOØ�‰×Ñ˜iÕ3r&   )r�   rv   N)TrP   )r   r   r   r    r!   rY   r_   r~   r   r€   r�   r‚   r6   rC   r%   r   r&   r'   r   r   %  s5   † ñö
Gôò*ò*ò
0ò5òòõ4r&   r   c                  óZ   • \ rS rSrSrSS jrS rSS jrS r SS jr	SS	 jr
 SS
 jrSrg)r   is  zŽ
Filtering PointPen that tries to determine whether an on-curve point
should be "smooth", ie. that it's a "tangent" point or a "curve" point.
c                ó*   • Xl         X l        S U l        g rL   )Ú_outPenÚ_errorÚ_points)r.   ÚoutPenÚerrors      r'   rY   ÚGuessSmoothPointPen.__init__y  s   € ØŒØŒØˆ�r&   c                óÖ  • U R                   c  [        S5      eU R                   n[        U5      nU(       d  g US   S   S:X  a  [        SUS-
  5      nOUS:”  a  [        SUS-
  5      nO/ nU HÌ  nX   u  pVpxn	Uc  M  US-
  n
US-   nX   S   b
  X   S   b  M,  X   S   nX   S   nX   S   nX\:w  d  MH  X]:w  d  MO  US   US   -
  US   US   -
  pþUS   US   -
  US   US   -
  nn[        R
                  " Xþ5      n[        R
                  " UU5      n[        UU-
  5      U R                  :  d  MÅ  XVSX‰4X'   MÎ     U H&  u  pVnp‰U R                  R                  " XVUU40 U	D6  M(     g )Nrp   r   rb   rc   r{   T)
r°   r   re   rh   ÚmathÚatan2Úabsr¯   r®   r>   )r.   ri   ÚnPointsÚindicesrk   r:   r;   r…   r=   r0   ÚprevÚnextÚprevPtÚnextPtÚdx1Údy1Údx2Údy2Úa1Úa2r<   s                        r'   r_   Ú!GuessSmoothPointPen._flushContour~  s™  € Ø�<‰<ÑÜÐ+Ó,Ð,Ø—‘ˆÜ�f“+ˆÞØØ�!‰9�Q‰<˜6Ó!ä˜A˜w¨™{Ó+‰GØ�q‹[ô ˜B ¨!¡Ó,‰Gð ˆGÛˆAØ/5©yÑ,ˆB˜Q fØÑ"ÙØ�q‘5ˆDØ�q‘5ˆDØ‰|˜A‰Ñ*¨v©|¸A©Ñ/JÙà‘˜1‘ˆBØ‘\ !‘_ˆFØ‘\ !‘_ˆFØ�| ¥Ø˜a™5 6¨!¡9Ñ,¨b°©e°f¸Q±iÑ.?�SØ! !™9 r¨!¡uÑ,¨f°Q©i¸"¸Q¹%Ñ.?�S�Ü—Z’Z Ó)�Ü—Z’Z  SÓ)�Ü�r˜B‘w“< $§+¡+Õ-Ø "°°tÐ C�F“Iñ% ó( 6<Ñ1ˆB˜V TØ�L‰L×!Ò! "°6¸4ÑJÀ6ÔJò 6<r&   Nc                óˆ   • U R                   b  [        S5      e/ U l         Ub  XS'   U R                  R                  " S0 UD6  g )NúPath already begunr/   r   )r°   r   r®   r1   r-   s      r'   r1   ÚGuessSmoothPointPen.beginPath¦  sB   € Ø�<‰<Ñ#ÜÐ/Ó0Ð0ØˆŒØÑ!Ø#-�<Ñ Ø�‰×ÒÑ( Ó(r&   c                óf   • U R                  5         U R                  R                  5         S U l        g rL   )r_   r®   r6   r°   r5   s    r'   r6   ÚGuessSmoothPointPen.endPath®  s%   € Ø×ÑÔØ�‰×ÑÔØˆ�r&   c                ó~   • U R                   c  [        S5      eUb  XVS'   U R                   R                  XSXF45        g )Nrp   r/   F)r°   r   rf   r9   s          r'   r>   ÚGuessSmoothPointPen.addPoint³  sA   € ð �<‰<ÑÜÐ+Ó,Ð,ØÑ!Ø#-�<Ñ Ø�‰×Ñ˜R¨e°TÐBÕCr&   c                ó|   • U R                   b  [        S5      eUb  X4S'   U R                  R                  " X40 UD6  g ©Nrª   r/   )r°   r   r®   rC   )r.   rH   rB   r/   r0   s        r'   rC   Ú GuessSmoothPointPen.addComponent¼  s=   € Ø�<‰<Ñ#ÜÐNÓOÐOØÑ!Ø#-�<Ñ Ø�‰×!Ò! )ÑF¸vÓFr&   c                ó~   • U R                   b  [        S5      eUb  XES'   U R                  R                  " XU40 UD6  g )Nz4VarComponents must be added before or after contoursr/   )r°   r   r®   rJ   rG   s         r'   rJ   Ú#GuessSmoothPointPen.addVarComponentÃ  sA   € ð �<‰<Ñ#ÜÐQÓRÐRØÑ!Ø#-�<Ñ Ø�‰×$Ò$ YÀÑSÈFÓSr&   )r¯   r®   r°   )gš™™™™™©?rL   rQ   )r   r   r   r    r!   rY   r_   r1   r6   r>   rC   rJ   r%   r   r&   r'   r   r   s  s<   † ñô
ò
&KôP)òð IMôDôGð ?C÷Tr&   r   c                  óJ   • \ rS rSrSrS rS rSS jrS r SS jr	SS	 jr
S
rg)r   iÍ  a  
This is a PointPen that passes outline data to another PointPen, but
reversing the winding direction of all contours. Components are simply
passed through unchanged.

Closed contours are reversed in such a way that the first point remains
the first point.
c                ó   • Xl         S U l        g rL   )rv   ÚcurrentContour)r.   ÚoutputPointPens     r'   rY   ÚReverseContourPointPen.__init__×  s   € Ø!Œà"ˆÕr&   c                ó�  • U R                   nU R                  nU(       d*  UR                  U R                  S9  UR	                  5         g US   S   S:g  nU(       d  SnOVUR                  UR                  S5      5        S n[        [        U5      5       H  nX&   S   c  M  Un  O   Uc  S nOX%   S   nUR                  5         U(       d%  US   S   c  UR                  S5        US   S   c  M  UR                  U R                  S9  U H'  u  pxpšnUb  UnUnOS nUR                  " U4XÉU
S.UD6  M)     UR	                  5         g )N)r/   r   rb   rc   )r;   r<   r=   )rv   rÓ   r1   ÚcurrentContourIdentifierr6   rf   rg   rh   re   Úreverser>   )r.   rv   r�   rƒ   ÚlastSegmentTyperj   rk   r:   ÚnextSegmentTyper<   r=   r0   r;   s                r'   r_   Ú$ReverseContourPointPen._flushContourÜ  sP  € Ø�h‰hˆØ×%Ñ%ˆÞØ�M‰M T×%BÑ%BˆMÑCØ�K‰KŒMØà˜‘˜A‘ &Ñ(ˆÞØ$‰Oð �N‰N˜7Ÿ;™; q›>Ô*àˆLÜœ3˜w›<Ö(�Ø‘:˜a‘=Ó,Ø#$�LÙñ )ð Ñ#ð #'‘à")Ñ"7¸Ñ":�à�‰ÔÞð ˜!‘*˜Q‘-Ñ'Ø—‘˜A”ð ˜!‘*˜Q‘-Ó'à�‰ ×!>Ñ!>ˆÑ?Û9@Ñ5ˆB ¨vØÑ*Ø-�Ø"1‘à"�Ø�LŠLØðØ +ÀñØIOôñ :Að 	�‰�r&   Nc                ó\   • U R                   b  [        S5      e/ U l         Xl        / U l        g )NrÆ   )rÓ   r   r×   ÚonCurver-   s      r'   r1   Ú ReverseContourPointPen.beginPath  s/   € Ø×ÑÑ*ÜÐ/Ó0Ð0Ø ˆÔØ(2Ô%Øˆ�r&   c                ób   • U R                   c  [        S5      eU R                  5         S U l         g ro   )rÓ   r   r_   r5   s    r'   r6   ÚReverseContourPointPen.endPath  s.   € Ø×ÑÑ&ÜÐ+Ó,Ð,Ø×ÑÔØ"ˆÕr&   c                ó~   • U R                   c  [        S5      eUb  XVS'   U R                   R                  XX4U45        g )Nrp   r/   )rÓ   r   rf   r9   s          r'   r>   ÚReverseContourPointPen.addPoint  sE   € ð ×ÑÑ&ÜÐ+Ó,Ð,ØÑ!Ø#-�<Ñ Ø×Ñ×"Ñ" B°VÀ6Ð#JÕKr&   c                ór   • U R                   b  [        S5      eU R                  R                  " X4SU0UD6  g rÍ   )rÓ   r   rv   rC   rŠ   s        r'   rC   Ú#ReverseContourPointPen.addComponent$  s6   € Ø×ÑÑ*ÜÐNÓOÐOØ�‰×Ò˜iÑT¸zÐTÈVÓTr&   )rÓ   r×   rÝ   rv   rL   rQ   )r   r   r   r    r!   rY   r_   r1   r6   r>   rC   r%   r   r&   r'   r   r   Í  s/   † ñò#ò
0ôdò#ð IMôL÷Ur&   r   c                  óN   ^ • \ rS rSrSrSr\rSSS. S
U 4S jjjrSS jrS	r	U =r
$ )ÚDecomposingPointPeni*  a  Implements a 'addComponent' method that decomposes components
(i.e. draws them onto self as simple contours).
It can also be used as a mixin class (e.g. see DecomposingRecordingPointPen).

You must override beginPath, addPoint, endPath. You may
additionally override addVarComponent and addComponent.

By default a warning message is logged when a base glyph is missing;
set the class variable ``skipMissingComponents`` to False if you want
all instances of a sub-class to raise a :class:`MissingComponentError`
exception by default.
TNF)ÚskipMissingComponentsÚreverseFlippedc               óþ   >• [         TU ]  " U0 UD6  Xl        Uc  U R                  R                  OUU l        USL a  [
        R                  U l        gUSL a  [
        R                  U l        g[        U5      U l        g)aå  Takes a 'glyphSet' argument (dict), in which the glyphs that are referenced
as components are looked up by their name.

If the optional 'reverseFlipped' argument is True or a ReverseFlipped enum value,
components whose transformation matrix has a negative determinant will be decomposed
with a reversed path direction to compensate for the flip.

The reverseFlipped parameter can be:
- False or ReverseFlipped.NO: Don't reverse flipped components
- True or ReverseFlipped.KEEP_START: Reverse, keeping original starting point
- ReverseFlipped.ON_CURVE_FIRST: Reverse, ensuring first point is on-curve

The optional 'skipMissingComponents' argument can be set to True/False to
override the homonymous class attribute for a given pen instance.
NFT)	ÚsuperrY   ÚglyphSetÚ	__class__rç   r   r"   rè   r#   )r.   rë   rç   rè   Úargsr0   rì   s         €r'   rY   ÚDecomposingPointPen.__init__<  sy   ø€ ô. 	‰Ò˜$Ð) &Ò)Ø Œð %Ñ,ð �N‰N×0Ò0à&ð 	Ô"ð ˜UÒ"Ü"0×"3Ñ"3ˆDÕØ˜tÒ#Ü"0×";Ñ";ˆDÕä"0°Ó"@ˆDÕr&   c                óâ  • SSK Jn   U R                  U   nU nU[        :w  a  U" Xr5      nU R                  [
        R                  :w  aL  USS u  p‰p«X‹-  Xš-  -
  S:  a7  [        U5      nU R                  [
        R                  :X  a  SSK	J
n  U" U5      nUR                  U5        g! [         a=    U R                  (       d  [        U5      eU R                  R!                  SU-  5         gf = f)z|Transform the points of the base glyph and draw it onto self.

The `identifier` parameter and any extra kwargs are ignored.
r   )ÚTransformPointPenNé   )ÚOnCurveFirstPointPenz,glyph '%s' is missing from glyphSet; skipped)ÚfontTools.pens.transformPenrð   rë   r   rè   r   r"   r   r$   ÚfontTools.pens.filterPenrò   Ú
drawPointsÚKeyErrorrç   r   ÚlogÚwarning)r.   rA   rB   r/   r0   rð   Úglyphrv   ÚaÚbÚcÚdrò   s                r'   rC   Ú DecomposingPointPen.addComponentb  sä   € õ
 	Bð	"Ø—M‘M -Ñ0ˆEð ˆCØ¤Ó)Ù'¨Ó<�Ø×"Ñ"¤n×&7Ñ&7Ó7ð ,¨B¨QÐ/‘
��aØ‘5˜1™5‘= 1Ó$Ü0°Ó5�Cà×*Ñ*¬n×.KÑ.KÓKÝQñ 3°3Ó7˜à×Ñ˜SÕ!øô1 ó 	Ø×-×-Ü+¨MÓ:Ð:Ø�H‰H×ÑØ>ÀÑNöð	ús   ˆB' Â'AC.Ã-C.)rë   rè   rç   )rè   zbool | ReverseFlippedrL   )r   r   r   r    r!   rç   r   rY   rC   r%   Ú__classcell__)rì   s   @r'   ræ   ræ   *  s@   ø† ñð !Ðà1Ðð #Ø05ñ$Að
 .÷$Að $A÷L!"ò !"r&   ræ   )&r!   Ú
__future__r   rµ   Útypingr   r   r   r   r   ÚfontTools.misc.enumToolsr	   ÚfontTools.misc.loggingToolsr
   ÚfontTools.misc.transformr   r   ÚfontTools.pens.basePenr   r   r   Ú__all__ÚfloatÚPointrS   Ú	PointNamerR   ÚSegmentPointListÚSegmentTyperr   r   r   r   r   r   r   r   ræ   r   r&   r'   Ú<module>r     sÿ   ðñõ #ã ß 3Õ 3å ,Ý 0ß Bß OÑ Oò€ð 	ˆe�UˆlÑ€Ø�S‰M€	à˜˜h u™o¨t°YÀÐCÑDÑEÐ Ø�s‰m€Ø�5˜Ð&6Ð6Ñ7Ñ8€ô
&�Wô 
&÷/ñ /ôdbIÐ,ô bIôJR4Ð-ô R4ôjK4˜ô K4ô\WTÐ*ô WTôtZUÐ-ô ZUôzY"˜(Ð$4õ Y"r&   