# cpp-mode **Repository Path**: lodahoo/cpp-mode ## Basic Information - **Project Name**: cpp-mode - **Description**: No description available - **Primary Language**: Unknown - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 1 - **Created**: 2022-02-26 - **Last Updated**: 2022-04-02 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README cpp-mode: A C++ IDE for vim =============================================== ![][1] ## 安装 - `vim-plug` Plug 'chxuan/cpp-mode' - `Vundle` Plugin 'chxuan/cpp-mode' ## 使用 - `:CopyCode` 拷贝函数或变量,和`:PasteCode`结合使用 - `:PasteCode` 生成函数实现或变量定义,和`:CopyCode`结合使用 - `:GoToFunImpl` 转到函数实现,该功能可替代ycm提供的转到函数实现(因为ycm转到函数实现经常不成功) - `:Switch` c++头文件和实现文件切换 - `:FormatFunParam` 格式化函数参数,用于函数参数列表过多的情况 - `:GenTryCatch` 生成try-catch代码块 ## 参考配置 请将以下配置加到 `~/.vimrc`,如果不喜欢以下映射,可根据个人喜好更改。 nnoremap y :CopyCode nnoremap p :PasteCode nnoremap U :GoToFunImpl nnoremap a :Switch nnoremap fp :FormatFunParam nnoremap if :FormatIf nnoremap t dd :GenTryCatch xnoremap t d :GenTryCatch ## License This software is licensed under the [MIT license][2]. © 2018 chxuan [1]: https://raw.githubusercontent.com/chxuan/cpp-mode/master/screenshots/cpp-mode.gif [2]: https://github.com/chxuan/cpp-mode/blob/master/LICENSE