fix: always show cursor on deinit
The render method always hides the cursor, and only shows it if it needs to be shown. This has the effect that if a caller never shows the cursor, exits the application, and the shell doesn't re-show the cursor then we have no visible cursor. Always show the cursor on deinit to prevent such a curse. Fixes: #10
This commit is contained in:
parent
9496270ecd
commit
449eb170f7
1 changed files with 2 additions and 0 deletions
|
@ -113,6 +113,8 @@ pub fn Vaxis(comptime T: type) type {
|
|||
if (self.state.alt_screen) {
|
||||
_ = tty.write(ctlseqs.rmcup) catch {};
|
||||
}
|
||||
// always show the cursor on exit
|
||||
_ = tty.write(ctlseqs.show_cursor);
|
||||
tty.flush() catch {};
|
||||
tty.deinit();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue