如何从ListView控件的右边缘设置边距垂直滚动条?控件、滚动条、边缘、ListView

由网友(每个人喜欢的类型都不一样,有人喜欢可爱的,有人喜欢幽默的,有)分享简介:有关Android平台:For Android Platform:我需要把保证金右侧列表视图垂直滚动条(这是自定义)。请参阅所附的图像。默认滚动条粘在extream右侧的列表视图中。I need to put margin on right side of the vertical scrollbar in lis...

有关Android平台:

For Android Platform:

我需要把保证金右侧列表视图垂直滚动条(这是自定义)。请参阅所附的图像。默认滚动条粘在extream右侧的列表视图中。

I need to put margin on right side of the vertical scrollbar in listview (it is customized). Please see the attached image. Default scrollbar sticks to the extream right side of the listview.

需要你的手。谢谢。

推荐答案

请参照documentation在安卓scrollbarStyle 查看属性。你可能想使用的风格是 insideOverlay (连同安卓paddingRight )。

Refer to documentation on android:scrollbarStyle attribute of View. The style you probably want to use is insideOverlay (in conjunction with android:paddingRight).

类似于

<LinearLayout android:orientation="vertical"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    android:gravity="center_horizontal"
    android:paddingRight="50dip">
    <ListView
        android:id="@+id/scrollable_table" 
        android:layout_width="fill_parent"
        android:layout_height="wrap_content"
        android:scrollbarStyle="insideOverlay">
    .
    .
    .
阅读全文

相关推荐

最新文章