
    Bh                     "   S r SSKrSSKrSSKrSSKrSSKJr  SSKrSSKJ	r	J
r
JrJr  SSKJr  SSKJr  SSKJr   " S	 S
\R&                  5      r " S S\R*                  5      r\" SSS9r\R1                  SSS9  \R1                  SSS9  \R1                  SSSS9  \R1                  SSSSSS9  \R1                  SSS S9  \R1                  S!S"S#S9  \R1                  S$S%SS&S'S9  \R1                  S(S)S9  \R1                  S*\S+S,9  \R1                  S-S.S9  \R1                  S/S0S1S29  \R1                  S3S0S4S29  \R1                  S5S0S6S29  \R1                  S7S8S0S9S29  \R1                  S:S0S;S29  \R1                  S<S0S=S29  \R1                  S>S?\S@SA9  \R1                  SBS0SCS29  \R1                  SDS0SES29  \R1                  SFSGSHSISJ9  \R1                  SKSL\SMSA9  \R1                  SNSOS0SPS29  \R1                  SQSRS0SSS29  \R1                  STSUS0SVS29  \R1                  SWSXSY\ 3SZS[9  \R1                  S\S]\SS^S_9  \R1                  S`Sa\SbSA9  \R4                  " Sf0 \	D6  SSS\
4Sc jr\=R                   Sd\R8                  -   -  sl         \Se:X  a  \" 5         gg)gz%Command-line interface to WeasyPrint.    N)partial   )DEFAULT_OPTIONSHTMLLOGGER__version__)VARIANTS)pango)default_url_fetcherc                       \ rS rSrS rSrg)	PrintInfo   c                     [         R                  " 5       n[        SUR                  5        [        SUR                  5        [        SUR
                  5        [        SUR                  5        [        5         [        S[        5        [        S[        R
                  R                  5       S   5        [        S[        R                  5        [        S	[        R                  " 5       5        [        R                  " 5         g )
NzSystem:zMachine:zVersion:zRelease:zWeasyPrint version:zPython version:r   zPydyf version:zPango version:)platformunameprintsystemmachineversionreleaser   syssplitpydyfr
   pango_versionexit)___r   s      E/var/www/html/env/lib/python3.13/site-packages/weasyprint/__main__.py__call__PrintInfo.__call__   s     i&j%--(j%--(j%--(#[1!2!2!4Q!78 1 12 3 3 56
     N)__name__
__module____qualname____firstlineno__r   __static_attributes__r"   r!   r   r   r      s    r!   r   c                   D   ^  \ rS rSrU 4S jrU 4S jr\S 5       rSrU =r	$ )Parser    c                 4   > 0 U l         [        TU ]  " U0 UD6  g )N)
_argumentssuper__init__)selfargskwargs	__class__s      r   r.   Parser.__init__!   s    $)&)r!   c                    > [         TU ]  " U0 UD6  US   R                  S5      nXS'   US   S   S:g  US'   X R                  U'   g )N-flagsr   
positional)r-   add_argumentlstripr,   )r/   r0   r1   keyr2   s       r   r9   Parser.add_argument%   sQ    d-f-2hooc"w#Bx{c1|%r!   c                    U R                   R                  S5      U R                   S'   / nU R                   R                  5        H  u  p#UR                  S5        UR	                  SS5      nUS    HJ  nUR                  U5        US   (       d  US;   a  UR                  SU S	35        UR                  S
5        ML     SUS'   UR                  SUS   S   R                  5        US   SS   S35        SU;   a)  S
R                  US   5      nUR                  SU S35        US:X  d  M  UR                  S5        M     SR                  U5      $ )Nhelpz.. option:: actionstorer7   r8   )r@   appendz <>z, 

r5   z  r   r   z.

choicesz  Possible choices: rA   z-  This option can be passed multiple times.

 )r,   popitemsrA   getupperjoin)r/   datar;   r0   r?   flagrD   s          r   	docstringParser.docstring,   s:   "&//"5"5f"=..0ICKK'XXh0FWD!L)f8K.KKK"SE,D!	 &
 DHKK"T&\!_2245d6l126F5GuMND ))DO427)5AB!MN 1 wwt}r!   )r,   )
r#   r$   r%   r&   r.   r9   propertyrM   r'   __classcell__)r2   s   @r   r)   r)       s!    *&  r!   r)   
weasyprintzRender web pages to PDF.)progdescriptioninputz1URL or filename of the HTML input, or - for stdin)r>   outputz1filename where output is written, or - for stdoutz-ez
--encodingz"force the input character encodingz-sz--stylesheetrA   stylesheetsz)URL or filename for a user CSS stylesheet)r?   destr>   z-mz--media-typez/media type to use for @media, defaults to printz-uz
--base-urluz   base for relative URLs in the HTML input, defaults to the input’s own filename or URL or the current directory for stdinz-az--attachmentattachmentsz7URL or filename of a file to attach to the PDF documentz--pdf-identifierzPDF file identifierz--pdf-variantzPDF variant to generate)rD   r>   z--pdf-versionzPDF version numberz--pdf-forms
store_truezinclude PDF forms)r?   r>   z--uncompressed-pdfz9do not compress PDF content, mainly for debugging purposez--custom-metadataz-include custom HTML meta tags in PDF metadataz-pz--presentational-hintsz follow HTML presentational hintsz--srgbzinclude sRGB color profilez--optimize-imagesz5optimize size of embedded images with no quality lossz-jz--jpeg-qualityz+JPEG quality between 0 (worst) to 95 (best))typer>   z--full-fontsz)embed unmodified font files when possiblez	--hintingz*keep hinting information in embedded fontsz-cz--cache-foldercachezistore cache on disk instead of memory, folder is created if needed and cleaned after the PDF is generated)rW   r>   z-Dz--dpiz4set maximum resolution of images embedded in the PDFz-vz	--verbosez&show warnings and information messagesz-dz--debugzshow debugging messagesz-qz--quietzhide logging messagesz	--versionr   zWeasyPrint version u,   print WeasyPrint’s version number and exit)r?   r   r>   z-iz--infoz!print system information and exit)r?   nargsr>   z-tz	--timeoutz(Set timeout in seconds for HTTP requestsc                    [         R                  U 5      nUR                  S:X  aP  U=(       d    [        R                  R
                  nUR                  c  SUl        O$UR                  S:X  a  SUl        OUR                  nUR                  S:X  a$  U=(       d    [        R                  R
                  nOUR                  n[        nUR                  b  [        [        UR                  S9n[        U5      R                  5        VV	s0 s H  u  pU[        ;   d  M  X_M     n
nn	UR                  (       a%  [         R"                  " [$        R&                  5        O5UR(                  (       a$  [         R"                  " [$        R*                  5        UR,                  (       d  [$        R.                  " 5       nUR                  (       a&  UR1                  [$        R2                  " S5      5        O%UR1                  [$        R2                  " S5      5        [         R4                  " U5        U" XTR                  UR6                  UR8                  US9nUR:                  " U40 U
D6  gs  sn	nf )	zyThe ``weasyprint`` program takes at least two arguments:

.. code-block:: sh

    weasyprint [options] <input> <output>

r6   N.rE   )timeoutzB%(levelname)s: %(filename)s:%(lineno)d (%(funcName)s): %(message)sz%(levelname)s: %(message)s)base_urlencoding
media_typeurl_fetcher)PARSER
parse_argsrT   r   stdinbufferr`   rU   stdoutr   r_   r   varsrG   r   debugr   setLevelloggingDEBUGverboseINFOquietStreamHandlersetFormatter	Formatter
addHandlerra   rb   	write_pdf)argvrh   rf   r   r0   sourcerU   rc   r;   valueoptionshandlerhtmls                r   mainr|      s    T"DzzS*#))**== DM]]b  DM{{c,3::,,%K||14<<H &*$Z%5%5%7S%7zs3/;Q

%7  S zz&	%::'')::  !!234
   !2!23O!PQ'"??=D 	NN6%W%/Ss   	I$I$rC   __main__r"   )__doc__argparserl   r   r   	functoolsr   r   rE   r   r   r   r   pdfr	   text.ffir
   urlsr   Actionr   ArgumentParserr)   rd   r9   intset_defaultsr|   rM   r#   r"   r!   r   <module>r      s   +    
   8 8   % X$$ D 
\/I	J   E  G   F  H   ,A  C   .	4  6   .	:  <   ,
G  H   .	B  D   &-B  C   X,E  G   O*>  ?   ,-@  B   	D  F   	8  :   
"<	+  -   \	%  '   	@  B   
	6  8   <	4  6   	5  7   

?  @   '	?  A   +l	1  3   )L/H  J   )L/F  H   	!+/	7  9   (9A	,  .   +C	3  5    &o & 4t$ 3&l ))) ) zF r!   