Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Auto-scroll truncated text #23

Open
ceuk opened this issue May 31, 2021 · 1 comment
Open

Auto-scroll truncated text #23

ceuk opened this issue May 31, 2021 · 1 comment
Labels

Comments

@ceuk
Copy link
Owner

ceuk commented May 31, 2021

When text is truncated it should automatically scroll left and right on an interval.

E.g. given the text "Never gonna give you up - Rick Astley"

You would move the truncation offset about 1 character every 500ms until the end is reached (at which point it should reverse).

There should also be a short delay (2 seconds or so) when the truncation offset reaches 0 again.

e.g. (the bar represents the truncation)

Never gonna give you up - Rick Astley
| ---------------- |

rendered: Never gonna give...

~500ms later:

Never gonna give you up - Rick Astley
  | ---------------- |

rendered: ever gonna give ...

~500ms later:

Never gonna give you up - Rick Astley
    | ---------------- |

rendered: ver gonna give y...

... etc

@octoshrimpy
Copy link
Contributor

I've been grabbing lil tidbits of the internet on where to learn things that might help add features to this, and I have just the thing for this one, with code example through python curses:

https://www.youtube.com/watch?v=FGcZeVDWXR0

@octoshrimpy octoshrimpy mentioned this issue May 31, 2021
20 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants