
    ,hP                         d Z ddlZddlmZ ddl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mZmZmZmZmZ g dZ G d d	e      Z G d
 de      Z G d de      Zy)z
    pygments.lexers.textedit
    ~~~~~~~~~~~~~~~~~~~~~~~~

    Lexers for languages related to text processing.

    :copyright: Copyright 2006-2025 by the Pygments team, see AUTHORS.
    :license: BSD, see LICENSE for details.
    N)bisect)
RegexLexerbygroupsdefaultincludethisusing)PythonLexer)	CommentKeywordNameNumberOperatorPunctuationStringText
Whitespace)AwkLexerSedLexerVimLexerc                      e Zd ZdZdZg dZdgZdgZdZdZ	de
fd	ej                  fg ed
      dej                  dfde
df ed      gde
dfgde
df ed
      dedfdedfdefdedfdej(                  dfdej*                  fdej.                  fdej0                  fdej4                  fdej6                  fdej8                  fdej:                  fdej                  fgdZy )!r   z
    For Awk scripts.
    Awk)awkgawkmawknawkz*.awkzapplication/x-awkz!https://en.wikipedia.org/wiki/AWKz1.5\s+#.*$commentsandwhitespacez(/(\\.|[^[/\\\n]|\[(\\.|[^\]\\\n])*])+/\B#popz(?=/))r    badregexz\nz	^(?=\s|/)slashstartsregexz8\+\+|--|\|\||&&|in\b|\$|!?~|\?|:|(\*\*|[-<>+*%\^/!=|])=?z[{(\[;,]z[})\].]z3(break|continue|do|while|exit|for|if|else|return)\bz
function\bz(atan2|cos|exp|int|log|rand|sin|sqrt|srand|gensub|gsub|index|length|match|split|sprintf|sub|substr|tolower|toupper|close|fflush|getline|next|nextfile|print|printf|strftime|systime|delete|system)\bz(ARGC|ARGIND|ARGV|BEGIN|CONVFMT|ENVIRON|END|ERRNO|FIELDWIDTHS|FILENAME|FNR|FS|IGNORECASE|NF|NR|OFMT|OFS|ORFS|RLENGTH|RS|RSTART|RT|SUBSEP)\bz[$a-zA-Z_]\w*z%[0-9][0-9]*\.[0-9]+([eE][0-9]+)?[fd]?z0x[0-9a-fA-F]+[0-9]+z"(\\\\|\\[^\\]|[^"\\])*"z'(\\\\|\\[^\\]|[^'\\])*')r   r"   r!   rootN)__name__
__module____qualname____doc__namealiases	filenames	mimetypesurlversion_addedr   r   Singler   r   Regexr   r   r   r   DeclarationReservedr   BuiltinOtherr   FloatHexIntegerDoubletokens     Z/var/www/html/Resume-Scraper/venv/lib/python3.12/site-packages/pygments/lexers/textedit.pyr   r      sc    D-G	I$%I
-CM TNgnn%"

 +,LL&*t12FO
 D&!
 4!34+,()13EG+'9:%"$68G//1CD! #*"2"24$%)\\3 tzz*5v||D

+'(&--8(&--8-
'Fr;   r   c                   B   e Zd ZdZdZg dZddgZdgZdZdZ	e
j                  Zd	Zd
defdej                   fdej$                  fdefdefdefd eeej                         fd eeej0                        fd eeej$                        fdez   dz    eeej2                  e      fdez   dz    eedej2                  e      fdez   dz   ez   dz    eeeej                   eej                   e      fdez   dz   ez   dz    eeeej2                  eej                   ee      fgiZy)r   z%
    Lexer for Sed script files.
    Sed)sedgsedssedz*.sedz	*.[gs]sedz
text/x-sedz!https://en.wikipedia.org/wiki/Sed z.((?:(?:\\[^\n]|[^\\])*?\\\n)*?(?:\\.|[^\\])*?)r$   r   r   r#   z\$z[{};,!]z[dDFgGhHlnNpPqQxz=]z([berRtTvwW:])([^;\n]*)z"([aci])((?:.*?\\\n)*(?:.*?[^\\]$))z([qQ])([0-9]*)z(/)z(\\(.))z(\2)Nz(y)(.)z(s)(.)z(\2)((?:[gpeIiMm]|[0-9])*))r%   r&   r'   r(   r)   r*   r+   r,   r-   r.   re	MULTILINEflags_inside_delimsr   r   r/   r   r7   r   r   r   r   r   r8   r0   r9   r:   r;   r<   r   r   L   s{    D%G+&II
-CMLLE GN 	Z gnn%'H%#W-''6==)IJ2HWfmm4TU&.. ABn$v-xV\\S^/_`.(72k4{CE''1NBWLg{FMM;Wbce''1NBEbbg{FLL+v}}Va 
Fr;   r   c                      e Zd ZdZdZdgZg dZdgZdZdZ	e
j                  ZdZd	d
ez   dz    e ee      eeeee ee      e      fd
ez   dz    e ee      ee ee            fdefdefdej.                  fdej0                  fdej2                  fdefdefdej6                  fdefdefdefdej<                  fdej>                  fdefgiZ d Z!d Z"d Z#y)r   z&
    Lexer for VimL script files.
    VimLvim)	z*.vimz.vimrcz.exrcz.gvimrc_vimrc_exrc_gvimrcvimrcgvimrcz
text/x-vimzhttps://www.vim.orgz0.8zpy(?:t(?:h(?:o(?:n)?)?)?)?r$   z^([ \t:]*)(z()([ \t]*)(<<)([ \t]*)(.*)((?:\n|.)*)(\6)z)([ \t])(.*)z^\s*".*z[ \t]+z!/[^/\\\n]*(?:\\[\s\S][^/\\\n]*)*/z!"[^"\\\n]*(?:\\[\s\S][^"\\\n]*)*"z'[^\n']*(?:''[^\n']*)*'z(?<=\s)"[^\-:.%#=*].*z-?\d+z#[0-9a-f]{6}z^:z[()<>+=!|,~-]z7\b(let|if|else|endif|elseif|fun|function|endfunction)\bz+\b(NONE|bold|italic|underline|dark|light)\bz\b\w+\b.c                 n    ddl m}m}m} || _        || _        || _        t        j                  | fi | y )Nr   )autocommandoption)	pygments.lexers._vim_builtinsrQ   rR   rS   _cmd_opt_autr   __init__)selfoptionsrQ   rR   rS   s        r<   rX   zVimLexer.__init__   s0    GG			D,G,r;   c                 ,   t        ||f      }|dkD  r>||dz
     d   |dt        ||dz
     d          k(  r||dz
     d   dt        |       |k(  ry|t        |      k  r6||   d   |dt        ||   d          k(  xr ||   d   dt        |       |k(  S y)a  
        It's kind of difficult to decide if something might be a keyword
        in VimL because it allows you to abbreviate them.  In fact,
        'ab[breviate]' is a good example.  :ab, :abbre, or :abbreviate are
        valid ways to call it so rather than making really awful regexps
        like::

            \bab(?:b(?:r(?:e(?:v(?:i(?:a(?:t(?:e)?)?)?)?)?)?)?)?\b

        we match `\b\w+\b` and then call is_in() on those tokens.  See
        `scripts/get_vimkw.py` for how the lists are extracted.
        r      NTF)r   len)rY   wmappingps       r<   is_inzVimLexer.is_in   s     7QD!q5qs|A!$9S1a%9"::qs|AwA'1,s7|1:a=A&9s71:a='9$:: ,
1gs1v&!+,r;   c              #     K   t        j                  | |      D ]  \  }}}|t        j                  u r| j	                  || j
                        r|t        |f A| j	                  || j                        s| j	                  || j                        r|t        j                  |f |t        |f |||f  y w)N)r   get_tokens_unprocessedr   r4   ra   rU   r   rV   rW   r3   r   )rY   textindextokenvalues        r<   rc   zVimLexer.get_tokens_unprocessed   s     
 11$=	*E5%

"::eTYY/%//ZZtyy1

5$))4u44u,,UE))	*s   B<B>N)$r%   r&   r'   r(   r)   r*   r+   r,   r-   r.   rC   rD   rE   _pythonr   r	   r   r   r   r   r
   r   r   r0   r8   r/   r   r6   r   r   r3   r4   r9   rX   ra   rc   r:   r;   r<   r   r   q   sK    DgGBII
CMLLE+G 	g%(SSeDk7D(D$K($01 g%7eDk7D%2DEG !16<<@16==A'7 &w/vfjj)K {+G;T\\J$4L3
F<-.*r;   r   )r(   rC   r   pygments.lexerr   r   r   r   r   r	   pygments.lexers.pythonr
   pygments.tokenr   r   r   r   r   r   r   r   r   __all__r   r   r   r:   r;   r<   <module>rm      sY    
  N N .* * * /3z 3l#z #J\*z \*r;   