android - Making GridView items square -
i items of gridview square. there 2 columns , items width fill_parent (e.g. take horizontal space possible. items custom views.
how make items height equal variable width?
there simpler solution when gridview columns stretched. override onmeasure of gridview item layout with...
@override public void onmeasure(int widthmeasurespec, int heightmeasurespec) { super.onmeasure(widthmeasurespec, widthmeasurespec); }
Comments
Post a Comment