kivy / kivy/python-for-android
Error in deleting characters in a text field
- Langage dominant
- Python
- Étoiles
- 8.9k
- Forks
- 2k
- Merge moyen
- 12 h 20 min
- PR mergées (30 j)
- 9
Description
To delete characters after defocusing the text field, you need to press the delete button as many times as the: number of characters * 2
### Versions
- Python: 3.9.9
- OS: Android
- Kivy: master
- Cython: latest
- OpenJDK: 17
- p4a: develop
```py
from kivy.app import App
from kivy.lang import Builder
kv = """
Screen:
TextInput:
size_hint_y: None
height: dp(45)
hint_text: "1"
write_tab: False
pos_hint: {"top": 0.9}
TextInput:
size_hint_y: None
height: dp(45)
hint_text: "2"
write_tab: False
pos_hint: {"top": 0.7}
"""
class Test(App):
def build(self):
return Builder.load_string(kv)
Test().run()
```
**buildozer.spec**
```
[app]
title = My Application
package.name = myapp
package.domain = org.test
source.dir = .
source.include_exts = py,png,jpg,kv,atlas
version = 0.1
requirements = kivy==master
orientation = all
osx.python_version = 3
osx.kivy_version = 2.1.0
fullscreen = 0
android.api = 33
android.minapi = 21
android.ndk = 25b
android.accept_sdk_license = True
android.enable_androidx = True
android.logcat_filters = *:S python:D
android.archs = arm64-v8a, armeabi-v7a
android.allow_backup = True
p4a.branch = develop
p4a.bootstrap = sdl2
[buildozer]
log_level = 2
warn_on_root = 1
```
https://user-images.githubusercontent.com/40869738/211171901-9a0d5a2d-2b11-4c29-99aa-7d420ba73907.mp4
Guide de contribution
Ouvrir le guide de contribution
Piste de recherche
Start by reproducing the provided two-TextInput example on Android with the listed Python, Kivy, and p4a versions, then compare deletion before and after defocusing. The issue names no source file or test, so trace the Android text-input handling and add a regression test for the reported deletion behavior; done means characters delete once per press.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- android, python
- Domaine
- mobile
- Type d'issue
- Bug
- Difficulté
- 4/5
- Temps estimé
- 3-5 jours
- Activité
- À l'abandon
- Clarté
- À clarifier
- Accessibilité débutants
- 28/100