
    ^hi                        S SK Jr  S SKrS SKJrJrJr  S SKJrJ	r	J
r
  SSKJrJr  SSKJr  SSKJr  \(       a  S S	KJr  S
/r S     SS jjrg)    )annotationsN)TYPE_CHECKINGTextIOcast)get_bell_environment_variableget_term_environment_variableis_conemu_ansi   )DummyOutputOutput)
ColorDepth)PlainTextOutputStdoutProxycreate_outputc                   [        5       n[        5       n[        R                  " 5       nU c\  [        R
                  n U(       aE  [        R
                  [        R                  4 H!  nUc  M  UR                  5       (       d  M  Un   O   SSKJ	n  [        X5      (       a  U R                  n [        X5      (       a  M  U c
  [        5       $ [        R                  S:X  a]  SSKJn  SSKJn  SSKJn	Jn
  U
" 5       (       a  [+        [,        U	" XS95      $ [/        5       (       a  [+        [,        U" XS95      $ U" XS9$ SS	KJn  U R                  5       (       d  [5        U 5      $ UR7                  U UUUS
9$ )a,  
Return an :class:`~prompt_toolkit.output.Output` instance for the command
line.

:param stdout: The stdout object
:param always_prefer_tty: When set, look for `sys.stderr` if `sys.stdout`
    is not a TTY. Useful if `sys.stdout` is redirected to a file, but we
    still want user input and output on the terminal.

    By default, this is `False`. If `sys.stdout` is not a terminal (maybe
    it's redirected to a file), then a `PlainTextOutput` will be returned.
    That way, tools like `print_formatted_text` will write plain text into
    that file.
r   r   win32r
   )ConEmuOutput)Win32Output)Windows10_Outputis_win_vt100_enabled)default_color_depth)Vt100_Output)termr   enable_bell)r   r   r   from_envsysstdoutstderrisattyprompt_toolkit.patch_stdoutr   
isinstanceoriginal_stdoutr   platformconemur   r   r   	windows10r   r   r   r   r	   vt100r   r   from_pty)r   always_prefer_ttyterm_from_envbell_from_envcolor_depth_from_envior   r   r   r   r   r   s               X/home/james-whalen/.local/lib/python3.13/site-packages/prompt_toolkit/output/defaults.pyr   r      s?   ( 23M13M%..0~ zz3::.>biikkF	 / 8
V
)
)'' V
)
) ~}
||w(&E!! R  VV  vPP'
 }}"6**$$ 4%	 % 
 	
    )NF)r   zTextIO | StdoutProxy | Noner)   boolreturnr   )
__future__r   r   typingr   r   r   prompt_toolkit.utilsr   r   r	   baser   r   color_depthr   
plain_textr   r!   r   __all__r    r/   r.   <module>r:      s`    " 
 . .  & # '7  KPQ
'Q
CGQ
Q
r/   