VScode使用护眼主题+Astyle代码格式化工具

Astyle的bin路径要加入系统环境变量
安装好插件后VScode设置

{
    /* AStyle */
    "astyle.additional_languages": [
        "c",
        "cpp",
        "*.h",
    ],
    "astyle.cmd_options": [
        // 预定义风格 -----------------------------------------------------------
         "--style=ansi",             //ANSI 风格格式和缩进
        // "--style=kr",               //Kernighan&Ritchie 风格格式和缩进
        //"--style=linux", //Linux 风格格式和缩进
        //"--style=gnu",               //GNU 风格格式和缩进
        // "--style=java",             //Java 风格格式和缩进
        "--indent=spaces=4", //缩进4个空格
        "--indent-preproc-block",
        "--pad-oper", //操作符两端插入一个空格
        "--pad-header",
        "--unpad-paren",
        "--suffix=none",
        "--align-pointer=name",
        "--lineend=linux",
        //"--convert-tabs", //TAB转换为空格
        "--verbose",
        // "--delete-empty-lines",   //删除多余空行
        "--pad-paren-in",         //括号内部加入空格
        "--unpad-paren", //移除括号两端多余空格
    ],
    "workbench.colorTheme": "Atom One Light",
    "editor.tabSize": 2, //工作台主题颜色
    "typescript.updateImportsOnFileMove.enabled": "always", // 开启 vscode 文件路径导航
    // "tslint.autoFixOnSave": true, // #每次保存的时候将代码按tslint格式进行修复
    "eslint.autoFixOnSave": true, // #每次保存的时候将代码按eslint格式进行修复
    // "prettier.semi": false,//prettier 设置语句末尾不加分号
    "prettier.singleQuote": true, // prettier 设置强制单引号
    "vetur.format.defaultFormatter.js": "vscode-typescript", // #让vue中的js按编辑器自带的ts格式进行格式化 
    "window.enableMenuBarMnemonics": false,
    "liveServer.settings.donotShowInfoMsg": true,
    // "workbench.colorTheme": "Winter is Coming (Light)", //窗口.不启用菜单栏输入法,修改主题配色
    "workbench.colorCustomizations": { // 颜色设置
        "editor.background": "#C7EDCC",
        //"editor.selectionHighlightBackground": "#f5f113",//选中代码高亮颜色
        //"editor.selectionBackground": "#f5f113",//选中区域背景色
        "sideBar.background": "#C7EDCC",
        "terminal.background": "#82e08f"
    },
    "editor.tokenColorCustomizations": {
        "[Atom One Light]":{
            "comments": "#043cf5",//注释
            //"strings": "#7e3648",//字符串
            "functions": "#367a33",//函数
            //"keywords": "#a207fc",//关键字
            //"variables": "#e21d1d",//变量
            //"numbers": "#e21d1d",//数字
            /*"textMateRules":[
                {
                    "name": "Operator",
                    "scope": "keyword.operator",
                    "settings":{
                        "foreground": "#e21d1d",
                        "fontStyle": "bold"
                    }
                },
                {
                    "name": "Punctuation",
                    "scope": "punctuation",
                    "settings":{
                        "foreground": "#a207fc",
                        "fontStyle": "bold"
                    }
                }
            ]*/
        }
    },
    "files.autoGuessEncoding": true,
    "editor.suggestSelection": "first",
    "vsintellicode.modify.editor.suggestSelection": "automaticallyOverrodeDefaultValue",
    "extensions.ignoreRecommendations": true,
    "window.zoomLevel": 0,
    "workbench.editor.enablePreview": false,
    "window.title": "${dirty}${activeEditorLong}${separator}${rootName}${separator}${appName}",
    "workbench.statusBar.visible": false
}

参照如下两个网址
http://www.360doc.com/content/17/1120/16/41190201_705592128.shtml
http://nicethemes.cn/news/txtlist_i37053v.html

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值