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

text: Improve EditText::maxscroll #18783

Merged
merged 2 commits into from
Nov 27, 2024
Merged

Conversation

kjarosh
Copy link
Member

@kjarosh kjarosh commented Nov 27, 2024

This patch makes EditText::maxscroll more accurate by using text height and taking the gutter into account.

This patch makes text/links_in_scrolled_text pass (it was an accident, but I'll accept that as a success).

A brute-force test for TextField.maxScrollV depending on textHeight and height is also added in order to make sure we're heading in the right direction here.

TODO: this requires #18772 to work properly, otherwise avm1/edittext_scroll fails.

@kjarosh kjarosh added text Issues relating to text rendering/input A-core Area: Core player, where no other category fits T-fix Type: Bug fix (in something that's supposed to work already) labels Nov 27, 2024
This patch makes it more accurate by using
text height and taking the gutter into account.

This also makes text/links_in_scrolled_text pass.
This test verifies how the max scroll behaves depending on
text field's height and text height.
@Dinnerbone Dinnerbone enabled auto-merge (rebase) November 27, 2024 22:18
@Dinnerbone Dinnerbone merged commit 37a9e44 into ruffle-rs:master Nov 27, 2024
22 checks passed
@kjarosh kjarosh deleted the maxscroll branch November 27, 2024 22:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-core Area: Core player, where no other category fits T-fix Type: Bug fix (in something that's supposed to work already) text Issues relating to text rendering/input
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants