public static StringBuilder createIndent() {
        IPreferenceStore preferenceStore = EditorsPlugin.getDefault().getPreferenceStore();
        boolean useSpaces = preferenceStore.getBoolean(AbstractDecoratedTextEditorPreferenceConstants.EDITOR_SPACES_FOR_TABS);
        StringBuilder oneIndent = new StringBuilder();
        if (!useSpaces) {
            oneIndent.append('\t');
        } else {
            int tabWidth = preferenceStore.getInt(AbstractDecoratedTextEditorPreferenceConstants.EDITOR_TAB_WIDTH);
            for (int i = 0; i < tabWidth; i++) {
                oneIndent.append(' ');
            }
        }

        return oneIndent;
    }
Creates a string that represents one indent (can be spaces or tabs..)

@return one indentation
plugins/org.jkiss.dbeaver.ui.editors.sql/src/org/jkiss/dbeaver/ui/editors/sql/indent/SQLIndenter.java