8
Android矢量可绘制应用程序:srcCompat不显示图像
我正在使用支持库在android kitkat上显示矢量图像。当我在模拟器上测试我的应用程序时,我看不到任何这些图像。我为Android Lollipop及更高版本制作了单独的布局,并且运行良好(我认为是因为我使用的是src属性,而不是srcCompat下面的代码,这是我在USIG支持库中使用的代码 <LinearLayout android:layout_alignParentBottom="true" android:id="@+id/lake_detail" android:background="@drawable/my_fishing_plan_footer_line" android:orientation="horizontal" android:layout_width="match_parent" android:layout_height="90dp" xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto"> <RelativeLayout android:layout_marginRight="3dp" android:id="@+id/fire_logo" android:layout_width="20sp" android:layout_height="20sp"> <ImageView android:tint="#d74313" app:srcCompat="@drawable/circle_icon" android:layout_width="30sp" android:layout_height="30sp" /> <ImageView android:layout_centerVertical="true" android:layout_centerHorizontal="true" app:srcCompat="@drawable/lauzaviete" android:layout_width="25dp" android:layout_height="25dp" /> </RelativeLayout> 这很奇怪,因为我在android studio预览窗口中看到了图像。