【问题标题】:popup keyboard key with more then one character - android带有多个字符的弹出键盘键 - android
【发布时间】:2014-08-12 05:19:18
【问题描述】:

有没有办法创建一个出现多个字符的弹出式键盘? (我的标签没有显示键盘上的选项键) 这是我在 xml 文件中的代码:

enter code here

  <Keyboard
    xmlns:android="http://schemas.android.com/apk/res-auto"
    android:keyWidth="15%p"
    android:horizontalGap="0px"
    android:verticalGap="0px"
    android:keyHeight="@dimen/popup_key_height"

    >
     <Row
        android:rowEdgeFlags="top|bottom"
        >
       <Key
            android:keyLabel="@string/popular_domain_1"
            android:keyOutputText="@string/popular_domain_1"
            android:keyEdgeFlags="left"
             />
       <Key
            android:keyLabel="@string/popular_domain_2"
            android:keyOutputText="@string/popular_domain_2"/>

在我的弹出标签中,我没有看到任何东西,只是一个空立方体...... tnx!

【问题讨论】:

  • Swiftkey 这样做,所以我不明白为什么不这样做。请向我们展示您的代码。

标签: android keyboard key


【解决方案1】:

如果您长按该键,我认为您是在要求弹出窗口?

还有一个名为 popupCharacters 的 xml 属性,您可以在其中声明多余的字符,然后您只需要在属性 popupKeyboard 中为它们进行布局。像这样:

    <Key
        android:codes="0x0628"
        android:keyLabel="&#x0628;"
        android:popupKeyboard="@xml/popup_keyboard"
        android:popupCharacters="&#x067E;"/>

【讨论】:

    猜你喜欢
    • 2012-12-23
    • 1970-01-01
    • 2020-11-24
    • 1970-01-01
    • 2015-06-06
    • 2017-01-09
    • 1970-01-01
    • 2017-05-24
    • 2015-11-26
    相关资源
    最近更新 更多