aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/python/prompt-toolkit/py3/prompt_toolkit/layout/controls.py
diff options
context:
space:
mode:
authorarcadia-devtools <arcadia-devtools@yandex-team.ru>2022-02-08 15:26:58 +0300
committerarcadia-devtools <arcadia-devtools@yandex-team.ru>2022-02-08 15:26:58 +0300
commit2efaaefec2cb2a55d55c01753d1eed2a3296adb5 (patch)
tree27ec5258b325565c3963b91b36d64e84084fdb04 /contrib/python/prompt-toolkit/py3/prompt_toolkit/layout/controls.py
parent23793c5d0827a08b5ff9242d2123eff92b681912 (diff)
downloadydb-2efaaefec2cb2a55d55c01753d1eed2a3296adb5.tar.gz
intermediate changes
ref:0bfa27bb6c38df8c510497e54e4ebf0b4fb84503
Diffstat (limited to 'contrib/python/prompt-toolkit/py3/prompt_toolkit/layout/controls.py')
-rw-r--r--contrib/python/prompt-toolkit/py3/prompt_toolkit/layout/controls.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/contrib/python/prompt-toolkit/py3/prompt_toolkit/layout/controls.py b/contrib/python/prompt-toolkit/py3/prompt_toolkit/layout/controls.py
index 1e1f15f7aa..45b50e68f8 100644
--- a/contrib/python/prompt-toolkit/py3/prompt_toolkit/layout/controls.py
+++ b/contrib/python/prompt-toolkit/py3/prompt_toolkit/layout/controls.py
@@ -208,7 +208,7 @@ class UIContent:
return self._line_heights_cache[key]
except KeyError:
if width == 0:
- height = 10 ** 8
+ height = 10**8
else:
# Calculate line width first.
line = fragment_list_to_text(self.get_line(lineno))[:slice_stop]
@@ -235,7 +235,7 @@ class UIContent:
prefix_width = get_cwidth(fragment_list_to_text(fragments2))
if prefix_width >= width: # Prefix doesn't fit.
- height = 10 ** 8
+ height = 10**8
break
text_width += prefix_width
@@ -244,7 +244,7 @@ class UIContent:
try:
quotient, remainder = divmod(text_width, width)
except ZeroDivisionError:
- height = 10 ** 8
+ height = 10**8
else:
if remainder:
quotient += 1 # Like math.ceil.
@@ -488,7 +488,7 @@ class DummyControl(UIControl):
return []
return UIContent(
- get_line=get_line, line_count=100 ** 100
+ get_line=get_line, line_count=100**100
) # Something very big.
def is_focusable(self) -> bool: