-
Notifications
You must be signed in to change notification settings - Fork 1
Description
On some machines, the text editor flickers. This is caused by repeatedly clearing and redrawing the entire screen at 30 frames per second and causes unnecessary CPU usage.
ideas to fix this:
-
change the term.ui source code to allow event driven ui and event functions. doing this would allow discarding framerate all together, only redrawing when necessary. This solution also requires that the blinking cursor logic (which is tied to the frame rate) be moved to a lightweight timer implementation or additional feature in the term.ui source.
-
implement changes to remove tui.clear() from the ui_loop. and tui.flush only relevant changes. this reduces CPU load but still renders 30 frames per second unnecessarily; however, this doesn't require changing the core tui library code.