I have two questions.
- How can I get the spinner in the figure below closer to the text?

I use the following xml layout
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:weightSum="4">
<TextView
android:layout_width="0dp"
android:layout_height="wrap_content"
android:text="Check by"
android:layout_weight="1"
android:textSize="20dp"/>
<Spinner
android:id="@+id/CheckBy"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:textSize="20dp"
android:enabled="false"/>
<TextView
android:layout_width="0dp"
android:layout_height="wrap_content"
android:text="Outcome"
android:layout_weight="1"
android:textSize="20dp"/>
<Spinner
android:id="@+id/Outcome"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:textSize="20dp"
android:enabled="false"/>
</LinearLayout>
- How can I change the text of the enter button, as in the below figure, and assign an action to be performed when it is clicked?
1) For the layout design use below code –
Simply remove the
weightsumand give thewrap_contentas width.