+
    f7iz c                   sP   R t ^ RIt^ RIHt ^ RIHt ^ RIHt ^ RIt^ RI	H
t
Ht ^ RIHt ^ RIHt ^ RIHt ^ R	IHt ^ R
IHt ^ RIHtHtHt ^ RIHtHtHt ^ RIHt ^ RI H!t! ^ RI"H#t# ^RI$H%t%H&t&H't'H(t(H)t) ^ RI*H+t,H-t.H/t0H1t2 ^ RI3H4t4H5t5 ^ RI6t6^ RI7t7^ RI8t8^ RI9t9^ RIH:t: ^ RI;H<t<H=t=H>t>H?t?H@t@ ]<'       d   ^ RIAHBtB ]6P                  ! ]D4      tE ! R R]:4      tF]! R. RO4      tGR]G! ]FP                  ^ ^^ 4      R]G! ]FP                  ^ ^^ 4      R]G! ]FP                  ^^^ 4      R]G! ]FP                  ^
^^4      R]G! ]FP                  ^
^^4      R]G! ]FP                  ^R^ 4      R]G! ]FP                  ^^^ 4      R ]G! ]FP                  ^ ^^ 4      R!]G! ]FP                  ^ ^^ 4      /	tQ^R" ^R# ^R$ ^R% /tR^R& ^R' ^R( ^R) /tSR* tTR+ tU ! R, R-4      tV ! R. R/4      tW ! R0 R1]X4      tY ! R2 R3]X4      tZ ! R4 R5]X4      t[ ! R6 R7][4      t\ ! R8 R9][4      t] ! R: R;]X4      t^ ! R< R=][4      t_ ! R> R?][4      t` ! R@ RA]%4      ta ! RB RC]a4      tb ! RD RE]a4      tc ! RF RG]a4      td ! RH RI]&4      teRJtf ! RK RL])! RM4      4      tg ! RN RO]%4      th ! RP RQ]%4      ti ! RR RS]&4      tj ! RT RU]&4      tk ! RV RW]&4      tl ! RX RY]&4      tm ! RZ R[]&4      tn ! R\ R]]%4      to ! R^ R_]%4      tp ! R` Ra]%4      tq ! Rb Rc]%4      tr ! Rd Re]4      ts ! Rf Rg])! RM4      4      tt ! Rh Ri])! RM4      4      tu ! Rj Rk]4      tv ! Rl Rm]4      tw ! Rn Ro]4      tx ! Rp Rq])! RM4      4      tyRrRRsRRIRRWRRtRRuRRvRRwRRxRRyRRzRR{RR|RR}RR~R/tzR t{R t|R t}R t~R tR tR^]|^]}^]~/R^]^]//tR tR t]! 4        R tR# )zfontTools.ttLib.tables.otTables -- A collection of classes representing the various
OpenType subtables.

Most are constructed upon import from data in otData.py, all are populated with
converter objects from otConverters.py.
N)IntEnum)reduce)radians)defaultdict
namedtuple)OPTIMIZE_FONT_SPEED)TupleVariation)dfs_base_table)quantizeRect)otRound)	TransformIdentityDecomposedTransform)	bytesjoinpadsafeEval)Vector)ControlBoundsPen)TransformPen)	BaseTableFormatSwitchingBaseTableValueRecordCountReference getFormatSwitchingBaseTableClass)fixedToFloatfloatToFixedfloatToFixedToStrstrToFixedToFloat)LookupDebugInfoLOOKUP_DEBUG_INFO_KEY)IntFlag)TYPE_CHECKINGIteratorListOptionalSet)_TTGlyphSetc                   sV    ] tR t^4t^t^t^t^t^t^ t	^@t
^tRtRtRtRtRtRtR	tR
tRtR# )VarComponentFlags Ni   i                 @  l      )__name__
__module____qualname____firstlineno__RESET_UNSPECIFIED_AXES	HAVE_AXESAXIS_VALUES_HAVE_VARIATIONTRANSFORM_HAS_VARIATIONHAVE_TRANSLATE_XHAVE_TRANSLATE_YHAVE_ROTATIONHAVE_CONDITIONHAVE_SCALE_XHAVE_SCALE_YHAVE_TCENTER_XHAVE_TCENTER_YGID_IS_24BITHAVE_SKEW_XHAVE_SKEW_YRESERVED_MASK__static_attributes__r&       F/usr/lib64/python3.14/site-packages/fontTools/ttLib/tables/otTables.pyr%   r%   4   sW    #I!'$MNLLNNLKK)MrA   r%   VarTransformMappingValuesZ
translateXZ
translateYZrotationscaleXscaleYZskewXZskewYZtCenterXZtCenterYc                 0    \         P                  ! R V 4      # >Bstructpackv   &rB   <lambda>rO   f       T1%rA   c                 rF   >HrI   rL   rN   rB   rO   rO   g   rP   rA   c                 s>    \         P                  ! R V 4      R,          # )>L   NNrI   rL   rN   rB   rO   rO   h   s    T1%b)rA   c                 rF   rS   rI   rL   rN   rB   rO   rO   i   rP   rA   c                 >    \         P                  ! R V 4      ^ ,          # rG   rJ   unpackrL   rN   rB   rO   rO   l       tQ'*rA   c                 rW   rQ   rX   rL   rN   rB   rO   rO   m   rZ   rA   c                 sL    \         P                  ! R RV ,           4      ^ ,          # )rS   s    rX   rL   rN   rB   rO   rO   n   s    tUQY/2rA   c                 rW   rV   rX   rL   rN   rB   rO   rO   o   rZ   rA   c                s   W,          pV^8  d   W!^,           3# V^8  d.   V^,
          ^,          W^,           ,          ,          V^,           3# V^8  dI   V^,
          ^,          W^,           ,          ^,          ,          W^,           ,          ,          V^,           3# V^8  de   V^,
          ^,          W^,           ,          ^,          ,          W^,           ,          ^,          ,          V V^,           ,          ,          V^,           3# V^,
          ^ ,          W^,           ,          ^,          ,          W^,           ,          ^,          ,          V V^,           ,          ^,          ,          W^,           ,          ,          V^,           3# )zdRead a variable-length number from data starting at index i.

Return the number and the next index.
r&   )dataiZb0   && rB   _read_uint32varr^   s   sD    
B	Dyq5y	dT	a$1u+-q1u44	dT	b 4A;!#33dq5kA1q5HH	dT	b 4A;"#44tE{a7GG$EK
 
q5 	 T	b 4A;"#44tE{b7HH4EL
L !e!e$ 	$rA   c                s   V ^8  d   \         P                  ! RV 4      # V R8  d   \         P                  ! RV R,          4      # V R8  d&   \         P                  ! RV R,          4      R,          # V R	8  d   \         P                  ! RV R
,          4      # \         P                  ! R^4      \         P                  ! RV 4      ,           # )z2Write a variable-length number.

Return the data.
rH   r+   rR      i    rS   i   rT   i   l      @ rI   rL   rN   rB   _write_uint32varr`      s    
 	4x{{4##	
V{{4!f*..	
X{{4!h,044	
Z{{4!j.22{{4&T1)===rA   c                   sZ   a  ] tR t^t o R tRR ltR tR tR tR t	R t
R	 tR
 tRtV tR# )VarComponentc                s&    V P                  4        R # N)populateDefaultsselfrN   rB   __init__ZVarComponent.__init__   s    rA   Nc                s    ^ V n         RV n        RV n        RV n        RV n        \
        V n        \
        V n        \        4       V n	        R# )    Nr&   )
flags	glyphNameconditionIndexaxisIndicesIndex
axisValuesNO_VARIATION_INDEXaxisValuesVarIndextransformVarIndexr   	transformre   Z
propagator   &&rB   rc   ZVarComponent.populateDefaults   sA    
" $"4!3,.rA   c                s  aaa ^ o\        SS4      w  V n        oV P                  oS\        P                  ,          '       d   ^M^p\        V,          ! SSSV,            4      pSV,          oVP
                  V,          V n        S\        P                  ,          '       d   \        SS4      w  V n        oS\        P                  ,          '       d   \        SS4      w  V n
        oMRV n
        V P                  f   ^ pM/VR,          P                  V P                  ,          p\        V4      pS\        P                  ,          '       dN   \        P                  ! VSS4      w  po\        ;QJ d    . R V 4       F  NK  	  5M! R V 4       4      V n        MRV n        \        V P                   4      V8X  g   Q hS\        P"                  ,          '       d   \        SS4      w  V n        oM\&        V n        S\        P(                  ,          '       d   \        SS4      w  V n        oM\&        V n        \-        4       V n        VVV3R lp	\0        P3                  4        F#  w  rV	! V4      p\5        V P.                  W4       K%  	  S\        P6                  ,          '       g&   V P.                  P8                  V P.                  n        S\        P<                  ,          pV'       d!   \        SS4      w  poW^,
          ,          pK(  SSR # )rg   NZAxisIndicesListc              3   :   "   T F  p\        V^4      x  K  	  R# 5ii   N)fi2fl.0rM      & rB   	<genexpr>Z)VarComponent.decompile.<locals>.<genexpr>   s     #E*QE!RLL*   c           	      s   < SV P                   ,          '       dY   \        \        P                  ! R SSS^,            4      ^ ,          V P                  4      V P
                  ,          pS^,          oV# V P                  # )>h)flagru   rJ   rY   fractionalBitsscaledefaultValue)valuesrM   r[   rh   r\      & rB   read_transform_componentZ8VarComponent.decompile.<locals>.read_transform_component   sn    v{{""dDQUO<Q?AVAV ll#  Q***rA   r&   )r^   rh   r%   r<   	_unpacker
glyphOrderri   r7   rj   r1   rk   ZItemlenr   ZdecompileDeltas_tuplerl   r2   rn   rm   r3   ro   r   rp   VAR_TRANSFORM_MAPPINGitemssetattrr9   rD   rE   r?   )re   r[   font
localStateZgidSizeglyphIDnumAxesZaxisIndicesrl   r   	attr_namemapping_valuesvalueZn_rh   r\   s   &f&&           @@rB   	decompileZVarComponent.decompile   sa   'a0
A

0====!1G$T!a'k%:;	W1$3333%4T1%="D$....'6tQ'?$D!1$(D!  (G$%67<<T=R=RSK+&G$....*;;GT1MMJ#e#E*#Eee#E*#EEDO DO4??#w...$????)8q)A&D#Q&8D#$<<<<(7a(@%D"A%7D",.	+ *?)D)D)F%I,^<EDNNI5 *G )6666$(NN$9$9DNN!%333"4+DAqQJAABxrA   c                s  a VP                   \        ,          p. pV P                  oVP                  V P                  4      pVR 8  d;   S\
        P                  ,          oVP                  \        ^,          ! V4      4       M:S\
        P                  ( ,          oVP                  \        ^,          ! V4      4       V P                  e<   S\
        P                  ,          oVP                  \        V P                  4      4       \        V P                  4      pV'       d   S\
        P                  ,          oVP                  \        V P                  4      4       TP                  \         P"                  ! V P                   Uu. uF  p\%        V^4      NK  	  upV'       * R7      4       MS\
        P                  ( ,          oV P&                  \(        8w  d=   S\
        P*                  ,          oVP                  \        V P&                  4      4       MS\
        P*                  ( ,          oV P,                  \(        8w  d=   S\
        P.                  ,          oVP                  \        V P,                  4      4       MS\
        P.                  ( ,          oV3R lp\0        P3                  4        F2  w  r\5        V P6                  V4      p
VP                  V! W4      4       K4  	  \        S4      \9        V4      ,           # u upi )  )ZoptimizeSizec                 s   < SVP                   ,          '       d<   \        P                  ! R \        WP                  ,          VP
                  4      4      # R# )r{   rA   )r|   rJ   rK   fl2fir~   r}   )r   r   rh   s   &&rB   write_transform_componentZ7VarComponent.compile.<locals>.write_transform_component  sA    v{{""{{% 4f6K6KL  rA   )Zcfgr   rh   
getGlyphIDri   r%   r<   append_packerrj   r7   r`   r   rl   r1   rk   r   ZcompileDeltaValues_r   rn   rm   r2   ro   r3   r   r   getattrrp   r   )re   r   ZoptimizeSpeedr[   r   r   rM   r   r   r   r   rh   s   &&         @rB   compileZVarComponent.compile   s<   !45

//$..1U?&333EKK
7+,'4444EKK
7+,*&555EKK()<)<=>doo&&000EKK()>)>?@KK22+/??;?aU1b\?;%2!2 '1111E""&88&AAAEKK()@)@AB'BBBBE!!%77&>>>EKK()?)?@A'????E	 *?)D)D)F%IDNNI6EKK1%HI *G  &488= <s   Lc                s
  a SP                  R V4       SP                  4        R
V3R llpV! RV P                  4       V P                  e   V! RV P                  4       V P                  e   V! RV P                  4       V P                  f(   V P
                  \        P                  ,          '       dd   V P
                  \        P                  ,          '       d   RpMR	pT! RV P                   Uu. uF  p\        \        V^4      4      NK  	  upV4       V P                  \        8w  d   V! RV P                  4       V P                  \        8w  d   V! RV P                  4       \        P                  4        F\  w  rgV P
                  VP                   ,          '       g   K*  \#        V P$                  V4      pV! V\        WWP&                  4      4       K^  	  SP)                  R 4       SP                  4        R# u upi )ra   c                 sl   < Ve/   SP                  V RV33V,           4       SP                  4        R # R # )Nr   )	simpletagnewline)namer   attrswriters   &&&rB   writeZ!VarComponent.toXML.<locals>.write-  s5       %(8':U'BC  !rA   ri   Nrj   rk   rl   rn   ro   r&   )r&   ))resetUnspecifiedAxesrU   )begintagr   ri   rj   rk   rh   r%   r0   rl   Zfloatfl2strrn   rm   ro   r   r   r|   r   rp   r}   endtag)re   r   ttFontr   r   rM   r   mappings   &f&&    rB   toXMLZVarComponent.toXML)  s   .	!
 	k4>>**"D$7$78  ,$d&;&;<!!-zz-DDDDzz-DDDD6,t O!va}!5 OQVW""&88&(?(?@!!%77%t'='=> #8"="="?IJJ--	2A)VA'='=>?	 #@ 	n%! !Ps   3H 
c                s   V Uu. uF  p\        V\        4      '       g   K  VNK  	  ppV P                  4        V EF  w  rpV'       d   Q hVR ,          pVR8X  d	   W`n        K)  VR8X  d   \	        V4      V n        KB  VR8X  d   \	        V4      V n        K[  VR8X  d   \        ;QJ d    . R \	        V4       4       F  NK  	  5M! R \	        V4       4       4      V n        \	        VP                  RR4      4      '       d*   V ;P                  \        P                  ,          un	        K  K  VR8X  d   \	        V4      V n        EK  VR	8X  d   \	        V4      V n        EK%  V\        9   dR   \        V P                   V\	        V4      4       V ;P                  \        V,          P"                  ,          un	        EK  Q T4       h	  R
# u upi )r   ri   rj   rk   rl   c              3   rs   rt   )str2flrv   rx   rB   ry   Z'VarComponent.fromXML.<locals>.<genexpr>b  s     'K{!q"{rz   r   Z0rn   ro   N)
isinstancer   rc   ri   r   rj   rk   rl   getrh   r%   r0   rn   ro   r   r   rp   r|   )re   r   r   contentr   crM      &&&&&  rB   fromXMLZVarComponent.fromXMLR  s_   %>gAu)=11g>$+ D;gA{"!"))&.qk#++(0%%"'%'Kx{'K%%'Kx{'K"KEII&<cBCCJJ"3"J"JJJ D--*21+',,)1!&..NNQK
 

3D9>>>

"d"u5 %,	 ?s
   GGc           	     s  a aa ^ oVVV 3R lp\         P                  4        F?  w  r4V! V4      p\        S P                  V\	        S P                  V4      V,           4       KA  	  S P
                  \        P                  ,          '       g&   S P                  P                  S P                  n	        S\        S4      8X  g   Q S\        S4      34       hR# )rg   c                 s   < SP                   V P                  ,          '       d:   \        SS,          V P                  4      V P                  ,          pS^,          oV# ^ # rU   )rh   r|   ru   r}   r~   )r   rM   deltasr\   re   r   rB   read_transform_component_deltaZIVarComponent.applyTransformDeltas.<locals>.read_transform_component_deltav  sF    zzFKK''&)V%:%:;fllJQrA   N)r   r   r   rp   r   rh   r%   r9   rD   rE   r   )re   r   r   r   r   r   r\   s   ff    @rB   applyTransformDeltasZ!VarComponent.applyTransformDeltass  s    	 *?)D)D)F%I2>BE	74>>9+MPU+U *G 

.;;;;$(NN$9$9DNN!CK1!S[!11rA   c                sr    \        V 4      \        V4      8w  d   \        # V P                  VP                  8H  # rb   )typeNotImplemented__dict__)re   otherrr   rB   __eq__ZVarComponent.__eq__  s+    :e$!!}}..rA   c                sJ    V P                  V4      pV\        J d   V# V'       * # rb   )r   r   )re   r   resultr]   rB   __ne__ZVarComponent.__ne__  s$    U#>1vA6zArA   )rk   rl   rn   rj   rh   ri   rp   ro   rb   )r,   r-   r.   r/   rf   rc   r   r   r   r   r   r   r   r@   __classdictcell____classdict__   @rB   ra   ra      s>      /DL89t'R#B2./
B BrA   ra   c                   B   a  ] tR tRt o R	R ltR tR tR tR tRt	V t
R# )
VarCompositeGlyphi  Nc                s,    Ve	   Wn         R # . V n         R # rb   
components)re   r   rr   rB   rf   ZVarCompositeGlyph.__init__  s    (2(>*BrA   c                s    . V n         V'       d:   \        4       pVP                  WV4      pV P                   P                  V4       KA  R # rb   )r   ra   r   r   )re   r[   r   r   	component   &&&& rB   r   ZVarCompositeGlyph.decompile  s<    $I&&t:>DOO""9- rA   c                s    . pV P                    F#  pVP                  VP                  V4      4       K%  	  \        V4      # rb   )r   r   r   r   )re   r   r[   r      &&  rB   r   ZVarCompositeGlyph.compile  s6    IKK	))$/0 )rA   c                s    VP                  R V4       VP                  4        \        V P                  4       F  w  rVVP	                  WRV3.4       K  	  VP                  R 4       VP                  4        R# )r   indexN)r   r   	enumerater   r   r   )re   	xmlWriterr   r   r   r\   r   r   rB   r   ZVarCompositeGlyph.toXML  sc    .6%doo6LAOOIwl^< 7,-rA   c                s    V Uu. uF  p\        V\        4      '       g   K  VNK  	  ppV FF  w  rpVR 8X  g   Q h\        4       pVP                  WW44       V P                  P                  V4       KH  	  R# u upi )ra   N)r   r   ra   r   r   r   )re   r   r   r   r   r   r   r   rB   r   ZVarCompositeGlyph.fromXML  sl    %>gAu)=11g>$+ D>)))$Id79OO""9-	 %, ?s
   A8A8r   rb   )r,   r-   r.   r/   rf   r   r   r   r   r@   r   r   r   rB   r   r     s$     G.. .rA   r   c                   &   a  ] tR tRt o R tRtV tR# )AATStateTablei  c                s0    / V n         . V n        . V n        R # rb   )GlyphClassesStatesPerGlyphLookupsrd   rN   rB   rf   ZAATStateTable.__init__  s    !rA   )r   r   r   Nr,   r-   r.   r/   rf   r@   r   r   r   rB   r   r     s     " "rA   r   c                   r   )AATStatei  c                s    / V n         R # rb   Transitionsrd   rN   rB   rf   ZAATState.__init__  s
    rA   r   Nr   r   r   rB   r   r     s      rA   r   c                   s@   a  ] tR tRt o Rt]R 4       tR tR tRt	V t
R# )	AATActioni  Nc                s    R# )NNNr&   )r   statesrr   rB   compileActionsZAATAction.compileActions  s    rA   c                s|   V P                    Uu. uF  q P                  V,          '       g   K  VNK!  	  ppV'       d3   VP                  R RP                  V4      R7       VP	                  4        V P
                  ^ 8w  d7   VP                  RRV P
                  ,          R7       VP	                  4        R# R# u upi )Flags,r   ReservedFlagsz0x%04XN)_FLAGSr   r   joinr   r   )re   r   frh   r   rB   _writeFlagsToXMLZAATAction._writeFlagsToXML  s     KK<Kq==+;+;K<sxx?"x$BTBT7TU #	 =s
   B9B9c                s`    WP                   9   g   Q R V,          4       hRV P                  V&   R# )zunsupported flag %sTN)r   r   re   r|   rr   rB   _setFlagZAATAction._setFlag  s+    {{"@$9D$@@""drA   r&   )r,   r-   r.   r/   r   staticmethodr   r   r   r@   r   r   r   rB   r   r     s+     F  # #rA   r   c                   s   a  ] tR tRt o ^t^ t. ROt/ ^ Rb^Rb^Rb^Rb^Rb^Rb^Rb^R	b^R
b^	Rb^
Rb^Rb^Rb^Rb^Rb^RbtR tR t	R t
R tR tRtV tR# )RearrangementMorphActioni  z	no changeu	   Ax ⇒ xAu	   xD ⇒ Dxu   AxD ⇒ DxAu   ABx ⇒ xABu   ABx ⇒ xBAu   xCD ⇒ CDxu   xCD ⇒ DCxu   AxCD ⇒ CDxAu   AxCD ⇒ DCxAu   ABxD ⇒ DxABu   ABxD ⇒ DxBAu   ABxCD ⇒ CDxABu   ABxCD ⇒ CDxBAu   ABxCD ⇒ DCxABu   ABxCD ⇒ DCxBAc                sZ    ^ V n         ^ V n        RV n        RV n        RV n        ^ V n        R# rg   FN)NewStateVerb	MarkFirstDontAdvanceMarkLastr   rd   rN   rB   rf   Z!RearrangementMorphAction.__init__  s.    	 rA   c                s   Ve   Q hVP                  V P                  4       V P                  ^ 8  d   V P                  ^8:  g   Q V P                  4       hV P                  V P                  ,          pV P                  '       d
   VR,          pV P
                  '       d
   VR,          pV P                  '       d
   VR,          pVP                  V4       R # Nr_   r+   r*   )writeUShortr   r   r   r   r   r   re   r   r   actionIndexrh   r   rB   r   Z RearrangementMorphAction.compile  s    """4==)yyA~$))r/<499<1		D...>>>VOEVOE===VOE5!rA   c                s   Ve   Q hVP                  4       V n        VP                  4       pV^,          V n        \        VR,          4      V n        \        VR,          4      V n        \        VR,          4      V n        VR,          V n        R # )Nr_   r+   r*   i  )
readUShortr   r   boolr   r   r   r   re   readerr   actionReaderrh   r   rB   r   Z"RearrangementMorphAction.decompile  st    ###))+!!#CK	efn-/UV^,"V^rA   c                s   VP                   ! V3/ VB  VP                  4        VP                  R V P                  R7       VP                  4        V P	                  V4       VP                  RV P
                  R7       V P                  P                  V P
                  4      pVe   VP                  V4       VP                  4        VP                  V4       VP                  4        R# )r   r   r   N)
r   r   r   r   r   r   _VERBSr   commentr   )re   r   r   r   r   ZverbComment   &&&&& rB   r   ZRearrangementMorphAction.toXML  s    4)5)Jdmm<i(F$))4kkoodii0"k*rA   c                s   ^ ;V n         ;V n        V n        R;V n        ;V n        V n        V Uu. uF  p\        V\        4      '       g   K  VNK  	  ppV F  w  rgpVR8X  d   \        VR,          4      V n         K&  VR8X  d   \        VR,          4      V n        KF  VR8X  d   \        VR,          4      V n        Kf  VR8X  g   Ko  VR,          P                  R4       F"  p	V P                  V	P                  4       4       K$  	  K  	  R# u upi )	rg   Fr   r   r   r   r   r   N)r   r   r   r   r   r   r   r   r   splitr   strip
re   r   r   r   r   teltNameeltAttrs
eltContentr|   
   &&&&&     rB   r   Z RearrangementMorphAction.fromXML  s    9:::	D$6<AAA)DM%>gAu)=11g>-4)Gz*$ ('): ;F"$Xg%67	O+%-hw.?%@"G#$W-33C8DMM$**,/ 9 .5 ?s   D	D	)r   r   r   r   r   r   N)r   r   r   )r,   r-   r.   r/   
staticSizeactionHeaderSizer   r   rf   r   r   r   r   r@   r   r   r   rB   r   r     s     J5F	;	; 	
; 	
=	
 	
= 	
= 	
= 	
= 	
? 	
? 	O 	O 	 	 	  	!F&",0 0rA   r   c                   sN   a  ] tR tRt o ^t^ tRR.tR tR tR t	R t
R tR	tV tR
# )ContextualMorphActioni,  SetMarkr   c                s^    ^ V n         RRuV n        V n        ^ V n        RRuV n        V n        R# )rg   Fr   N)r   r   r   r   	MarkIndexCurrentIndexrd   rN   rB   rf   ZContextualMorphAction.__init__1  s3    ).&d&,2F))rA   c                sZ   Ve   Q hVP                  V P                  4       V P                  pV P                  '       d
   VR,          pV P                  '       d
   VR,          pVP                  V4       VP                  V P
                  4       VP                  V P                  4       R # )Nr_   r+   )r   r   r   r   r   r   r   r   r   rB   r   ZContextualMorphAction.compile7  s    """4==)""<<<VOEVOE5!4>>*4,,-rA   c                s(   Ve   Q hVP                  4       V n        VP                  4       p\        VR,          4      V n        \        VR,          4      V n        VR,          V n        VP                  4       V n        VP                  4       V n        R # )Nr_   r+   i?  )r   r   r   r   r   r   r   r   r   r   rB   r   ZContextualMorphAction.decompileC  sz    ###))+!!#EFN+/"V^**,"--/rA   c                s   VP                   ! V3/ VB  VP                  4        VP                  R V P                  R7       VP                  4        V P	                  V4       VP                  RV P
                  R7       VP                  4        VP                  RV P                  R7       VP                  4        VP                  V4       VP                  4        R# )r   r   r   r   N)r   r   r   r   r   r   r   r   re   r   r   r   r      &&&&&rB   r   ZContextualMorphAction.toXMLM  s    4)5)Jdmm<i(Kt~~>N$2C2CDrA   c                s^   ^ ;V n         V n        R;V n        V n        RRuV n        V n        V Uu. uF  p\        V\        4      '       g   K  VNK  	  ppV F  w  rgpVR8X  d   \        VR,          4      V n         K&  VR8X  dA   VR,          P                  R4       F"  p	V P                  V	P                  4       4       K$  	  Km  VR8X  d   \        VR,          4      V n        K  VR8X  d   \        VR,          4      V n        K  VR	8X  g   K  \        VR,          4      V n        K  	  R
# u upi )rg   Fr   r   r   r   r   r   r   r   N)r   r   r   r   r   r   r   r   r   r   r   r   r   r   rB   r   ZContextualMorphAction.fromXMLZ  s    -..**//t',2F))%>gAu)=11g>-4)Gz*$ ('): ;G#$W-33C8DMM$**,/ 9O+%-hw.?%@"K'!)(7*;!<N*$,Xg->$?! .5 ?s   D*D*)r   r   r   r   r   r   N)r,   r-   r.   r/   r   r   r   rf   r   r   r   r   r@   r   r   r   rB   r   r   ,  s:     J'F;
.0@ @rA   r   c                   r   )	LigActionim  c                s"    R V n         ^ V n        R# )FN)StoreGlyphIndexDeltard   rN   rB   rf   ZLigAction.__init__n  s    
  !rA   )r  r  Nr   r   r   rB   r  r  m  s     ! !rA   r  c                   sj   a  ] tR tRt o ^t^tRR.tR tR tR t	]
R 4       tR tR	 tR
 tR tRtV tR# )LigatureMorphActioni|  SetComponentr   c                sN    ^ V n         RRuV n        V n        ^ V n        . V n        R# r   )r   r  r   r   Actionsrd   rN   rB   rf   ZLigatureMorphAction.__init__  s*    .3U+4+rA   c                s   Vf   Q hVP                  V P                  4       V P                  pV P                  '       d
   VR,          pV P                  '       d
   VR,          p\        V P                  4      ^ 8  d
   VR,          pVP                  V4       \        V P                  4      ^ 8  d*   V P                  4       pVP                  W5,          4       R # VP                  ^ 4       R # r   )r   r   r   r  r   r   r  compileLigActions)re   r   r   r   rh   actionss   &&&&  rB   r   ZLigatureMorphAction.compile  s    &&&4==)""VOEVOEt||q VOE5!t||q ,,.G{34q!rA   c                sf   Vf   Q hVP                  4       V n        VP                  4       p\        VR,          4      V n        \        VR,          4      V n        \        VR,          4      pVR,          V n        VP                  4       pV'       d   V P                  W64      V n        R # . V n        R # )Nr_   r+   r*   i  )r   r   r   r  r   r   _decompileLigActionsr  )re   r   r   r   rh   ZperformActionr      &&&&   rB   r   ZLigatureMorphAction.decompile  s    '''))+!!# 0/UV^, #V^'')44\ODLDLrA   c                s   R \        4       / rCpV FE  pVP                  P                  4        F$  w  rgVP                  VP	                  4       4       K&  	  KG  	  \        VR R7       F^  pW9  g   K  \        ^ \        V4      ^4       F1  p	WR p
\        V4      V	,           ^,          pVP                  W4       K3  	  W(,          pK`  	  \        V^4      pW$3# )rA   c                     \        V 4      ) V 3# rb   r   ZxrN   rB   rO   Z4LigatureMorphAction.compileActions.<locals>.<lambda>  s    Q|rA   keyN)
setr   r   addr	  sortedranger   
setdefaultr   )r   r   r   r
  r   state_glyphClasstransar\   ZsuffixZsuffixIndex   &&          rB   r   Z"LigatureMorphAction.compileActions  s    '*CE2E&+&7&7&=&=&?"E3356 '@  %;<A#q#a&!,ArUF#&v;?q"8K**6? -  = VQ$$rA   c                sd   . p\        V P                  4       F  w  r#V\        V P                  4      ^,
          8H  pVP                  R,          pYT'       d   RM^ ,          pYSP                  '       d   RM^ ,          pVP                  \        P                  ! RV4      4       K  	  \        V4      # )rU   ?           @rS   )	r   r  r   r  r  r   rJ   rK   r   )re   r   r\   actionlastr      &     rB   r	  Z%LigatureMorphAction.compileLigActions  s    "4<<0IADLL)A--D**Z7E4ZQ.E<<<ZQ6EMM&++dE23 1   rA   c                sZ   . pR pVP                  VP                  V^,          ,           4      pV'       gv   VP                  4       p\        VR,          4      p\	        4       pVP                  V4       \        VR,          4      Vn        VR,          pVR8  d
   RV,           pWn        K}  V# )Fr  r  r  i    i   )getSubReaderposZ	readULongr   r  r   r  r  )	re   r   r   r
  r   r   r   r  delta	   &&&      rB   r  Z(LigatureMorphAction._decompileLigActions  s    **<+;+;kAo+MN$$&E
*+D[FNN6"
 23FLJ&E
"#e+%*"rA   c                s   ^ ;V n         V n        R;V n        V n        ^ V n        . V n        V Uu. uF  p\        V\        4      '       g   K  VNK  	  ppV EF  w  rgpVR8X  d   \        VR,          4      V n         K'  VR8X  dA   VR,          P                  R4       F"  p	V P                  V	P                  4       4       K$  	  Kn  VR8X  d   \        VR,          4      V n        K  VR8X  g   K  \        4       p
VP                  RR4      P                  R4      pV Uu. uF  qP                  4       NK  	  ppR	V9   V
n        \        VR
,          4      V
n        V P                  P                  V
4       EK  	  R# u upi u upi )rg   Fr   r   r   r   r   ActionZ r  r  N)r   r   r  r   r  r   r   r   r   r   r   r  r   r  r  r   )re   r   r   r   r   r   r   r   r   r|   r  rh   r   s   &&&&&        rB   r   ZLigatureMorphAction.fromXML  sB   -..*/44D,%>gAu)=11g>-4)Gz*$ ('): ;G#$W-33C8DMM$**,/ 9O+%-hw.?%@"H$" Wb177<,12EqE2&%/)1(;L2M)N&##F+ .5 ? 3s   E9E9E>c                s   VP                   ! V3/ VB  VP                  4        VP                  R V P                  R7       VP                  4        V P	                  V4       V P
                   FW  pRVP                  3.pVP                  '       d   VP                  R4       VP                  RV4       VP                  4        KY  	  VP                  V4       VP                  4        R# )r   r   r  r&  N)r   r  )
r   r   r   r   r   r  r  r  r   r   )re   r   r   r   r   r  Zattribsr   rB   r   ZLigatureMorphAction.toXML  s    4)5)Jdmm<i(llF)6+A+ABCG|||12'2 # 	rA   )r  r   r   r   r  N)r,   r-   r.   r/   r   r   r   rf   r   r   r   r   r	  r  r   r   r@   r   r   r   rB   r  r  |  sX     J m,F""& % %4! ,, rA   r  c                   sd   a  ] tR tRt o ^t^t. ROtR tR tR t	R t
R tR t]R 4       tR	tV tR
# )InsertionMorphActioni	  c                s~    ^ V n         V P                   F  p\        WR4       K  	  ^ V n        . . uV n        V n        R# r   )r   r   r   r   CurrentInsertionActionMarkedInsertionActionr   rx   rB   rf   ZInsertionMorphAction.__init__  s;    KKDD&  BDb?#T%?rA   c                sl   Vf   Q hVP                  V P                  4       V P                  pV P                  '       d
   VR,          pV P                  '       d
   VR,          pV P
                  '       d
   VR,          pV P                  '       d
   VR,          pV P                  '       d
   VR,          pV P                  '       d
   VR,          pV\        V P                  4      ^,          ,          pV\        V P                  4      ,          pVP                  V4       \        V P                  4      ^ 8  d   V\        V P                  4      ,          pMRpVP                  V4       \        V P                  4      ^ 8  d   V\        V P                  4      ,          pMRpVP                  V4       R # )Nr_   r+   r*   r)   r(   r'   r   )r   r   r   r   r   CurrentIsKashidaLikeMarkedIsKashidaLikeCurrentInsertBeforeMarkedInsertBeforer   r(  r)  r   )re   r   r   r   rh   ZcurrentIndexZmarkedIndexr  rB   r   ZInsertionMorphAction.compile  sY   &&&4==)""<<<VOEVOE$$$VOE###VOE###VOE"""VOET001Q66T//005!t**+a/&uT-H-H'IJL!L<(t))*Q.%eD,F,F&GHK K;'rA   c                s6   Vf   Q hVP                  4       V n        VP                  4       p\        VR,          4      V n        \        VR,          4      V n        \        VR,          4      V n        \        VR,          4      V n        \        VR,          4      V n        \        VR,          4      V n        V P                  W2VP                  4       VR,          ^,	          R7      V n
        V P                  W2VP                  4       V^,          R7      V n        R # )	Nr_   r+   r*   r)   r(   r'   i  )r   count)r   r   r   r   r   r*  r+  r,  r-  _decompileInsertionActionr(  r)  r   r   rB   r   ZInsertionMorphAction.decompile:  s    '''))+!!#EFN+/$($8!#'#7 #'#7 "&uv~"6&*&D&Df&7&7&956>VWBW 'E '
# &*%C%Cf&7&7&9%&. &D &
"rA   c                s    VR 8X  g   V^ 8X  d   . # VP                  VP                  V^,          ,           4      pVP                  VP                  V4      4      # )r   )r"  r#  getGlyphNameManyZreadUShortArray)re   r   r   r   r.  r   r   rB   r/  Z.InsertionMorphAction._decompileInsertionActionK  sO    F?eqjI**<+;+;eai+GH$$V%;%;E%BCCrA   c                s   VP                   ! V3/ VB  VP                  4        VP                  R V P                  R7       VP                  4        V P	                  V4       V P
                   F&  pVP                  RVR7       VP                  4        K(  	  V P                   F&  pVP                  RVR7       VP                  4        K(  	  VP                  V4       VP                  4        R# )r   r   r(  glyphr)  N)r   r   r   r   r   r(  r)  r   )re   r   r   r   r   gr   rB   r   ZInsertionMorphAction.toXMLQ  s    4)5)Jdmm<i(,,A 8B - ++A 7qA , 	rA   c                s   V P                  4        V Uu. uF  p\        V\        4      '       g   K  VNK  	  ppV F  w  rgpVR 8X  d   \        VR,          4      V n        K&  VR8X  dA   VR,          P                  R4       F"  p	V P                  V	P                  4       4       K$  	  Km  VR8X  d%   V P                  P                  VR,          4       K  VR8X  d%   V P                  P                  VR,          4       K  Q T4       h	  R# u upi )r   r   r   r   r(  r2  r)  N)rf   r   r   r   r   r   r   r   r(  r   r)  r   r   rB   r   ZInsertionMorphAction.fromXML`  s    %>gAu)=11g>-4)Gz*$ ('): ;G#$W-33C8DMM$**,/ 944++228G3DE33**11(72CD%g%u .5 ?s
   D
D
c                s   \        4       / R rCpV F  pVP                  P                  4        Fk  w  rgVP                  e%   VP	                  \        VP                  4      4       VP                  f   KG  VP	                  \        VP                  4      4       Km  	  K  	  \        VR R7       F  pW9   d   K  \        ^ \        V4      4       FT  p	\        V4      ^,          V	,           p
\        V	\        V4      4       F  pWV^,            pVP                  W4       K!  	  KV  	  V F2  pV P                  V4      pV\        P                  ! RV4      ,          pK4  	  K  	  WC3# )rA   c                 r  rb   r  r  rN   rB   rO   Z5InsertionMorphAction.compileActions.<locals>.<lambda>|  s    c!fWaLrA   r  rR   )r  r   r   r(  r  r   r)  r  r  r   r  r   rJ   rK   )r   r   r
  r   r   r  r  r  r  startZ
startIndexZlimitglyphsr2  r      &&             rB   r   Z#InsertionMorphAction.compileActionsp  s/   '*ub#fE&+&7&7&=&=&?"//;KKe&B&B CD..:KKe&A&A BC	 '@  W*@AF $q#f+.!&kQ.%7
"5#f+6E#EAI6F**6> 7 /
  //%0&++dG44   B" ""rA   )
r,  r(  r*  r   r-  r)  r+  r   r   r   N)r   r   r*  r+  r,  r-  )r,   r-   r.   r/   r   r   r   rf   r   r   r/  r   r   r   r   r@   r   r   r   rB   r'  r'  	  sK     JFI(<
"D&  # #rA   r'  c                   s0   a  ] tR tRt o R tRR ltRtV tR# )FeatureParamsi  c                s    \         P                  VR ,          4      V P                  8X  g+   Q RVR ,          : RV P                  P                  : 24       h\        P
                  ! WV4       R# )Z
FeatureTagz&Wrong FeatureParams type for feature 'z': N)featureParamTypesr   	__class__r,   r   r   )re   r   r      &&&rB   r   ZFeatureParams.compile  s\    !!&"674>>I	
 <  NN##
	
I
 	$-rA   Nc                s`    \         P                  ! WW#V P                  P                  R 7       R# ))r   N)r   r   r9  r,   r  r  rB   r   ZFeatureParams.toXML  s    4>>;R;RSrA   r&   r   )r,   r-   r.   r/   r   r   r@   r   r   r   rB   r7  r7    s     .T TrA   r7  c                       ] tR tRtRtR# )FeatureParamsSizei  r&   Nr,   r-   r.   r/   r@   r&   rA   rB   r<  r<        rA   r<  c                   r;  )FeatureParamsStylisticSeti  r&   Nr=  r&   rA   rB   r?  r?    r>  rA   r?  c                   r;  )FeatureParamsCharacterVariantsi  r&   Nr=  r&   rA   rB   r@  r@    r>  rA   r@  c                   r   )
Coveragei  Nc                <    \        V R 4      '       g
   . V n        R# R# )r5  N)hasattrr5  rq   rr   rB   rc   ZCoverage.populateDefaults  s    tX&&DK 'rA   c           	     s(   V P                   ^8X  d   VR,          V n        V = R# V P                   ^8X  d   . ;q0n        VR,          p\        VR R7      pWE8w  d   \        P	                  R4       Tp?V Fm  pVP
                  pVP                  pVP                  V4      p	VP                  V4      ^,           p
VP                  VP                  \        W4      4      4       Ko  	  V = R# . V n        \        P	                  RV P                   4       V = R# )rU   
GlyphArrayRangeRecordc                     V P                   # rb   )StartCoverageIndexr  rN   rB   rO   Z#Coverage.postRead.<locals>.<lambda>  s
    9M9MrA   r  .GSUB/GPOS Coverage is not sorted by glyph ids.zUnknown Coverage format: %sN)Formatr5  r  logwarningStartEndr   extendr0  r  )re   rawTabler   r5  rangesZsorted_rangesrr4  endstartIDendID   &&&        rB   postReadZCoverage.postRead  s    ;;!"<0DK* K) [[A#%%F[m,F #6/MNM&LM&ee//%0,q0d33E'4IJK  K DKKK5t{{CKrA   c                s8   \        V R R4      pVf	   . ;q n        ^pRV/pV'       Edl   VP                  V4      p\        V4      V8g  pV^ ,          pV..pVR,           F<  p	W^,           8w  d+   VR,          P	                  V4       VP	                  V	.4       T	pK>  	  VR,          P	                  V4       V'       g!   \        V4      ^,          \        V4      8  d   ^ p
\        V4       Fd  w  pw  r\        4       pWn        VP                  V4      Vn
        VP                  V4      Vn        Wn        WV&   W,           V,
          ^,           p
Kf  	  V'       d)   \        P                  R4       VP                  R R7       V F  pV=K  	  ^pRV/pW0n        V# )	r5  NrD  rT   rI  c                 rF  rb   )StartIDrH  rN   rB   rO   Z#Coverage.preWrite.<locals>.<lambda>  s    aiirA   r  rE  )r   r5  getGlyphIDManyr  r   r   r   rE  rX  ZgetGlyphNamerM  rN  rG  rK  rL  sortrJ  )re   r   r5  formatrP  glyphIDsZbrokenOrderr   rQ  r   r   r\   r4  rS  rR  r6  rB   preWriteZCoverage.preWrite  s   x.>#%%F[ &)6**62H *h6KA;DfXF#B<<Qh&2J%%d+MM7),	 (
 2Jd#c&kAoF;'0'8OA|#A %I"//6AG --c2AE+0( !1I!K%/!3E (9 KK PQKK$7K8A	  )62 rA   c                st    \        V R . 4       F&  pVP                  RVR7       VP                  4        K(  	  R# )r5  Glyphr   N)r   r   r   )re   r   r   ri   s   &&& rB   toXML2ZCoverage.toXML2  s4     x4Iy9 5rA   c                sh    \        V R R4      pVf	   . pWPn        VP                  VR,          4       R# )r5  Nr   )r   r5  r   )re   r   r   r   r   r5  r   rB   r   ZCoverage.fromXML  s/    x.>F KeGn%rA   )rJ  r5  rb   r,   r-   r.   r/   rc   rW  r^  r`  r   r@   r   r   r   rB   rA  rA    s$     2)V 
& &rA   rA  l    c                   sX   a  ] tR tRt o RR ltR t]R 4       tR tR t	R t
R	 tR
tV tR# )DeltaSetIndexMapi  Nc                rB  r   NrC  r   rq   rr   rB   rc   Z!DeltaSetIndexMap.populateDefaults      tY''DL (rA   c                sP    VR ,          R,          ^ 8X  g   Q hVR,          V n         R# )EntryFormat  r   Nr   )re   rP  r   r:  rB   rW  ZDeltaSetIndexMap.postRead  s&    '&0Q666	*rA   c                st   ^ pV  F  pW,          pK  	  VR,          p^ pV'       d   V^,          pV^,          pK  \        V^4      pV^8:  g   Q hV^V,
          ,	          V^V,          ^,
          ,          ,          pV^8:  d   ^pMVR8:  d   ^pMVR8:  d   ^pM^pV^,
          ^,          V^,
          ,          # )rg   r   i )max)r   ZoredZidxinnerZ	innerBitsZ	entrySizer!  rB   getEntryFormatZDeltaSetIndexMap.getEntryFormat  s    CKD  v	NIaKE	1%	Bi(Ta9n5I-JK:IZIZIIQ1$Q77rA   c                s    \        V R R4      pVf	   . ;q n        \        V4      R8  d   ^M^ V n        V P                  P                  4       p\        V4      VR&   V P                  V4      VR&   V# )r   Nr   MappingCountrf  )r   r   r   rJ  r   copyrk  )re   r   r   rP  r   rB   r^  ZDeltaSetIndexMap.preWrite*  sm    $	40?%''Glw<&0aa==%%'#&w< "&"5"5g">rA   c                s4   VP                  R 4       VP                  4        \        \        V R. 4      4       F\  w  r4RV3.pV\        8w  d&   VP                  RV^,	          3RVR,          3.4       VP                  RV4       VP                  4        K^  	  R# )z7Omitted values default to 0xFFFF/0xFFFF (no variations)r   r   outerrj  r   MapN)r   r   r   r   rm   rO  r   )re   r   r   r\   r   r      &&&   rB   r`  ZDeltaSetIndexMap.toXML24  s     	ST!'$	2">?HAq\NE** %2+. %&.1 u- @rA   c                s   \        V R R4      pVf
   . ;V n        p\        VR,          4      p\        VP                  RR4      4      p\        VP                  RR4      4      pVR8:  g   Q hVP	                  Wg^,          V,          4       R# )r   Nr   rn  Z0xFFFFrj  r   )r   r   r   r   insert)	re   r   r   r   r   r   r   rn  rj  	   &&&&&    rB   r   ZDeltaSetIndexMap.fromXMLE  sz    $	40?%''DL7w(7H567H56u{e34rA   c                sh    V\        V P                  4      8  d   V P                  V,          # \        # rb   )r   r   rm   )re   r\   rr   rB   __getitem__ZDeltaSetIndexMap.__getitem__O  s&    "#c$,,&7"7t||AO=OOrA   rJ  r   rb   )r,   r-   r.   r/   rc   rW  r   rk  r^  r`  r   rs  r@   r   r   r   rB   rb  rb    s>     + 8 82 "5P PrA   rb  Zuint8c                   H   a  ] tR tRt o R
R ltR tR tR tR tR t	R	t
V tR# )	VarIdxMapiS  Nc                <    \        V R 4      '       g
   / V n        R# R# rc  rd  rq   rr   rB   rc   ZVarIdxMap.populateDefaultsT  re  rA   c                s
   VR ,          R,          ^ 8X  g   Q hVP                  4       pVR,          pVP                  VR,          .\        V4      \        V4      ,
          ,          4       \        \	        W44      4      V n        R# )rf  rg  r   NrY  )getGlyphOrderrO  r   dictzipr   )re   rP  r   r   ZmapList   &&&  rB   rW  ZVarIdxMap.postReadX  sg    '&0Q666'')
9%}J#g,(FGHC
45rA   c                s8   \        V R R4      pVf	   / ;q n        VP                  4       pV Uu. uF  qBV,          NK  	  pp\        V4      ^8  d   VR,          VR,          8X  d   VR K*  R V/p\        V4      VR&   \        P                  V4      VR&   V# u upi )r   Nrl  rf  irY  )r   r   rx  r   rb  rk  )re   r   r   r   r3  rP     &&    rB   r^  ZVarIdxMap.preWrite_  s    $	40?%''Gl'')
'12z!1::z2'lQ72;'"+#=w'#&w< "2"A"A'"J 3s   Bc                s    \        \        V R / 4      P                  4       4       F@  w  r4RV3RV^,	          3RVR,          33pVP                  RV4       VP	                  4        KB  	  R# )r   r2  rn  rj  r   ro  N)r  r   r   r   r   )re   r   r   r2  r   r   rp  rB   r`  ZVarIdxMap.toXML2n  sk    "74B#?#E#E#GHLE% %2+&%&.)E
 u- IrA   c                s   \        V R R4      pVf	   / pWPn         VR,          p\        TR,          4      p\        TR,          4      pTR8:  g   Q hT^,          T,          YV&   R#    TP                  4       TR,          ,          p Lc; i)r   Nr2  r   rn  rj  r   )r   r   rx  r   )	re   r   r   r   r   r   r2  rn  rj  rr  rB   r   ZVarIdxMap.fromXMLx  s    $	40?G"L	9'NE w(w(2+.	9&&(w8Es   	A% % Bc                sB    V P                   P                  V\        4      # rb   )r   r   rm   )re   ri   rr   rB   rs  ZVarIdxMap.__getitem__  s    ||	+=>>rA   rh  rb   )r,   r-   r.   r/   rc   rW  r^  r`  r   rs  r@   r   r   r   rB   rv  rv  S  s(     6 /? ?rA   rv  c                   r   )VarRegionListi  c                s    VP                  R 4      pV'       d   \        VP                  4      V n        / V P                  CR\        V P                  R4      /C# )ZfvarRegionAxisCount)r   r   Zaxesr~  r   r   )re   r   Z	fvarTabler]   rB   r^  ZVarRegionList.preWrite  sR     HHV$	#&y~~#6D 
mm
~dmm=NO
 	
rA   )r~  Nr,   r-   r.   r/   r^  r@   r   r   r   rB   r}  r}    s     
 
rA   r}  c                   r   )
SingleSubsti  Nc                rw  rc  rd  rq   rr   rB   rc   ZSingleSubst.populateDefaults  re  rA   c                s    / p\        VR ,          4      pV P                  ^8X  dc   VR,          pVP                  V4      pV Uu. uF  qwV,           R,          NK  	  ppVP                  V4      p	\	        WI4       F	  w  rWV
&   K  	  MiV P                  ^8X  dA   \        V4      VR,          8X  g   Q R4       hVR,          p\	        WL4       F	  w  rWV
&   K  	  MQ RT P                  ,          4       hW0n        V =R# u upi )rA  DeltaGlyphID   Z
GlyphCountz invalid SingleSubstFormat2 table
Substituteunknown format: %sN)_getGlyphsFromCoverageTablerJ  rZ  r0  rz  r   r   )re   rP  r   r   inputr$  Z	inputGIDSr   ZoutGIDSZoutNamesinpoutsubstZsub   &&&           rB   rW  ZSingleSubst.postRead  s    +HZ,@A;;!^,E++E2I@IJ	W%500	GJ,,W5H0" 1[[AE
h|442124\*E-" . 9*T[[881K Ks   C;c                st   \        V R R4      pVf	   / ;q n        \        VP                  4       4      pVP                  pV UUu. uF  w  rVV! V4      V! V4      3NK  	  ppp\        \        Ws4      4      p^p	Rp
V F.  w  rV
f   W,
          R,          p
W,           R,          V8w  g   K.   M	  V
f   ^p	M^p	/ pWn        \        4       pV Uu. uF  q^,          ^ ,          NK  	  ppV Uu. uF  q^,          ^,          NK  	  ppVVn	        WR&   V	^8X  d   V
f   Q hWR&   V# VVR&   V# u uppi u upi u upi )r   Nr  rA  r  r  )
r   r   listr   r   r  rz  rJ  rA  r5  )re   r   r   r   r   r  ZbZgidItemsZsortableItemsr\  r$  ZinIDZoutIDrP  covitemr  r     &&                rB   r^  ZSingleSubst.preWrite  sO   $	40?%''GlW]]_%__
?DEutqZ]JqM2uEs834 #KD}.%. $ }j(56a6(56a6
"Q;$$$',^$  &+H\"? F, 76s   D*D0+D5c                    \        V P                  P                  4       4      pV F-  w  rEVP                  R RV3RV3.4       VP	                  4        K/  	  R# )Substitutioninr  N)r  r   r   r   r   )re   r   r   r   inGlyphZoutGlyphrp  rB   r`  ZSingleSubst.toXML2  sP    t||))+,!&G$5(BS0TU "'rA   c                s\    \        V R R4      pVf	   / pWPn        VR,          WRR,          &   R# )r   Nr  r  )r   r   )re   r   r   r   r   r   r   rB   r   ZSingleSubst.fromXML  s/    $	40?G"L$U|drA   rt  rb   ra  r   r   rB   r  r    s$     ,%N , ,rA   r  c                   sR   a  ] tR tRt o R
R ltR tR tR tR t]	R 4       t
R	tV tR# )MultipleSubsti  Nc                rw  rc  rd  rq   rr   rB   rc   ZMultipleSubst.populateDefaults  re  rA   c                s   / pV P                   ^8X  dI   \        VR,          4      pVR,           Uu. uF  qUP                  NK  	  pp\        \	        WF4      4      pMQ RT P                   ,          4       hW0n        V = R# u upi )rU   rA  Sequencer  N)rJ  r  r  ry  rz  r   )re   rP  r   r   r5  Zsr     &&&    rB   rW  ZMultipleSubst.postRead  sr    ;;!0*1EFF+3J+?@+?a\\+?E@3v-.G8*T[[881K As   A>c           
     s2   \        V R R4      pVf	   / ;q n        \        4       p\        \	        VP                  4       4      VP                  R7      Vn        ^V n        RTRVP                   Uu. uF  q@P                  W$,          4      NK  	  up/pV# u upi )r   Nr  rA  r  )
r   r   rA  r  r  keysr   r5  rJ  makeSequence_)re   r   r   r  r2  rP  r|  rB   r^  ZMultipleSubst.preWrite  s    $	40?%''GljD0dooF
T++GN;T
  Us   /B
c                s    \        V P                  P                  4       4      pV F>  w  rER P                  V4      pVP	                  RRV3RV3.4       VP                  4        K@  	  R# )r   r  r  r  N)r  r   r   r   r   r   )re   r   r   r   r  	outGlyphsr  r  rB   r`  ZMultipleSubst.toXML2	  s]    t||))+,"'G((9%C$5#,0OP #(rA   c                s   \        V R R4      pVf	   / pWPn        VR8X  d[   . V n        V FK  p\        V\        4      '       g   K  Vw  rxp	VR8X  g   K)  V P                  P                  VR,          4       KM  	  R# VR8X  d   \        VP                  R\        V4      4      4      p
V P                  V
,          p. ;qV&   V FA  p\        V\        4      '       g   K  Vw  rxp	VR8X  g   K)  VP                  VR,          4       KC  	  R# VR,          '       d   VR,          P                  R	4      M. pV Uu. uF  qP                  4       NK  	  upWRR
,          &   R# u upi )r   NrA  r_  r   r  r   r  r  r   r  )r   r   old_coverage_r   r   r   intr   r   r   r   )re   r   r   r   r   r   elementZelement_nameZelement_attrsr   r   r2  Zglyph_mappingr  r3  s   &&&&&          rB   r   ZMultipleSubst.fromXML  s>   $	40?G"L :!#D"!'51118.Q7*&&--mG.DE # :		'3w<89E&&u-E-//MEN"!'51118.Q</!((w)?@ #  05U||E%L&&s+	3<=9a	9=d=s   5Ec                s&    \        4       pWn        V# rb   )r  r  )r3  Zseqrx   rB   r  ZMultipleSubst.makeSequence_0  s    j
rA   )rJ  r   r  rb   )r,   r-   r.   r/   rc   rW  r^  r`  r   r   r  r@   r   r   r   rB   r  r    s3     	 >@  rA   r  c                   ru  )ClassDefi7  Nc                rw  )	classDefsN)rC  r  rq   rr   rB   rc   ZClassDef.populateDefaults8      t[))DN *rA   c                s   / pV P                   ^8X  ds   VR,          pVR,          pVP                  V4      pV\        V4      ,           pVP                  \	        Wg4      4      p\        W4       F  w  rV
'       g   K  WV	&   K  	  MV P                   ^8X  d   VR,          pV F  pVP                  p
V
'       g   K  VP                  pVP                  pVP                  V4      pVP                  V4      ^,           pVP                  \	        Wg4      4      pV F  p	WV	&   K	  	  K  	  M \        P                  RV P                   4       W0n        V = R# )rU   
StartGlyphClassValueArrayClassRangeRecordzUnknown ClassDef format: %sN)rJ  r   r   r0  r  rz  ClassrM  rN  rK  rL  r  )re   rP  r   r  r4  Z	classListrT  rU  Z
glyphNamesri   clsrecordsrecrS  r  rB   rW  ZClassDef.postRead<  s"   	;;!\*E !23Iooe,Gc)n,E..uW/DEJ"%j"<	3+.i( #= [[A12Gii		gg//%0,q0!2253HI
!+I+.i( ",  KK5t{{C"KrA   c                s   \        V R R4      pVf
   / V n        R# VP                  p. pVP                  4        F(  w  rVV'       g   K  VP	                  V! V4      WV34       K*  	  V'       d   VP                  4        V^ ,          w  rxp	WV..p
VR,           FK  w  rpW^,           8w  g   Wi8w  d-   V
R,          P                  Wx.4       V
P	                  WkV.4       TpTpTp	KM  	  V
R,          P                  Wx.4       V
# R# )r  NrT   rY  )r   r  r   r   r   r[  rO  )re   r   r  r   r   ri   r  r   ZlastNameZlastClsrQ  r   r  rB   _getClassRangesZClassDef._getClassRanges[  s    D+t4	DN__
'oo/NILL*Y/@A 0 JJL&+Ah#DGh/0F+099'CQh&#.2J%%t&67MM3";<$ ,5 2Jt./M rA   c                s   ^pR. /pV P                  V4      pV'       d   V^ ,          ^,          pVR,          ^,          pWe,
          ^,           p\        V4      ^,          V^,           8  dA   \        V4       F*  w  pw  rrp\        4       pWn        Wn        Wn        WV&   K,  	  ^pRV/pMZV^ ,          ^,          p^ .V,          pV F2  w  rrp\        W,
          W,
          ^,           4       F  pV	VV&   K
  	  K4  	  ^pRVRV/pW n        V# )   r  r  r  rY  )	r  r   r   r  rM  rN  r  r  rJ  )re   r   r\  rP  rQ  Z
startGlyphZendGlyphZ
glyphCountr\   r  r4  Z	startNamerS  ZendNamer  ZstartGlyphNameZclassesr3  r  rB   r^  ZClassDef.preWritet  s   &+%%d+1Jbz!}H!.2J6{Qa/@I&@Q<A<IG*,C )I%G #I #1I AR .7 "(1#
*;A7C	"5#5s7G!7KL%(
 M <B (.:KWUrA   c                r  )r  r2  classN)r  r  r   r   r   )re   r   r   r   ri   r  rp  rB   r`  ZClassDef.toXML2  sO    t~~++-.#NI
gy-AGS>,RS $rA   c                sn    \        V R R4      pVf	   / pWPn        \        VR,          4      WRR,          &   R# )r  Nr  r2  )r   r  r  )re   r   r   r   r   r  r   rB   r   ZClassDef.fromXML  s5    D+t4	I&N$'g$7	.!rA   )rJ  r  rb   )r,   r-   r.   r/   rc   rW  r  r^  r`  r   r@   r   r   r   rB   r  r  7  s(      >2< 8 8rA   r  c                   r   )
AlternateSubsti  Nc                rw  )
alternatesN)rC  r  rq   rr   rB   rc   ZAlternateSubst.populateDefaults  s    t\** DO +rA   c                s   / pV P                   ^8X  dZ   \        VR,          4      pVR,          p\        V4      \        V4      8X  g   Q h\        WE4       F  w  rgVP                  W6&   K  	  MQ RT P                   ,          4       hW0n        V = R# )rU   rA  AlternateSetr  N)rJ  r  r   rz  	Alternater  )re   rP  r   r  r  altsr  alt   &&&     rB   rW  ZAlternateSubst.postRead  s~    
;;!/0DEEN+Du:T***,"%--
 - 9*T[[881$KrA   c                s   ^V n         \        V RR4      pVf	   / ;q n        \        VP	                  4       4      p\        V4       F  w  pw  rVVP                  V4      WV3W4&   K  	  VP                  4        \        4       pV Uu. uF  q^,          NK  	  upVn	        . pV Uu. uF  qR,          NK  	  p	pV	 F$  p\        4       p
Wjn        VP                  V
4       K&  	  ^V n        RVRV/# u upi u upi )rU   r  NrA  r  rY  )rJ  r   r  r  r   r   r   r[  rA  r5  r  r  r   sortCoverageLast)re   r   r  r   r\   ri   r  r  r  setListr     &&         rB   r^  ZAlternateSubst.preWrite  s    T<6
+--JZ%%'(#,U#3A	y19AEH $4

j*/0%$1gg%0

(-.88.C>D Nd#  !"C<< 1.s   C-#C2c                sB   \        V P                  P                  4       4      pV Fu  w  rEVP                  R VR7       VP	                  4        V F&  pVP                  RVR7       VP	                  4        K(  	  VP                  R 4       VP	                  4        Kw  	  R# )r  r1  r  N)r  r  r   r   r   r   r   )re   r   r   r   ri   r  r  r  rB   r`  ZAlternateSubst.toXML2  s    t,,./%*!I~Y?!##Ks#;!!# " ^, &+rA   c                s    \        V R R4      pVf	   / pWPn        VR,          p. pWuV&   V F8  p\        V\        4      '       g   K  Vw  rpVP	                  VR,          4       K:  	  R# )r  Nr2  )r   r  r   r   r   )	re   r   r   r   r   r  ri   r  r  rr  rB   r   ZAlternateSubst.fromXML  sj    T<6
J(O'N	 #9Ggu--#* DJJuW~&	 rA   )rJ  r  r  rb   ra  r   r   rB   r  r    s#     !=2	 ' 'rA   r  c                   sR   a  ] tR tRt o R
R ltR t]R 4       tR tR t	R t
R	tV tR# )LigatureSubsti  Nc                rw  )	ligaturesN)rC  r  rq   rr   rB   rc   ZLigatureSubst.populateDefaults  r  rA   c                s*   / pV P                   ^8X  d`   \        VR,          4      pVR,          p\        V4      \        V4      8X  g   Q h\        V4       F  w  rgWV,          P                  W7&   K  	  MQ RT P                   ,          4       hW0n        V = R# )rU   rA  LigatureSetr  N)rJ  r  r   r   Ligaturer  )re   rP  r   r  r  ligSetsr\   r  r  rB   rW  ZLigatureSubst.postRead  s    	;;!/0DEE}-Gu:W---#E*!(!4!4	 + 9*T[[881"KrA   c                s    \        V 4      ) # rb   r  r   rN   rB   _getLigatureSortKeyZ!LigatureSubst._getLigatureSortKey  s    6 JrA   c                s   ^V n         \        V RR4      pVf	   / ;q n        V'       d   \        \	        \        V4      4      \        4      '       d   \        4       p\        VP                  4       V P                  R7       F`  p\        4       pVR,          Vn        \        V4      Vn        W$,          Vn        VP!                  V^ ,          . 4      P#                  V4       Kb  	  Tp\%        VP'                  4       4      p\)        V4       F  w  pw  rVP+                  V4      W3Wg&   K  	  VP-                  4        \/        4       p
V Uu. uF  q^,          NK  	  upV
n        . pV Uu. uF  qR,          NK  	  ppV F@  p	\3        4       p. ;qn        V	 F  pVP#                  V4       K  	  VP#                  V4       KB  	  ^V n        RV
RV/# u upi u upi )rU   r  Nr  rT   rA  r  rY  )rJ  r   r  r   ZnextZiterr   ry  r  r  r  r  	Componentr   	CompCountLigGlyphr  r   r  r   r   r   r[  rA  r5  r  r  )re   r   r  ZnewLigaturesZcompsZligaturer   r\   ri   r  r  r  r  r  ZligSetligsligs   &&               rB   r^  ZLigatureSubst.preWrite  s   D+t4	)++IDi$95AA
  6L	 0d6N6NO#:%*2Y"%(Z"$-$4!''a"5<<XF P %IY__&'#,U#3A	y19AEH $4

j*/0%$1gg%0
(-.88.C ]F%''D?C  NN6"  !"C88 1 /s   	G(Gc           	     s   \        V P                  P                  4       4      pV F  w  rEVP                  R VR7       VP	                  4        V FJ  pVP                  RVP                  RP                  VP                  4      R7       VP	                  4        KL  	  VP                  R 4       VP	                  4        K  	  R# )r  r1  r  r   )r2  r   N)
r  r  r   r   r   r   r  r   r  r   )re   r   r   r   ri   r  r  r  rB   r`  ZLigatureSubst.toXML2=  s    t~~++-."'I}I>##cllsxx?V $  !!#	 
 ]+ #(rA   c                sz   \        V R R4      pVf	   / pWPn        VR,          p. pWuV&   V F  p\        V\        4      '       g   K  Vw  rp\	        4       p	VR,          V	n        VR,          p
V
'       d   V
P                  R4      M. V	n        \        V	P                  4      V	n	        VP                  V	4       K  	  R# )r  Nr2  r   r   )r   r  r   r   r  r  r   r  r   r  r   )re   r   r   r   r   r  ri   r  r  r  r   s   &&&&&      rB   r   ZLigatureSubst.fromXMLJ  s    D+t4	I&N'N	#)Ggu--#* D*C >CL|,J5?J,,S1RCM.CMKK rA   )rJ  r  r  rb   )r,   r-   r.   r/   rc   rW  r   r  r^  r`  r   r@   r   r   r   rB   r  r    s8          8'9R  rA   r  c                   sB   a  ] tR tRt o R tR tRV 3R lR lltRtV tR# )	COLRi^  c                s2   VP                  ^ R7      pV P                  4        FP  pVP                  R8w  d   VP                  VP                  4       K1  VP                  W2/ R7      WP                  &    M	  \        R4      h\        P                  ! WV4      # )rg   )ZoffsetLayerRecordCount)Z	tableDictz$LayerRecordCount converter not found)	r"  getConvertersr   Zadvancer   ZreadZAssertionErrorr   r   )re   r   r   Z	subReaderconvr{  rB   r   ZCOLR.decompile_  s     ''q'1	&&(Dyy..!!$//2 $		)R	 HF99 ) !!GHH""466rA   c                s\    R V n         / V P                  CR\        V P                  R4      /C# )Nr  )r  r   r   re   r   rr   rB   r^  ZCOLR.preWritep  s8     !%
mm
t}}>P Q
 	
rA   c                s$   < V ^8  d   QhRRRS[ /# )r  glyphSetr$   quantization)r  r\  r      "rB   __annotate__ZCOLR.__annotate__z  s     ( ( (c (rA   c                s   V P                   ^ 8X  d   R# / pV P                  P                   F4  p VP                  P	                  WV4      pTf   K&  YSTP                  &   K6  	  \        V R4      ;'       d    V P                  RJpV'       g   V'       d
   RV n
        R# R# V'       g!   \        4       V n
        ^V P                  n        W0P                  n        R#   \
         d#   p^ RIHp T! RTP                  : 24      ThRp?ii ; i)rg   N)
TTLibErrorz#Failed to compute COLR ClipBox for ClipList)ZVersionBaseGlyphListBaseGlyphPaintRecordPaintcomputeClipBoxZ	ExceptionfontTools.ttLibr  	BaseGlyphrC  r  rJ  clips)	re   r  r  r  r  clipBoxZer  ZhasClipListr%  rB   computeClipBoxesZCOLR.computeClipBoxesz  s    <<1%%::C))224<P "'.cmm$ ; dJ/MMDMM4M $   (
'($"'MM%  6 9#--9JKs   CD&DD)r  r  Nr   )	r,   r-   r.   r/   r   r^  r  r@   r   r   r   rB   r  r  ^  s     7"
( ( (rA   r  c                   sB   a a ] tR tRt o]R 4       tV 3R ltRtVtV ;t	# )
LookupListi  c                s   V P                    Fr  pVP                   F_  p\        V4      P                  P	                  R 4      '       d     R# \        V4      P                  P	                  R4      '       g   K]    R# 	  Kt  	  \
        h)ZSubstGSUBZPosGPOS)LookupSubTabler   r,   Zendswith
ValueError)re   Zlst   &  rB   tableZLookupList.table  sb    Ajj8$$--g66!8$$--e44!	 !  rA   c           
     s  < V'       d$   R V9  g   \         VR ,          P                  9  d   \        SV `  W4      # VR ,          P                  \         ,          V P                  ,          pV P                  4        EFy  pVP                  '       d   \        WP                  . 4      p\        V4       F  w  rg\        V4      V9   d   \        V\        V4      ,          !  pVP                  p	VP                  '       d   VP                   RV	 2p	VP                  '       d   VP                  w  rpV	 RV RV
 RV R2p	VP                  V	4       VP                  4        VP!                  WWtP                  RV3.4       K  	  EK  VP"                  '       d*   \%        VP"                  R\'        V 4      4      '       g   EKF  \        WP                  R4      pVP!                  WWTP                  . 4       EK|  	  R# )ZDebgz: z in z (Z/Z)r   N)r   r[   Zsuperr`  r  r  Zrepeatr   r   r   Zstrr   Zlocationfeaturer   r   ZxmlWriteZauxZevalZvars)re   r   r   Z	debugDatar  r   lookupIndexr  ZinfoZtagZscriptZlanguager  r9  s   &&&          rB   r`  ZLookupList.toXML2  s   T!$DL,=,==7>)22L%%&;<TZZH	&&(D{{{ii4)25)9%K;'94.	#k:J0KL"mm999%)YYKr#"7C<<<8<5Fg%(EgYb(1"MC!))#.!))+MM!yyG[;Q:R *:  888D4d$D$D))T iuiiD1 )rA   r&   )
r,   r-   r.   r/   Zpropertyr  r`  r@   r   Z__classcell__)r9  r   s   @@rB   r  r    s#       E  ErA   r  c                   r   )BaseGlyphRecordArrayi  c                x   a \        V P                  V3R  lR7      V n        V P                  P                  4       # )c                 :   < SP                  V P                  4      # rb   r   r  r  r      &rB   rO   Z/BaseGlyphRecordArray.preWrite.<locals>.<lambda>  s    $//#--2PrA   r  )r  BaseGlyphRecordr   rm  r     &frB   r^  ZBaseGlyphRecordArray.preWrite  s1    %  &P 
 }}!!##rA   )r  Nr  r   r   rB   r  r         $ $rA   r  c                   r   )r  i  c                r  )c                 r  rb   r  r  r  rB   rO   Z(BaseGlyphList.preWrite.<locals>.<lambda>  s    ts}}7UrA   r  )r  r  r   rm  r  r  rB   r^  ZBaseGlyphList.preWrite  s1    $*%%+U%
! }}!!##rA   )r  Nr  r   r   rB   r  r    r  rA   r  c                   s4   a  ] tR tRt o ^t^tR tR tRtV t	R# )ClipBoxFormati  c                s    W P                   J # rb   Variablerd   rN   rB   is_variableZClipBoxFormat.is_variable  s    }}$$rA   c                rF  rb   r  rd   rN   rB   as_variableZClipBoxFormat.as_variable  s    }}rA   r&   N)
r,   r-   r.   r/   Staticr  r  r  r@   r   r   r   rB   r  r    s     FH% rA   r  c                   s0   a  ] tR tRt o ]tR tR tRtV t	R# )ClipBoxi  c                s   a  \         ;QJ d%    . V 3R  lS P                  4        4       F  NK  	  5# ! V 3R  lS P                  4        4       4      # )c              3   sP   <"   T F  p\        SVP                  4      x  K  	  R # 5irb   )r   r   )rw   r  re      & rB   ry   Z#ClipBox.as_tuple.<locals>.<genexpr>  s!     O:N$WT499--:Ns   #&)r   r  rd   s   frB   as_tupleZClipBox.as_tuple  s7    uO$:L:L:NOuOuO$:L:L:NOOOrA   c                sR    V P                   P                   V P                  4        2# rb   )r9  r,   r  rd   rN   rB   __repr__ZClipBox.__repr__  s#    ..))*4==?*;<<rA   r&   N)
r,   r-   r.   r/   r  
formatEnumr  r  r@   r   r   r   rB   r  r    s     JP= =rA   r  c                   sL   a  ] tR tRt o R
R ltR tR tR tRR ltR t	R	t
V tR# )r  i  Nc                rw  )r  N)rC  r  rq   rr   rB   rc   ZClipList.populateDefaults  s    tW%%DJ &rA   c           	     s   / pVP                  4       p\        VR ,          4       EF,  w  rVVP                  VP                  8  d/   \        P                  RVVP                  VP                  4       KO  . p. p\        VP                  VP                  ^,           4       FG  p	 WI,          p
Y9  d%   \        P                  ! TP                  4      Y:&   K6  TP                  T	4       KI  	  V'       d+   \        P                  RV\        V4      \        V4      4       V'       g   EK  \        P                  RV\        V4      \        V4      4       EK/  	  W0n        R#   \         d    TP                  T	4        K  i ; i)
ClipRecordzCinvalid ClipRecord[%i].StartGlyphID (%i) > EndGlyphID (%i); skippedzqClipRecord[%i] overlaps previous records; ignoring redefined clip boxes for the following glyph ID range: [%i-%i]z:ClipRecord[%i] range references missing glyph IDs: [%i-%i]N)rx  r   StartGlyphID
EndGlyphIDrK  rL  r  Z
IndexErrorr   rm  r  minri  r  )re   rP  r   r  r   r\   r  ZredefinedGlyphsZmissingGlyphsr   r2  rV  rB   rW  ZClipList.postRead  sG   '')
 67FA#..0/$$NN  OM !1!13>>A3EF&/E %#'99S[[#9EL#**73 G 8 (( }S&&	A 8L 
/ " !((1s   #EE>=E>c                sD   \        \        4      p/ pV P                  P                  4        F8  w  r4VP	                  4       pW,          P                  V4       WR9  g   K4  WBV&   K:  	  VP                  4        UUu/ uF  w  rV\        V4      W%,          bK  	  upp# u uppi rb   )r   r  r  r   r  r   Z	frozenset)re   ZglyphsByClipZuniqueClipsri   r  r  r5  s   &      rB   groupsZClipList.groups  s    "4("&**"2"2"4I""$C$$Y/%#*C 	 #5 DPCUCUCW
CWKCIf{//CW
 	
 
s   ;Bc                s  a \        V R 4      '       g   / V n        / pVP                  4       oV P                  4       P	                  4        F  w  r4\        V3R lV 4       4      pV'       g   K$  V^ ,          pV..pVR,           F<  pW^,           8w  d+   VR,          P                  V4       VP                  V.4       TpK>  	  VR,          P                  V4       V F  w  rW3V9  g   Q hWBW3&   K  	  K  	  . p\        VP	                  4       4       F5  w  w  rp\        4       pWn        Wn	        WLn
        VP                  V4       K7  	  R\        V4      RV/pV# )r  c              3   sF   <"   T F  qS9   g   K  SV,          x  K  	  R # 5irb   r&   )rw   ri   glyphMapr  rB   ry   Z$ClipList.preWrite.<locals>.<genexpr>,  s$      5;	H?T###Vs   !!rT   Z	ClipCountr  rY  )rC  r  ZgetReverseGlyphMapr  r   r  r   r  r  r  r  r   )re   r   ZclipBoxRangesr5  r  r]  r   rQ  r   r4  rS  ZclipRecordsrecordrP  r  s   &&            @rB   r^  ZClipList.preWrite&  s[   tW%%DJ**,#{{}224OF 5; H A;DfXF#B<<Qh&2J%%d+MM7),	 (
 2Jd#$
|=888.5ul+ %  5$ %+M,?,?,A%B!LU'\F"' #$Nv& &C [)+
 rA   c                sJ   V'       d   TMV P                   P                  pVf   . p\        V R4      '       d   VP                  RV P                  34       VP                  WS4       VP                  4        \        V P                  4       P                  4       R R7       F  w  rgVP                  R4       VP                  4        \        V4       F&  pVP                  RVR7       VP                  4        K(  	  VP                  RRVP                  3.4       VP                  4        VP                  W4       VP                  R4       VP                  4        VP                  R4       VP                  4        K  	  VP                  V4       VP                  4        R # )NrJ  c                 s&    \        V ^ ,          4      # )rg   )r  )r  rN   rB   rO   Z ClipList.toXML.<locals>.<lambda>T  s    CQLrA   r  Clipr_  r   r  )r9  r,   rC  r   rJ  r   r   r  r  r   r   r`  r   )	re   r   r   r   r   	tableNamer5  r  ri   rr  rB   r   ZClipList.toXMLJ  sP    Ddnn&=&=	=E4""LL(DKK019,%KKM!'@ 
OF v&#F^	##G9#=!!# , yHgnn+E*FGNN9+Y'V$ 
 	#rA   c                s   \        V R R4      pVf
   / ;V n        pVR8X  g   Q h. pRpV F  p\        V\        4      '       g   K  Vw  rpVR8X  d   VP	                  VR,          4       KA  VR8X  g   KJ  \        4       p\        VR,          4      Vn        V F2  p\        V\        4      '       g   K  Vw  rpVP                  WW44       K4  	  K  	  V'       d   V F  p	WuV	&   K	  	  R# R# )r  Nr  r_  r   r  rJ  )	r   r  r   r   r   r  r   rJ  r   )
re   r   r   r   r   r  r5  r  Zelemri   r   rB   r   ZClipList.fromXMLe  s    gt,=!##DJv~~DdE**#' DweGn-"!)!)%/!:#D%dE22 +/(DOOD?	 $  #	#*i  $ rA   )r  rb   r   )r,   r-   r.   r/   rc   rW  r  r^  r   r   r@   r   r   r   rB   r  r    s*     )V

"H6+ +rA   r  c                   s"    ] tR tRt^ t^t^tRtR# )
ExtendModei  r&   N)r,   r-   r.   r/   ZPADZREPEATZREFLECTr@   r&   rA   rB   r  r    s    
CFGrA   r  c                   s    ] tR tRt^ t^t^t^t^t^t	^t
^t^t^	t^
t^t^t^t^t^t^t^t^t^t^t^t^t^t^t^t^t^tRt R# )CompositeModei  r&   N)!r,   r-   r.   r/   ZCLEARZSRCZDESTZSRC_OVERZ	DEST_OVERZSRC_INZDEST_INZSRC_OUTZDEST_OUTZSRC_ATOPZ	DEST_ATOPZXORZPLUSZSCREENZOVERLAYZDARKENZLIGHTENZCOLOR_DODGEZ
COLOR_BURNZ
HARD_LIGHTZ
SOFT_LIGHTZ
DIFFERENCEZ	EXCLUSIONZMULTIPLYZHSL_HUEZHSL_SATURATIONZ	HSL_COLORZHSL_LUMINOSITYr@   r&   rA   rB   r  r    s    E
CDHIFGGHHI
CDFGFGKJJJJIHGNINrA   r  c                   s   a  ] tR tRt o ^t^t^t^t^t^t	^t
^t^	t^
t^t^t^t^t^t^t^t^t^t^t^t^t^t^t^t^t^t^t^t ^t!^t"^ t#R t$R t%Rt&V t'R# )PaintFormati  c                s8    V P                   P                  R 4      # )PaintVar)r   
startswithrd   rN   rB   r  ZPaintFormat.is_variable  s    yy##J//rA   c                s    V P                  4       '       d   V #  \        P                  R V P                  R,           2,          #   \         d     R# i ; i)r  :i   NNN)r  r  Z__members__r   KeyErrorrd   rN   rB   r  ZPaintFormat.as_variable  sM    K	**Xdiim_+EFF 		s   *A AAr&   N)(r,   r-   r.   r/   PaintColrLayersZ
PaintSolidZPaintVarSolidZPaintLinearGradientZPaintVarLinearGradientZPaintRadialGradientZPaintVarRadialGradientZPaintSweepGradientZPaintVarSweepGradient
PaintGlyphPaintColrGlyphPaintTransformZPaintVarTransformPaintTranslateZPaintVarTranslate
PaintScaleZPaintVarScalePaintScaleAroundCenterZPaintVarScaleAroundCenterPaintScaleUniformZPaintVarScaleUniformPaintScaleUniformAroundCenterZ PaintVarScaleUniformAroundCenterPaintRotateZPaintVarRotatePaintRotateAroundCenterZPaintVarRotateAroundCenter	PaintSkewZPaintVarSkewPaintSkewAroundCenterZPaintVarSkewAroundCenterZPaintCompositer  r  r@   r   r   r   rB   r  r    s     OJMJNNNJM "$&!')$KN !#IL!N0 rA   r  c                   s   a  ] tR tRt o ]tR tRR ltV 3R lR ltV 3R lR lt	V 3R	 lR
 lt
V 3R lR ltRV 3R lR lltRtV tR# )r  i  c                s     V P                  V P                  4      P                  #   \         d    \	        R T P                   24      hi ; i)zUnknown Paint format: )r  rJ  r   r  NotImplementedErrorrd   rN   rB   getFormatNameZPaint.getFormatName  sI    	N??4;;/444 	N%(>t{{m&LMM	Ns	   $' $ANc                sp   V'       d   TMV P                   P                  pVf   . pVP                  RV P                  34       VP	                  WS4       VP                  V P                  4       4       VP                  4        V P                  W4       VP                  V4       VP                  4        R # )NrJ  )
r9  r,   r   rJ  r   r   r  r   r`  r   )re   r   r   r   r   r  r   rB   r   ZPaint.toXML  s     Ddnn&=&=	=Eh,-9,$,,./I$#rA   c                sJ   < V ^8  d   QhRS[ RS[S[P                  ,          /# )r  colrreturn)r  r    r   SubTableEntryr  r  rB   r  Paint.__annotate__  s*     K Kt K9P9P0Q KrA   c              #  s`  "   V P                   \        P                  8X  dj   . pVP                  e   VP                  P                  pR \        W P                  V P                  V P                  ,            4       4        R j  xL
  R # V P                   \        P                  8X  dy   VP                  P                   FE  pVP                  V P                  8X  g   K   \        P                  ! RVP                  R7      x   R # 	  \        V P                  : R24      hV P!                  4        Fs  pVP"                  f   K  \%        VP"                  \'        V 4      4      '       g   K:  \)        WP*                  4      p\        P                  ! VP*                  VR7      x  Ku  	  R #  EL'5i)Nc              3   sV   "   T F  w  r\         P                  ! R W!R7      x  K!  	  R# 5i)ZLayers)r   r   r   N)r   r  )rw   r\   rM   r  rB   ry   Z+Paint.iterPaintSubTables.<locals>.<genexpr>  s-      DA ''XQHHs   ')r  )r   r   z not in colr.BaseGlyphList)rJ  r  r  Z	LayerListr  r   ZFirstLayerIndexZ	NumLayersr  r  r  r  r_  r   r  r   r  Z
tableClassZ
issubclassr   r   r   )re   r  Zlayersr  r  r   r|  rB   iterPaintSubTablesZPaint.iterPaintSubTables  s=    ;;+555F~~)--%//$2F2F2WX   ;;+444,,AA##tzz1#11{&,,WW B
 $**/IJKK&&(D*z$//4PT:/V/Vii0--499EJJ )!s'   BF.F+AF. A F."F.,A F.c                s.   < V ^8  d   QhRS[ R,          /# )r  r  r  )r!   r  r  rB   r  r    s     @ @4= @rA   c                s`    V P                  V4       Uu. uF  q"P                  NK  	  up# u upi rb   )r  r   )re   r  Zpr]   rB   getChildrenZPaint.getChildren  s)    !%!8!8!>?!>A!>???s   +c                    < V ^8  d   QhRS[ /# )r  r  )r  r  r  rB   r  r    s     	 	T 	rA   c                s   a \        V4      '       g   \        R4      h\        V V3R lR7       F  pVR,          P                  pV! V4       K   	  R# )zEDepth-first traversal of graph rooted at self, callback on each node.zcallback must be callablec                 &   < V P                  S4      # rb   r  paintr  r  rB   rO   Z Paint.traverse.<locals>.<lambda>      %2J2J42PrA   Ziter_subtables_fnNrY  )ZcallableZ	TypeErrorr   r   )re   r  Zcallbackpathr  s   &f&  rB   traverseZPaint.traverse  sE    !!788"$P
D HNNEUO	
rA   c                r  )r  r  )r
   r  r  rB   r  r    s     ) )i )rA   c                s	   V P                   \        P                  8X  dY   V P                  p\        VP                  VP
                  VP                  VP                  VP                  VP                  4      # V P                   \        P                  8X  d,   \        P                  ! V P                  V P                  4      # V P                   \        P                  8X  d,   \        P                  ! V P                  V P                   4      # V P                   \        P"                  8X  dv   \        P                  ! V P$                  V P&                  4      P                  V P                  V P                   4      P                  V P$                  ) V P&                  ) 4      # V P                   \        P(                  8X  d!   \        P                  ! V P                  4      # V P                   \        P*                  8X  dk   \        P                  ! V P$                  V P&                  4      P                  V P                  4      P                  V P$                  ) V P&                  ) 4      # V P                   \        P,                  8X  d*   \        P.                  ! \1        V P2                  4      4      # V P                   \        P4                  8X  dt   \        P                  ! V P$                  V P&                  4      P/                  \1        V P2                  4      4      P                  V P$                  ) V P&                  ) 4      # V P                   \        P6                  8X  d?   \        P8                  ! \1        V P:                  ) 4      \1        V P<                  4      4      # V P                   \        P>                  8X  d   \        P                  ! V P$                  V P&                  4      P9                  \1        V P:                  ) 4      \1        V P<                  4      4      P                  V P$                  ) V P&                  ) 4      # \        V P                   4      PA                  4       '       d   \C        R V P                    24      h\        # )zVariable Paints not supported: )"rJ  r  r  r
   ZxxZyxZxyZyyZdxZdyr  r   Z	translater  r~   rD   rE   r  ZcenterXZcenterYr  r	  r
  Zrotater   Zangler  r  ZskewZ
xSkewAngleZ
ySkewAngler  r  r  )re   r   rx   rB   getTransformZPaint.getTransform  s   ;;+444AQTT144qttQTT144@@[[K666%%dggtww77[[K222>>$++t{{;;[[K>>>""4<<>t{{DKK0DLL=4<<-8
 [[K999>>$**--[[KEEE""4<<>tzz"DLL=4<<-8
 [[K333??74::#677[[K???""4<<>

+,DLL=4<<-8
 [[K111==$//)9!:GDOO<TUU[[K===""4<<>gt./1IJDLL=4<<-8
 t{{#//11%(G}&UVVrA   c          	      s@   < V ^8  d   QhRS[ RRRS[RS[S[,          /# )r  r  r  r$   r  r  )r  r  r"   r  r  r  rB   r  r  >  s2      $1AD	'	rA   c                s$  a \        V4      p\        V V3R  lR7       F  pVR,          P                  pVP                  \        P
                  8X  g   K7  \        \        P                  R V 4       \        4      pW&P                  ,          P                  \        WG4      4       K  	  VP                  f   R# \        4       p\        \         P"                  4      Vn        \%        VP                  V4      w  Vn        Vn        Vn        Vn        V# )c                 r  rb   r  r  r  rB   rO   Z&Paint.computeClipBox.<locals>.<lambda>C  r  rA   r  c              3   sT   "   T F  qP                   P                  4       x  K   	  R # 5irb   )r   r  )rw   r  rx   rB   ry   Z'Paint.computeClipBox.<locals>.<genexpr>I  s     <tXX**,,ts   &(NrY  )r   r   r   rJ  r  r  r   r
   rp   r   r_  Zdrawr   Zboundsr  r  r  r  r   ZxMinZyMinZxMaxZyMax)	re   r  r  r  Zpenr  r  ZtransformationZcbs	   &f&&     rB   r  ZPaint.computeClipBox>  s     x("$P
D HNNE||{555!'''<t<"
 %**<+LM
 ::Y,,-	-9#**l-S*"'27	rA   r&   r   r   )r,   r-   r.   r/   r  r  r  r   r  r  r  r  r  r@   r   r   r   rB   r  r    sQ     JN
K K6@ @	 	) )V  rA   r  	MarkArrayZLangSysZAnchorZDeviceZAxisZMinMaxZ	BaseCoordZJstfLangSysZJstfGSUBModListZJstfGPOSModListZJstfMaxZMathKernZMathGlyphConstructionc                s   ^ pVP                   pVP                  f
   V^,
          pV^ 8  d   V# VP                  R8X  d   ^pMVP                  R8X  d   ^	pWP                  ,          P                  P                  P
                  pWS,          pVP                  ^ ,          P                  P                  X8X  d   V^,
          pV^ 8  d   V# WS,          pKH  \        V\        V4      4       F  pWS,          pVP                  V8w  g   K  WFn        \        VP                  4       FE  w  rx\        VP                  ,          V,          p	V	! 4       p
^V
n        Wn        WP                  V&   KG  	  K  	  ^pV# )a  Either the offset from the LookupList to a lookup overflowed, or
an offset from a lookup to a subtable overflowed.

The table layout is::

  GPSO/GUSB
          Script List
          Feature List
          LookUpList
                  Lookup[0] and contents
                          SubTable offset list
                                  SubTable[0] and contents
                                  ...
                                  SubTable[n] and contents
                  ...
                  Lookup[n] and contents
                          SubTable offset list
                                  SubTable[0] and contents
                                  ...
                                  SubTable[n] and contents

If the offset to a lookup overflowed (SubTableIndex is None)
        we must promote the *previous* lookup to an Extension type.

If the offset from a lookup to subtable overflowed, then we must promote it
        to an Extension Lookup type.
r  r  )LookupListIndexSubTableIndex	tableTyper  r  r  r  r9  
LookupTyper  r   r   lookupTypesrJ  ExtSubTable)ttfoverflowRecordokr  ZextTypeZlookupslookupZsiZsubTableZextSubTableClassextSubTabler  rB   fixLookupOverFlowsr,    sG   8 
B 00K##+!AoQ	6)		!	!V	+**+11<<CCG!F
//!

&
&
1
1W
<!Ao?I%[#g,7%' ' )&// :#.~/G/G#H#Q .0%&"*2'&1# !;	 8 
BIrA   c                    ^p\        V P                  P                  4       4      p\        V4      pVP                  R9   d   V^,          pM$VP                  R8X  d   VP
                  ^,
          p/ Vn        \        XV4       F7  pWG,          pV^ ,          p	V^,          VP                  V	&   V P                  V	 K9  	  V# )rU   r  rA  rE  )r  r   r   r   itemName	itemIndexr  )
oldSubTablenewSubTabler(  r)  Z
oldMappingoldLennewLenr\   r  r  
   &&&       rB   splitMultipleSubstr6    s    	
B++1134J_F"== 1		 	 J	.  ))A-K66"}1g#'7C $	 # IrA   c                 s   ^p\        V R4      '       d   V P                  Vn        \        V P                  P	                  4       4      p\        V4      pVP                  R9   d   V^,          pM$VP                  R8X  d   VP                  ^,
          p/ Vn        \        XV4       F7  pWG,          pV^ ,          p	V^,          VP                  V	&   V P                  V	 K9  	  V# )rU   r  r  r.  )	rC  r  r  r  r   r   r/  r0  r  )
r1  r2  r(  r)  ZoldAltsr3  r4  r\   r  r  r5  rB   splitAlternateSubstr7  
	  s    	
B{.//'2'C'C$[++1134G\F"== 1		 	 N	2  ))A-K66"z1g&*1gs#""3'	 # IrA   c                 r-  )rU   r  r.  )r  r  r   r   r/  r0  r  )
r1  r2  r(  r)  ZoldLigsr3  r4  r\   r  r  r5  rB   splitLigatureSubstr8  '	  s    	
B[**0023G\F"== 1		 	 M	1  ))A-K66"z1g%)!Wc"!!#&	 # IrA   c           	      sR  a T pR pV P                   Vn         V P                   ^8X  Ed
   \        V P                  4      ^8  d   R F  p\        W\	        W4      4       K  	  V P
                  P                  4       Vn        V P
                  P                  pV P                  p\        V P                  4      ^,          oVRS V P
                  n        VRS V n        VSR VP
                  n        VSR Vn        \        V P                  4      V n        \        VP                  4      Vn        RpV# V P                   ^8X  EdN   \        V P                  4      ^8  Ed3   \        V R4      '       g,   \        V P                  ^ ,          P                  4      V n        R F  p\        W\	        W4      4       K  	  RV n        V P
                  P                  4       Vn        V P                  P                  4       Vn        V P
                  P                  pV P                  P                  pV P                  p\        V P                  4      ^,          o\!        V3R lVP#                  4        4       4      p	V U
u. uF  qV	9  g   K  V
NK  	  up
V P
                  n        VP#                  4        UUu/ uF  w  rVS8  g   K  WbK  	  uppV P                  n        VRS V n	        V U
u. uF  qV	9   g   K  V
NK  	  up
VP
                  n        VP#                  4        UUu/ uF  w  rVS8  g   K  WS,
          bK  	  uppVP                  n        VSR Vn	        \        V P                  4      V n        \        VP                  4      Vn        RpV# u up
i u uppi u up
i u uppi )FNTClass2Countc              3   s>   <"   T F  w  rVS8  g   K  Vx  K  	  R # 5irb   r&   )rw   krM   oldCounts   &  rB   ry   ZsplitPairPos.<locals>.<genexpr>r	  s     I&7da1=&7s   
)ValueFormat1ValueFormat2)r9  	ClassDef2r<  r=  )rJ  r   ZPairSetr   r   rA  r9  r5  ZPairSetCountZClass1RecordrC  ZClass2Recordr9  	DontShare	ClassDef1r  r  r   ZClass1Count)r1  r2  r(  r  r)  r   coverager  r  Z	newGlyphsr3  r:  rM   r;  s   &&&          @rB   splitPairPosrB  A	  s5   	B	B$++KQ3{':':#;a#?2DKw{'AB 3
  +33==?''..%%{**+q0&.y&9#%ix0&.xy&9#%hi0#&{':':#; #&{':':#; T IQ 
		q	 S)A)A%BQ%F{M22&)+*B*B1*E*R*R&SK#NDKw{'AB O !%  +33==? + 5 5 ? ? A''..))33	**{//0A5Iioo&7II	2:&Q(Qy>Pqq(&Q#&__.+
.TQ!h,DAD.+
' $+9H#5 2:&M(Q9nqq(&M#*3//*;+
*;$!q8|AH*;+
' $+89#5 "%k&>&>"?"%k&>&>"?I# 'R+

 'N+
s0   :NN2NN)N6N!N#1N#c                 sr   V P                   pV^8  d   R# V^,          pW4,
          p. . rv. . r\        V P                  P                  V P                  P
                  4       Fu  w  rVP                  V8  d%   VP                  V
4       VP                  V4       K:  V;P                  V,          un        VP                  V
4       V	P                  V4       Kw  	  . . rV P                  P                   Fm  pVP                  4       VP                  4       ppVP                  RV Vn        VP                  VR Vn        VP                  V4       VP                  V4       Ko  	  V P                  Vn        W`P                  n        V P                  P                  4       Vn        WP                  n        V P                  Vn        W@n         WQn         WpP                  n        V P                  P                  4       Vn        WP                  n        \        V4      V P                  n        \        V	4      VP                  n        WP                  n	        V P                  P                  4       Vn        WP                  n	        \        V4      V P                  n        \        V4      VP                  n        R# )r  FNT)Z
ClassCountrz  MarkCoverager5  r   Z
MarkRecordr  r   Z	BaseArrayZ
BaseRecordr9  
BaseAnchorrJ  BaseCoverager   Z	MarkCountZ	BaseCount)r1  r2  r(  Z
classCountZoldClassCountZnewClassCountZoldMarkCoverageZoldMarkRecordsZnewMarkCoverageZnewMarkRecordsri   Z
markRecordZoldBaseRecordsZnewBaseRecordsr  ZoldBaseRecordZnewBaseRecords   &&&              rB   splitMarkBasePosrF  	  s<   ''JA~!OM.M&("^&("^!$  '')>)>)I)I"	 m+""9-!!*--""9-!!*-" &(N$$//'*}}}#&>>.=#A #&>>-.#A m,m, 0 %++K&5#*77AACK&5#  +77K**'5$'11;;=K'5$&).&9K#&).&9K#'5$'11;;=K'5$&).&9K#&).&9K#rA   r  r  c                sJ   WP                   ,          P                  pVP                  P                  VP                  ,          pVP
                  pVP                  V,          p\        VR4      '       g
   RVn        R# \        VR4      '       d   VP                  P                  P                  pTpVP                  p\        VP                   ,          VP                  P                  ,          pV! 4       p	VP                  V	n        T	p
\        VP                   ,          V,          pV! 4       pWn	        M=VP                  P                  p\        VP                   ,          V,          pV! 4       pTp
\        VR4      '       d   VP                  ^,           Vn         \        VP                   ,          V,          pT! Y\T4      pT'       d$   TP                  P'                  T^,           T
4       T#   \          d&    \"        P%                  RTP                   T4        R# i ; i)zb
An offset has overflowed within a sub-table. We need to divide this subtable into smaller parts.
r?  Tr&  SubTableCountz)Don't know how to split %s lookup type %sF)r#  r  r  r  r!  r"  r  rC  r?  r&  r9  r$  r%  rJ  rG  
splitTabler   rK  Zerrorrq  )r'  r(  r  r*  ZsubIndexZsubtableZsubTableTyper+  ZnewExtSubTableClassZnewExtSubTableZtoInsertZnewSubTableClassr2  Z	splitFuncr)  r6  rB   fixSubTableOverFlowsrI  	  s    (()//E$$^%C%CDF++Hx(H 8[))!x''  ++55@@**).*B*BC!!,,
 -. + 2 2!&~'?'?@N&(%0"))44&~'?'?@N&(v''%33a7~778F	 
8.	9B	x!|X6I  		7$$	

 s   G2 2,H"!H"c                  st   ^ RI p ^RIHp V P                  R4      p\        4       pV Fw  w  rE\        pVP                  V4      pV'       d-   VP                  ^4      pV^ ,          ^ ,          p\        V4      pWC9  g   KX  \        WF3/ 4      p	VR9   d   RV	n	        WV&   Ky  	  V Fc  w  rJVP                  R4      '       g   K  \        V4      ^8  g   K0  VR,          V9   g   K@  W4,          pW4R,          ,          pWn        Wn        Ke  	  \        P                  4        F  w  rW=,          pV F  pWV&   K	  	  K  	  R^\         ^\"        ^\$        ^\&        ^\(        ^\*        ^\,        ^\.        /R^\0        ^\2        ^\4        ^\6        ^\8        ^\:        ^\<        ^\>        ^	\@        /	R	^\B        /R
^ \D        ^\F        ^\H        ^\B        ^\J        //s&\L        R,          \L        R&   \L        PO                  4        F$  pVP                  4        F  w  pp	VV	n(        K  	  K&  	  R\R        /s*\W        ^^4       F  p\X        \T        RV,          &   K  	  \W        ^^d4       F  p\Z        \T        RV,          &   K  	  ^RI.H/p V F  w  rEVP                  V4      pV'       dz   VPa                  4       w  pp\c        V4      pW4,          p	\e        V	R4      '       g   / V	n3        / V	n4        V! VR,          V4      w  ppVV	Pf                  V&   VV	Ph                  V&   K  W4,          p	V! WS4      w  V	n3        V	n4        K  	  R# )rg   N)otDataz([A-Za-z0-9]+)Format(\d+)$r  r  TZVar:i   NNZmortZmorxZJSTFZsizezss%02dzcv%02d)buildConverters
convertersrT   )r  r  )5rerJ  r   Zglobalsr   ZmatchZgroupr   r   r?  r  r   Z	NoVarTypeZVarType_equivalentsr   r  r  r  r  ZContextSubstZChainContextSubstZExtensionSubstZReverseChainSingleSubstZ	SinglePosZPairPosZ
CursivePosZMarkBasePosZ
MarkLigPosZMarkMarkPosZ
ContextPosZChainContextPosZExtensionPosZNoncontextualMorphZRearrangementMorphZContextualMorphZLigatureMorphZInsertionMorphr%  r   r$  r<  r8  r  r?  r@  ZotConvertersrK  r  r  rC  rL  convertersByName)rM  rJ  Z	formatPatZ	namespacer   r  Z	baseClassZmZ
formatTyper  r   ZvarTypeZ	noVarTypeZbaser  r  Z
lookupEnumenumr\   rK  r\  rL  rO  s                          rB   _buildClassesrQ  
  s   

89I	I 	OOD!771:D q!J8DI t\2.C'' $!dO! & ??5!!c$i!mRI8MoG!r(+I ) '  #((*
C!cN  + 	{}~}| ~&	
 	ywz{z{z|

 	!
 	!}!~
3!KD &f-K!((*
#))+ID#!CN , + 	! 1f*C(Q,' 1f*H(Q,'  .OOD!88:LD&[F/C3--!#')$+:59i+P(J(%/CNN6"+;C  ( /C3B53T0CNC0! rA   c                 s&    V f   . # V P                   # rb   )r5  )rA  rN   rB   r  r  
  s    	rA   )r|   r}   r~   r   iL)Z
Mark1Array)ZDefaultLangSys)rC  rE  ZLigatureCoverageZMark1CoverageZMark2CoverageZBacktrackCoverageZInputCoverageZLookAheadCoverageZVertGlyphCoverageZHorizGlyphCoverageZTopAccentCoverageZExtendedShapeCoverageZMathKernCoverage)r@  r>  ZBacktrackClassDefZInputClassDefZLookAheadClassDefZGlyphClassDefZMarkAttachClassDef)ZEntryAnchorZ
ExitAnchorrD  ZLigatureAnchorZMark2AnchorZ
MarkAnchor)Z
XPlaDeviceZ
YPlaDeviceZ
XAdvDeviceZ
YAdvDeviceZXDeviceTableZYDeviceTableZDeviceTable)Z	HorizAxisZVertAxis)ZDefaultMinMax)ZMinCoordZMaxCoord)ZDefJstfLangSys)ZShrinkageEnableGSUBZShrinkageDisableGSUBZExtensionEnableGSUBZExtensionDisableGSUB)ZShrinkageEnableGPOSZShrinkageDisableGPOSZExtensionEnableGPOSZExtensionDisableGPOS)ZShrinkageJstfMaxZExtensionJstfMax)ZTopRightMathKernZTopLeftMathKernZBottomRightMathKernZBottomLeftMathKern)ZVertGlyphConstructionZHorizGlyphConstruction)Z__doc__rm  rP  r    Z	functoolsr   Zmathr   Z	itertoolsZcollectionsr   r   r  r   Z%fontTools.ttLib.tables.TupleVariationr   Z!fontTools.ttLib.tables.otTraverser   ZfontTools.misc.arrayToolsr   ZfontTools.misc.roundToolsr	   ZfontTools.misc.transformr
   r   r   ZfontTools.misc.textToolsr   r   r   ZfontTools.misc.vectorr   ZfontTools.pens.boundsPenr   ZfontTools.pens.transformPenr   ZotBaser   r   r   r   r   ZfontTools.misc.fixedToolsr   ru   r   r   r   r   r   r   Z fontTools.feaLib.lookupDebugInfor   r   ZloggingrJ   ZarrayZsysr   Ztypingr   r    r!   r"   r#   ZfontTools.ttLib.ttGlyphSetr$   Z	getLoggerr,   rK  r%   rC   r4   r5   r6   r8   r9   r=   r>   r:   r;   r   r   r   r^   r`   ra   r   Zobjectr   r   r   r   r   r  r  r'  r7  r<  r?  r@  rA  rm   rb  rv  r}  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  rN  r,  r6  r7  r8  rB  rF  rH  rI  rQ  r  r&   rA   rB   <module>rR     s        / / @ < 2 - M M = = ( 5 4   T    
  ? ?6 !* *6 '7  +**Aq! +**Aq! )*;*I*I2sTUV'(9(F(FAqQ'(9(F(FAqQ&'8'D'Db$PQR&'8'D'Db#qQ)*;*J*JAqRST)*;*J*JAqRST $ %%)%	 **2*		$.>"vB vBr. .D"F "v 
# #*R0y R0j>@I >@B! !J) JZD#9 D#NTI T	 		 		] 	U&' U&t   IP7@ IPX4?	 4?n
I 
$M,* M,`H, HVf8' f8RB'- B'Jv, vr6(9 6(r+E +E\$9 $$I $G =.w7 =R+/8 R+j G >+' +\@,W5 @T "             &        PYMj;|4:4DN9z 					 	<		

25vkU^ rA   