如何在 Android 应用中使用 Material Design? [英] How to Use Material Design in Android App?
问题描述
我已转到 Android 开发人员文档以了解如何使用 Material Design,此处:
I've gone to the Android Developer documentation to see how I can use material design, here:
https://developer.android.com/training/material/theme.html>
这里:
https://developer.android.com/training/material/get-started.html一个>
本质上,我希望有人总结一下如何设置/使用材料设计,因为我觉得开发人员文档上有很多信息,我似乎无法理解它.如果您更愿意给我一个指向其他人创建的指南的链接,那也会很有帮助.
Essentially, I would like for someone to summarize how to set up/use material design, because I feel like there is a lot of information on the developer docs, and I can't seem to wrap my mind around it. If you'd rather give me a link to a guide created by someone else, that'd be helpful as well.
我也在使用 API 级别 19(目标 SDK 版本 19),据我所知,我需要使用 com.android.support:cardview-v7:21.0.+
I'm also using API level 19 (target SDK version 19) and from what I can see, I'll need to use com.android.support:cardview-v7:21.0.+
我也在使用 Android Studio,而不是 eclipse.
I'm also using Android Studio, and not eclipse.
我希望能够为没有运行 Android 5.0 Lollipop 的设备使用 Material Design,因为根据 Android 分布数据,只有不到 0.1% 的设备运行 Lollipop:Android 分布数据
I would like to be able to use material design for devices that are not running Android 5.0 Lollipop, because according to the Android distribution data, there are less than 0.1% of devices running Lollipop: Android Distribution Data
推荐答案
安装Android 5.0 SDK
的 SDK 平台,然后通过 SDK-Manager 将您的 Support Library 和 Support Repository 更新到最新版本.
Install SDK platform of Android 5.0 SDK
then update your Support Library and Support Repository to the latest version via the SDK-Manager.
看看这个链接来创建材料应用
Take a look at this link for creating material app
http://developer.android.com/training/material/index.html
借助支持库,您可以在旧设备上提供类似的行为,例如:
With support libraries, you can provide similar behaviour on older devices like:
- 使用 Material 主题
- UI 小部件的子集,例如
EditText
微调器
单选按钮
另请参阅android设计支持库.
更多信息:
- https://chris.banes.me/2014/10/17/appcompat-v21/
- http://android-developers.blogspot.co.uk/2014/10/appcompat-v21-material-design-for-pre.html
- https://developer.android.com/training/material/compatibility.html
但是要在您的应用程序中使用诸如
FloatingActionButton
之类的概念,您可以使用此库:https://github.com/makovkastar/FloatingActionButtonBut for using some concepts like
FloatingActionButton
in your application you can use this library : https://github.com/makovkastar/FloatingActionButton此处提供更多库
这篇关于如何在 Android 应用中使用 Material Design?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!