gord-project / gord

The Discord terminal client you never knew you wanted.
https://yellowsink.vercel.app/project/gord
BSD 3-Clause "New" or "Revised" License
65 stars 6 forks source link

delay/"lag" when scrolling up too fast #16

Open ghost opened 3 years ago

ghost commented 3 years ago

How have you installed gord

What happened

When scrolling through messages fast enough, the screen will start delaying from the inputs, meaning, if you focus the message container and hold Up for a bit, then, say, hold Down, it'll take a second before it actually starts going down

Error output

How do you reproduce this bug

  1. Go into a channel with a bunch of messages
  2. Focus message container
  3. hold Up for a little bit
  4. Release and then hold Down
  5. Wait and observe

System information

Key Value
OS TODO Artix Linux
Architecture TODO amd64
Terminal TODO kitty
Bios-Marcel commented 3 years ago

The problem is that tview#TextView was being abused to do all kinds of rendering, selection and whatnot. I'd advise writing a completly custom component that's optimized for the usecase. It'd also allow to fix some other bugs that exist right now, such as the faulty code highlighting and the inability to control textwrap.