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

Editing text in an entry on android causes the press-and-hold behavior of backspace to stop working #5467

Open
2 tasks done
hkparker opened this issue Jan 26, 2025 · 1 comment
Labels
bug Something isn't working

Comments

@hkparker
Copy link
Contributor

Checklist

  • I have searched the issue tracker for open issues that relate to the same problem, before opening a new one.
  • This issue only relates to a single bug. I will open new issues for any other problems.

Describe the bug

With the entry widget, when you press and hold the backspace button, it will delete a character, there will be a small delay, and then it will continue to delete characters as long as you hold it down. This is the desired behavior and it usually works well.

On android, however, if you type into an entry, then click on some earlier text and make an edit, then put the cursor back at the end, you can no longer use this feature. Now, when you press and hold backspace, it only deletes one character.

How to reproduce

  1. Type into an entry until there's a reasonable amount of text
  2. Press and hold backspace from the end, the text will all delete
  3. Type more text, but this time click back anywhere and make and edit
  4. Click the cursor back to the end and try to delete

Screenshots

screen-20250126-081935.mp4

Example code

package main

import (
	"fyne.io/fyne/v2"
	"fyne.io/fyne/v2/app"
	"fyne.io/fyne/v2/container"
	"fyne.io/fyne/v2/widget"
)

func main() {
	demo := app.New()
	window := demo.NewWindow("Demo")
	window.SetMaster()
	window.Resize(fyne.Size{Height: 400, Width: 400})

	window.Show()
	window.SetContent(container.NewVBox(widget.NewEntry()))

	demo.Run()
}

Fyne version

2.5.3

Go compiler version

go1.23.4 linux/amd64

Operating system and version

Android 15 / Pixel 9 Pro XL

Additional Information

No response

@hkparker hkparker added the unverified A bug that has been reported but not verified label Jan 26, 2025
@andydotxyz andydotxyz added bug Something isn't working and removed unverified A bug that has been reported but not verified labels Jan 27, 2025
@andydotxyz andydotxyz added this to the "F" release, Early 2025 milestone Jan 27, 2025
@andydotxyz
Copy link
Member

I believe this is due to how we set up the native version of entry each time the edit "starts" - it is probably related to the reason that suggestions don't always work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants