a
    lc2                     @   s   d dl Z e jdksJ d dlmZmZmZ d dlmZ ddlm	Z	 ddl
mZ ddlmZ dd	lmZ d
gZG dd
 d
Ze	e dS )    Nwin32)AnyOptionalTextIOSize   )Output)
ColorDepth)Vt100_Output)Win32OutputConEmuOutputc                   @   sJ   e Zd ZdZdeee ddddZee	dddZ
eed	d
dZdS )r   a  
    ConEmu (Windows) output abstraction.

    ConEmu is a Windows console application, but it also supports ANSI escape
    sequences. This output class is actually a proxy to both `Win32Output` and
    `Vt100_Output`. It uses `Win32Output` for console sizing and scrolling, but
    all cursor movements and scrolling happens through the `Vt100_Output`.

    This way, we can have 256 colors in ConEmu and Cmder. Rendering will be
    even a little faster as well.

    http://conemu.github.io/
    http://gooseberrycreative.com/cmder/
    N)stdoutdefault_color_depthreturnc                 C   s&   t ||d| _t|dd |d| _d S )N)r   c                   S   s
   t ddS )Nr   r    r   r   X/var/www/html/django/DPS/env/lib/python3.9/site-packages/prompt_toolkit/output/conemu.py<lambda>(       z'ConEmuOutput.__init__.<locals>.<lambda>)r   win32_outputr   vt100_output)selfr   r   r   r   r   __init__#   s    
zConEmuOutput.__init__)r   c                 C   s   dS )NFr   )r   r   r   r   responds_to_cpr+   s    zConEmuOutput.responds_to_cpr)namer   c                 C   s$   |dv rt | j|S t | j|S d S )N)get_sizeZget_rows_below_cursor_positionZenable_mouse_supportZdisable_mouse_supportZscroll_buffer_to_promptZget_win32_screen_buffer_infoZenable_bracketed_pasteZdisable_bracketed_paste)getattrr   r   )r   r   r   r   r   __getattr__/   s    
zConEmuOutput.__getattr__)N)__name__
__module____qualname____doc__r   r   r
   r   propertyboolr   strr   r   r   r   r   r   r      s    )sysplatformtypingr   r   r   Zprompt_toolkit.data_structuresr   baser	   Zcolor_depthr
   Zvt100r   r   r   __all__r   registerr   r   r   r   <module>   s   ,