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

ui: refactor text with raylib #34306

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

sunnyhaibin
Copy link
Contributor

@sunnyhaibin sunnyhaibin commented Dec 24, 2024

Qt Raylib
image image

@adeebshihadeh
Copy link
Contributor

adeebshihadeh commented Dec 24, 2024

So the really important thing to make sure with text is that we can easily make the scrolling good (iPhone-quality) on raylib. Maybe @deanlee has already investigated this?

If that's not easy with raylib, we'll have to look into something else. This UI rewrite is all about fixing the lag: from building to the actual input in the UI.

@deanlee
Copy link
Contributor

deanlee commented Dec 25, 2024

@sunnyhaibin Great work! That said, the scrolling implementation seems a bit more complex than necessary. I wanted to share a draft of ui_text I previously worked on using Raylib: link to text.cc, This draft implements a scrollable text area using raylib’s ScissorMode. Feel free to take a look and see if there’s anything you find useful or applicable for reference.

Additionally, to fully migrate all UI components, we might need to consider integrating rayui (a single-file, header-only library). This can simplify a lot of tasks, including handling scrolling-related components. I haven’t tried rayui yet, but you can give it a try if you’re interested.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants