Can Clang formatting be used in Netbeans

谁都会走 提交于 2019-12-05 14:11:50

At the time you posted your question the answer was no, but now (over a year later!) you can use the clang formatter in NetBeans, subject to the following constraints:

  1. You must use version 8.2 of NetBeans rather than version 8.1.

  2. You must install from a recent nightly development build of NetBeans 8.2 rather than using the standard release. That's because this functionality was only added recently. See NetBeans bug 270882.

To use the clang formatter in NetBeans:

  • Create a trivial C++ application in NetBeans.

  • Select its project node in the Projects tab, right click, and select Properties from the popup menu.

  • In the Project Properties window that opens click Formatting in the list of categories.

  • On the right side of the screen there is a new radio button named Use clang-format. Click that, and you can then either use a predefined style, or supply your own customized format file, as shown in the screen shot below.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!