hyb
2026-01-30 15bc7727b58bf9ca0c8f21702fa893daac232b8d
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
Ë
ñúhÀ¹ãóÚ—UddlZddlmZmZddlmZddlmZddlm    Z    m
Z
m Z m Z m Z mZmZmZmZmZmZddlmZddlmZdd    lmZdd
lmZdd lmZmZdd lm Z dd l!m"Z"ddl#m$Z$ddl%m&Z&ddl'm(Z(ddl)m*Z*ddl+m,Z,m-Z-e    r ddl.m/Z/m0Z0m1Z1m2Z2dZ3de4d<dZ5de4d<ejld«Z7ee8dfZ9    e e8gee-fZ:Gd„de«Z;Gd„de&«Z<e=dk(rdd l>m/Z/e<d!«Z?e?jd"gd#«e?jd$gd%«e/«Z.e.jƒd&«e.j…e?d'¬(«e.j…«e.jƒd)«e.j…e?d*d+¬,«e.j…«e.jƒd-«e.j…e?d.d/¬,«e.j…«e.jƒd0«e.j…e?d1d2¬,«e.j…«yy)3éN)ÚpartialÚreduce)Úgcd)Ú
itemgetter) Ú TYPE_CHECKINGÚAnyÚCallableÚDictÚIterableÚListÚ
NamedTupleÚOptionalÚPatternÚTupleÚUnioné)Ú    loop_last)Ú    pick_bool)Ú divide_line)Ú AlignMethod)Úcell_lenÚ set_cell_size)ÚLines)Ústrip_control_codes)Ú EmojiVariant)Ú JupyterMixin)Ú Measurement)ÚSegment)ÚStyleÚ    StyleType)ÚConsoleÚConsoleOptionsÚ JustifyMethodÚOverflowMethodÚdefaultr#ÚDEFAULT_JUSTIFYÚfoldr$ÚDEFAULT_OVERFLOWz\s+$ÚTextcó¨—eZdZUdZeed<    eed<    eeefed<    defd„Z    de
fd„Z dede de dffd    „Zdeddfd
„Zdeddfd „Zd eddfd „Zy)ÚSpanz A marked up region in some text.ÚstartÚendÚstyleÚreturncóV—d|j›d|j›d|j›dS)NzSpan(z, ú))r,r-r.©Úselfs úHH:\Change_password\venv_build\Lib\site-packages\pip/_vendor/rich/text.pyÚ__repr__z Span.__repr__9s)€Øt—z‘zl " T§X¡X J¨b°·±°¸aÐ@Ð@ócó4—|j|jkDS©N)r-r,r2s r4Ú__bool__z Span.__bool__<s€Øx‰x˜$Ÿ*™*Ñ$Ð$r6Úoffsetcó¾—||jkr|dfS||jk\r|dfS|\}}}t|t||«|«}t|j||«}||fS)z)Split a span in to 2 from a given offset.N)r,r-r+Úmin)r3r:r,r-r.Úspan1Úspan2s       r4Úsplitz
Span.split?sm€ð D—J‘JÒ Ø˜:Ð Ø T—X‘XÒ Ø˜:Ð à ÑˆˆsEܐUœC  VÓ,¨eÓ4ˆÜU—Y‘Y  UÓ+ˆØeˆ|Ðr6có4—|\}}}t||z||z|«S)zÔMove start and end by a given offset.
 
        Args:
            offset (int): Number of characters to add to start and end.
 
        Returns:
            TextSpan: A new TextSpan with adjusted position.
        ©r+©r3r:r,r-r.s     r4Úmovez    Span.moveLs'€ð!шˆsEܐE˜F‘N C¨&¡L°%Ó8Ð8r6cóJ—|\}}}||k\r|St|t||«|«S)z¶Crop the span at the given offset.
 
        Args:
            offset (int): A value between start and end.
 
        Returns:
            Span: A new (possibly smaller) span.
        )r+r<rBs     r4Ú
right_cropzSpan.right_cropXs2€ð!шˆsEØ SŠ=؈KܐEœ3˜v sÓ+¨UÓ3Ð3r6Úcellscó6—|r|\}}}t|||z|«S|S)z²Extend the span by the given number of cells.
 
        Args:
            cells (int): Additional space to add to end of span.
 
        Returns:
            Span: A span.
        rA)r3rFr,r-r.s     r4Úextendz Span.extendfs+€ñ Ø $Ñ ˆE3˜Ü˜˜s U™{¨EÓ2Ð 2àˆKr6N)Ú__name__Ú
__module__Ú __qualname__Ú__doc__ÚintÚ__annotations__rÚstrrr5Úboolr9rrr?rCrErH©r6r4r+r+/sœ…Ù*à ƒJØØ     ƒHØØ eÑ ÓØ)ðA˜#óAð%˜$ó%ð ˜Cð  E¨&°(¸6Ñ2BÐ*BÑ$Có ð
9˜3ð
9 6ó
9ð 4 ð 4¨ó 4ð ˜Cð  Fô r6r+có—eZdZdZgd¢Z        ddddddddœdedeeefd    ed
d ed d ee    dedee
dee e ddfd„Z de
fd„Zde    fd„Zdefd„Zdefd„Zdeddfd„Zdede    fd„Zdede    fd„Zdee
efddfd„Zede
fd„«Zedefd„«Zeddddddd œdedeeefd!e    d"eed    ed
d ed deddfd#„«Zedddddd$d%œdedeeefd    ed
d ed d ee    dedee
ddfd&„«Ze    d€ddd'œdede d    ed
d ed ddf
d(„«Z!edddddd$dd)œd*eede"ee ffdeeefd    ed
d ed d ee    dede
d+ee#eefddfd,„«Z$edefd-„«Z%e%jLd.eddfd/„«Z%ede e fd0„«Z'e'jLde e ddfd1„«Z'd€d2eddfd3„Z(dd4„Z)        d‚deeefd5e
dee
ddfd6„Z*        d‚deeefd5e
dee
ddfd7„Z+    d‚d+e#eefd5e
dee
ddfd8„Z,dƒd+ee#eefd9eddfd:„Z-d;eddfd<„Z.d=d>d?e
defd@„Z/dAe
ddfdB„Z0    dƒddCœdDee1eefdeee2e fdEede
fdF„Z3ddGœdHe4edeeefdIe    de
fdJ„Z5d„dK„Z6dLe
ddfdM„Z7dNe
ddfdO„Z8d=d>dPdQde4e9fdR„Z:d=d>dPdQde;fdS„Z<d€d=d>dede4dTfdU„Z=dVe4dddfdW„Z>dƒdee
ddfdX„Z?ddYdZœd[e
d ed d\e    ddfd]„Z@d„d^„ZAd…d_e
d`eddfda„ZBd…d_e
d`eddfdb„ZCd…d_e
d`eddfdc„ZDd…ddeEdee
d`eddfdf„ZF    dƒdedefdeeedgfddfdh„ZGd†di„ZHdje4e"eee fddfdk„ZId‡dl„ZJ    dˆdYdYdmœdnedoe    dpe    deKfdq„ZLdre4e
deKfds„ZMd‰dte
ddfdu„ZNddd$ddvœd=d>dee
d    ed
d ed de
d ee    deKfdw„ZOdee
deKfdx„ZPde
fdy„ZQ    dƒdzd{d|œd}ee
d`ede ddfd~„ZRy)Šr)aùText with color / style.
 
    Args:
        text (str, optional): Default unstyled text. Defaults to "".
        style (Union[str, Style], optional): Base style for text. Defaults to "".
        justify (str, optional): Justify method: "left", "center", "full", "right". Defaults to None.
        overflow (str, optional): Overflow method: "crop", "fold", "ellipsis". Defaults to None.
        no_wrap (bool, optional): Disable text wrapping, or None for default. Defaults to None.
        end (str, optional): Character to end text with. Defaults to "\\n".
        tab_size (int): Number of spaces per tab, or ``None`` to use ``console.tab_size``. Defaults to None.
        spans (List[Span], optional). A list of predefined style spans. Defaults to None.
    )    Ú_textr.ÚjustifyÚoverflowÚno_wrapr-Útab_sizeÚ_spansÚ_lengthÚNú
)rTrUrVr-rWÚspansÚtextr.rTr#rUr$rVr-rWr\r/có´—t|«}    |    g|_||_||_||_||_||_||_|xsg|_t|    «|_
yr8) rrSr.rTrUrVr-rWrXÚlenrY)
r3r]r.rTrUrVr-rWr\Úsanitized_texts
          r4Ú__init__z Text.__init__sY€ô-¨TÓ2ˆØ$Ð%ˆŒ
؈Œ
Ø29ˆŒ Ø4<ˆŒ ؈Œ ؈ŒØ ˆŒ Ø"'¢+¨2ˆŒ Ü Ó/ˆ r6có—|jSr8)rYr2s r4Ú__len__z Text.__len__§s €Ø|‰|Ðr6có,—t|j«Sr8)rPrYr2s r4r9z Text.__bool__ªs€ÜD—L‘LÓ!Ð!r6có—|jSr8©Úplainr2s r4Ú__str__z Text.__str__­s €Øz‰zÐr6cóV—d|j›d|j›d|j›dS)Nz<text ú ú>)rgrXr.r2s r4r5z Text.__repr__°s)€Ø˜Ÿ
™
~ Q t§{¡{ o°Q°t·z±z°nÀAÐFÐFr6Úothercó€—t|ttf«r#|j«}|j    |«|St
Sr8)Ú
isinstancerOr)ÚcopyÚappendÚNotImplemented)r3rlÚresults   r4Ú__add__z Text.__add__³s2€Ü eœc¤4˜[Ô )Ø—Y‘Y“[ˆFØ M‰M˜%Ô  ØˆMÜÐr6có–—t|t«stS|j|jk(xr|j|jk(Sr8)rnr)rqrgrX©r3rls  r4Ú__eq__z Text.__eq__ºs7€Ü˜%¤Ô&Ü!Ð !؏z‰z˜UŸ[™[Ñ(ÒH¨T¯[©[¸E¿L¹LÑ-HÐHr6có—t|t«r||jvSt|t«r|j|jvSy)NF)rnrOrgr)rus  r4Ú __contains__zText.__contains__¿s;€Ü eœSÔ !ؘDŸJ™JÐ&Ð &Ü ˜œtÔ $Ø—;‘; $§*¡*Ð,Ð ,Ør6Úslicecóð‡—dtddfˆfd„ }t|t«r||«S|jt‰j««\}}}|dk(r‰j ||g«}|dSt d«‚)Nr:r/r)c óĕ—t}t‰j|‰jDcgc]\}}}||cxkDr|k\r nn
|dd|«‘Œ c}}}d¬«}|Scc}}}w)NrrrZ)r\r-)r+r)rgrX)r:Ú_Spanr,r-r.r]r3s      €r4Ú get_text_atz%Text.__getitem__.<locals>.get_text_atÇslø€ÜˆEÜØ—
‘
˜6Ñ"ð.2¯[©[÷ðá)˜˜s EؘVÔ, uÕ,ñ˜!˜Q Õ&ôð
ôˆDðˆKùôs«#Arz%slices with step!=1 are not supported)rMrnÚindicesr_rgÚdivideÚ    TypeError)r3ryr}r,ÚstopÚstepÚliness`      r4Ú __getitem__zText.__getitem__Æszø€ð     ¤ð     ¨õ     ô eœSÔ !Ù˜uÓ%Ð %à %§ ¡ ¬c°$·*±*«oÓ >Ñ ˆE4˜ØqŠyØŸ ™  U¨D MÓ2Ø˜Q‘xô Ð GÓHÐHr6có,—t|j«S)z5Get the number of cells required to render this text.)rrgr2s r4rz Text.cell_lenàs€ô˜Ÿ
™
Ó#Ð#r6có´—ddlm}g}|j}dd|jfgd„|jD«¢d„|jD«¢t |«d|jf‘}|j tdd«¬«d}|j}|D]5\}}}    ||kDr|||||««|}|    sŒ"||rd    |    ›d
nd |    ›d
«Œ7d j|«}
|
S) z~Get console markup to render this Text.
 
        Returns:
            str: A string potentially creating markup tags.
        r)ÚescaperFc3óNK—|]}|jd|jf–—Œy­w©FN)r,r.©Ú.0Úspans  r4ú    <genexpr>zText.markup.<locals>.<genexpr>ósèø€Ò F°$ˆtz‰z˜5 $§*¡*Ô-Ñ Fùó‚#%c3óNK—|]}|jd|jf–—Œy­w©TN)r-r.rŠs  r4rzText.markup.<locals>.<genexpr>ôsèø€Ò C¨tˆtx‰x˜˜tŸz™zÔ*Ñ CùrŽT©Úkeyz[/ú]ú[rZ)
Úmarkupr‡rgr.rXr_ÚsortrrpÚjoin) r3r‡ÚoutputrgÚ markup_spansÚpositionrpr:Úclosingr.r•s            r4r•z Text.markupåsü€õ    #àˆà—
‘
ˆà t—z‘zÐ "ð
á F¸$¿+¹+Ô Fð
ñD°t·{±{Ô Cð
ô‹Z˜˜tŸz™zÐ *ð    
ˆ ð     ×Ñœj¨¨AÓ.ÐÔ/؈ؗ‘ˆØ&2ò    CÑ "ˆFG˜UؘҠّv˜e H¨VÐ4Ó5Ô6Ø!ÚÙ©˜˜E˜7 !‘}°q¸¸¸q°\ÕBð     Cð —‘˜“ˆØˆ r6T)r.ÚemojiÚ emoji_variantrTrUr-rœrcóT—ddlm}|||||¬«}    ||    _||    _||    _|    S)añCreate Text instance from markup.
 
        Args:
            text (str): A string containing console markup.
            style (Union[str, Style], optional): Base style for text. Defaults to "".
            emoji (bool, optional): Also render emoji code. Defaults to True.
            emoji_variant (str, optional): Optional emoji variant, either "text" or "emoji". Defaults to None.
            justify (str, optional): Justify method: "left", "center", "full", "right". Defaults to None.
            overflow (str, optional): Overflow method: "crop", "fold", "ellipsis". Defaults to None.
            end (str, optional): Character to end text with. Defaults to "\\n".
 
        Returns:
            Text: A Text instance with markup rendered.
        r)Úrender)rœr)r•rŸrTrUr-)
Úclsr]r.rœrrTrUr-rŸÚ rendered_texts
          r4Ú from_markupzText.from_markups5€õ4    #á˜t U°%À}ÔUˆ Ø 'ˆ ÔØ!)ˆ ÔØˆ ÔØÐr6é©r.rTrUrVr-rWc    ó’—ddlm}td||||||¬«}    |«}
|    jd„|
j    |«D««} | S)aÜCreate a Text object from a string containing ANSI escape codes.
 
        Args:
            text (str): A string containing escape codes.
            style (Union[str, Style], optional): Base style for text. Defaults to "".
            justify (str, optional): Justify method: "left", "center", "full", "right". Defaults to None.
            overflow (str, optional): Overflow method: "crop", "fold", "ellipsis". Defaults to None.
            no_wrap (bool, optional): Disable text wrapping, or None for default. Defaults to None.
            end (str, optional): Character to end text with. Defaults to "\\n".
            tab_size (int): Number of spaces per tab, or ``None`` to use ``console.tab_size``. Defaults to None.
        r)Ú AnsiDecoderr[)rTrUrVr-rWr.c3ó K—|]}|–—Œy­wr8rQ©r‹Úlines  r4rz!Text.from_ansi.<locals>.<genexpr>Hsèø€ÒC dœTÑCùs‚ )Úansir¦r)r—Údecode) r r]r.rTrUrVr-rWr¦ÚjoinerÚdecoderrrs             r4Ú    from_ansizText.from_ansi%sQ€õ.    &äØ ØØØØØØô
ˆñ“-ˆØ—‘ÑC¨g¯n©n¸TÓ.BÔCÓCˆØˆ r6©rTrUcó>—||||¬«}|j|«|S)aaConstruct a Text instance with a pre-applied styled. A style applied in this way won't be used
        to pad the text when it is justified.
 
        Args:
            text (str): A string containing console markup.
            style (Union[str, Style]): Style to apply to the text. Defaults to "".
            justify (str, optional): Justify method: "left", "center", "full", "right". Defaults to None.
            overflow (str, optional): Overflow method: "crop", "fold", "ellipsis". Defaults to None.
 
        Returns:
            Text: A text instance with a style applied to the entire string.
        r¯)Ústylize)r r]r.rTrUÚ styled_texts      r4Ústyledz Text.styledKs&€ñ*˜$¨¸(ÔCˆ Ø×јEÔ"ØÐr6)r.rTrUrVr-rWÚmetaÚpartsr´cóº—|||||||¬«}    |    j}
t} |D]"} t| | tf«r    |
| «Œ|
| ŽŒ$|r|    j    |«|    S)a¹Construct a text instance by combining a sequence of strings with optional styles.
        The positional arguments should be either strings, or a tuple of string + style.
 
        Args:
            style (Union[str, Style], optional): Base style for text. Defaults to "".
            justify (str, optional): Justify method: "left", "center", "full", "right". Defaults to None.
            overflow (str, optional): Overflow method: "crop", "fold", "ellipsis". Defaults to None.
            no_wrap (bool, optional): Disable text wrapping, or None for default. Defaults to None.
            end (str, optional): Character to end text with. Defaults to "\\n".
            tab_size (int): Number of spaces per tab, or ``None`` to use ``console.tab_size``. Defaults to None.
            meta (Dict[str, Any], optional). Meta data to apply to text, or None for no meta data. Default to None
 
        Returns:
            Text: A new text instance.
        r¤)rpr)rnrOÚ
apply_meta) r r.rTrUrVr-rWr´rµr]rpÚ_TextÚparts              r4Úassemblez Text.assembledsq€ñ6ØØØØØØô 
ˆð—‘ˆÜˆØò    ˆDܘ$ ¬  Ô-ِt• ᘒ ð        ñ
Ø O‰O˜DÔ !؈ r6có¢—t|j«dk7r)dj|j«g|jdd|jdS)z Get the text as a single string.rrZNr)r_rSr—r2s r4rgz
Text.plain’s?€ô ˆtz‰z‹?˜aÒ ØŸW™W T§Z¡ZÓ0Ð1ˆDJ‰J‘qˆM؏z‰z˜!‰}Ðr6Únew_textcóҗ||jk7rXt|«}|g|jdd|j}t    |«|_||jkDr|j «yyy)zSet the text to a new value.N)rgrrSrYr_Ú _trim_spans)r3r¼r`Ú
old_lengths    r4rgz
Text.plain™sa€ð t—z‘zÒ !Ü0°Ó:ˆNØ+Ð,ˆDJ‰J‘qˆMØŸ™ˆJܘ~Ó.ˆDŒLؘDŸL™LÒ(Ø× Ñ Õ"ð)ð "r6có—|jS)z.Get a reference to the internal list of spans.©rXr2s r4r\z
Text.spans¤s€ð{‰{Ðr6có—|dd|_y)z
Set spans.NrÁ)r3r\s  r4r\z
Text.spans©s€ð™Ahˆ r6rgc    ó¢—t||j|j|j|j|j
|j ¬«}|S)zNReturn a new Text instance with copied metadata (but not the string or spans).r¤)r)r.rTrUrVr-rW)r3rgÚ    copy_selfs   r4Ú
blank_copyzText.blank_copy®sA€äØ Ø—*‘*Ø—L‘LØ—]‘]Ø—L‘LØ—‘Ø—]‘]ô
ˆ    ðÐr6c    óè—t|j|j|j|j|j
|j |j¬«}|j|jdd|S)zReturn a copy of this instance.r¤N)    r)rgr.rTrUrVr-rWrX)r3rÄs  r4roz    Text.copy»sY€äØ J‰JØ—*‘*Ø—L‘LØ—]‘]Ø—L‘LØ—‘Ø—]‘]ô
ˆ    ð#Ÿk™kˆ    ×Ñ™ÐØÐr6r,c    óƗ|r_t|«}|dkr||z}|€|}|dkr||z}||k\s||kry|jjt|t    ||«|««yy)azApply a style to the text, or a portion of the text.
 
        Args:
            style (Union[str, Style]): Style instance or style definition to apply.
            start (int): Start offset (negative indexing is supported). Defaults to 0.
            end (Optional[int], optional): End offset (negative indexing is supported), or None for end of text. Defaults to None.
        rN)r_rXrpr+r<©r3r.r,r-Úlengths     r4r±z Text.stylizeÉsq€ñ ܘ“YˆFؐqŠyØ ™Øˆ{ؐؐQŠwؘs‘lØ˜Š #¨¢,àØ K‰K× Ñ œt E¬3¨v°sÓ+;¸UÓCÕ Dð r6c
óȗ|r`t|«}|dkr||z}|€|}|dkr||z}||k\s||kry|jjdt|t    ||«|««yy)a¶Apply a style to the text, or a portion of the text. Styles will be applied before other styles already present.
 
        Args:
            style (Union[str, Style]): Style instance or style definition to apply.
            start (int): Start offset (negative indexing is supported). Defaults to 0.
            end (Optional[int], optional): End offset (negative indexing is supported), or None for end of text. Defaults to None.
        rN)r_rXÚinsertr+r<rÈs     r4Ústylize_beforezText.stylize_beforeãss€ñ ܘ“YˆFؐqŠyØ ™Øˆ{ؐؐQŠwؘs‘lØ˜Š #¨¢,àØ K‰K× Ñ ˜q¤$ u¬c°&¸#Ó.>ÀÓ"FÕ Gð r6cóV—tj|«}|j|||¬«y)agApply metadata to the text, or a portion of the text.
 
        Args:
            meta (Dict[str, Any]): A dict of meta information.
            start (int): Start offset (negative indexing is supported). Defaults to 0.
            end (Optional[int], optional): End offset (negative indexing is supported), or None for end of text. Defaults to None.
 
        )r,r-N)rÚ    from_metar±)r3r´r,r-r.s     r4r·zText.apply_metaýs$€ô—‘ Ó%ˆØ  ‰ U %¨Sˆ Õ1r6Úhandlersc óҗ|€in|}|j|j«Dcic] \}}d|›|“Œ c}}«|jtj|««|Scc}}w)aÄApply event handlers (used by Textual project).
 
        Example:
            >>> from rich.text import Text
            >>> text = Text("hello world")
            >>> text.on(click="view.toggle('world')")
 
        Args:
            meta (Dict[str, Any]): Mapping of meta information.
            **handlers: Keyword args are prefixed with "@" to defined handlers.
 
        Returns:
            Text: Self is returned to method may be chained.
        ú@)ÚupdateÚitemsr±rrÎ)r3r´rÏr’Úvalues     r4ÚonzText.on s\€ð\‰r tˆØ  ‰ ¸¿¹Ó8H×I©*¨#¨uq˜˜Y Ñ%ÓIÔJØ  ‰ ”U—_‘_ TÓ*Ô+؈ ùóJs¥A#
Úsuffixcóp—|jj|«r|jt|««yy)zaRemove a suffix if it exists.
 
        Args:
            suffix (str): Suffix to remove.
        N)rgÚendswithrEr_)r3rÖs  r4Ú remove_suffixzText.remove_suffixs+€ð :‰:× Ñ ˜vÔ &Ø O‰OœC ›KÕ (ð 'r6Úconsoler!r:cóæ—|dkrt|«|z}|j}||j«j«}|jD]"\}}}||cxkDr|k\sŒnŒ|||d¬«z }Œ$|S)a
Get the style of a character at give offset.
 
        Args:
            console (~Console): Console where text will be rendered.
            offset (int): Offset in to text (negative indexing supported)
 
        Returns:
            Style: A Style instance.
        rrZ©r%)r_Ú    get_styler.rorX)r3rÚr:rÝr.r,r-Ú
span_styles        r4Úget_style_at_offsetzText.get_style_at_offset(sz€ð AŠ:ܘ“Y Ñ'ˆFØ×%Ñ%ˆ    Ù˜$Ÿ*™*Ó%×*Ñ*Ó,ˆØ&*§k¡kò    ;Ñ "ˆE3˜
ؐVÔ$˜uÖ$Ø™ :°rÔ:Ñ:‘ð    ;ðˆ r6Úspacescó\—|dkry|j}d|z}|ryt|«}|Dcgc]$}|j|k\r|j|«n|‘Œ&c}|jdd|j
j |«|xj|z c_y|xj|z c_ycc}w)z¹Extend the Text given number of spaces where the spaces have the same style as the last character.
 
        Args:
            spaces (int): Number of spaces to add to the Text.
        rNrj)    r\r_r-rHrXrSrprYrg)r3ràr\Ú
new_spacesÚ
end_offsetrŒs      r4Ú extend_stylezText.extend_style<sœ€ð QŠ;Ø Ø—
‘
ˆØ˜6‘\ˆ
٠ܘT›ˆJð"öàð(,§x¡x°:Ò'=— ‘ ˜FÔ#À4ÑGòˆDK‰K™ˆNð J‰J× Ñ ˜jÔ )Ø LŠL˜FÑ "ŽLà JŠJ˜*Ñ $ŽJùòs©)B))Ú style_prefixÚ re_highlightråc
ó—d}|jj}t}|j}t    |t
«rt j|«}|j|«D]œ}|j}    |r9|    «\}
} t|«r |||
| «n|} | | |
kDr|||
| | ««|dz }|j«j«D]-} |    | «\}
} |
dk7sŒ| |
kDsŒ|||
| |›| ›««Œ/Œž|S)a%Highlight text with a regular expression, where group names are
        translated to styles.
 
        Args:
            re_highlight (Union[re.Pattern, str]): A regular expression object or string.
            style (Union[GetStyleCallable, StyleType]): Optional style to apply to whole match, or a callable
                which accepts the matched text and returns a style. Defaults to None.
            style_prefix (str, optional): Optional prefix to add to style group names.
 
        Returns:
            int: Number of regex matches
        rréÿÿÿÿ) rXrpr+rgrnrOÚreÚcompileÚfinditerrŒÚcallableÚ    groupdictÚkeys)r3rær.råÚcountÚ append_spanr|rgÚmatchÚget_spanr,r-Ú match_styleÚnames              r4Úhighlight_regexzText.highlight_regexQs €ð&ˆØ—k‘k×(Ñ(ˆ ܈ؗ
‘
ˆÜ l¤CÔ (ÜŸ:™: lÓ3ˆLØ!×*Ñ*¨5Ó1ò     LˆEØ—z‘zˆHÙÙ%›Z‘
sÜ9AÀ%¼™e E¨%°Ð$4Ô5Èe ØÐ*¨s°Uª{Ù¡ e¨S°+Ó >Ô?à Q‰JˆEØŸ™Ó)×.Ñ.Ó0ò LÙ% d›^‘
sؘB“; 3¨£;Ù¡ e¨S°\°NÀ4À&Ð2IÓ JÕKñ Lð     Lðˆ r6)Úcase_sensitiveÚwordsröcó6—djd„|D««}|jj}d}t}t    j
||j |rdntj¬«D]+}|jd«\}    }
|||    |
|««|dz }Œ-|S)aBHighlight words with a style.
 
        Args:
            words (Iterable[str]): Words to highlight.
            style (Union[str, Style]): Style to apply.
            case_sensitive (bool, optional): Enable case sensitive matching. Defaults to True.
 
        Returns:
            int: Number of words highlighted.
        ú|c3óFK—|]}tj|«–—Œy­wr8)rér‡©r‹Úwords  r4rz'Text.highlight_words.<locals>.<genexpr>Šsèø€Ò>°œBŸI™I dŸOÑ>ùs‚!r©Úflagsr)    r—rXrpr+rérërgÚ
IGNORECASErŒ) r3r÷r.röÚre_wordsÚadd_spanrïr|rñr,r-s            r4Úhighlight_wordszText.highlight_wordsys€ð"—8‘8Ñ>¸Ô>Ó>ˆØ—;‘;×%Ñ%ˆØˆÜˆÜ—[‘[Ø d—j‘j©^©ÄÇÁô
ò    ˆE🙠A›‰JˆE3Ù ‘U˜5 # uÓ-Ô .Ø Q‰J‰Eð     ð ˆ r6cóB—|jj«|_y)z"Strip whitespace from end of text.N)rgÚrstripr2s r4rz Text.rstrip–s€à—Z‘Z×&Ñ&Ó(ˆ
r6Úsizecóޗt|«}||kDr]||z
}tj|j«}|6t|j    d««}|j t ||««yyy)zŽRemove whitespace beyond a certain width at the end of the text.
 
        Args:
            size (int): The desired size of the text.
        Nr)r_Ú_re_whitespaceÚsearchrgÚgrouprEr<)r3rÚ text_lengthÚexcessÚwhitespace_matchÚwhitespace_counts      r4Ú
rstrip_endzText.rstrip_endšso€ô ˜$“iˆ Ø ˜Ò Ø  4Ñ'ˆFÜ-×4Ñ4°T·Z±ZÓ@Ð ØÐ+Ü#&Ð'7×'=Ñ'=¸aÓ'@Ó#AРؗ‘¤Ð$4°fÓ =Õ>ð,ð r6Ú
new_lengthcó‚—t|«}||k7r/||kr|j||z
«y|j||z
«yy)z<Set new length of the text, clipping or padding is required.N)r_Ú    pad_rightrE)r3rrÉs   r4Ú
set_lengthzText.set_length¨sB€äT“ˆØ ZÒ Ø˜
Ò"Ø—‘˜z¨FÑ2Õ3à—‘ ¨Ñ 3Õ4ð      r6Úoptionsr"c #óæK—|j€ |jn |j}|jxs|jxst}|jxs|jxst}|j ||j |||xsdt|j|jd«¬«}td«j|«}|j||j¬«Ed{–—†y7Œ­w)Nr£F©rTrUrWrVr[©r-) rWrTr&rUr(ÚwrapÚ    max_widthrrVr)r—rŸr-)r3rÚrrWrTrUrƒÚ    all_liness        r4Ú__rich_console__zText.__rich_console__±sÄèø€ð-1¯M©MÐ,A˜×(Ò(ÀtÇ}Á}ˆØ—,‘,ÒD '§/¡/ÒD´_ˆà—=‘=ÒH G×$4Ñ$4ÒHÔ8Hˆà—    ‘    Ø Ø × Ñ ØØØ’] Ü˜dŸl™l¨G¯O©O¸UÓCð ó
ˆô˜“J—O‘O EÓ*ˆ    Ø×#Ñ# G°·±Ð#Ó:×:Ò:ús‚C'C1Ã)C/Ã*C1cóʗ|j}|j«}|rtd„|D««nd}|j«}|rtd„|D««n|}t    ||«S)Nc3ó2K—|]}t|«–—Œy­wr8©rr¨s  r4rz(Text.__rich_measure__.<locals>.<genexpr>Ésèø€Ò>°œX dŸ^Ñ>ùó‚rc3ó2K—|]}t|«–—Œy­wr8rrûs  r4rz(Text.__rich_measure__.<locals>.<genexpr>Ìsèø€Ò1 4”˜—Ñ1ùr)rgÚ
splitlinesÚmaxr?r)r3rÚrr]rƒÚmax_text_widthr÷Úmin_text_widths        r4Ú__rich_measure__zText.__rich_measure__Äs^€ðz‰zˆØ—‘Ó!ˆÙBGœÑ>¸Ô>Ô>ÈQˆØ—
‘
“ ˆá5:ŒCÑ1¨5Ô1Ô 1Àð    ô˜>¨>Ó:Ð:r6rc#óV‡‡‡‡‡K—t}|j}|jst|«–—|r
||«–—yt|jt j «¬«}tt|jd««}|Dcic]\}}|||j«“Œc}}Š||j«‰d<dgd„|D«¢d„|D«¢t|«ddf‘}    |    jtdd«¬    «gЉj}
‰j} iЉjŠt
j Šd
t
fˆˆˆˆˆfd „ } t#|    |    dd«D]9\\} }}\}}}|r    | |«n|
|«|| kDsŒ'||| || ««–—Œ;|r ||«–—yycc}}w­w) aRender the text as Segments.
 
        Args:
            console (Console): Console instance.
            end (Optional[str], optional): Optional end character.
 
        Returns:
            Iterable[Segment]: Result of render that may be written to the console.
        NrÜrr)rFrc3ó@K—|]\}}|jd|f–—Œy­wr‰)r,©r‹ÚindexrŒs   r4rzText.render.<locals>.<genexpr>ésèø€Ò M©[¨U°Dˆtz‰z˜5 %Ô(Ñ Mùó‚c3ó@K—|]\}}|jd|f–—Œy­wrrr's   r4rzText.render.<locals>.<genexpr>êsèø€Ò J©+¨%°ˆtx‰x˜˜uÔ%Ñ Jùr)Tr‘r/cót•—tˆfd„t‰«D««}‰|«}||S‰|«}|‰|<|S)z#Construct current style from stack.c3ó(•K—|]    }‰|–—Œ y­wr8rQ)r‹Ú    _style_idÚ    style_maps  €r4rz9Text.render.<locals>.get_current_style.<locals>.<genexpr>ùsøèø€ÒO°I˜9 YÕ/ÑOùsƒ)ÚtupleÚsorted)ÚstylesÚ cached_styleÚ current_styleÚcombineÚstackÚ style_cacheÚstyle_cache_getr.s   €€€€€r4Úget_current_stylez&Text.render.<locals>.get_current_style÷sFø€äÓOÄÈÃÔOÓOˆFÙ*¨6Ó2ˆLØÐ'Ø#Ð#Ù# F›OˆMØ"/ˆK˜Ñ Ø Ð  r6)rrgrXrrÝrÚnullÚlistÚ    enumerater.r_r–rrpÚremoveÚgetr4Úzip)r3rÚr-Ú_Segmentr]rÝÚenumerated_spansr(rŒr\Ú stack_appendÚ    stack_popr8r:ÚleavingÚstyle_idÚ next_offsetÚ_r4r5r6r7r.s                  @@@@@r4rŸz Text.renderÐsµüèø€ôˆØz‰zˆØ{Š{ܘ$“-Ò ÙÙ˜s“mÒ#Ø Ü˜G×-Ñ-´u·z±z³|ÔDˆ    ä¤    ¨$¯+©+°qÓ 9Ó:ÐØEU×V±k°e¸TU™I d§j¡jÓ1Ñ1ÓVˆ    Ù  §¡Ó,ˆ    !‰ ð ð
á MÐ<LÔ Mð
ñKÐ9IÔ Jð
ô‹Y˜˜aÐ  ð    
ˆð     
‰
”z ! QÓ'ˆ
Ô(àˆØ—|‘|ˆ Ø—L‘Lˆ    à68ˆ Ø%Ÿ/™/ˆÜ—-‘-ˆð    !¤5÷    !ñ    !ôADÀEÈ5ÐQRÐQSÈ9Ó@Uò    NÑ <Ñ 'ˆVW˜hÑ)<¨+°q¸!ÙÙ˜(Õ#á˜XÔ&ؘVÓ#Ù˜t F¨;Ð7Ñ9JÓ9LÓMÓMð     Nñ Ù˜3“-Ó ð ùóIWùs‡BF) F#Â*CF)Æ)F)rƒc
ó䇇‡‡    —‰j«}dtdfˆˆfd„ }|jj}|jj
}|jj}dŠ    t Š|«D]p}||j«|jr&|‰‰    ‰    t|«z|j««|ˆˆ    fd„|jD««‰    t|«z Š    Œr‰    |_    |S)zèJoin text together with this instance as the separator.
 
        Args:
            lines (Iterable[Text]): An iterable of Text instances to join.
 
        Returns:
            Text: A new text instance containing join text.
        r/r)c3ó|•K—‰jrt‰«D]\}}|–—|rŒ ‰–—Œy‰Ed{–—†y7Œ­wr8)rgr)Úlastr©rƒr3s  €€r4Ú    iter_textzText.join.<locals>.iter_texts>øèø€ØzŠzÜ"+¨EÓ"2ò#‘JD˜$Ø’JÚØ"›
ñ#ð
!× Ò úsƒ$<¨ <´:µ<rc3óF•K—|]\}}}‰‰|z‰|z|«–—Œy­wr8rQ)r‹r,r-r.r|r:s    €€r4rzText.join.<locals>.<genexpr>*s0øèø€òá%E˜3 ñf˜u‘n f¨s¡l°E×:ñùóƒ!)
rÅr rSrHrXrpr+r.r_rY)
r3rƒr¼rJÚ extend_textrðÚ extend_spansr]r|r:s
``      @@r4r—z    Text.join sÕû€ð—?‘?Ó$ˆð    !œ8 FÑ+ö    !ð—n‘n×+Ñ+ˆ Ø—o‘o×,Ñ,ˆ Ø—‘×-Ñ-ˆ ؈܈á“Kò     ˆDÙ ˜Ÿ
™
Ô #؏zŠzÙ™E &¨&´3°t³9Ñ*<¸d¿j¹jÓIÔJÙ ôà)-¯©ôô ð ”c˜$“iÑ ‰Fð     ð"ˆÔ؈r6có—d|jvry|€ |j}|€d}g}|j}|jdd¬«D]»}d|jvr    ||«Œd}|jdd¬«}|D]ˆ}|jj    d«rT|j
dddd    z|j
d<||j z }||z}|r+||z
}    |j|    «||    z }n||j z }||«ŒŠŒ½td
«j|«}
|
jg|_t|j«|_ |
j|jddy) ztConverts tabs to spaces.
 
        Args:
            tab_size (int, optional): Size of tabs. Defaults to 8.
 
        ú    Nr£r[T)Úinclude_separatorrrèrjrZ) rgrWrpr?rØrSrrär)r—r_rYrX) r3rWr¼rpr©Ú cell_positionrµr¹Ú tab_remainderràrrs            r4Ú expand_tabszText.expand_tabs2sV€ð t—z‘zÑ !Ø Ø Ð Ø—}‘}ˆHØ Ð ØˆHà!ˆØ—‘ˆà—J‘J˜t°tJÓ<ò    !ˆDؘ4Ÿ:™:Ñ%ِt• à ! ØŸ
™
 4¸4˜
Ó@Ø!ò !DØ—z‘z×*Ñ*¨4Ô0Ø)-¯©°B©¸¸Ð)<¸sÑ)B˜Ÿ
™
 2™Ø%¨¯©Ñ6˜ Ø(5¸Ñ(@˜ Ù(Ø%-° Ñ%=˜FØ ×-Ñ-¨fÔ5Ø)¨VÑ3™Mà%¨¯©Ñ6˜ Ù˜4•Lñ !ð     !ô&b“—‘˜xÓ(ˆà—l‘l^ˆŒ
ܘ4Ÿ:™:“ˆŒ ØŸ™ˆ ‰ ‘A‰r6F)rUÚpadrrUcóz—|xs|jxst}|dk7ržt|j«}||kDrB|dk(r"t    |j|dz
«dz|_nt    |j|«|_|r?||kr9||z
}|j›d|z›g|_t |j«|_yyyy)auTruncate text if it is longer that a given width.
 
        Args:
            max_width (int): Maximum number of characters in text.
            overflow (str, optional): Overflow method: "crop", "fold", or "ellipsis". Defaults to None, to use self.overflow.
            pad (bool, optional): Pad with spaces if the length is less than max_width. Defaults to False.
        ÚignoreÚellipsisru…rjN)rUr(rrgrrSr_rY)r3rrUrUÚ    _overflowrÉràs       r4Útruncatez Text.truncate\sµ€ðÒA § ¡ ÒAÔ1Aˆ    Ø ˜Ò  Ü˜dŸj™jÓ)ˆFؘ    Ò!Ø 
Ò*Ü!.¨t¯z©z¸9Àq¹=Ó!IÈEÑ!QD•Jä!.¨t¯z©z¸9Ó!ED”Jِv     Ò)Ø" VÑ+Ø!%§¡  ¨S°6©\¨NÐ;Ð<”
Ü" 4§:¡:›• ð*ˆsð !r6c
ó2—t|j«}t}|jDcgc]T}|j|krC|j
|kr|n1||jt ||j
«|j«‘ŒVc}|jddycc}w)z=Remove or modify any spans that are over the end of the text.N)r_rgr+rXr,r-r<r.)r3Ú
max_offsetr|rŒs    r4r¾zText._trim_spansws€€ä˜Ÿ™“_ˆ
܈🠙 ö 
ð Øz‰z˜JÒ&ð    —8‘8˜jÒ(ñá˜4Ÿ:™:¤s¨:°t·x±xÓ'@À$Ç*Á*ÓMñNò
ˆ ‰ ‘A‰ùò
sªABrïÚ    characterc
ó—t|«dk(sJd«‚|r`||z}|›|j›|›|_t}|jDcgc]\}}}|||z||z|«‘Œc}}}|jddyycc}}}w)zÎPad left and right with a given number of characters.
 
        Args:
            count (int): Width of padding.
            character (str): The character to pad with. Must be a string of length 1.
        rú&Character must be a string of length 1N©r_rgr+rX)r3rïr]Úpad_charactersr|r,r-r.s        r4rUzText.pad…s”€ô9‹~ Ò"ÐLÐ$LÓLÐ"Ù Ø&¨Ñ.ˆNØ*Ð+¨D¯J©J¨<¸Ð7GÐHˆDŒJ܈Eð*.¯©÷ðá%E˜3 ñe˜e‘m S¨5¡[°%Õ8ôˆDK‰K™‰Nð     ùôsÁ
A9c
óø—t|«dk(sJd«‚|r\||z›|j›|_t}|jDcgc]\}}}|||z||z|«‘Œc}}}|jddyycc}}}w)zÁPad the left with a given character.
 
        Args:
            count (int): Number of characters to pad.
            character (str, optional): Character to pad with. Defaults to " ".
        rr_Nr`)r3rïr]r|r,r-r.s       r4Úpad_leftz Text.pad_left–sŠ€ô9‹~ Ò"ÐLÐ$LÓLÐ"Ù Ø%¨Ñ-Ð.¨t¯z©z¨lÐ;ˆDŒJ܈Eð*.¯©÷ðá%E˜3 ñe˜e‘m S¨5¡[°%Õ8ôˆDK‰K™‰Nð ùôsÁA5cód—t|«dk(sJd«‚|r|j›||z›|_yy)zÂPad the right with a given character.
 
        Args:
            count (int): Number of characters to pad.
            character (str, optional): Character to pad with. Defaults to " ".
        rr_N)r_rg)r3rïr]s   r4rzText.pad_right¦s>€ô9‹~ Ò"ÐLÐ$LÓLÐ"Ù Ø ŸJ™J˜<¨    °EÑ(9Ð':Ð;ˆDJð r6ÚalignÚwidthcó—|j|«|t|j«z
}|r]|dk(r|j||«y|dk(r-|dz}|j    ||«|j||z
|«y|j    ||«yy)zñAlign text to a given width.
 
        Args:
            align (AlignMethod): One of "left", "center", or "right".
            width (int): Desired width.
            character (str, optional): Character to pad with. Defaults to " ".
        ÚleftÚcenteréN)rZrrgrrc)r3rerfr]Ú excess_spacerhs      r4rez
Text.align±s€ð      ‰ eÔØœx¨¯
©
Ó3Ñ3ˆ Ù Ø˜ŠØ—‘˜|¨YÕ7ؘ(Ò"Ø# qÑ(Ø— ‘ ˜d IÔ.Ø—‘˜|¨dÑ2°IÕ>à— ‘ ˜l¨IÕ6ð r6rc    óh‡‡—t|ttf«s td«‚t    |«r‚t|t«r~t |«}|j j|«t    |«}t    |«Š|r)|jjt||‰z|««|xj‰z c_
|St|t«rätŠ| td«‚|jŠ|jr9|jj‰‰‰t    |«z|j««|j j|j«|jjˆˆfd„|jj«D««|xjt    |«z c_
|S)zøAdd text with an optional style.
 
        Args:
            text (Union[Text, str]): A str or Text to append.
            style (str, optional): A style name. Defaults to None.
 
        Returns:
            Text: Returns self for chaining.
        z(Only str or Text can be appended to Textz2style must not be set when appending Text instancec3óF•K—|]\}}}‰|‰z|‰z|«–—Œy­wr8rQ©r‹r,r-r.r|r
s    €€r4rzText.append.<locals>.<genexpr>ês2øèø€ò#á)˜˜s Eñ˜% +Ñ-¨s°[Ñ/@À%×Hñ#ùrL)rnrOr)r€r_rrSrprXr+rYÚ
ValueErrorr.rgrHro)r3r]r.r`r:r|r
s     @@r4rpz Text.appendÅsXù€ô˜$¤¤d  Ô,ÜÐFÓGÐ Gä ˆt9ܘ$¤Ô$Ü!4°TÓ!:Ø—
‘
×!Ñ! .Ô1ܘT›Ü! .Ó1 ÙØ—K‘K×&Ñ&¤t¨F°F¸[Ñ4HÈ%Ó'PÔQØ— ’   Ñ+• ð$ˆ ô#˜D¤$Ô'ܐØÐ$Ü$ØLóðð#Ÿl™l Ø—:’:Ø—K‘K×&Ñ&Ù˜k¨;¼¸T»Ñ+BÀDÇJÁJÓOôð—
‘
×!Ñ! $§*¡*Ô-Ø— ‘ ×"Ñ"ô#à-1¯[©[×-=Ñ-=Ó-?ô#ôð— ’ ¤ D£    Ñ)• ؈ r6c    ó¸‡‡—tŠ|jŠ|jr9|jj    ‰‰‰t |«z|j««|j j    |j«|jjˆˆfd„|jj«D««|xjt |«z c_|S)a Append another Text instance. This method is more performant that Text.append, but
        only works for Text.
 
        Args:
            text (Text): The Text instance to append to this instance.
 
        Returns:
            Text: Returns self for chaining.
        c3óF•K—|]\}}}‰|‰z|‰z|«–—Œy­wr8rQrns    €€r4rz#Text.append_text.<locals>.<genexpr>s2øèø€ò
á!s˜Eñ %˜+Ñ% s¨[Ñ'8¸%× @ñ
ùrL)
r+rYr.rXrpr_rSrgrHro)r3r]r|r
s  @@r4Ú append_textzText.append_textñsù€ôˆØ—l‘lˆ Ø :Š:Ø K‰K× Ñ ™u [°+ÄÀDà   Ñ2IÈ4Ï:É:ÓVÔ WØ 
‰
×ј$Ÿ*™*Ô%Ø  ‰ ×Ñô
à%)§[¡[×%5Ñ%5Ó%7ô
ô    
ð      Š œ˜D›    Ñ! ؈ r6Útokensc
ó —|jj}|jj}t}t    |«}|D]D\}}t |«}||«|r||||t    |«z|««|t    |«z }ŒF||_|S)a)Append iterable of str and style. Style may be a Style instance or a str style definition.
 
        Args:
            tokens (Iterable[Tuple[str, Optional[StyleType]]]): An iterable of tuples containing str content and style.
 
        Returns:
            Text: Returns self for chaining.
        )rSrprXr+r_rrY)r3rsrrrðr|r:Úcontentr.s        r4Ú append_tokenszText.append_tokenssŽ€ð—j‘j×'Ñ'ˆ Ø—k‘k×(Ñ(ˆ ܈ܐT“ˆØ$ò    #‰NˆGUÜ)¨'Ó2ˆGÙ ˜Ô  ÙÙ™E &¨&´3°w³<Ñ*?ÀÓGÔHØ ”c˜'“lÑ "‰Fð     #𠈌 ؈ r6cóN—|jj|j«y)z–Copy styles from another Text instance.
 
        Args:
            text (Text): A Text instance to copy styles from, must be the same length.
        N)rXrH)r3r]s  r4Ú copy_styleszText.copy_styless€ð       ‰ ×ј4Ÿ;™;Õ'r6)rQÚ allow_blankÚ    separatorrQryc󲇇—‰sJd«‚|jЉ‰vrt|j«g«S|r@|jd„t    j
t    j ‰«‰«D««}n<dttfˆˆfd„ }tˆfd„|j|««D««}|s!‰j‰«r|j«|S)aÑSplit rich text in to lines, preserving styles.
 
        Args:
            separator (str, optional): String to split on. Defaults to "\\n".
            include_separator (bool, optional): Include the separator in the lines. Defaults to False.
            allow_blank (bool, optional): Return a blank line if the text ends with a separator. Defaults to False.
 
        Returns:
            List[RichText]: A list of rich text, one per line of the original.
        zseparator must not be emptyc3ó<K—|]}|j«–—Œy­wr8r)r‹rñs  r4rzText.split.<locals>.<genexpr>?sèø€ò Ø %—    ‘    — ñ ùs‚r/c3ó •K—tjtj‰«‰«D]}|j«\}}|–—|–—Œy­wr8)rérër‡rŒ)rñr,r-rzr]s   €€r4Ú flatten_spansz!Text.split.<locals>.flatten_spansDsCøèø€ÜŸ[™[¬¯©°9Ó)=¸tÓDòEØ!&§¡£‘JE˜3Ø’KØ“IñùsƒA Ac3óB•K—|]}|j‰k7sŒ|–—Œy­wr8rf)r‹r©rzs  €r4rzText.split.<locals>.<genexpr>Js!øèø€òØÀÇÁÈyÓAX”ñùsƒ˜) rgrrorrérër‡r rMrØÚpop)r3rzrQryrƒr~r]s `    @r4r?z
Text.split's»ù€ñ"Ð7Ð7Ó7ˆyàz‰zˆØ ˜DÑ  Ü˜$Ÿ)™)›+˜Ó'Ð 'á Ø—K‘Kñ Ü)+¯©´R·Y±Y¸yÓ5IÈ4Ó)Pô ó‰Eð
 ¤8¬C¡=ö ô óØ!%§¡©]«_Ó!=ôóˆEñ˜tŸ}™}¨YÔ7Ø I‰IŒKàˆ r6Úoffsetsc    óž‡‡‡‡‡—t|«}|st|j«g«S|jŠt    ‰«}dg|¢|‘}tt ||dd««}|j Š|jŠ|jŠtŠtˆˆˆˆˆfd„|D««}|js|S|jDcgc]}|jj‘Œ}}t    |«}    t}
|jD]È\} } Šd} |    }| |zdz}    ||\}}| |kr|dz
}n | |kDr|dz} nn    | |zdz}Œ(| |kr|}n/|x}} |    }    ||\}}| |kr|dz
}n | |kDr|dz} nn    | |zdz}Œ(t||dz«D]D}||\}}td| |z
«}t!| |z
||z
«}||kDsŒ2|||
||‰««ŒFŒÊ|Scc}w)zÜDivide text in to a number of lines at given offsets.
 
        Args:
            offsets (Iterable[int]): Offsets used to divide text.
 
        Returns:
            Lines: New RichText instances between offsets.
        rrNc3óB•K—|]\}}‰‰||‰‰‰¬«–—Œy­w))r.rTrUNrQ)r‹r,r-r¸rTrUr.r]s   €€€€€r4rzText.divide.<locals>.<genexpr>js;øèø€ò
ñsñ ؐU˜3ØØØ!÷     ð ñ
ùsƒrj)r:rrorgr_r>r.rTrUr)rXÚ_linesrpr+Úranger!r<)r3rÚ_offsetsr
Údivide_offsetsÚ line_rangesÚ    new_linesr©Ú _line_appendsÚ
line_countr|Ú
span_startÚspan_endÚ lower_boundÚ upper_boundÚ start_line_noÚ
line_startÚline_endÚ end_line_noÚline_noÚ    new_startÚnew_endr¸rTrUr.r]s                      @@@@@r4rz Text.divideSsIü€ô˜“=ˆáܘ$Ÿ)™)›+˜Ó'Ð 'àz‰zˆÜ˜$“iˆ ØÐ4˜hÐ4¨ Ð4ˆÜœ3˜~¨~¸a¸bÐ/AÓBÓCˆ à—
‘
ˆØ—,‘,ˆØ—=‘=ˆÜˆÜ÷
ð*ô
ó
ˆ    ð{Š{ØÐ à8A×8HÑ8HÖI°˜Ÿ™×+Ó+ÐIˆ ÐIܘÓ%ˆ
܈à+/¯;©;ò$    MÑ 'ˆJ˜ %؈KØ$ˆKØ(¨;Ñ6¸1Ñ<ˆMàØ'2°=Ñ'AÑ$
˜HØ 
Ò*Ø"/°!Ñ"3‘KØ (Ò*Ø"/°!Ñ"3‘KàØ!,¨{Ñ!:¸qÑ @ ðð˜(Ò"Ø+‘ à,9Ð9 ˜kØ( àØ+6°{Ñ+CÑ(J Ø *Ò,Ø&1°A¡o™ Ø! HÒ,Ø&1°A¡o™ àØ#.°Ñ#<ÀÑ"BKðô! ° ¸a±Ó@ò MØ'2°7Ñ';Ñ$
˜HÜ  :°
Ñ#:Ó;    Ü˜h¨Ñ3°XÀ
Ñ5JÓKØ˜YÓ&Ø*M 'Ñ*©5°¸GÀUÓ+KÕLñ  Mð?$    MðLÐùòUJsÃG
Úamountc
óŽ—t|j«|z
}t}|jDcgc]T}|j|krC|j
|kr|n1||jt ||j
«|j«‘ŒVc}|jdd|jd| g|_|xj|zc_    ycc}w)z7Remove a number of characters from the end of the text.N)
r_rgr+rXr,r-r<r.rSrY)r3r—r\r|rŒs     r4rEzText.right_crop¢s¬€ä˜Ÿ™“_ vÑ-ˆ
܈🠙 ö 
ð Øz‰z˜JÒ&ð    —8‘8˜jÒ(ñá˜4Ÿ:™:¤s¨:°t·x±xÓ'@À$Ç*Á*ÓMñNò
ˆ ‰ ‘Aˆð—j‘j  6 'Ð*Ð+ˆŒ
Ø  Š ˜ÑŽ ùò
s­ACrcó6—|xs|jxst}|xs|jxst}t    ||j
d«xs|dk(}t «}    |jd¬«D]«}
d|
vr|
j|«|r t |
g«} n+tt|
«||dk(¬«} |
j| «} | D]}
|
j|«Œ|r| j||||¬«| D]}
|
j||¬    «Œ|    j| «Œ­|    S)
aCWord wrap the text.
 
        Args:
            console (Console): Console instance.
            width (int): Number of cells available per line.
            justify (str, optional): Justify method: "default", "left", "center", "full", "right". Defaults to "default".
            overflow (str, optional): Overflow method: "crop", "fold", or "ellipsis". Defaults to None.
            tab_size (int, optional): Default tab size. Defaults to 8.
            no_wrap (bool, optional): Disable wrapping, Defaults to False.
 
        Returns:
            Lines: Number of lines.
        FrWT©ryrPr')r'r¯)rU)rTr&rUr(rrVrr?rTrrOrrrZrH) r3rÚrfrTrUrWrVÚ wrap_justifyÚ wrap_overflowrƒr©r‰rs              r4rz    Text.wrap²s€ð.ÒA $§,¡,ÒA´/ˆ Ø ÒE D§M¡MÒEÔ5Eˆ ä˜G T§\¡\°5Ó9ÒQ¸XÈÑ=Qˆä“ˆØ—J‘J¨4JÓ0ò    $ˆDؐt‰|Ø× Ñ  Ô*ÙÜ! 4 &›M‘    ä%¤c¨$£i°¸]ÈfÑ=TÔUØ ŸK™K¨Ó0    Ø!ò 'Ø—‘ Õ&ð 'áØ×!Ñ!ؘU¨LÀ=ð"ôð"ò =Ø— ‘ ˜e¨m Õ<ð =à L‰L˜Õ #ð!    $ð"ˆ r6cóŽ—t«}|j}|j«D]}|j|«||«Œ|S)z¼Fit the text in to given width by chopping in to lines.
 
        Args:
            width (int): Maximum characters in a line.
 
        Returns:
            Lines: Lines container.
        )rrpr?r)r3rfrƒrpr©s     r4ÚfitzText.fitâsC€ô“wˆØ—‘ˆØ—J‘J“Lò    ˆDØ O‰O˜EÔ "Ù 4Lð    ðˆ r6có:—tjd|jtj¬«Dchc]}t    |j d««’Œ}}    t t|Dcgc]
}|dzrŒ    |‘Œ c}«xsd}|Scc}wcc}w#t$rd}Y|SwxYw)zrAuto-detect indentation of code.
 
        Returns:
            int: Number of spaces used to indent code.
        ú
^( *)(.*)$rýrrj)    rérërgÚ    MULTILINEr_r    rrr€)r3rñÚ _indentationsÚindentÚ indentations     r4Údetect_indentationzText.detect_indentationòsœ€ôŸ™ ]°D·J±JÄbÇlÁlÔSö
àô — ‘ ˜A“Õ ð
ˆ ð
ð
    ä”s°-ÖR¨ÀvÐPQÃzšVÒRÓSÒXÐWXð ð Ðùò
ùòSøäò    Ø‰KàÐð    ús/³!BÁB Á%
B
Á0B
Á4 B ÂB  BÂBu│z    dim green)r]r.Ú indent_sizecó$—|€|j«n|}|j«}|j«|›d|dz
z›}tjd«}g}|j
}    d}
|j d¬«D]Ó} |j| j«} | r| jd«s|
dz }
Œ7| jd«} tt| «|«\}}||z›d|z›}|| jt|«dz| _| j|dt|««|
r"|jt||¬    «g|
z«d}
|    | «ŒÕ|
r |jtd
|¬    «g|
z«|jd «j!|«}|S) u‹Adds indent guide lines to text.
 
        Args:
            indent_size (Optional[int]): Size of indentation, or None to auto detect. Defaults to None.
            character (str, optional): Character to use for indentation. Defaults to "│".
            style (Union[Style, str], optional): Style of indent guides.
 
        Returns:
            Text: New text with indentation guides.
        Nrjrr rTršrj©r.rZr[)r¥rorTrérêrpr?rñrgr    Údivmodr_r±rHr)rÅr—)r3r¦r]r.Ú _indent_sizer]Ú indent_lineÚ    re_indentr‰Úadd_lineÚ blank_linesr©rñr£Ú full_indentsÚremaining_spaceÚ
new_indentr¼s                  r4Úwith_indent_guideszText.with_indent_guidess‹€ð$5@Ð4Gt×.Ñ.Ô0È[ˆ ày‰y‹{ˆØ ×ÑÔØ"˜  C¨<¸!Ñ+;Ñ$<Ð#=Ð>ˆ ä—J‘J˜}Ó-ˆ    Ø "ˆ    Ø×#Ñ#ˆØˆ Ø—J‘J¨4JÓ0ò     ˆDØ—O‘O D§J¡JÓ/ˆEÙ § ¡ ¨A¤Ø˜qÑ  ØØ—[‘[ “^ˆFÜ,2´3°v³;À Ó,MÑ )ˆL˜/Ø'¨,Ñ6Ð7¸¸oÑ8MÐ7NÐOˆJØ# d§j¡j´°Z³Ð1BÐ&CÑCˆDŒJØ L‰L˜ ¤3 z£?Ô 3ÙØ× Ñ ¤$ z¸Ô"?Ð!@À;Ñ!NÔOؐ Ù TNð     ñ Ø × Ñ œd 2¨UÔ3Ð4°{ÑBÔ Cà—?‘? 4Ó(×-Ñ-¨iÓ8ˆØˆr6)rZrZ)rZ)r/r))rNr8)r/N)rj)r]r)r/r))r]r)r/N)r[)r)SrIrJrKrLÚ    __slots__rOrrrrPrMr r+rarcr9rhr5rrsÚobjectrvrxryr„Úpropertyrr•Ú classmethodrr¢r®r r³rr
rºrgÚsetterr\rÅror±rÌr·rÕrÙrßrärÚGetStyleCallablerõr rrrrrrrr$rŸr—rTrZr¾rUrcrrrerprrrvrxrr?rrErržr¥r²rQr6r4r)r)vs"    „ñ ò
€IðØ#%ð0ð
.2Ø/3Ø"&ØØ"&Ø&*ò0àð0ðS˜%ZÑ ð0ð
˜/Ñ*ð 0ð Ð+Ñ,ð 0ð˜$‘ð0ðð0ð˜3‘-ð0ð˜˜T™
Ñ#ð0ð
ó0ð.˜óð"˜$ó"ð˜óðG˜#óGð˜Sð VóðI˜FðI tóIð
 &ð¨TóðI  s¨E zÑ!2ðI°vóIð4ð$˜#ò$óð$ðð˜òóðð:ð
$&ØØ04Ø-1Ø/3ØòàððS˜%ZÑ ð    ð
ð ð    Ñ-ð ð˜/Ñ*ððÐ+Ñ,ðððð
òóððBð
$&Ø-1Ø/3Ø"&ØØ"#ò#àð#ðS˜%ZÑ ð    #ð
˜/Ñ*ð #ð Ð+Ñ,ð #ð˜$‘ð#ðð#ð˜3‘-ð#ð
ò#óð#ðJððð
.2Ø/3ò àðððð
˜/Ñ*ð ð Ð+Ñ,ð ð
òóðð0ð$&Ø-1Ø/3Ø"&ØØØ)-ò+àc˜6 5¨¨i¨Ñ#8Ð8Ñ9ð+ðS˜%ZÑ ð+ð˜/Ñ*ð    +ð
Ð+Ñ,ð +ð ˜$‘ð +ðð+ðð+ðt˜C ˜H‘~Ñ&ð+ð
ò+óð+ðZðsòóðð  ‡\\ð#˜cð# dò#óð#ððt˜D‘zòóðð ‡\\ð˜4 ™:ð¨$òóðñ  ð ¨Vó ó ð"Ø!ñ    EàS˜%ZÑ ðEððEðc‰]ð    Eð
 
ó Eð:Ø!ñ    HàS˜%ZÑ ðHððHðc‰]ð    Hð
 
ó Hð6JNñ 2ؘ˜c˜‘Nð 2Ø+.ð 2Ø9AÀ#¹ð 2à     ó 2ñx  S¨# X¡Ñ/ðÀCðÈFóð() Cð)¨Dó)ð¨9ð¸cðÀeóð(% 3ð%¨4ó%ð0?Cð&ð
ò &à˜G C™L¨#Ð-Ñ.ð&ð˜Ð.°    Ð9Ñ:Ñ;ð&ð
ð &ð
ó &ðZ $ò à˜‰}ððS˜%ZÑ ðð
ð ð
ó ó:)ð ?˜sð ? tó ?ð5 Sð5¨Tó5ð;Ø ð;Ø+;ð;à    'Ñ    ó;ð&
;Ø ð
;Ø+;ð
;à    ó
;ñ9 ˜ið9 ¨cð9 ¸8ÀIÑ;Nó9 ðv%˜( 6Ñ*ð%¨vó%ñN(' H¨S¡Mð('¸Tó('ð\04Øò /àð/ðÐ+Ñ,ð    /ð
ð /ð
ó /ó6 
ñ˜ð¨ð°tóñ"˜cð¨cð¸Dóñ     <˜sð    <¨sð    <¸Tó    <ñ7˜;ð7¨sð7¸sð7ÈTó7ð*PTñ*ؘ& #˜+Ñ&ð*Ø/7¸¸cÀ7¸lÑ8KÑ/Lð*à    ó*óXð,ؘu S¨(°9Ñ*=Ð%=Ñ>Ñ?ðà    óó0(ðð*ð#(Ø!ò *àð*ð ð    *ð
ð *ð
ó *ðXM˜h s™mðM°óMñ^ ð¨Tóð*.2Ø/3ØØ"&ò.àð.ðð.ð
˜/Ñ*ð .ð Ð+Ñ,ð .ðð.ð˜$‘ð.ð
ó.ð`˜ð óð  Cóð.&*ð.ðØ&ò .à˜c‘]ð.ðð    .ð
ð .ð
ô .r6Ú__main__)r!a¿
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
ÚLoremÚboldÚipsumÚitaliczjustify='left'Úredr¨zjustify='center'Úgreenri)r.rTzjustify='right'ÚblueÚrightzjustify='full'ÚmagentaÚfull)CréÚ    functoolsrrÚmathrÚoperatorrÚtypingrrr    r
r r r rrrrÚ_looprÚ_pickrÚ_wraprrerrFrrÚ
containersrÚcontrolrrœrÚjupyterrÚmeasurerÚsegmentrr.rr rÚr!r"r#r$r&rNr(rêrrOÚTextTyper¸r+r)rIÚpip._vendor.rich.consoler]rÚruleÚprintrQr6r4ú<module>rÔs¯ðÜ    ß%ÝÝ÷ ÷ ÷ ñ õÝÝÝß*ÝÝ(ÝÝ!Ý Ýß#áßOÓOà#,€Ó,Ø%+ÐÐ"Ó+𐗑˜GÓ$€à fÑ €Ø1à˜S˜E 8¨IÑ#6Ð6Ñ7ÐôDˆ:ôDôNˆ<ôðD& ˆzÓÝ0á ð    Pó €Dð    ×ј'˜ FÔ+Ø×ј'˜ HÔ-á‹i€Gà ‡LLÐ!Ô"Ø ‡MM$˜e€MÔ$Ø ‡MM„Oà ‡LLÐ#Ô$Ø ‡MM$˜g¨x€MÔ8Ø ‡MM„Oà ‡LLÐ"Ô#Ø ‡MM$˜f¨g€MÔ6Ø ‡MM„Oà ‡LLÐ!Ô"Ø ‡MM$˜i°€MÔ8Ø ‡MM…Oð3r6