У меня есть xml
макет, и у меня есть некоторые проблемы.
Проблема первая:
Это пользователь для приложения чата. У меня есть LinearLayout
, который содержит EditText
.android Предварительный просмотр студии показывает это LinearLayout
, нопри запуске приложения на моем устройстве не отображается.
Проблема вторая:
Я хочу добавить padding-right к EditText
, чтобы убрать значок отправки. Я добавляю padding, но не работаю.
Проблема третья:
Как получить доступ к моему значку отправки в задании, чтобы установить для него OnClickListener
.
Задача четвертая: Текст EditText
выглядит жирным, хотя я не придаю ему жирный стиль.Это мой xml
файл:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
>
<android.support.v7.widget.RecyclerView
android:id="@+id/reyclerview_message_list"
android:layout_width="match_parent"
android:layout_height="wrap_content">
</android.support.v7.widget.RecyclerView>
<LinearLayout
android:id="@+id/layout_chatbox"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:minHeight="48dp"
android:orientation="horizontal">
<EditText
android:id="@+id/edittext_chatbox"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_marginLeft="16dp"
android:layout_marginRight="16dp"
android:background="@drawable/rounded_edittext"
android:drawableRight="@drawable/ic_upwards_arrow"
android:hint="نوشتن پیام"
android:maxLines="6"
android:padding="5dip"
android:textSize="14sp"
android:textStyle="normal" />
</LinearLayout>
</LinearLayout>