Vscode-cpptools: Please add snippet editing to this extention

Created on 29 Apr 2019  路  4Comments  路  Source: microsoft/vscode-cpptools

Type: LanguageService

It would be really useful to be able to tweak the snippets to my liking in a text file. I personally have minor formatting tweaks that I'd like to do like adjusting the position of the first curly bracket after for and having **env in the main function. I'd prefer not to have duplicates in the context menu either.

Feature Request Auto-complete Language Service help wanted

Most helpful comment

It would be great if it just used the clang-format that was already set. Then you wouldn't even have to edit the snippets, but they would just conform to the existing code style you have chosen.

All 4 comments

Another user requested this at https://github.com/Microsoft/vscode-cpptools/issues/3354 too.

Yeah, this is relatively straight-forward to implement, we just need to add a setting for a snippets json file with the snippet data, and then send the file path to our language server process, similar to how we handle the compileCommands json setting.

@sean-mcmanus any plan to implement this feature锛烮 alse want to modify the extension's snippet for some different code style.

@chongchai We'd like too eventually, but we're all busy working on other higher priority stuff currently. If someone could help out with a pull request with the TypeScript changes that would help (we'd still have to add some language server side changes to handle the new snippets).

It would be great if it just used the clang-format that was already set. Then you wouldn't even have to edit the snippets, but they would just conform to the existing code style you have chosen.

Was this page helpful?
0 / 5 - 0 ratings