android:在可扩展列表视图中设置指示器的大小
我正在制作一个应用程序,其中我必须使用组指示器的图像,当应用它时,它会显示放大图像。任何人都可以帮助我如何在可扩展列表视图中设置指示器图像。任何帮助将不胜感激。
I am making an app in which i have to use image of group indicator when when applied it shows enlargrd image .Can anyone help me how to set indicator image in expandable list view .Any help will be appreciated.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
自定义绘图可能就是您所需要的。您不能玩弄内置指示器。看看这个。该页面底部的 group_indicator.xml 是自定义指示器的示例。您只需将此可绘制对象添加到您的可扩展列表视图元素的 android:groupindicator 值中即可。通过这种方式,您可以控制指示器的行为和大小,并且通过一些调整,如果组中没有子项,也可以隐藏指示器。
希望有帮助。
a custom drawable is probably what you need. You cant toy with the in built indicator. have a look at this. The group_indicator.xml at the bottom of that page is an example of a custom indicator. You just add this drawable to the android:groupindicator value of you expandablelistview element. This way you can control the indicator behavious and size and with aa few tweaks also hide the indicator if there are no children in the group.
Hope it helps.
下面的代码可能会有所帮助
The following code may be helpful
该版本使用最新的ic_keyboard_arrow矢量图标(24dp):
This version uses the latest ic_keyboard_arrow vector icons (24dp):