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

[3.x] Fix cursor after last character INDEX in line counting as a character outside of the viewing area #81352

Merged
merged 1 commit into from
Sep 18, 2023

Conversation

MJacred
Copy link
Contributor

@MJacred MJacred commented Sep 5, 2023

Fixes #81349 for Godot 3.x

This fix should be ok like this, because last character and cursor are rendered together (at least on my machine: Ubuntu)

Before fix

before.webm

After fix

after.webm

…de of the viewing area

The cursor column can be after the last_visible_char index and still be visible.
@MJacred MJacred requested a review from a team as a code owner September 5, 2023 17:42
@AThousandShips AThousandShips modified the milestones: 3.6, 3.x Sep 5, 2023
AUTHORS.md Outdated Show resolved Hide resolved
@AThousandShips
Copy link
Member

AThousandShips commented Sep 5, 2023

I would suggest to open a 4.x fix as well, we tend to prioritise getting fixes on the main development branch first

@MJacred
Copy link
Contributor Author

MJacred commented Sep 5, 2023

I'm currently trying to fix it for 4.x and will make a draft soon (tonight).

That code has been overhauled, so it's rather different. In the linked issue you can see that the bug is not exactly the same. Well, I'm on it

@AThousandShips
Copy link
Member

Great! Sorry missed that detail as the relevant code seemed the same and had the same range check offset

@akien-mga akien-mga changed the title 3.x: Fix cursor after last character INDEX in line counting as a character outside of the viewing area [3.x] Fix cursor after last character INDEX in line counting as a character outside of the viewing area Sep 5, 2023
@MJacred
Copy link
Contributor Author

MJacred commented Sep 5, 2023

Haha, thought the same! So I tried the same fix, but it just fixes one area and breaks another...

@MJacred
Copy link
Contributor Author

MJacred commented Sep 11, 2023

@Paulb23, could you please have a look at this micro PR as well?

@akien-mga akien-mga modified the milestones: 3.x, 3.6 Sep 18, 2023
@akien-mga akien-mga merged commit d6c2a4b into godotengine:3.x Sep 18, 2023
13 checks passed
@akien-mga
Copy link
Member

Thanks!

@MJacred
Copy link
Contributor Author

MJacred commented Sep 18, 2023

@akien-mga: can we cherrypick this for 3.5, please? 3.6 is months (a year?) away from being released (based on past 3.6 dev snapshot dates).

@akien-mga akien-mga added the cherrypick:3.5 Considered for cherry-picking into a future 3.5.x release label Sep 18, 2023
@MJacred MJacred deleted the 3.x branch September 18, 2023 18:59
@akien-mga
Copy link
Member

Cherry-picked for 3.5.3.

@akien-mga akien-mga removed the cherrypick:3.5 Considered for cherry-picking into a future 3.5.x release label Sep 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants