代码拉取完成,页面将自动刷新
一个包含 2000 多个材料矢量图标的库,可轻松用作 PixelMap和独立控件。 厌倦了每次要测试某些东西时都必须搜索和生成 png 资源? 这个库结束了这种负担并使交换图标变得轻而易举,查看下面的用法,你就会明白为什么。
在project的build.gradle中添加mavenCentral()的引用
repositories {
...
mavenCentral()
...
}
在entry的build.gradle中添加依赖
dependencies {
...
implementation 'com.gitee.archermind-ti:materialiconlib:1.0.1'
...
}
MaterialDrawableBuilder.with(context).setIconColor(0xFF000000).setResId(resId).build();
<net.steamcrafted.materialiconlib.MaterialIconView
ohos:height="250"
ohos:width="250"
app:miv_icon_color="#FF000000"
app:miv_bg_color="#FF0000AA"
app:miv_padding="30"
app:miv_img_src="$media:file"/>
Run
运行即可(真机运行可能需要配置签名)MaterialDesignicons Released under the SIL Open Font License 1.1
Google Material Design Icons Released under the Apache 2.0 License
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。
1. 开源生态
2. 协作、人、软件
3. 评估模型