CZddlZddlmZejeZdZGddeZdS)N)AbstractDisplayXvfbc 8eZdZdZdddddddgdf d Zd Zd ZdS) XvfbDisplayz Xvfb wrapper Xvfb is an X server that can run on machines with no display hardware and no physical input devices. It emulates a dumb framebuffer using virtual memory. )iiblackFN Tc d|_||_||_||_||_||_t j|t|||| dS)z :param bgcolor: 'black' or 'white' :param fbdir: If non-null, the virtual screen is memory-mapped to a file in the given directory ('-fbdir' option) :param dpi: screen resolution in dots per inch if not None r) use_xauthretries extra_argsmanage_global_envN) _screen_size _color_depth_bgcolor_fbdir_dpir__init__PROGRAM) selfsize color_depthbgcolorr fbdirdpir r rs /srv/buildsys-work-dir/castor/build_node/builder-2/WGSG1/unpkd_srcs/cloudlinux-venv-1.0.6/venv/lib/python3.11/site-packages/pyvirtualdisplay/xvfb.pyrzXvfbDisplay.__init__se$  '     !/       cdS)N)rhelptexts r _check_flagszXvfbDisplay._check_flags5s rc tdd|jdddt|jdt tt |j|jgzg}|j r |d|j gz }|j |d t|j gz }|j r|d t|j gz }n ||j gz }tg|zS) Nz-brz-wr)rwhitez -nolistentcpz-screenxz-fbdirz-dpiz -displayfd)dictrstrrjoinmaplistrrrr_has_displayfd _pipe_wfdnew_display_varr)rcmds r_cmdzXvfbDisplay._cmd8s uE * * *4= 9       HHSd4:..$2C1DDEE F F   ; + Hdk* *C 9 FC NN+ +C   * L#dn"5"56 6CC D() )Cy3r)__name__ __module__ __qualname____doc__rr"r0r rrrr sn      D   rr)logging pyvirtualdisplay.abstractdisplayr getLoggerr1logrrr rrr9sk<<<<<<g!! ?????/?????r