ボタンのテキストを中央に配置しようとしていますが、常に右にくっついています。私は試しgravity
ましtextAlignment
たが、ここでは何も機能しません。私のコードは次のとおりです。
<Button
android:id="@+id/button1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/textView1"
android:layout_centerHorizontal="true"
android:layout_marginTop="35dp"
android:gravity="center"
android:text="@string/Recipies" />