Android Studio設(shè)置小技巧

1、添加文件描述

step1: 點(diǎn)擊 setting>>Editor>>File and code Templates? (ctrl+alt+s)

step2: 選中includes標(biāo)簽

step3: 點(diǎn)擊File Header

step4: 在右邊輸入框輸入以下內(nèi)容

/**

* @author ${USER}

* @date ${DATE} ${TIME}

* @description

*/


點(diǎn)擊應(yīng)用-->點(diǎn)擊ok即可


2、添加方法注釋

step1: 點(diǎn)擊 setting>>Editor>>File and code Templates

step2: 選中includes標(biāo)簽

step3: 點(diǎn)擊綠色的”+”新建一個(gè)名為”Method Header”的子元素

step4: 選中新建的”Method Header”,在右邊輸入框輸入以下內(nèi)容,點(diǎn)擊OK

/**

? * description: <一句話功能簡(jiǎn)述>

? * @param [參數(shù)1] [參數(shù)1說(shuō)明]

? * @param [參數(shù)2] [參數(shù)2說(shuō)明]

? * @return [返回類型說(shuō)明]

? * @exception/throws [違例類型] [違例說(shuō)明]

? * @see [類、類#方法、類#成員]

? */


點(diǎn)擊應(yīng)用-->點(diǎn)擊ok


3、Logcat 顏色配置

File->Settings-> Editor -> Colors Scheme -> Android Logcat 或在上面的搜索框中輸入Logcat 點(diǎn)中Verbose , Info, Debug等選項(xiàng),然后在后面將右下角 Use Inberited attributes 去掉勾選 再將 Foreground 前的復(fù)選框選上,就可以雙擊后面的框框去選擇顏色了 Apply–>OK


顏色配置如下:

Log級(jí)別色值

? ? ? VERBOSE? ? BBBBBB

? ? ? DEBUG? ? ? ? 0070BB

? ? ? INFO? ? ? ? ? 48BB31

? ? ? WARN? ? ? ? BBBB23

? ? ? ERROR? ? ? ? FF0006

? ? ? ASSERT? ? ? 8F0005


也可以按照自己喜歡的顏色進(jìn)行配置哦!

?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請(qǐng)聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時(shí)請(qǐng)結(jié)合常識(shí)與多方信息審慎甄別。
平臺(tái)聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡(jiǎn)書系信息發(fā)布平臺(tái),僅提供信息存儲(chǔ)服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

友情鏈接更多精彩內(nèi)容