Android 4.4 退格键不修改 Kivy TextInput 中的默认文本

标签 android python-2.7 kivy

在将我的 nexus 4 从 Android 4.3 升级到 4.4(Kitkat) 之前,我可以使用 BackSpace 按钮删除我在 TextInput 中加载时转换的默认文本。奇怪的是,现在我无法在使用默认键盘(Google 键盘)时删除此 TextInput 的文本,但可以与 Google Play 上提供的其他键盘完美配合。我不知道这是操作系统问题还是我的代码需要修改或可能需要升级到 Kivy。

我的代码如下所示(以 kv 为单位):

TextInput:
    id:txt_from_mail
    font_size: root.height * .044
    size_hint: (None,None)
    size: root.width*.65,root.height*.0833
    background_color:(1,2,0.7,0.9)
    foreground_color: (.2,.4,.5,.9)
    padding_y:self.height*.12
    text:"YourGmail@gmail.com" # this is the text that i cannot delete or modify
    multiline:False
    on_focus:root.clear_mail_feedback()

在 Python 中,该函数如下所示:

def clear_mail_feedback(self):
    self.the_mail_feedback.text="" # this is a label in my form that gives text feedback to users

编辑:我还可以添加其他发现。在 TextInput 中输入文本,将应用程序置于后台,回调应用程序,并尝试编辑您的文本,但您做不到!这可能是 latinIME 的问题吗?使用 native 编码???无知...

最佳答案

这是 kitkat、kivy 的一个已知问题。有一个临时 hack/fix here

关于Android 4.4 退格键不修改 Kivy TextInput 中的默认文本,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20262201/

相关文章:

python - 我如何确定具体从 PyQt4 导入什么?

android - 无法解析 : com. afollestad :bridge:5. 1.2

c# - 如何使用 Unity3D 获取已安装的应用程序列表?

Django管理命令: using LabelCommand

c结构数组的cython内存 View

python - pycharm ubuntu : ImportError: No module named _clock 上的 Kivy 1.9.1

python - Kivy:在对 ListAdapter 数据进行排序时无法更新 ListView

python - 错误 : from matplotlib import _png ImportError: cannot import name '_png' from 'matplotlib' (C:\\Garden\lib\site-packages\matplotlib\__init__. py)

Android:罕见且不可重现的 ClassNotFoundException

android - Kotlin 合并两个可为空的可变列表