您的位置:首页 > 其它

学习Material Design Support

2015-12-27 23:05 211 查看
读Blog,学会使用控件

http://android-developers.blogspot.com/2015/05/android-design-support-library.html

cheesesquare,使用5.0控件项目

https://github.com/chrisbanes/cheesesquare

DrawerLayout,NavigationView.用于侧边栏实现。

CoordinatorLayout:最外层用于滑动控制app:layout_scrollFlags=“”

scroll: this flag should be set for all views that want to scroll off the screen - for views that do not use this flag, they’ll remain pinned to the top of the screen

enterAlways: this flag ensures that any downward scroll will cause this view to become visible, enabling the ‘quick return’ pattern

enterAlwaysCollapsed: When your view has declared a minHeight and you use this flag, your View will only enter at its minimum height (i.e., ‘collapsed’), only re-expanding to its full height when the scrolling view has reached it’s top.

exitUntilCollapsed: this flag causes the view to scroll off until it is ‘collapsed’ (its minHeight) before exiting

AppBarLayout:

using an AppBarLayoutallows your Toolbar and other views (such as tabs provided by TabLayout) to react to scroll events in a sibling view marked with a ScrollingViewBehavior.

ToolBar:

using a Toolbar in your layout, allowing you to more easily customize the look and integration of that iconic part of an app with the rest of your layout.

CollapsingToolBarLayout:

Adding a Toolbar directly to an AppBarLayout gives you access to the enterAlwaysCollapsed andexitUntilCollapsed scroll flags, but not the detailed control on how different elements react to collapsing. For that, you can use CollapsingToolbarLayout:

处理子元素相应不同的collapsing。

app:layout_collapseMode=“pin” 或者”parallax”
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: