
    *f}                     V    d dl Z d dlmZ  e j                  e      ZdZ G d de      Zy)    N)AbstractDisplayXvncc            	       6    e Zd ZdZdddddddg d	f	d
Zd Zd Zy)XvncDisplayz
    Xvnc wrapper
    )i   i      blackFi  N
   Tc
                     || _         || _        || _        || _        || _        t        j                  | t        ||||	       y)au  
        :param bgcolor: 'black' or 'white'
        :param rfbport: Specifies the TCP port on which Xvnc listens for connections from viewers
        (the protocol used in VNC is called RFB - "remote framebuffer").
        The default is 5900 plus the display number.
        :param rfbauth: Specifies the file containing the password used to authenticate viewers.
        )	use_xauthretries
extra_argsmanage_global_envN)_size_color_depth_bgcolor_rfbport_rfbauthr   __init__PROGRAM)
selfsizecolor_depthbgcolorr   rfbportrfbauthr   r   r   s
             R/var/www/html/flask-app/venv/lib/python3.12/site-packages/pyvirtualdisplay/xvnc.pyr   zXvncDisplay.__init__   sH    & 
'  !/	
    c                      y )N )r   helptexts     r   _check_flagszXvncDisplay._check_flags1   s    r   c           	      v   t         dt        | j                        dd| j                  d   | j                  d   fz  dt        | j                        g}| j
                  r|dt        | j
                        gz  }n|dd	gz  }| j                  r|d
t        | j                        gz  }|S || j                  gz  }|S )Nz-depthz	-geometryz%dx%dr      z-rfbportz-rfbauthz-SecurityTypesNonez
-displayfd)	r   strr   r   r   r   _has_displayfd	_pipe_wfdnew_display_var)r   cmds     r   _cmdzXvncDisplay._cmd4   s    !!"tzz!}djjm44
 ==JDMM 233C $f--CL#dnn"566C 
 D(())C
r   )__name__
__module____qualname____doc__r   r!   r*   r   r   r   r   r   
   s4      
Dr   r   )logging pyvirtualdisplay.abstractdisplayr   	getLoggerr+   logr   r   r   r   r   <module>r3      s0     <g!
@/ @r   