Skip to content

Commit d9f35b6

Browse files
Display 'VISUAL BLOCK' and 'INSERT' when we're in these modes.
1 parent 3bfdaf7 commit d9f35b6

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

ptpython/layout.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -374,7 +374,10 @@ def toggle_vi_mode(cli, mouse_event):
374374
elif cli.current_buffer.selection_state.type == SelectionType.CHARACTERS:
375375
append((token.InputMode, 'Vi (VISUAL)', toggle_vi_mode))
376376
append((token, ' '))
377-
elif mode == InputMode.INSERT:
377+
elif cli.current_buffer.selection_state.type == 'BLOCK':
378+
append((token.InputMode, 'Vi (VISUAL BLOCK)', toggle_vi_mode))
379+
append((token, ' '))
380+
elif mode in (InputMode.INSERT, 'vi-insert-multiple'):
378381
append((token.InputMode, 'Vi (INSERT)', toggle_vi_mode))
379382
append((token, ' '))
380383
elif mode == InputMode.NAVIGATION:

0 commit comments

Comments
 (0)