Skip to content

Commit 8e6ed34

Browse files
authored
Prevent blinking on Windows with overwrite_display
When overwrite_display keyword is used, output control characters and table with a single print statement, rather than two separate print statements. The former seems to avoid blinking between successive displays.
1 parent 42f8640 commit 8e6ed34

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/backends/text/text_backend.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1397,10 +1397,10 @@ function _text__print_table(
13971397

13981398
if overwrite_display
13991399
num_new_lines = max(count(==('\n'), output_str), 0)
1400-
print(context, "\e[1F\e[2K"^num_new_lines)
1400+
print(context, "\e[1F\e[2K"^num_new_lines * output_str)
1401+
else
1402+
print(context, output_str)
14011403
end
14021404

1403-
print(context, output_str)
1404-
14051405
return nothing
14061406
end

0 commit comments

Comments
 (0)