Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package com.gameforge.idea.Corona.lang.formatter;
- import com.gameforge.idea.Corona.lang.parser.CoronaElementTypes;
- import com.intellij.formatting.Indent;
- import com.intellij.lang.ASTNode;
- import com.intellij.psi.impl.source.tree.FileElement;
- public class CoronaIndent implements CoronaElementTypes {
- public static Indent getIndent(CoronaFormatBlock parent, ASTNode child) {
- if (child.getElementType() == BLOCK && !(parent.getNode().getPsi() instanceof FileElement)) {
- return Indent.getNormalIndent();
- }
- return Indent.getNoneIndent();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement