左侧Edittext内的Tiny Circular ProgressBar

时间:2017-03-03 07:00:35

标签: android progress-bar

我想在左侧的edittext中实现微小的循环进度对话框,用户可以在进度对话框后输入单词,如何实现? 我是android的新手,所以我需要你的帮助。

1 个答案:

答案 0 :(得分:0)

您可以在里面创建RelativeLayout EditTextProgressBar。将进度放在布局的左侧,并为EditText内的文本留下一些填充。

示例:

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    >
  <EditText
      android:id="@+id/editText"
      android:layout_width="match_parent"
      android:layout_height="wrap_content"
      android:paddingLeft="50dp"
      android:text="I'm EditText"
      />
  <ProgressBar
      android:layout_width="50dp"
      android:layout_height="wrap_content"
      android:layout_alignBottom="@+id/editText"
      android:layout_alignParentStart="true"
      android:paddingBottom="8dp"
      />
</RelativeLayout>

enter image description here