Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想在每个单元格(单元格中心)中有一个 3 列和 3 行的网格和一个图像按钮。
我尝试使用gridview,但无法修复行数。我尝试了一个表格布局和 3 个表格行,但我无法在运行时更改宽度/高度
有任何想法吗?
如果您使用的是表格布局,您只需在每个 ImageButton 上执行以下操作:
this.setPadding(0, 0, 0, 0); this.setScaleType(ScaleType.CENTER_INSIDE);