I have this problem that when I run application I get undesired whitespace on top of and below my imageviews.
I have tried to use adjustViewBounds and different scale types, the thing is I want to keep my pictures, exactly as they are, but just remove the whitespace.
The Imageviews changes to a src picture in my java code where I download the pictures to the phones activity and then set the image to the downloaded bitmap.
Here is a picture of how it looks on my emulator, there is one full screen of whitespace until you get to the next imageView, by scrolling down on the ScrollView. Here!
Here you can see my XML code. TouchImageView is just a zoomable type of imageView.
<ScrollView xmlns:android="http://ift.tt/nIICcg"
android:id="@+id/ScrollView01"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:fadingEdge="none"
android:fillViewport="true" >
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content" >
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical" >
<TextView
android:id="@+id/tVInformation"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:layout_centerHorizontal="true"
android:text="TextView"
android:visibility="gone" />
<com.fluffow.csgosmokes.TouchImageView
android:id="@+id/iVsmoke1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:adjustViewBounds="true"
android:scaleType="centerInside"
android:src="@drawable/ic_launcher" />
<com.fluffow.csgosmokes.TouchImageView
android:id="@+id/iVsmoke2"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:adjustViewBounds="true"
android:scaleType="centerInside"
android:src="@drawable/ic_launcher" />
<com.fluffow.csgosmokes.TouchImageView
android:id="@+id/iVsmoke3"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:adjustViewBounds="true"
android:scaleType="centerInside"
android:src="@drawable/ic_launcher" />
<com.fluffow.csgosmokes.TouchImageView
android:id="@+id/iVsmoke4"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:adjustViewBounds="true"
android:scaleType="centerInside"
android:src="@drawable/ic_launcher"
android:visibility="invisible" />
</LinearLayout>
</RelativeLayout>
No comments:
Post a Comment