plox.print.indent_print¶
Module for indented printing; both automatically and manually.
from plox.print import indent_print
Functions¶
|
Print a message with an appropriately indented prefix. |
|
Get stack size for caller's frame. |
Module Contents¶
- plox.print.indent_print.indent_print(msg, indent_level=None, indent_char='|- ')¶
Print a message with an appropriately indented prefix.
Example
>>> from plox.print.indent_print import indent_print as printi >>> >>> def test(): ... printi("inside test") >>> >>> def test2(): ... printi("inside test2") ... test() >>> >>> def test3(): ... printi("This it the inside of test3") ... test2() ... test() >>> >>> test3() |- test3():This it the inside of test3 |- |- test2():inside test2 |- |- |- test():inside test |- |- test():inside test