summaryrefslogtreecommitdiff
path: root/examples/async_printing.py
diff options
context:
space:
mode:
authorTodd Leonhardt <todd.leonhardt@gmail.com>2019-06-28 00:09:41 -0400
committerTodd Leonhardt <todd.leonhardt@gmail.com>2019-06-28 00:09:41 -0400
commit307c53e9eb49aad69ba243e61d70474c384d185e (patch)
tree7be5c88a21dc10d921f2edea698699beab69d710 /examples/async_printing.py
parent06c9adea8f0a0136afc48e2784ce89d694c6dd37 (diff)
downloadcmd2-git-307c53e9eb49aad69ba243e61d70474c384d185e.tar.gz
Improve background color display of prompt in async_printing.py example
Diffstat (limited to 'examples/async_printing.py')
-rwxr-xr-xexamples/async_printing.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/async_printing.py b/examples/async_printing.py
index b3618475..a9b20408 100755
--- a/examples/async_printing.py
+++ b/examples/async_printing.py
@@ -144,7 +144,7 @@ class AlerterApp(cmd2.Cmd):
"""
fg_color = random.choice(list(ansi.FG_COLORS.keys()))
bg_color = random.choice(list(ansi.BG_COLORS.keys()))
- return ansi.style(self.visible_prompt, fg=fg_color, bg=bg_color)
+ return ansi.style(self.visible_prompt.rstrip(), fg=fg_color, bg=bg_color) + ' '
def _alerter_thread_func(self) -> None:
""" Prints alerts and updates the prompt any time the prompt is showing """