Skip to content

Latest commit

 

History

History
39 lines (26 loc) · 1.32 KB

code_style_settings.md

File metadata and controls

39 lines (26 loc) · 1.32 KB
title
16. Code Style Setting

Code style settings allow defining formatting options. A code style settings provider will create an instance of the settings, and also create an options page in order to edit them. In this example, we'll create a page that uses the default language code style settings, customised by a language code style settings provider.

16.1. Define code style settings

{% include /code_samples/simple_language_plugin/src/main/java/com/intellij/sdk/language/SimpleCodeStyleSettings.java %}

16.2. Define code style settings provider

{% include /code_samples/simple_language_plugin/src/main/java/com/intellij/sdk/language/SimpleCodeStyleSettingsProvider.java %}

16.3. Register the code style settings provider

<codeStyleSettingsProvider implementation="com.simpleplugin.SimpleCodeStyleSettingsProvider"/>

16.4. Define language code style settings provider

{% include /code_samples/simple_language_plugin/src/main/java/com/intellij/sdk/language/SimpleLanguageCodeStyleSettingsProvider.java %}

16.5. Register the language code style settings provider

<langCodeStyleSettingsProvider implementation="com.simpleplugin.SimpleLanguageCodeStyleSettingsProvider"/>

16.6. Run the project

Code Style Settings