CLion 2021.2 Help

Objective-C/C++

CLion enables you to work with Objective-C/C++ files as comprehensively and productively as with code written in C or C++.

You can open, create and add Objective-C/C++ files with .m and .mm extensions into your CMake or compilation database project, and use all of the features for code inspection, assistance and refactoring that CLion provides. Live and code templates are also available for Objective-C/C++ code. For more details, see CLion Features in Different Languages.

To configure Objective-C/C++ specific settings, use the following pages of the Settings/Preferences dialog Ctrl+Alt+S:

  • Editor | Inspections | Objective-C

  • Editor | File and Code Templates (and select the Code tab)

  • Editor | Live Templates

Enable code style and color scheme settings for Objective-C/C++

  1. Press Ctrl+Shift+A or choose Help | Find Action from the main menu. In the popup that opens, start typing Registry, select the corresponding item and press Enter.

    Searching for Registry in Find Action
  2. In the Registry dialog, start typing clion.enable.objc.settings and select the checkbox next to the corresponding key:

    Enabling Objective-C/C++ in the registry
  3. As a result, Color Schemes and Code Styles pages of the Settings/Preferences dialog now cover Objective-C/C++:

    Objective-C/C++ color scheme settings
    Objective-C/C++ code style settings
Last modified: 26 August 2021