美文网首页azoyaclub
android studio 的相关配置

android studio 的相关配置

作者: kai_w | 来源:发表于2017-10-12 13:20 被阅读0次

从工具到代码,全规范开发,实现多协同工作,减少彼此工作对接交叉代价
链接代码规范

一. setting 页面默认快捷键

  1. mac -> "command + ,"
  2. windows -> "ctrl +alt + s"

二. 基础设置

  1. 单词提示功能忽略大小写(Setting-->Editor-->General-->Code Completion-->匹配none搜索 )
Code Completion Setting
  1. 类包自动导入(Setting-->Editor-->General-->AutoImport -->勾选 Add unambiguous improts on the fly)
AutoImport Setting
  1. 显示代码行数(Setting-->Editor-->Appearance-->show line numbers)
show line numbers setting
  1. 设置自动编译功能(Setting-->Build、Execution、Deployment-->Compiler-->勾选make project automatically)
  1. 编辑代码时自动优化import(Preferences – Editor – General – Auto Import – Optimize imports on the fly)

三. 规范设置

step 1, 设置 as 基础文件格式(UTF-8) window 默认GBK,更改setting :

File Encodings setting

step 2, 设置 as 的java 代码中的成员变量和局部变量的列对齐方式。

image.png

四. 实用功能

  1. 查找项目中的含有中文字符串的位置
打开全局搜索,利用其查找功能和正则表达式:
 ^((?!(\*|//)).)+[\u4e00-\u9fa5]

相关文章

网友评论

    本文标题:android studio 的相关配置

    本文链接:https://www.haomeiwen.com/subject/ecnnyxtx.html