以下に示す例で、画像を垂直方向に中央揃えにするにはどうすればよいですか?
次のようにする必要があります。
私が使用しているレイアウトは次のとおりです。
<RelativeLayout
android:id="@+id/layoutBranding"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_below="@id/banner"
android:layout_margin="7dp">
<ImageView
android:id="@+id/imgInstallerLogo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginRight="7dp"
android:src="@drawable/logonarrow"
android:layout_centerVertical="true"
android:layout_alignParentLeft="true"
android:layout_alignParentTop="true" />
<TextView
android:id="@+id/txtInstallerName"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="[Installer Description]"
android:textSize="20sp"
android:layout_toRightOf="@id/imgInstallerLogo"
android:layout_alignParentTop="true" />
<TextView
android:id="@+id/txtIntallerPhone"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="[Installer Phone Number]"
android:textSize="15sp"
android:layout_below="@id/txtInstallerName"
android:layout_toRightOf="@id/imgInstallerLogo" />
</RelativeLayout>