1.如上图,as升级到2.3之后,新建布局默认变成了约束布局
2.在as安装目录\plugins\android\lib\templates\activities\common\root\res\layout下,找到simple.xml.ftl文件
3.用以下布局替换
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context="${relativePackage}.${activityClass}">
<TextView
android:text="@string/hello_world"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
</RelativeLayout>
4.重启as,大公告成!