Commit 63ca00b3 authored by Christian Hergert's avatar Christian Hergert

spaces-style: add new flags type for spaces styling

We can use this in file-settings to describe some basic spaces styling.
Then from completion providers we can attempt to do the right thing.
parent 6e7fca73
/* ide-spaces-style.h
*
* Copyright © 2018 Christian Hergert <chergert@redhat.com>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include <glib.h>
G_BEGIN_DECLS
typedef enum
{
IDE_SPACES_STYLE_IGNORE = 0,
IDE_SPACES_STYLE_BEFORE_LEFT_PAREN = 1 << 0,
IDE_SPACES_STYLE_BEFORE_LEFT_BRACKET = 1 << 1,
IDE_SPACES_STYLE_BEFORE_LEFT_BRACE = 1 << 2,
IDE_SPACES_STYLE_BEFORE_LEFT_ANGLE = 1 << 3,
IDE_SPACES_STYLE_BEFORE_COLON = 1 << 4,
IDE_SPACES_STYLE_BEFORE_COMMA = 1 << 5,
IDE_SPACES_STYLE_BEFORE_SEMICOLON = 1 << 6,
} IdeSpacesStyle;
G_END_DECLS
......@@ -3,6 +3,7 @@ files_headers = [
'ide-file-settings.h',
'ide-file-settings.defs',
'ide-indent-style.h',
'ide-spaces-style.h',
]
files_sources = [
......@@ -12,6 +13,7 @@ files_sources = [
files_enums = [
'ide-indent-style.h',
'ide-spaces-style.h',
]
libide_public_headers += files(files_headers)
......
......@@ -12,6 +12,7 @@
#include "diagnostics/ide-diagnostic.h"
#include "doap/ide-doap.h"
#include "files/ide-indent-style.h"
#include "files/ide-spaces-style.h"
#include "highlighting/ide-highlighter.h"
#include "runtimes/ide-runtime.h"
#include "sourceview/ide-cursor.h"
......
......@@ -101,6 +101,8 @@ G_BEGIN_DECLS
#include "editor/ide-editor-view.h"
#include "files/ide-file-settings.h"
#include "files/ide-file.h"
#include "files/ide-indent-style.h"
#include "files/ide-spaces-style.h"
#include "genesis/ide-genesis-addin.h"
#include "greeter/ide-greeter-section.h"
#include "highlighting/ide-highlight-engine.h"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment