e SSKrSSKrSSKrSSKJrJr SSKJr \R"S5r\R"S5r \ RSSS.5r \RS \ S \4S j5rS \ S \4S jrSS \ S\S \ 4SjjrS\ S \\\44Sjrg)N) CharBuffer CharWidths)tracez\x1b\[[ -@]*[A-~]z \x01.*?\x02)creturnc^[U5S:ag[R"U5nUS;agg)Nr)NNaHA)ord unicodedataeast_asian_width)r ws 3/opt/imh/python3.13/lib/python3.13/_pyrepl/utils.py str_widthr s/ 1v|$$Q'A !! sc[U5S:XaUS:wa [U5$[SU55n[R U5nUR S5nU[SU55- U-$)Nrc38# UHn[U5v M g7fN)r.0is r wlen..s)q!1qc38# UHn[U5v M g7fr)lenrs rr"r#s11Ar$)r&rsumANSI_ESCAPE_SEQUENCEfindallcount)rlengthsequence ctrl_z_cnts rwlenr.se 1v{qF{| )q) )F#++A.HJ C111 1J >>rincluding_contentcfU(a[RSU5$UR[5$)zReturn `s` with \001 and \002 characters removed. If `including_content` is True, content between \001 and \002 is also stripped. r)ZERO_WIDTH_BRACKETsub translateZERO_WIDTH_TRANS)rr/s r unbracketr5!s* !%%b!,, ;;' ((rbufferc8/n/nU(dX4$UHnUS:Xa$URU5 URS5 M-[U5S:a$URU5 URS5 M`[R"U5R S5(a;S[U5-nURU5 UR[ U55 MURU5 UR[ U55 M [S[U5XS9 X4$) a6Decompose the input buffer into a printable variant. Returns a tuple of two lists: - the first list is the input buffer, character by character; - the second list is the visible width of each character in the input buffer. Examples: >>> utils.disp_str("a = 9") (['a', ' ', '=', ' ', '9'], [1, 1, 1, 1, 1]) rrr rCz\u%04xzdisp_str({buffer}) = {s}, {b})r6rb) appendrrcategory startswithr&rrrepr)r6chars char_widthsr s rdisp_strr@,sE K !!  ; LLO   q ! Vc\ LLO   q !  ! !! $ / / 4 4CF"A LLO   s1v & LLO   y| , )$v,%W  r)F)rer functoolstypesrrrcompiler(r1str maketransr4cacheintrr.boolr5tupler@rrrLs )zz"67ZZ/=="b!9:     ?C?C?)))#)!S!U:z#9:!r