Skip to content

Commit

Permalink
Corrected the apply_formatting example
Browse files Browse the repository at this point in the history
  • Loading branch information
Tails86 committed Apr 20, 2024
1 parent 18aa504 commit d7d299b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Binary file modified docs/examples.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 3 additions & 3 deletions src/ansi_string/ansi_string.py
Original file line number Diff line number Diff line change
Expand Up @@ -782,9 +782,9 @@ class AnsiString:
Example 3:
s = AnsiString('This string contains multiple color settings across different ranges')
s.apply_formatting(AnsiFormat.BOLD, 5, 6)
s.apply_formatting(AnsiFormat.BG_BLUE, 21, 8)
s.apply_formatting([AnsiFormat.FG_ORANGE, AnsiFormat.ITALIC], 21, 14)
s.apply_formatting(AnsiFormat.BOLD, 5, 11)
s.apply_formatting(AnsiFormat.BG_BLUE, 21, 29)
s.apply_formatting([AnsiFormat.FG_ORANGE, AnsiFormat.ITALIC], 21, 35)
print(s)
Example 4:
Expand Down

0 comments on commit d7d299b

Please sign in to comment.