
    <`                          d dl mZ d dlmZ d dlZ ej        e          ZdZdZ	 G d de
          Z G d d	e          Z G d
 de          ZdS )    )sstruct)safeEvalNz
  > # big endian
  height:       B
  width:        B
  horiBearingX: b
  horiBearingY: b
  horiAdvance:  B
  vertBearingX: b
  vertBearingY: b
  vertAdvance:  B
zX
  > # big endian
  height:   B
  width:    B
  BearingX: b
  BearingY: b
  Advance:  B
c                       e Zd Zd Zd ZdS )BitmapGlyphMetricsc                    |                     | j        j                   |                                 t	          j        | j        j                  d         D ];}|                    |t          | |                     |                                 <|	                    | j        j                   |                                 d S )N   )value)
begintag	__class____name__newliner   	getformatbinaryFormat	simpletaggetattrendtag)selfwriterttFont
metricNames       Ilib/python3.11/site-packages/fontTools/ttLib/tables/BitmapGlyphMetrics.pytoXMLzBitmapGlyphMetrics.toXML!   s    //$.)***..%dn&ABB1E  j	JgdJ&?&?@@@	>>--'(((..    c                 J   t          t          j        | j        j                  d                   }|D ]n}t          |t                    s|\  }}}||v r&t          |d                   t          |           |<   Ht          
                    d|| j        j                   od S )Nr   r	   z&unknown name '%s' being ignored in %s.)setr   r   r   r   
isinstancetupler   varslogwarningr   )r   nameattrscontentr   metricNameselements          r   fromXMLzBitmapGlyphMetrics.fromXML*   s    G%dn&ABB1EFF+ Y Yg
We
$
$ !4
kg//DJJtKK8$@WXXXXY Yr   N)r   
__module____qualname__r   r&    r   r   r   r      s7          
Y 
Y 
Y 
Y 
Yr   r   c                       e Zd ZeZdS )BigGlyphMetricsN)r   r'   r(   bigGlyphMetricsFormatr   r)   r   r   r+   r+   7   s        %r   r+   c                       e Zd ZeZdS )SmallGlyphMetricsN)r   r'   r(   smallGlyphMetricsFormatr   r)   r   r   r.   r.   :   s        'r   r.   )fontTools.miscr   fontTools.misc.textToolsr   logging	getLoggerr   r   r,   r/   objectr   r+   r.   r)   r   r   <module>r5      s    # " " " " " - - - - - -  g!!
  Y Y Y Y Y Y Y Y0& & & & &( & & &( ( ( ( (* ( ( ( ( (r   