ivy*_*the 6 icons android android-studio android-vectordrawable adaptive-icon
首先
我注意到在 Android Studio 中创建一个新项目时它会生成drawable-v24带有ic_launcher_foreground.xml图标的文件夹。
我的问题是:
drawable-v24放在drawable-v21文件夹中而不是放在文件夹中?其次
另一个生成的资产是ic_launcher_background.xml在res/drawable文件夹中创建的,后来从mipmap-anydpi-v26/ic_launcher.xml.
res/drawable文件夹中创建而不是在res/drawable-v24或 中res/drawable-v26?是由于 mipmap 文件夹的某些性质吗?尽管 VectorDrawable功能是从 API-21 引入的,但它在某种程度上已集成到 API-24 中。我认为 Google 的开发人员认为 API-24+ 对于自适应图标来说是理想的或稳定的。
\n\n例如,Nick Butcher(Android 设计师 + 开发者@Google)在他的文章:在 Android 应用程序中使用矢量资源(2018 年 12 月 11 日)中说道,
\n\n\n\n\n\n
\n- nonZero 和 EvenOdd 路径 fillTypes \xe2\x80\x94 定义形状内部的两种常见方法,经常在 SVG 中使用(evenOdd 添加到 API 24 中的平台实现中)
\n- 渐变和 ColorStateList 填充/描边(添加到 API 24 中的平台实现)
\n
而关于ic_launcher_background,它仅引用自mipmap-anydpi-v26/ic_launcher.xml和mipmap-anydpi-v26/ic_launcher_round.xml。我认为这只是没有必要阻止直接引用它(它已经通过放置ic_launcher.xmlandic_launcher_round.xml来阻止mipmap-anydpi-v26文件夹中来阻止)。不应该有更多、更深刻的含义。
| 归档时间: |
|
| 查看次数: |
1173 次 |
| 最近记录: |