2012-12-31 29 views
5

में खिंचाव छवि दृश्य बनाएं मेरे ग्रिडव्यू में छवि खिंचाव नहीं है।ग्रिडव्यू

मैं इसे कैसे बढ़ा सकता हूं?

यह मेरा है।

enter image description here

यह मैं क्या चाहते है

enter image description here

GridView

<ScrollView 
    android:layout_width="match_parent" 
    android:layout_height="match_parent" > 

    <LinearLayout 
     android:layout_width="match_parent" 
     android:layout_height="match_parent" > 

     <LinearLayout 
      android:id="@+id/layout2" 
      android:layout_width="match_parent" 
      android:layout_height="wrap_content" 
      android:background="@drawable/bg_base" 
      android:orientation="vertical" > 

      <com.camitss.mcolle.ScrollableGridView 
       android:id="@+id/grid_all" 
       android:layout_width="match_parent" 
       android:layout_height="wrap_content" 
       android:columnWidth="110dp" 
       android:gravity="center" 
       android:horizontalSpacing="10dp" 
       android:numColumns="auto_fit" 
       android:padding="5dp" 
       android:verticalSpacing="10dp" /> 
     </LinearLayout> 
    </LinearLayout> 
</ScrollView> 

GridView आइटम

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" 
android:layout_width="match_parent" 
android:layout_height="match_parent" 
android:background="@drawable/card_base" 
android:orientation="vertical" > 

<!-- Green Image --> 
<ImageView 
    android:id="@+id/category_card" 
    android:layout_width="105dp" 
    android:layout_height="105dp" 
    android:layout_centerInParent="true" /> 

<!-- Picture --> 
<ImageView 
    android:id="@+id/imageView1" 
    android:layout_width="95dp" 
    android:layout_height="95dp" 
    android:layout_centerInParent="true" /> 

+0

सेट छवि की लंबाई और ऊंचाई का प्रयास करें = माता पिता को भरने, बजाय "xxdp" – swiftBoy

+0

यह काम नहीं कर रहा है। मैं पहले से ही इसका परीक्षण करता हूं। : डी – kongkea

+0

मुझे कोशिश करने दो !! बस स्रोत छवियों को साझा करें – swiftBoy

उत्तर

6

इस

<!-- Picture --> 

    <ImageView 
     android:id="@+id/imageView1" 
     android:layout_width="95dp" 
     android:layout_height="95dp" 
     android:layout_centerInParent="true" 
     android:scaleType="fitXY" 
     android:adjustViewBounds="true" /> 
+0

मुझे एपू – kongkea

+0

की मदद करने के लिए धन्यवाद आपका स्वागत है कोंगके। – Kanth