File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed
src/main/kotlin/org/domaframework/doma/intellij/formatter/processor Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change 1616package org.domaframework.doma.intellij.formatter.processor
1717
1818import com.intellij.application.options.CodeStyle
19+ import com.intellij.ide.highlighter.JavaFileType
1920import com.intellij.lang.injection.InjectedLanguageManager
2021import com.intellij.openapi.command.WriteCommandAction
2122import com.intellij.openapi.editor.Document
@@ -45,7 +46,7 @@ class InjectionSqlFormatter(
4546
4647 private fun createSpaceIndent (project : Project ): String {
4748 val settings = CodeStyle .getSettings(project)
48- val java = settings.indentOptions
49+ val java = settings.getIndentOptions( JavaFileType . INSTANCE )
4950 val indentSize = java.INDENT_SIZE
5051 val prefixLen = " @Sql(\"\"\" " .length
5152 return StringUtil .SINGLE_SPACE .repeat(indentSize.plus(prefixLen))
You can’t perform that action at this time.
0 commit comments