-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make
RichHelpFormatter
itself renderable with rich (#90)
This is a new approach that allows the formatter itself to be rendered with rich. The handling of whitespace manipulation and wrapping is now baked into the renderable itself. This also removes the need to use `soft_wrap=True` when printing the formatted help. The downside is that the code is now very low-level in terms of rich rendering, it needs to do line-by-line handling of `Segment` objects. This could help unblock more niche use-cases like #81 and #54.
- Loading branch information
Showing
4 changed files
with
137 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters