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

Godot 4 rc2: shortcut for line comment toggling, bug if cursor at beginning of line #73367

Closed
Juuliuus opened this issue Feb 15, 2023 · 2 comments · Fixed by #73440
Closed

Godot 4 rc2: shortcut for line comment toggling, bug if cursor at beginning of line #73367

Juuliuus opened this issue Feb 15, 2023 · 2 comments · Fixed by #73440

Comments

@Juuliuus
Copy link

Godot version

4.0 rc2

System information

Linux Ubuntu

Issue description

If the cursor is at the beginning of the line and then using the comment line toggle shortcut the # is placed AFTER the cursor instead of before it. This behavior has changed since rc1 I believe because I would have noticed it.

The expected behavior is that the # will be placed before the cursor.

I often go to the beginning of a blank line, invoke the toggle comment shortcut, and then start typing. With this current behavior it starts pushing the # which is unexpected and more work while then I have to move the cursor to after the #.

Steps to reproduce

On Linux version, Godot 4 rc2 place your cursor on a blank empty line, or at the beginning of a code line.

Invoke line comment toggle shortcut, the described above behavior occurs with the # being placed after the cursor instead of in front of it.

Minimal reproduction project

@akien-mga
Copy link
Member

I can reproduce the issue, and confirm that it changed in RC 2.

Probably caused by #72671, CC @aXu-AP @Paulb23 (didn't test to confirm that hunch though).

@akien-mga akien-mga modified the milestones: 4.0, 4.x Feb 15, 2023
@aXu-AP
Copy link
Contributor

aXu-AP commented Feb 15, 2023

Yes, this is from my rewrite. I didn't notice the distinction of selection being at the start of the line vs only caret being there. It's an easy fix, I'll try do it tomorrow (too late to wait compiling Godot 😅).

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

Successfully merging a pull request may close this issue.

3 participants