如何将相对布局设置为默认布局 [英] How to set Relative Layout as default layout
本文介绍了如何将相对布局设置为默认布局的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我通常在大部分活动中都使用相对布局.我想让Android Studio在创建新活动时默认创建相对布局,而不是约束布局.有办法吗?
I usually use Relative layout for most of my activity. I want to make Android studio create Relative layout by default when I create new activity, instead of Constraint Layout. Is there a way to do that?
推荐答案
- 右键单击布局文件夹->新建->编辑文件模板...
- 打开一个对话框,转到其他"标签.
- 更改内容 "LayoutResourceFile.xml"和"LayoutResourceFile_vertical.xml" 将根标记更改为所需的布局类型.希望有帮助:)
- Right click on layout folder -> New -> Edit File Templates...
- A dialog opened, go to "Other" tab.
- Change the content of "LayoutResourceFile.xml" and "LayoutResourceFile_vertical.xml" Change root tag to the type of layout you want. Hope this help :)
这篇关于如何将相对布局设置为默认布局的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文