44Copy this file to $XDG_CONFIG_HOME/ptpython/config.py
55"""
66from __future__ import unicode_literals
7+
78from prompt_toolkit .filters import ViInsertMode
89from prompt_toolkit .key_binding .key_processor import KeyPress
910from prompt_toolkit .keys import Keys
1011from pygments .token import Token
1112
1213from ptpython .layout import CompletionVisualisation
1314
14- __all__ = (
15- 'configure' ,
16- )
15+ __all__ = ("configure" ,)
1716
1817
1918def configure (repl ):
@@ -50,7 +49,7 @@ def configure(repl):
5049
5150 # Swap light/dark colors on or off
5251 repl .swap_light_and_dark = False
53-
52+
5453 # Highlight matching parethesis.
5554 repl .highlight_matching_parenthesis = True
5655
@@ -75,7 +74,7 @@ def configure(repl):
7574 repl .paste_mode = False
7675
7776 # Use the classic prompt. (Display '>>>' instead of 'In [1]'.)
78- repl .prompt_style = ' classic' # 'classic' or 'ipython'
77+ repl .prompt_style = " classic" # 'classic' or 'ipython'
7978
8079 # Don't insert a blank line after the output.
8180 repl .insert_blank_line_after_output = False
@@ -108,14 +107,14 @@ def configure(repl):
108107 repl .enable_input_validation = True
109108
110109 # Use this colorscheme for the code.
111- repl .use_code_colorscheme (' pastie' )
110+ repl .use_code_colorscheme (" pastie" )
112111
113112 # Set color depth (keep in mind that not all terminals support true color).
114113
115- #repl.color_depth = 'DEPTH_1_BIT' # Monochrome.
116- #repl.color_depth = 'DEPTH_4_BIT' # ANSI colors only.
117- repl .color_depth = ' DEPTH_8_BIT' # The default, 256 colors.
118- #repl.color_depth = 'DEPTH_24_BIT' # True color.
114+ # repl.color_depth = 'DEPTH_1_BIT' # Monochrome.
115+ # repl.color_depth = 'DEPTH_4_BIT' # ANSI colors only.
116+ repl .color_depth = " DEPTH_8_BIT" # The default, 256 colors.
117+ # repl.color_depth = 'DEPTH_24_BIT' # True color.
119118
120119 # Syntax.
121120 repl .enable_syntax_highlighting = True
@@ -142,7 +141,6 @@ def _(event):
142141 event.current_buffer.validate_and_handle()
143142 """
144143
145-
146144 # Typing 'jj' in Vi Insert mode, should send escape. (Go back to navigation
147145 # mode.)
148146 """
@@ -178,8 +176,7 @@ def _(event):
178176# `ptpython/style.py` for all possible tokens.
179177_custom_ui_colorscheme = {
180178 # Blue prompt.
181- Token .Layout .Prompt : 'bg:#eeeeff #000000 bold' ,
182-
179+ Token .Layout .Prompt : "bg:#eeeeff #000000 bold" ,
183180 # Make the status toolbar red.
184- Token .Toolbar .Status : ' bg:#ff0000 #000000' ,
181+ Token .Toolbar .Status : " bg:#ff0000 #000000" ,
185182}
0 commit comments