
    /hf                     (   d dl Z d dlmZ d dlmZmZ d dlmZ d dlm	Z	m
Z
mZmZmZmZmZmZ ddlmZ ddlmZmZmZmZ dd	lmZmZ dd
lmZmZ eedf         Z G d d          Z e G d d                      Z! e!            Z" G d d          Z#dS )    N)	lru_cache)dumpsloads)randint)AnyDictIterableListOptionalTypeUnioncast   )errors)ColorColorParseErrorColorSystem	blend_rgb)Result	rich_repr)DEFAULT_TERMINAL_THEMETerminalThemeStylec                   T    e Zd ZdZdgZdeddfdZddd	ed         dee	         fd
Z
dS )_Bitz.A descriptor to get/set a style attribute bit.bitbit_noreturnNc                     d|z  | _         d S )Nr   )r   )selfr   s     I/var/www/html/venv/lib/python3.11/site-packages/pip/_vendor/rich/style.py__init__z_Bit.__init__   s    ;    objr   objtypec                 J    |j         | j        z  r|j        | j        z  dk    S d S )Nr   )_set_attributesr   _attributes)r    r$   r%   s      r!   __get__z_Bit.__get__   s-    ) 	3?TX-22tr#   )__name__
__module____qualname____doc__	__slots__intr"   r   r   boolr)    r#   r!   r   r      st        88Is t    7 T'] x~      r#   r   c            &          e Zd ZU dZee         ed<   ee         ed<   eed<   eed<   ee         ed<   eed<   ee	         ed<   g d	Z
d
dddddddddddddZi ddddddddddddddddd d d!d!d"d"d#d"d$d$d%d$d&d&d'd&d(d(d(d)d*d+d+d,Zd-d-d-d-d-d-d-d-d-d-d-d-d-d-d-d-d-d.d/eeeef                  d0eeeef                  dee         dee         dee         dee         d ee         d!ee         d"ee         d$ee         d&ee         d(ee         d)ee         d*ee         d+ee         d1ee         d2eeeef                  f"d3Zedqd5            Ze	 drd/ee         d0ee         d4d fd6            Zed2eeeef                  d4d fd7            Zedsd2eeeef                  d8ed4d fd9            Z ed:          Z ed;          Z ed<          Z ed=          Z ed>          Z ed?          Z ed@          Z edA          Z edB          Z  edC          Z! edD          Z" edE          Z# edF          Z$e%d4efdG            Z&d4efdHZ'd4efdIZ(dJe)d4efdKZ*e e+dLM          dNed4efdO                        Z,edPee-         d4e-fdQ            Z.d4e/fdRZ0dSed4efdTZ1dSed4efdUZ2d4efdVZ3e%d4ee         fdW            Z4e%d4ee         fdX            Z5e%d4ee         fdY            Z6e%d4efdZ            Z7e%dqd[            Z8e%d4eeef         fd\            Z9e%dqd]            Z:e e+d^M          d_ed4d fd`                        Z; e+dLM          dsdaee<         d4efdb            Z=edce>d          d4d fdd            Z?edtde            Z@dqdfZAdsd1ee         d4d fdgZB	 due)jC        didjdkedJee)         dled4efdmZDdsdkee         d4d-fdnZE e+dLM          dNed          d4d fdo            ZFdNed          d4d fdpZGd-S )vr   a  A terminal style.

    A terminal style consists of a color (`color`), a background color (`bgcolor`), and a number of attributes, such
    as bold, italic etc. The attributes have 3 states: they can either be on
    (``True``), off (``False``), or not set (``None``).

    Args:
        color (Union[Color, str], optional): Color of terminal text. Defaults to None.
        bgcolor (Union[Color, str], optional): Color of terminal background. Defaults to None.
        bold (bool, optional): Enable bold text. Defaults to None.
        dim (bool, optional): Enable dim text. Defaults to None.
        italic (bool, optional): Enable italic text. Defaults to None.
        underline (bool, optional): Enable underlined text. Defaults to None.
        blink (bool, optional): Enabled blinking text. Defaults to None.
        blink2 (bool, optional): Enable fast blinking text. Defaults to None.
        reverse (bool, optional): Enabled reverse text. Defaults to None.
        conceal (bool, optional): Enable concealed text. Defaults to None.
        strike (bool, optional): Enable strikethrough text. Defaults to None.
        underline2 (bool, optional): Enable doubly underlined text. Defaults to None.
        frame (bool, optional): Enable framed text. Defaults to None.
        encircle (bool, optional): Enable encircled text. Defaults to None.
        overline (bool, optional): Enable overlined text. Defaults to None.
        link (str, link): Link URL. Defaults to None.

    _color_bgcolorr(   r'   _hash_null_meta)r3   r4   r(   r'   _link_link_id_ansi_style_definitionr5   r6   r7   12345678921515253)r   r                        	   
         dimdboldbitalici	underlineublinkblink2reverserconcealcstrikes
underline2frameencircleoverline)uure   rf   rg   oN)colorbgcolorrV   rT   rX   rZ   r\   r]   r^   r`   rb   rd   re   rf   rg   linkmetarj   rk   rl   rm   c                   d | _         d | _        dt          t          t          f         dt          fd}|d n
 ||          | _        |d n
 ||          | _        t          |d u|d uod|d uod|d uod|d uod|d uod|	d uod	|
d uod
|d uod|d uod|d uod|d uod|d uodf          | _        | j        rPt          |rdpd|rdpd|rdpd|rdpd|rdpd|rdpd|	rd	pd|
rd
pd|rdpd|rdpd|rdpd|rdpd|rdpdf          nd| _	        || _
        |d nt          |          | _        |s|r&t          dd           t          | j                   nd| _        d | _        | j        p|p|p|p| | _        d S )Nrj   r   c                 X    t          | t                    r| nt          j        |           S N)
isinstancer   parse)rj   s    r!   _make_colorz#Style.__init__.<locals>._make_color   s%    &ue44L55%+e:L:LLr#   rI   rK   rO          @                     r   r   ?B  )r:   r;   r   r   strr3   r4   sumr'   r(   r8   r   r7   r   hashr9   r5   r6   )r    rj   rk   rV   rT   rX   rZ   r\   r]   r^   r`   rb   rd   re   rf   rg   rl   rm   rs   s                      r!   r"   zStyle.__init__z   s   * %)
04	MuUCZ0 	MU 	M 	M 	M 	M $mddU1C1C '[[5I5I"D 4%Ad"(q%+!T!(bd")rt#*t#+d"*s$&.3T!*d$-$- 
  
F ##CJQO!IANLq%AO!(qLb%AMr&QN'aO(qNs'a&3+!Nd'a%*%*  $ ' 	, 
!\TTuT{{
:>O$Owq&!!54
#3#3555R 	 %)
.R%R7RdRdS


r#   r   c                     t           S )zCCreate an 'null' style, equivalent to Style(), but more performant.)
NULL_STYLE)clss    r!   nullz
Style.null   s
     r#   c                     |                      t                    }d|_        d|_        ||_        ||_        d|_        d|_        d|_        d|_	        d|_
        |p| |_        d|_        |S )a  Create a new style with colors and no attributes.

        Returns:
            color (Optional[Color]): A (foreground) color, or None for no color. Defaults to None.
            bgcolor (Optional[Color]): A (background) color, or None for no color. Defaults to None.
        Nr   r~   )__new__r   r:   r;   r3   r4   r'   r(   r8   r9   r7   r6   r5   )r   rj   rk   styles       r!   
from_colorzStyle.from_color   sr     {{5))"&  ! +G,r#   c                 8   |                      t                    }d|_        d|_        d|_        d|_        d|_        d|_        d|_        t          |          |_
        t          dd           t          |j
                   |_        d|_        | |_        |S )zCreate a new style with meta data.

        Returns:
            meta (Optional[Dict[str, Any]]): A dictionary of meta data. Defaults to None.
        Nr   r}   )r   r   r:   r;   r3   r4   r'   r(   r8   r   r7   r   r   r9   r5   r6   )r   rm   r   s      r!   	from_metazStyle.from_meta   s     {{5))"& !Dkk#Av..CU[0A0ACCjr#   handlersc                     |i n|}|                     d |                                D                        |                     |          S )a  Create a blank style with meta information.

        Example:
            style = Style.on(click=self.on_click)

        Args:
            meta (Optional[Dict[str, Any]], optional): An optional dict of meta information.
            **handlers (Any): Keyword arguments are translated in to handlers.

        Returns:
            Style: A Style with meta information attached.
        Nc                      i | ]\  }}d | |S )@r1   ).0keyvalues      r!   
<dictcomp>zStyle.on.<locals>.<dictcomp>  s$    III*#uYYYIIIr#   )updateitemsr   )r   rm   r   s      r!   onzStyle.on   sN     \rrtII8H8HIIIJJJ}}T"""r#   r   r   rI   rJ   rK   rL   rM   rN   rO   rP   rQ   rR   rS   c                     | j         S )z+Get a link id, used in ansi code for links.)r9   r    s    r!   link_idzStyle.link_id       }r#   c                    | j         g }|j        }| j        }|dz  rd|dz  r || j        rdnd           |dz  r || j        rdnd           |d	z  r || j        rd
nd           |dz  r || j        rdnd           |dz  r}|dz  r || j        rdnd           |dz  r || j        rdnd           |dz  r || j	        rdnd           |dz  r || j
        rdnd           |dz  r || j        rdnd           |dz  rd|d z  r || j        rd!nd"           |d#z  r || j        rd$nd%           |d&z  r || j        rd'nd(           |d)z  r || j        rd*nd+           | j         || j        j                   | j          |d,            || j        j                   | j        r |d-            || j                   d.                    |          pd/| _         | j         S )0z-Re-generate style definition from attributes.N   r   rV   znot boldrI   rT   znot dimrK   rX   z
not italicrO   rZ   znot underline  rt   r\   z	not blinkru   r]   z
not blink2rv   r^   znot reverserw   r`   znot concealrx   rb   z
not strike   ry   rd   znot underline2rz   re   z	not framer{   rf   znot encircler|   rg   znot overliner   rl    none)r;   appendr'   rV   rT   rX   rZ   r\   r]   r^   r`   rb   rd   re   rf   rg   r3   namer4   r8   join)r    
attributesr   bitss       r!   __str__zStyle.__str__  s   !)$&J&F'Do% O!8 @FTY>66J???6? =FDH;55)<<<6? FFt{D88EEE6? OF$.M;;oNNNo% 
F6? CFdjA77kBBB6? FFt{D88EEE6? IFG99-HHH6? IFG99-HHH6? FFt{D88EEEo% L6? RF4?P<<@PQQQ7# CFdjA77kBBB7# LFJ::NKKK7# LFJ::NKKK{&t{'(((}(tt})***z #vtz"""%(XXj%9%9%CVD"%%r#   c                     | j          S )z;A Style is false if it has no attributes, colors, or links.)r6   r   s    r!   __bool__zStyle.__bool__K  s    :~r#   color_systemc                 &   | j         g }|j        }| j        }| j        | j        z  }|r|dz  r ||d                    |dz  r ||d                    |dz  r ||d                    |dz  r ||d                    |dz  r,t          dd	          D ]}|d|z  z  r |||                    |d
z  r,t          d	d          D ]}|d|z  z  r |||                    | j        ?|                    | j                            |          	                                           | j
        A|                    | j
                            |          	                    d                     d                    |          | _         | j         S )zGenerate ANSI codes for this style.

        Args:
            color_system (ColorSystem): Color system.

        Returns:
            str: String containing codes.
        Nr   r   rI   rK   rO   rJ   r   rP   r      F
foreground;)r:   r   
_style_mapr(   r'   ranger3   extend	downgradeget_ansi_codesr4   r   )r    r   sgrr   r   r   r   s          r!   _make_ansi_codeszStyle._make_ansi_codesO  s    :CZFJ)D,@@J 4> *F:a=)))> *F:a=)))> *F:a=)))> *F:a=)))/ 4$Q{{ 4 4%c2 4"F:c?333/ 4$Q|| 4 4%c2 4"F:c?333{&

4;00>>MMOOPPP}(

M++L99HH#( I    
 #DJzr#   rz   )maxsizer   c                     	 t          |                     |                    S # t          j        $ r) |                                                                cY S w xY w)zNormalize a style definition so that styles with the same effect have the same string
        representation.

        Args:
            style (str): A style definition.

        Returns:
            str: Normal form of style definition.
        )r   rr   r   StyleSyntaxErrorstriplower)r   r   s     r!   	normalizezStyle.normalizez  s_    	)syy''(((& 	) 	) 	);;==&&(((((	)s   !$ 5AAvaluesc                 6    |D ]}||c S 	t          d          )zPick first non-None style.Nz$expected at least one non-None style)
ValueError)r   r   r   s      r!   
pick_firstzStyle.pick_first  s6      	 	E  !?@@@r#   c              #     K   d| j         d fV  d| j        d fV  d| j        d fV  d| j        d fV  d| j        d fV  d| j        d fV  d| j        d fV  d| j        d fV  d	| j        d fV  d
| j	        d fV  d| j
        d fV  d| j        d fV  d| j        d fV  d| j        d fV  d| j        d fV  | j        rd| j        fV  d S d S )Nrj   rk   rV   rT   rX   rZ   r\   r]   r^   r`   rb   rd   re   rf   rl   rm   )rj   rk   rV   rT   rX   rZ   r\   r]   r^   r`   rb   rd   re   rf   rl   r7   rm   r   s    r!   __rich_repr__zStyle.__rich_repr__  sn     tz4''''t++++di&&&&TXt$$$$T))))4>40000tz4''''T))))t++++t++++T))))DOT1111tz4''''$-----di%%%%: 	$$)######	$ 	$r#   otherc                     t          |t                    st          S |                                 |                                k    S rp   rq   r   NotImplemented__hash__r    r   s     r!   __eq__zStyle.__eq__  7    %'' 	"!!}}%.."2"222r#   c                     t          |t                    st          S |                                 |                                k    S rp   r   r   s     r!   __ne__zStyle.__ne__  r   r#   c                     | j         | j         S t          | j        | j        | j        | j        | j        | j        f          | _         | j         S rp   )r5   r   r3   r4   r(   r'   r8   r7   r   s    r!   r   zStyle.__hash__  sR    :!: $

	
 	

 zr#   c                     | j         S )z.The foreground color or None if it is not set.)r3   r   s    r!   rj   zStyle.color  s     {r#   c                     | j         S )z.The background color or None if it is not set.)r4   r   s    r!   rk   zStyle.bgcolor  r   r#   c                     | j         S )zLink text, if set.)r8   r   s    r!   rl   z
Style.link  s     zr#   c                 ,    | j         du p| j         j        S )z6Check if the style specified a transparent background.N)rk   
is_defaultr   s    r!   transparent_backgroundzStyle.transparent_background  s     |t#>t|'>>r#   c                 ,    t          | j                  S )zA Style with background only.)rk   )r   rk   r   s    r!   background_stylezStyle.background_style  s     T\****r#   c                     | j         i n8t          t          t          t          f         t          | j                             S )z=Get meta information (can not be changed after construction).)r7   r   r   r   r   r   r   s    r!   rm   z
Style.meta  s1     Z'rrT$sCx.%
BSBS-T-TTr#   c                 >   | j         rt          S |                     t                    }d|_        d|_        d|_        d|_        | j        |_        | j	        |_	        | j
        |_
        | j
        rt          dd           nd|_        d|_         d|_        d|_        |S )z+Get a copy of the style with color removed.Nr   r}   r~   F)r6   r   r   r   r:   r;   r3   r4   r(   r'   r8   r   r9   r7   r5   r    r   s     r!   without_colorzStyle.without_color  s     : 	||E**"& , $ 4j48JFGAv..00Br#   r|   style_definitionc                    |                                 dk    s|s|                                 S | j        }d}d}i }d}t          |                                          }|D ][}|                                }	|	dk    rnt          |d          }	|	st          j        d          	 t          j
        |	          du  n-# t          $ r }
t          j        d|	d|
           dd}
~
ww xY w|	}|	dk    rDt          |d          }	|                    |	          }|t          j        d	|	          d
||<   |	dk    r*t          |d          }	|	st          j        d          |	}|	|v rd|||	         <   	 t          j
        |	           n-# t          $ r }
t          j        d|	d|
           dd}
~
ww xY w|	}]t          d|||d|}|S )a  Parse a style definition.

        Args:
            style_definition (str): A string containing a style.

        Raises:
            errors.StyleSyntaxError: If the style definition syntax is invalid.

        Returns:
            `Style`: A Style instance.
        r   Nr   r~   zcolor expected after 'on'zunable to parse z as background color; notz,expected style attribute after 'not', found Frl   zURL expected after 'link'Tz as color; )rj   rk   rl   r1   )r   r   STYLE_ATTRIBUTESitersplitr   nextr   r   r   rr   r   getr   )r   r   r   rj   rk   r   rl   wordsoriginal_wordworderror	attributer   s                r!   rr   zStyle.parse  sh    !!##v--5E-88::/#!%/1
"%++--.." '	 '	M &&((Dt||E2 O 12MNNN K%%---&       1P4PPPP    E2,0066	$ 1OtOO   ).
9%%E2 O 12MNNN)))59
+D122 K%%%%&       1E4EEeEE    LE7LLLLs0   %B<<
C&C!!C&8F
F7F22F7themec                    |pt           }g }|j        }| j        }| j        }| j        r||}}| j        rF||j        n|                    |          }t          j	        t          ||j        d                    }|;|                    |          } |d|j                     |d|j                    |*|                    |d          } |d|j                    | j        r |d           | j        r |d	           | j        r |d
           | j        r |d           | j        r |d           d                    |          S )zGet a CSS style rule.Ng      ?zcolor: ztext-decoration-color: Fr   zbackground-color: zfont-weight: boldzfont-style: italicztext-decoration: underlineztext-decoration: line-throughztext-decoration: overlinez; )r   r   rj   rk   r^   rT   foreground_colorget_truecolorr   from_tripletr   background_colorhexrV   rX   rZ   rb   rg   r   )r    r   cssr   rj   rk   r   theme_colors           r!   get_html_stylezStyle.get_html_style3  s    //
,< 	,$e7E8 	*/-&&U=P=PQV=W=W  &*E,BCHH E --e44KF.[_..///F>[_>>???!//%/HHKF999:::9 	(F&'''; 	)F'(((> 	1F/000; 	4F2333= 	0F.///yy~~r#   stylesc                 Z    t          |          }t          |t          |                    S )zCombine styles and get result.

        Args:
            styles (Iterable[Style]): Styles to combine.

        Returns:
            Style: A new style instance.
        r   r   r   r   r   iter_styless      r!   combinezStyle.combineX  '     6ll;[ 1 1222r#   c                 Z    t          |          }t          |t          |                    S )zCombine styles from positional argument in to a single style.

        Args:
            *styles (Iterable[Style]): Styles to combine.

        Returns:
            Style: A new style instance.
        r   r   s      r!   chainzStyle.chaine  r   r#   c                 z   | j         rt          S |                     t                    }| j        |_        | j        |_        | j        |_        | j        |_        | j        |_        | j	        |_	        | j
        |_
        | j
        rt          dd           nd|_        | j        |_        d|_         | j        |_        |S )zwGet a copy of this style.

        Returns:
            Style: A new Style instance with identical attributes.
        r   r}   r~   F)r6   r   r   r   r:   r;   r3   r4   r(   r'   r8   r   r9   r5   r7   r   s     r!   copyz
Style.copyr  s     : 	||E**j"&"8{ , $ 4j48JFGAv..00Bjjr#   c                 @   |                      t                    }| j        |_        | j        |_        | j        |_        | j        |_        | j        |_        | j        |_        ||_        |rt          dd           nd|_
        d|_        d|_        | j        |_        |S )zGet a copy with a different value for link.

        Args:
            link (str, optional): New value for link. Defaults to None.

        Returns:
            Style: A new Style instance.
        r   r}   r~   NF)r   r   r:   r;   r3   r4   r(   r'   r8   r   r9   r5   r6   r7   )r    rl   r   s      r!   update_linkzStyle.update_link  s     ||E**j"&"8{ , $ 448@GAv..00bjr#   r~   F)r   legacy_windowstextr   c                    |r||S | j         p|                     |          }|r	d| d| dn|}| j        r|sd| j         d| j         d| d}|S )	aD  Render the ANSI codes for the style.

        Args:
            text (str, optional): A string to style. Defaults to "".
            color_system (Optional[ColorSystem], optional): Color system to render to. Defaults to ColorSystem.TRUECOLOR.

        Returns:
            str: A string containing ANSI style codes.
        Nz[mz[0mz]8;id=r   z\z]8;;\)r:   r   r8   r9   )r    r   r   r   attrsrendereds         r!   renderzStyle.render  s       	|+K
Ad33LAA49C050040000t: 	n 	WT]WWTZWWxWWW  r#   c                     |pt          |           }t          j                            |                     |           d           dS )zWrite text with style directly to terminal.

        This method is for testing purposes only.

        Args:
            text (Optional[str], optional): Text to style or None for style name.

        
N)r   sysstdoutwriter  )r    r   s     r!   testz
Style.test  sE      s4yy
DKK--11122222r#   c                 6   ||j         r| S | j         r|S |                     t                    }d |_        d |_        |j        p| j        |_        |j        p| j        |_        | j        |j         z  |j        |j        z  z  |_        | j        |j        z  |_        |j	        p| j	        |_	        |j
        p| j
        |_
        |j         |_         | j        r*|j        r#t          i | j        |j                  |_        n| j        p|j        |_        d |_        |S rp   )r6   r   r   r:   r;   r3   r4   r(   r'   r8   r9   r7   r   rm   r5   )r    r   	new_styles      r!   _addz
Style._add  s   =EK=K: 	L<<..		&*	# <64;	"^<t}	!%!1U5J4J!J 55!
	 %)$85;P$P	!+3	"^<t}	+	: 	8%+ 	8#$?ty$?EJ$?@@IOO"j7EKIO	r#   c                 f    |                      |          }|j        r|                                n|S rp   )r  rl   r   )r    r   combined_styles      r!   __add__zStyle.__add__  s2    5))(6(;O~""$$$Or#   )r   r   )NNrp   )r   r   r   r   )r~   )Hr*   r+   r,   r-   r   r   __annotations__r/   r0   bytesr.   r   r   r   r   r   r   r"   classmethodr   r   r   r   r   rV   rT   rX   rZ   r\   r]   r^   r`   rb   rd   re   rf   rg   propertyr   r   r   r   r   r   r   	StyleTyper   r   r   r   r   r   rj   rk   rl   r   r   rm   r   rr   r   r   r	   r   r   r   r   	TRUECOLORr  r	  r  r  r1   r#   r!   r   r      s	         4 UOuoC=KKKE?  I   J uU 	 	V	
 	( 	X 	[ 	[ 	 	( 	9 	Y 	9 	Y 	(  	X!" 	l#$ -  8 .2/3#"!%$( $!%"&"&!%%) $#'#'")-'JT JT JT eSj)*JT %s
+,	JT
 tnJT d^JT JT D>JT ~JT JT $JT $JT JT TNJT ~JT  4.!JT" 4.#JT$ sm%JT& tCH~&'JT JT JT JTX    [ GK UO5=e_	   [. Xd38n5 '    [( # #htCH~. #3 #7 # # # [#" 477D
$q''CT!WWFQIDGGET!WWFd1ggGd1ggGT!WWFaJDHHEtBxxHtBxxH    X,& ,& ,& ,& ,&\$    )[ )S ) ) ) )V Yt)c )c ) ) )  [) A)!4 A A A A [A$v $ $ $ $&3C 3D 3 3 3 3
3C 3D 3 3 3 3
#     x    X %    X hsm    X ? ? ? ? X? + + + X+ Ud38n U U U XU    X$ Yt?S ?W ? ? ?  [?B Yt" "H]$; "s " " " "H 
3Xg. 
37 
3 
3 
3 [
3 
3 
3 
3 [
3   ,      2  /:.C$   {+	
  
   4
3 
3# 
3$ 
3 
3 
3 
3 Yt(7+     0PXg. P7 P P P P P Pr#   c                   d    e Zd ZdZdgZddZdefdZede	fd	            Z
d
e	ddfdZde	fdZdS )
StyleStackzA stack of styles._stackdefault_styler   r   Nc                     |g| _         d S rp   r  )r    r  s     r!   r"   zStyleStack.__init__  s    $1?r#   c                     d| j         dS )Nz<stylestack >r  r   s    r!   __repr__zStyleStack.__repr__  s    .dk....r#   c                     | j         d         S )z&Get the Style at the top of the stack.r  r   s    r!   currentzStyleStack.current  s     {2r#   r   c                 V    | j                             | j         d         |z              dS )z}Push a new style on to the stack.

        Args:
            style (Style): New style to combine with current style.
        r   N)r  r   r   s     r!   pushzStyleStack.push  s+     	4;r?U233333r#   c                 N    | j                                          | j         d         S )z}Pop last style and discard.

        Returns:
            Style: New current style (also available as stack.current)
        r   )r  popr   s    r!   r%  zStyleStack.pop  s"     	{2r#   )r  r   r   N)r*   r+   r,   r-   r.   r"   r   r  r  r   r!  r#  r%  r1   r#   r!   r  r    s        
I3 3 3 3/# / / / /     X4% 4D 4 4 4 4U      r#   r  )$r  	functoolsr   marshalr   r   randomr   typingr   r   r	   r
   r   r   r   r   r~   r   rj   r   r   r   r   reprr   r   terminal_themer   r   r   r  r   r   r   r  r1   r#   r!   <module>r,     s   



                             I I I I I I I I I I I I I I I I I I I I       A A A A A A A A A A A A # # # # # # # # A A A A A A A A #w,	        AP AP AP AP AP AP AP APH UWW
         r#   