helix-mods/helix-tui
Michael Davis 3d85024717 Move terminal claim/restore code to helix-tui
This moves the `Application::claim_term` and
`helix-term::application::restore_term` functions into the helix-tui
crate. How the terminal should be claimed and restored is a TUI concern
and is implemented differently through different TUI backends.

This cleans out a lot of crossterm and TUI code in Application and
makes it easier to modify claim/restore based on information we query
from the terminal host. The child commit will take advantage of this
to cache the check for whether the host terminal supports the keyboard
enhancement protocol. Without this change, caching that information
takes much more code which is not easily reusable for anything else.

The code to restore the terminal is somewhat duplicated by this patch:
we want to restore the terminal in cases of panics. Panic handler hooks
must live for `'static` and the Application's terminal does not.
2023-03-08 10:49:32 +09:00
..
src Move terminal claim/restore code to helix-tui 2023-03-08 10:49:32 +09:00
tests Allow the area to be bigger than u16 (width and height remain u16) (#4318) 2022-10-26 12:00:13 +09:00
.gitignore Inline tui as helix-tui fork. 2021-05-09 17:52:55 +09:00
Cargo.toml Move terminal claim/restore code to helix-tui 2023-03-08 10:49:32 +09:00
README.md Fix grammatical error (#1427) 2022-01-04 10:45:31 +09:00

helix-tui

This library is a fork of the great library tui-rs. We've mainly relied on the double buffer implementation and render diffing, side-stepping its widget and layouting.