侧边栏壁纸
  • 累计撰写 80 篇文章
  • 累计创建 41 个标签
  • 累计收到 3 条评论

目 录CONTENT

文章目录

Eclipse/MyEclipse 安装后应该更改的设置

已删除用户
2016-08-21 / 0 评论 / 0 点赞 / 161 阅读 / 3669 字 / 正在检测是否收录...

基本上都通过 Window -> Preferences 进行设置:

Java 保存自动格式化:

Java:Java -> Editor -> Save Actions,选中 Perform the selected actions on save,选中 Format source code;

image-1661960422323

JavaScript 格式化:

MyEclipse -> Files and Editors -> JavaScript -> Editor -> Save Actions,操作同上。

image-1661960433552

XML 格式化:

General -> MyEclipse -> XML -> XML Files -> XML Source -> Split multiple attributes each on a new line。

image-1661960442210

代码自动提示:

Java -> Editor -> Content Assist,将 Auto activation triggers for Java 的值由 “.” 更改为 “.abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ”。

image-1661960451531

单行注释不换行(非更改行长度),保持注释前格式:

Java -> Code Style -> Formatter,Edit(如果没有新建的话请先新建),Comments 选项卡,将 Enable line comment formatting 取消勾选即可。

image-1661960460086

PS:<pre> …… </pre> 是在 /** …… */ 中保持格式不改变。

代码格式的缩进为空格:

Java -> Code Style -> Formatter,Edit(如果没有新建的话请先新建),Indentation 选项卡,将 Tab policy 更改为 Spaces only,Indetation size 的话看喜好。

image-1661960470167

制表符更改为空格:

General -> Editors -> Text Editors,勾选 Insert sapces for tabs, Displayed tab width 的话看喜好。

image-1661960478655

将默认 JRE 替换为自定义的:

Java -> Installed JREs,点击 Add 按钮,选中 Standard VM,点击 Next 按钮,点击 Directory… 按钮,选择 JDK 目录。

image-1661960489517

然后勾选刚添加的 JRE,将它作为默认的。

修改 JSP 文件默认编码:

MyEclipse -> Files and Editors -> JSP,将 Encoding 更改为 ISO 10646/Unicode(UTF-8)。

image-1661960498408

关闭 Maven 自动更新:

Maven:MyEclipse -> Maven[4MyEclipse],去除勾选 Download repository index updates on startup。

image-1661960508777

取消文件自动校验:

Myeclipse -> Validation,Build 一列,只保留 Classpath Dependency Validator,其它全部去掉。

手工验证方法:在需要验证的文件上,鼠标右键,MyEclipse -> Run Validation。

image-1661960517355

设置工作空间项目编码(创建在工作空间的项目编码自动为 UTF-8):

General -> Workspace,Text file encoding 更改为 Other UTF-8[,New text file line delimiter 更改为 Other Unix],Next text file line delimiter 更改为 Other Unix。

image-1661960527718

更改 JSP 默认编辑器:

General -> Editors -> File Associations,File types 中找到 *.jsp,Association editors 中将 MyEclipse JSP Editor 设置为 Default。

image-1661960535457

取消启动和关闭时加载的模块:

General -> Startup and Shutdown,取消勾选一些不用的模块,模块作用暂略。

image-1661960543474

关闭启动 Service 后自动跳转回 Servers 窗口:

image-1661960552308

0

评论区