
    g	                          G d  de       Z G d de      Z G d de      Z G d de      Z G d d	e      Z G d
 de      Z G d de      Zy)c                       e Zd ZdZy)Errorz0Base Cu2Qu exception class for all other errors.N)__name__
__module____qualname____doc__     n/home/viktor/gitlab-persoonlijk/factuur-applicatie/venv/lib/python3.12/site-packages/fontTools/cu2qu/errors.pyr   r      s    :r	   r   c                        e Zd Z fdZ xZS )ApproxNotFoundErrorc                 <    d|z  }t         |   |       || _        y )Nzno approximation found: %s)super__init__curve)selfr   message	__class__s      r
   r   zApproxNotFoundError.__init__   s!    .6!
r	   )r   r   r   r   __classcell__)r   s   @r
   r   r      s     r	   r   c                       e Zd Zy)UnequalZipLengthsErrorN)r   r   r   r   r	   r
   r   r      s    r	   r   c                       e Zd Zd Zd Zy)IncompatibleGlyphsErrorc                     t        |      dkD  sJ || _        t        d |D              }t        |      dkD  r#ddj                  t	        |            z  | _        y |j                         | _        y )N   c              3   F   K   | ]  }t        |j                          y wN)reprname.0gs     r
   	<genexpr>z3IncompatibleGlyphsError.__init__.<locals>.<genexpr>#   s     1QDL1s   !z{%s}, )lenglyphssetjoinsortedcombined_namepop)r   r%   namess      r
   r   z IncompatibleGlyphsError.__init__    s\    6{Q1&11u:>!'$))F5M*B!BD!&Dr	   c                 N    dt        |       j                  d| j                  dS )N< >)typer   r)   r   s    r
   __repr__z IncompatibleGlyphsError.__repr__)   s     J//1C1CDDr	   N)r   r   r   r   r2   r   r	   r
   r   r      s    -Er	   r   c                       e Zd Zd Zy)IncompatibleSegmentNumberErrorc                      d| j                   z  S )Nz1Glyphs named %s have different number of segments)r)   r1   s    r
   __str__z&IncompatibleSegmentNumberError.__str__.   s    B
 	
r	   N)r   r   r   r6   r   r	   r
   r4   r4   -   s    
r	   r4   c                       e Zd Zd Zd Zy)IncompatibleSegmentTypesErrorc                 >    t         j                  | |       || _        y r   )r   r   segments)r   r%   r:   s      r
   r   z&IncompatibleSegmentTypesError.__init__5   s    ((v6 r	   c           	      v   g }t        t        t        | j                                    }t	        | j                  j                               D ]J  \  }}|j                  t        |      j                  |      ddj                  d |D              d       L d| j                  ddj                  |      S )Nz: (r#   c              3   2   K   | ]  }t        |        y wr   r   )r    ts     r
   r"   z8IncompatibleSegmentTypesError.__str__.<locals>.<genexpr>>   s     >U1tAw>U   )zGlyphs named z$ have incompatible segment types:
  z
  )
r$   strmaxr:   r(   itemsappendrjustr'   r)   )r   linesndigitsitagss        r
   r6   z%IncompatibleSegmentTypesError.__str__9   s    c#dmm,-.dmm1134 	GAtLL!!fll73TYY>UPT>U5UV	
 KK
 	
r	   Nr   r   r   r   r6   r   r	   r
   r8   r8   4   s    !

r	   r8   c                       e Zd Zd Zd Zy)IncompatibleFontsErrorc                     || _         y r   )glyph_errors)r   rN   s     r
   r   zIncompatibleFontsError.__init__G   s
    (r	   c                 z    ddj                  d t        | j                  j                               D              z  S )Nz&fonts contains incompatible glyphs: %sr#   c              3   2   K   | ]  }t        |        y wr   r=   r   s     r
   r"   z1IncompatibleFontsError.__str__.<locals>.<genexpr>L   s     H!d1gHr?   )r'   r(   rN   keysr1   s    r
   r6   zIncompatibleFontsError.__str__J   s5    7IIHvd.?.?.D.D.F'GHH
 	
r	   NrJ   r   r	   r
   rL   rL   F   s    )
r	   rL   N)	Exceptionr   r   r   r   r4   r8   rL   r   r	   r
   <module>rS      s]    ;I ;% 	U 	Ee E
%< 

$; 
$
U 
r	   