Android:XML文件的设计视图为白色和空白 [英] Android: Design view of XML file is white and blank
本文介绍了Android:XML文件的设计视图为白色和空白的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在res文件夹下创建了一个菜单文件夹,然后在该菜单文件夹中创建了一个名为抽屉文件.这是该文件的文本:
I created a menu folder under res folder and, in that menu folder, I created a file called drawer_menu.xml. This is the text of that file:
<?xml version="1.0" encoding="utf-8"?>
<menu xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
tools:showIn="navigation_view">
<group
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:checkableBehavior="single">
<item
android:id="@+id/nav_profile"
android:icon="@drawable/ic_profile"
android:title="Message" />
<item
android:id="@+id/nav_my_events"
android:icon="@drawable/ic_my_events"
android:title="Chat" />
</group>
<item android:title="Communicate">
<menu>
<item
android:id="@+id/nav_settings"
android:icon="@drawable/ic_settings"
android:title="Share" />
<item
android:id="@+id/nav_logout"
android:icon="@drawable/ic_logout"
android:title="Send" />
</menu>
</item>
</menu>
但是设计视图为白色和空白.没有显示任何元素.我也看不到通常在布局xml文件中显示的AppThemes选项.
But the design view is white and blank. No element shows up.Also I don't get to see AppThemes option which usually shows up in layout xml files.
推荐答案
我正在使用Android Studio Canary 3.2,看起来像这样.
I am using Android Studio Canary 3.2 and looks like that.
所以,也许是您的Android Studio版本的错误.
So maybe is a bug of your Android Studio version.
这篇关于Android:XML文件的设计视图为白色和空白的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文