[gnome-builder] snippets: whitespace cleanup



commit 1100312d666267957239e8dd7c7945e84a492b7a
Author: Christian Hergert <chergert redhat com>
Date:   Mon Jun 11 17:51:48 2018 -0700

    snippets: whitespace cleanup

 src/libide/snippets/ide-snippet-chunk.c   |  34 ++++-----
 src/libide/snippets/ide-snippet-context.c |  18 ++---
 src/libide/snippets/ide-snippet-context.h |  41 ++++++-----
 src/libide/snippets/ide-snippet.c         | 112 +++++++++++++++---------------
 4 files changed, 102 insertions(+), 103 deletions(-)
---
diff --git a/src/libide/snippets/ide-snippet-chunk.c b/src/libide/snippets/ide-snippet-chunk.c
index 22e92b98a..e311d27b6 100644
--- a/src/libide/snippets/ide-snippet-chunk.c
+++ b/src/libide/snippets/ide-snippet-chunk.c
@@ -40,14 +40,14 @@
 
 struct _IdeSnippetChunk
 {
-  GObject                  parent_instance;
+  GObject            parent_instance;
 
   IdeSnippetContext *context;
-  guint                    context_changed_handler;
-  gint                     tab_stop;
-  gchar                   *spec;
-  gchar                   *text;
-  guint                    text_set : 1;
+  guint              context_changed_handler;
+  gint               tab_stop;
+  gchar             *spec;
+  gchar             *text;
+  guint              text_set : 1;
 };
 
 G_DEFINE_TYPE (IdeSnippetChunk, ide_snippet_chunk, G_TYPE_OBJECT)
@@ -126,7 +126,7 @@ ide_snippet_chunk_get_context (IdeSnippetChunk *chunk)
 
 void
 ide_snippet_chunk_set_context (IdeSnippetChunk   *chunk,
-                                      IdeSnippetContext *context)
+                               IdeSnippetContext *context)
 {
   g_return_if_fail (IDE_IS_SNIPPET_CHUNK (chunk));
   g_return_if_fail (!context || IDE_IS_SNIPPET_CONTEXT (context));
@@ -166,7 +166,7 @@ ide_snippet_chunk_get_spec (IdeSnippetChunk *chunk)
 
 void
 ide_snippet_chunk_set_spec (IdeSnippetChunk *chunk,
-                                   const gchar           *spec)
+                            const gchar     *spec)
 {
   g_return_if_fail (IDE_IS_SNIPPET_CHUNK (chunk));
 
@@ -184,7 +184,7 @@ ide_snippet_chunk_get_tab_stop (IdeSnippetChunk *chunk)
 
 void
 ide_snippet_chunk_set_tab_stop (IdeSnippetChunk *chunk,
-                                       gint                   tab_stop)
+                                gint             tab_stop)
 {
   g_return_if_fail (IDE_IS_SNIPPET_CHUNK (chunk));
   chunk->tab_stop = tab_stop;
@@ -200,7 +200,7 @@ ide_snippet_chunk_get_text (IdeSnippetChunk *chunk)
 
 void
 ide_snippet_chunk_set_text (IdeSnippetChunk *chunk,
-                                   const gchar           *text)
+                            const gchar     *text)
 {
   g_return_if_fail (IDE_IS_SNIPPET_CHUNK (chunk));
 
@@ -222,7 +222,7 @@ ide_snippet_chunk_get_text_set (IdeSnippetChunk *chunk)
 
 void
 ide_snippet_chunk_set_text_set (IdeSnippetChunk *chunk,
-                                       gboolean               text_set)
+                                gboolean         text_set)
 {
   g_return_if_fail (IDE_IS_SNIPPET_CHUNK (chunk));
 
@@ -249,9 +249,9 @@ ide_snippet_chunk_finalize (GObject *object)
 
 static void
 ide_snippet_chunk_get_property (GObject    *object,
-                                       guint       prop_id,
-                                       GValue     *value,
-                                       GParamSpec *pspec)
+                                guint       prop_id,
+                                GValue     *value,
+                                GParamSpec *pspec)
 {
   IdeSnippetChunk *chunk = IDE_SNIPPET_CHUNK (object);
 
@@ -284,9 +284,9 @@ ide_snippet_chunk_get_property (GObject    *object,
 
 static void
 ide_snippet_chunk_set_property (GObject      *object,
-                                       guint         prop_id,
-                                       const GValue *value,
-                                       GParamSpec   *pspec)
+                                guint         prop_id,
+                                const GValue *value,
+                                GParamSpec   *pspec)
 {
   IdeSnippetChunk *chunk = IDE_SNIPPET_CHUNK (object);
 
diff --git a/src/libide/snippets/ide-snippet-context.c b/src/libide/snippets/ide-snippet-context.c
index 1f332e429..e231207a2 100644
--- a/src/libide/snippets/ide-snippet-context.c
+++ b/src/libide/snippets/ide-snippet-context.c
@@ -100,8 +100,8 @@ ide_snippet_context_clear_variables (IdeSnippetContext *context)
 
 void
 ide_snippet_context_add_variable (IdeSnippetContext *context,
-                                        const gchar            *key,
-                                        const gchar            *value)
+                                  const gchar       *key,
+                                  const gchar       *value)
 {
   g_return_if_fail (IDE_IS_SNIPPET_CONTEXT (context));
   g_return_if_fail (key);
@@ -111,8 +111,8 @@ ide_snippet_context_add_variable (IdeSnippetContext *context,
 
 void
 ide_snippet_context_add_shared_variable (IdeSnippetContext *context,
-                                                const gchar             *key,
-                                                const gchar             *value)
+                                         const gchar       *key,
+                                         const gchar       *value)
 {
   g_return_if_fail (IDE_IS_SNIPPET_CONTEXT (context));
   g_return_if_fail (key);
@@ -122,7 +122,7 @@ ide_snippet_context_add_shared_variable (IdeSnippetContext *context,
 
 const gchar *
 ide_snippet_context_get_variable (IdeSnippetContext *context,
-                                        const gchar            *key)
+                                  const gchar       *key)
 {
   const gchar *ret;
 
@@ -522,7 +522,7 @@ scan_forward (const gchar  *input,
 
 gchar *
 ide_snippet_context_expand (IdeSnippetContext *context,
-                                   const gchar             *input)
+                            const gchar       *input)
 {
   const gchar *expand;
   gunichar c;
@@ -650,7 +650,7 @@ ide_snippet_context_expand (IdeSnippetContext *context,
 
 void
 ide_snippet_context_set_tab_width (IdeSnippetContext *context,
-                                         gint                    tab_width)
+                                   gint               tab_width)
 {
   g_return_if_fail (IDE_IS_SNIPPET_CONTEXT (context));
   context->tab_width = tab_width;
@@ -658,7 +658,7 @@ ide_snippet_context_set_tab_width (IdeSnippetContext *context,
 
 void
 ide_snippet_context_set_use_spaces (IdeSnippetContext *context,
-                                          gboolean                use_spaces)
+                                    gboolean           use_spaces)
 {
   g_return_if_fail (IDE_IS_SNIPPET_CONTEXT (context));
   context->use_spaces = !!use_spaces;
@@ -666,7 +666,7 @@ ide_snippet_context_set_use_spaces (IdeSnippetContext *context,
 
 void
 ide_snippet_context_set_line_prefix (IdeSnippetContext *context,
-                                           const gchar            *line_prefix)
+                                     const gchar       *line_prefix)
 {
   g_return_if_fail (IDE_IS_SNIPPET_CONTEXT (context));
   g_free (context->line_prefix);
diff --git a/src/libide/snippets/ide-snippet-context.h b/src/libide/snippets/ide-snippet-context.h
index c34cb0aae..864140def 100644
--- a/src/libide/snippets/ide-snippet-context.h
+++ b/src/libide/snippets/ide-snippet-context.h
@@ -27,39 +27,38 @@ G_BEGIN_DECLS
 #define IDE_TYPE_SNIPPET_CONTEXT (ide_snippet_context_get_type())
 
 IDE_AVAILABLE_IN_ALL
-G_DECLARE_FINAL_TYPE (IdeSnippetContext, ide_snippet_context,
-                      IDE, SNIPPET_CONTEXT, GObject)
+G_DECLARE_FINAL_TYPE (IdeSnippetContext, ide_snippet_context, IDE, SNIPPET_CONTEXT, GObject)
 
 IDE_AVAILABLE_IN_ALL
 IdeSnippetContext *ide_snippet_context_new                 (void);
 IDE_AVAILABLE_IN_ALL
-void                     ide_snippet_context_emit_changed        (IdeSnippetContext *context);
+void               ide_snippet_context_emit_changed        (IdeSnippetContext *context);
 IDE_AVAILABLE_IN_ALL
-void                     ide_snippet_context_clear_variables     (IdeSnippetContext *context);
+void               ide_snippet_context_clear_variables     (IdeSnippetContext *context);
 IDE_AVAILABLE_IN_ALL
-void                     ide_snippet_context_add_variable        (IdeSnippetContext *context,
-                                                                         const gchar             *key,
-                                                                         const gchar             *value);
+void               ide_snippet_context_add_variable        (IdeSnippetContext *context,
+                                                            const gchar       *key,
+                                                            const gchar       *value);
 IDE_AVAILABLE_IN_ALL
-void                     ide_snippet_context_add_shared_variable (IdeSnippetContext *context,
-                                                                         const gchar             *key,
-                                                                         const gchar             *value);
+void               ide_snippet_context_add_shared_variable (IdeSnippetContext *context,
+                                                            const gchar       *key,
+                                                            const gchar       *value);
 IDE_AVAILABLE_IN_ALL
-const gchar             *ide_snippet_context_get_variable        (IdeSnippetContext *context,
-                                                                         const gchar             *key);
+const gchar       *ide_snippet_context_get_variable        (IdeSnippetContext *context,
+                                                            const gchar       *key);
 IDE_AVAILABLE_IN_ALL
-gchar                   *ide_snippet_context_expand              (IdeSnippetContext *context,
-                                                                         const gchar             *input);
+gchar             *ide_snippet_context_expand              (IdeSnippetContext *context,
+                                                            const gchar       *input);
 IDE_AVAILABLE_IN_ALL
-void                     ide_snippet_context_set_tab_width       (IdeSnippetContext *context,
-                                                                         gint                     tab_size);
+void               ide_snippet_context_set_tab_width       (IdeSnippetContext *context,
+                                                            gint               tab_size);
 IDE_AVAILABLE_IN_ALL
-void                     ide_snippet_context_set_use_spaces      (IdeSnippetContext *context,
-                                                                         gboolean                 
use_spaces);
+void               ide_snippet_context_set_use_spaces      (IdeSnippetContext *context,
+                                                            gboolean           use_spaces);
 IDE_AVAILABLE_IN_ALL
-void                     ide_snippet_context_set_line_prefix     (IdeSnippetContext *context,
-                                                                         const gchar             
*line_prefix);
+void               ide_snippet_context_set_line_prefix     (IdeSnippetContext *context,
+                                                            const gchar       *line_prefix);
 IDE_AVAILABLE_IN_ALL
-void                     ide_snippet_context_dump                (IdeSnippetContext *context);
+void               ide_snippet_context_dump                (IdeSnippetContext *context);
 
 G_END_DECLS
diff --git a/src/libide/snippets/ide-snippet.c b/src/libide/snippets/ide-snippet.c
index e1803512a..10dd48892 100644
--- a/src/libide/snippets/ide-snippet.c
+++ b/src/libide/snippets/ide-snippet.c
@@ -92,7 +92,7 @@ static GParamSpec * properties[LAST_PROP];
  */
 IdeSnippet *
 ide_snippet_new (const gchar *trigger,
-                        const gchar *language)
+                 const gchar *language)
 {
   return g_object_new (IDE_TYPE_SNIPPET,
                        "trigger", trigger,
@@ -178,7 +178,7 @@ ide_snippet_get_n_chunks (IdeSnippet *self)
  */
 IdeSnippetChunk *
 ide_snippet_get_nth_chunk (IdeSnippet *self,
-                                  guint             n)
+                           guint       n)
 {
   g_return_val_if_fail (IDE_IS_SNIPPET (self), 0);
 
@@ -212,8 +212,8 @@ ide_snippet_get_trigger (IdeSnippet *self)
  * Sets the trigger for the snippet.
  */
 void
-ide_snippet_set_trigger (IdeSnippet *self,
-                                const gchar      *trigger)
+ide_snippet_set_trigger (IdeSnippet  *self,
+                         const gchar *trigger)
 {
   g_return_if_fail (IDE_IS_SNIPPET (self));
 
@@ -252,8 +252,8 @@ ide_snippet_get_language (IdeSnippet *self)
  * This should match the #GtkSourceLanguage:id identifier.
  */
 void
-ide_snippet_set_language (IdeSnippet *self,
-                                 const gchar      *language)
+ide_snippet_set_language (IdeSnippet  *self,
+                          const gchar *language)
 {
   g_return_if_fail (IDE_IS_SNIPPET (self));
 
@@ -288,8 +288,8 @@ ide_snippet_get_description (IdeSnippet *self)
  * Sets the description for the snippet.
  */
 void
-ide_snippet_set_description (IdeSnippet *self,
-                                    const gchar      *description)
+ide_snippet_set_description (IdeSnippet  *self,
+                             const gchar *description)
 {
   g_return_if_fail (IDE_IS_SNIPPET (self));
 
@@ -301,8 +301,8 @@ ide_snippet_set_description (IdeSnippet *self,
 }
 
 static gint
-ide_snippet_get_offset (IdeSnippet *self,
-                               GtkTextIter      *iter)
+ide_snippet_get_offset (IdeSnippet  *self,
+                        GtkTextIter *iter)
 {
   GtkTextIter begin;
   gint ret;
@@ -318,8 +318,8 @@ ide_snippet_get_offset (IdeSnippet *self,
 }
 
 static gint
-ide_snippet_get_index (IdeSnippet *self,
-                              GtkTextIter      *iter)
+ide_snippet_get_index (IdeSnippet  *self,
+                       GtkTextIter *iter)
 {
   gint offset;
   gint run;
@@ -350,8 +350,8 @@ ide_snippet_get_index (IdeSnippet *self,
 }
 
 static gboolean
-ide_snippet_within_bounds (IdeSnippet *self,
-                                  GtkTextIter      *iter)
+ide_snippet_within_bounds (IdeSnippet  *self,
+                           GtkTextIter *iter)
 {
   GtkTextIter begin;
   GtkTextIter end;
@@ -370,8 +370,8 @@ ide_snippet_within_bounds (IdeSnippet *self,
 }
 
 gboolean
-ide_snippet_insert_set (IdeSnippet *self,
-                               GtkTextMark      *mark)
+ide_snippet_insert_set (IdeSnippet  *self,
+                        GtkTextMark *mark)
 {
   GtkTextIter iter;
 
@@ -389,10 +389,10 @@ ide_snippet_insert_set (IdeSnippet *self,
 }
 
 static void
-ide_snippet_get_nth_chunk_range (IdeSnippet *self,
-                                        gint              n,
-                                        GtkTextIter      *begin,
-                                        GtkTextIter      *end)
+ide_snippet_get_nth_chunk_range (IdeSnippet  *self,
+                                 gint         n,
+                                 GtkTextIter *begin,
+                                 GtkTextIter *end)
 {
   gint run;
   gint i;
@@ -417,9 +417,9 @@ ide_snippet_get_nth_chunk_range (IdeSnippet *self,
 
 void
 ide_snippet_get_chunk_range (IdeSnippet      *self,
-                                    IdeSnippetChunk *chunk,
-                                    GtkTextIter           *begin,
-                                    GtkTextIter           *end)
+                             IdeSnippetChunk *chunk,
+                             GtkTextIter     *begin,
+                             GtkTextIter     *end)
 {
   IdeSnippetChunk *item;
   guint i;
@@ -443,7 +443,7 @@ ide_snippet_get_chunk_range (IdeSnippet      *self,
 
 static void
 ide_snippet_select_chunk (IdeSnippet *self,
-                                 gint              n)
+                          gint        n)
 {
   GtkTextIter begin;
   GtkTextIter end;
@@ -651,9 +651,9 @@ ide_snippet_update_tags (IdeSnippet *self)
 }
 
 gboolean
-ide_snippet_begin (IdeSnippet *self,
-                          GtkTextBuffer    *buffer,
-                          GtkTextIter      *iter)
+ide_snippet_begin (IdeSnippet    *self,
+                   GtkTextBuffer *buffer,
+                   GtkTextIter   *iter)
 {
   IdeSnippetContext *context;
   gboolean ret;
@@ -739,7 +739,7 @@ ide_snippet_unpause (IdeSnippet *self)
 
 void
 ide_snippet_add_chunk (IdeSnippet      *self,
-                              IdeSnippetChunk *chunk)
+                       IdeSnippetChunk *chunk)
 {
   gint tab_stop;
 
@@ -757,7 +757,7 @@ ide_snippet_add_chunk (IdeSnippet      *self,
 
 gchar *
 ide_snippet_get_nth_text (IdeSnippet *self,
-                                 gint              n)
+                          gint        n)
 {
   GtkTextIter iter;
   GtkTextIter end;
@@ -781,9 +781,9 @@ ide_snippet_get_nth_text (IdeSnippet *self,
 }
 
 static void
-ide_snippet_replace_chunk_text (IdeSnippet *self,
-                                       gint              n,
-                                       const gchar      *text)
+ide_snippet_replace_chunk_text (IdeSnippet  *self,
+                                gint         n,
+                                const gchar *text)
 {
   GtkTextIter begin;
   GtkTextIter end;
@@ -844,11 +844,11 @@ ide_snippet_rewrite_updated_chunks (IdeSnippet *self)
 }
 
 void
-ide_snippet_before_insert_text (IdeSnippet *self,
-                                       GtkTextBuffer    *buffer,
-                                       GtkTextIter      *iter,
-                                       gchar            *text,
-                                       gint              len)
+ide_snippet_before_insert_text (IdeSnippet    *self,
+                                GtkTextBuffer *buffer,
+                                GtkTextIter   *iter,
+                                gchar         *text,
+                                gint           len)
 {
   gint utf8_len;
   gint n;
@@ -875,11 +875,11 @@ ide_snippet_before_insert_text (IdeSnippet *self,
 }
 
 void
-ide_snippet_after_insert_text (IdeSnippet *self,
-                                      GtkTextBuffer    *buffer,
-                                      GtkTextIter      *iter,
-                                      gchar            *text,
-                                      gint              len)
+ide_snippet_after_insert_text (IdeSnippet    *self,
+                               GtkTextBuffer *buffer,
+                               GtkTextIter   *iter,
+                               gchar         *text,
+                               gint           len)
 {
   IdeSnippetChunk *chunk;
   GtkTextMark *here;
@@ -919,10 +919,10 @@ ide_snippet_after_insert_text (IdeSnippet *self,
 }
 
 void
-ide_snippet_before_delete_range (IdeSnippet *self,
-                                        GtkTextBuffer    *buffer,
-                                        GtkTextIter      *begin,
-                                        GtkTextIter      *end)
+ide_snippet_before_delete_range (IdeSnippet    *self,
+                                 GtkTextBuffer *buffer,
+                                 GtkTextIter   *begin,
+                                 GtkTextIter   *end)
 {
   gint *run;
   gint len;
@@ -989,10 +989,10 @@ ide_snippet_before_delete_range (IdeSnippet *self,
 }
 
 void
-ide_snippet_after_delete_range (IdeSnippet *self,
-                                       GtkTextBuffer    *buffer,
-                                       GtkTextIter      *begin,
-                                       GtkTextIter      *end)
+ide_snippet_after_delete_range (IdeSnippet    *self,
+                                GtkTextBuffer *buffer,
+                                GtkTextIter   *begin,
+                                GtkTextIter   *end)
 {
   GtkTextMark *here;
 
@@ -1132,9 +1132,9 @@ ide_snippet_finalize (GObject *object)
 
 static void
 ide_snippet_get_property (GObject    *object,
-                                 guint       prop_id,
-                                 GValue     *value,
-                                 GParamSpec *pspec)
+                          guint       prop_id,
+                          GValue     *value,
+                          GParamSpec *pspec)
 {
   IdeSnippet *self = IDE_SNIPPET (object);
 
@@ -1175,9 +1175,9 @@ ide_snippet_get_property (GObject    *object,
 
 static void
 ide_snippet_set_property (GObject      *object,
-                                 guint         prop_id,
-                                 const GValue *value,
-                                 GParamSpec   *pspec)
+                          guint         prop_id,
+                          const GValue *value,
+                          GParamSpec   *pspec)
 {
   IdeSnippet *self = IDE_SNIPPET (object);
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]