Android のグリッド ビュー レイアウトに問題があります。グリッド ビューの余分なスペースを削除する解決策が見つかりません。以下のように、グリッド ビューのコードについて言及します。
<?xml version="1.0" encoding="utf-8"?>
<GridView xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/gridview"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:alwaysDrawnWithCache="true"
android:background="@android:color/background_dark"
android:clipChildren="true"
android:columnWidth="100dp"
android:gravity="center_horizontal"
android:horizontalSpacing="2dp"
android:numColumns="auto_fit"
android:padding="0dp"
android:scrollingCache="true"
android:smoothScrollbar="true"
android:stretchMode="columnWidth"
android:verticalSpacing="2dp" />
今、私のアプリケーションのグリッド ビューは次のようになります
示されているように、削除したい余分なスペースがあり、次のようになります:-
だから私に解決策を提供してください..事前に感謝..