Flutter 在颤振中的滑动条和滑动列表之间添加空格
我有一个滑动条,下面是一个滑动列表 第一个SliverList项太靠近SliverAppBar。我想在两者之间添加一些间距,无论是通过滑动条下方的底部边距还是滑动列表上方的底部边距 如何做到这一点?-p>将此小部件包装起来 您的解决方案应该如下所示:Flutter 在颤振中的滑动条和滑动列表之间添加空格,flutter,flutter-sliver,Flutter,Flutter Sliver,我有一个滑动条,下面是一个滑动列表 第一个SliverList项太靠近SliverAppBar。我想在两者之间添加一些间距,无论是通过滑动条下方的底部边距还是滑动列表上方的底部边距 如何做到这一点?-p>将此小部件包装起来 您的解决方案应该如下所示: SliverPadding( padding: EdgeInsets.only(bottom: 8.0) sliver: SliverAppBar(...) ) 或 MediaQuery.removePadding帮助了我。 Sliver
SliverPadding(
padding: EdgeInsets.only(bottom: 8.0)
sliver: SliverAppBar(...)
)
或
MediaQuery.removePadding帮助了我。
SliverPadding(
padding: EdgeInsets.only(top: 8.0)
sliver: SliverList(...)
)