私は制約レイアウトを使用しています。私は画像ビューに画像を配置すると、タブバーと画像の間に巨大なスペースを持つ垂直方向の画面の中心に垂直に配置されます。私はそれを正確にタブバーの下に持っていくことはできません。画像の解像度は2048 * 1152です。私のアプリのバナーとして使うことを計画しています。アンドロイドのタブ付きバーの下にイメージビューを使用してイメージを配置する方法は?
<android.support.constraint.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
xmlns:app="http://schemas.android.com/apk/res-auto"
tools:context="com.manu.program.MainTwo">
<ImageView
android:id="@+id/imageView"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:srcCompat="@drawable/banner_image"
/>
</android.support.constraint.ConstraintLayout>
私が添付された画像need to remove the space between the image and tab bar
をadjustViewBoundsを追加=真の画像表示で –
は、あなたの完全なXML –
セットImageViewの高さwrap_content –