Skip to content

Commit 7c90454

Browse files
committed
Improved docstring for TextGroup.__rich__().
1 parent 9046e81 commit 7c90454

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

cmd2/argparse_custom.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1375,7 +1375,11 @@ def __init__(
13751375
self.formatter_creator = formatter_creator
13761376

13771377
def __rich__(self) -> Group:
1378-
"""Perform custom rendering."""
1378+
"""Return a renderable Rich Group object for the class instance.
1379+
1380+
This method formats the title and indents the text to match argparse
1381+
group styling, making the object displayable by a Rich console.
1382+
"""
13791383
formatter = self.formatter_creator()
13801384

13811385
styled_title = Text(

0 commit comments

Comments
 (0)