独立的提示,我想告诉用户关于其应当低于为TextInputLayout和AutocompleteTextView
所以我用AutocompleteTextView内TextInputLayout像下面的代码
<android.support.design.widget.TextInputLayout
android:id="@+id/profile_youraddress"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/profile_emailaddress"
android:layout_marginTop="@dimen/margin_10"
android:hint="@string/your_address"
android:textColor="@color/home_primary_color">
<AutoCompleteTextView
android:id="@+id/profile_addresstext"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="Malviya Nagar, New Delhi, Delhi"
android:singleLine="true" />
</android.support.design.widget.TextInputLayout>
喜欢的类型定位模式
问题是,当TextInputLayout不在焦点时,它有两个提示相互重叠,如下所示
我该如何重写TextInputLayout的AutocompleteTextView提示在非可聚焦状态下的提示?任何帮助将不胜感激。
我在寻找:
当焦点不,提示应该是“你的地址”(“马尔维亚格尔,新德里,印度”应该被隐藏),当焦点提示应该是“新德里,德里的Malviya Nagar”。
参考http://stackoverflow.com/questions/30537413/textinputlayout-not-showing-edittext-hint-before-user-focus-on-it – sasikumar
我有已经检查出...这不是问题在这里....我已经在使用'compile'com.android.support:design:23.4.0''。 –
你在找什么行为?也就是说,在你的第二张图片中,你想让提示成为“你的地址”还是“新德里新德里的Malviya Nagar”? –