いくつかのボタンが入った線形レイアウトがあります。ボタンの画像はすべて同じサイズで、同じ属性を持っています...1つのボタンを除いて。この1つのボタンのフォントサイズは小さくなっています。これ以外のすべてのボタンは、私が望むように完全に並んでいます。何らかの理由で、フォントが小さいボタンは、他のボタンよりも画面上で少し低く表示されます。必要なスペースが少なくて済み、追加のスペースを占めるボタンのアイデアに頭を悩ませるのに苦労しています。
誰かが私に何を読むべきかについてのヒントを教えてもらえますか?
編集
これがmain.xmlです(SOがその一部をフィルタリングしているようです。重要なものはすべてここにあります...)
<ScrollView android:id="@+id/scroll"
android:layout_width="match_parent"
android:layout_height="300px">
<TextView
android:id="@+id/the_text_view"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:typeface="monospace"
android:textSize="9pt"
android:background="@color/paper"
android:paddingLeft="20dp"
android:paddingBottom="20dp"
android:textColor="@color/type"
/>
</ScrollView>
<LinearLayout
android:orientation="horizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<Button style="@style/ASR33_button"
android:tag="Y"
android:text="Y"
/>
<Button style="@style/ASR33_button"
android:tag="N"
android:text="N"
/>
<Button style="@style/ASR33_button"
android:tag="E"
android:text="E"
/>
<Button style="@style/ASR33_button"
android:tag="W"
android:text="W"
/>
<Button style="@style/ASR33_button"
android:tag="S"
android:text="S"
/>
<Button style="@style/ASR33_button"
android:tag="F"
android:text="F"
/>
<Button style="@style/ASR33_button"
android:tag="R"
android:text="R"
/>
<Button style="@style/ASR33_button"
android:tag="M"
android:text="M"
/>
<Button style="@style/ASR33_button"
android:tag="T"
android:text="T"
/>
<Button style="@style/ASR33_button"
android:onClick="onEnterButtonClicked"
android:textSize="6pt"
android:text="RE-\nTURN"
/>
<Button style="@style/ASR33_button"
android:tag="U"
android:text="U"
/>
</LinearLayout>
<LinearLayout
android:orientation="horizontal"
android:layout_marginTop="10dp"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<TextView
android:id="@+id/instructions"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:textSize="9pt"
android:paddingLeft="10dp"
android:typeface="normal"
android:text="Commands: (Y)es, (N)o, (N)orth, (E)ast, (W)est, (S)outh, (M)ap, (ST)atus, (Fight), (R)un, (SU)icide. All commands must be followed by RETURN."
/>
</LinearLayout>
不安定なのは下から2番目で、onclickイベントが異なります。スタイルの文字サイズは11ptです。私がそれを使用すると(そして他の人のように1文字のボタン名)、それは動作します。しかし、それはASR33の「エンター」キーが持っているものではありません。したがって、フォントサイズを6 ptに縮小すると、奇妙なことが起こります。
スタイルはここで見ることができます。
繰り返しになりますが、参考文献やアイデアを読んでください。検索する単語が1つか2つあるかどうかがわかります。あなたが知らないことを知るのは難しいです...
解像度
アヌラグはそれを正しく持っています、以下の彼の答えを見てください。更新されたLinearLayoutの抜粋を次に示します。
<LinearLayout
android:orientation="horizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:baselineAligned="false">