android - 如何在 api 17 或更高版本中使 android seekbar 全宽?

标签 android layout width padding seekbar

我想让搜索栏全宽,没有填充。

我看过这个答案 How to make SeekBar take up full width of parent

但在 api 17 及更高版本中它不起作用。搜索栏的左侧和右侧有一个填充。如何删除此填充?

enter image description here

最佳答案

我只是在运行时设置了 padding,现在就可以了!

musicSeekbar.setPadding(0,0,0,0);

关于android - 如何在 api 17 或更高版本中使 android seekbar 全宽?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33327246/

相关文章:

android - 如何从android中的通知栏调用对话框?

Android Spinner 数据 View 未在重新选择的项目上更新

java - android:layout_alignParentBottom ="true"和android:gravity ="bottom"似乎对RelativeLayout没有影响

c++ - 如何调整 QVBoxLayout 的大小以填充没有空格的表单?

响应式网页设计中的宽度与最大宽度

html - 根据设备调整 div 大小

android - 上次 sdk 更新后,android studio 找不到任何 google play 服务或 firebase 库

没有滚动条的CSS粘性页脚

javascript - Qooxdoo 布局问题

html - 两个div,左边是static div,右边是fluid div