[英]How to set the size of a drawable?
The android developer docs say that the size for an icon in the action bar should be 32x32 dp . android开发人员文档说,操作栏中图标的大小应为32x32 dp 。 I have an xml as follows:
我有一个XML,如下所示:
<?xml version="1.0" encoding="utf-8"?>
<menu xmlns:android="http://schemas.android.com/apk/res/android">
<item android:id="@+id/new_game"
android:icon="@drawable/my_pic1"
android:title="@string/new_game"
android:showAsAction="ifRoom"/>
</menu>
How can I make the size of my_pic1 32x32dp? 如何使my_pic1的大小为32x32dp?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.