diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-03 20:03:26 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-03 20:03:26 +0000 |
commit | 75c118cf7675e6f19cbb80bc16e92740676c7f4b (patch) | |
tree | b7840cfab1291920b36df87833c253051d4b54f0 /ptpython/layout.py | |
parent | Adding upstream version 3.0.26. (diff) | |
download | ptpython-upstream.tar.xz ptpython-upstream.zip |
Adding upstream version 3.0.27.upstream/3.0.27upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'ptpython/layout.py')
-rw-r--r-- | ptpython/layout.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/ptpython/layout.py b/ptpython/layout.py index 2c1ec15..622df59 100644 --- a/ptpython/layout.py +++ b/ptpython/layout.py @@ -1,6 +1,7 @@ """ Creation of the `Layout` instance for the Python input/REPL. """ + from __future__ import annotations import platform @@ -131,7 +132,7 @@ def python_sidebar(python_input: PythonInput) -> Window: tokens.append(("class:sidebar" + sel, " >" if selected else " ")) tokens.append(("class:sidebar.label" + sel, "%-24s" % label, select_item)) tokens.append(("class:sidebar.status" + sel, " ", select_item)) - tokens.append(("class:sidebar.status" + sel, "%s" % status, goto_next)) + tokens.append(("class:sidebar.status" + sel, f"{status}", goto_next)) if selected: tokens.append(("[SetCursorPosition]", "")) @@ -528,7 +529,7 @@ def create_exit_confirmation( def get_text_fragments() -> StyleAndTextTuples: # Show "Do you really want to exit?" return [ - (style, "\n %s ([y]/n) " % python_input.exit_message), + (style, f"\n {python_input.exit_message} ([y]/n) "), ("[SetCursorPosition]", ""), (style, " \n"), ] |