unkyulee / micro-journal

Other
233 stars 7 forks source link

Screen redraw bug: quickly deleted content remains on screen #9

Open benhoh opened 3 months ago

benhoh commented 3 months ago

I'm not sure if this is exclusive to 1.0.14, but I've noticed that the rapid deletion of words (by double-tapping the backspace key in quick succession) often results in the cursor getting to a position above a bunch of old characters that remain on the screen. They're not in the buffer or the file, just on the screen.

unkyulee commented 3 months ago

This is possible, I am working on it to solve this issue.

Thought process on this is, if I try to clear the screen then it will cause flicker. So, I need to clear the screen as less as possible to provide smoother experience. This mean, I have to identify the cases when to clear the screen. Since the double tap, it creates more cases that I haven't handled for the screen refresh.

Root cause, is the full screen refresh causes the flicker and solution for case by case is not optimal. I am looking into the root cause of the flickering and will try to find a way to refresh the screen fully in most cases, so that this type of issues can be resolved from the root.

Thanks for the feedback.