[gtksourceview] Clean-up in the completion utils
- From: SÃbastien Wilmet <swilmet src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtksourceview] Clean-up in the completion utils
- Date: Fri, 15 Feb 2013 23:35:32 +0000 (UTC)
commit 75051a696d34a490c02f9512097a597b6ed44d31
Author: SÃbastien Wilmet <swilmet gnome org>
Date: Sat Feb 16 00:22:13 2013 +0100
Clean-up in the completion utils
Some functions are used only internally, so make them static.
And get_word() was used nowhere.
gtksourceview/gtksourcecompletionutils.c | 19 ++-----------------
gtksourceview/gtksourcecompletionutils.h | 12 ------------
2 files changed, 2 insertions(+), 29 deletions(-)
---
diff --git a/gtksourceview/gtksourcecompletionutils.c b/gtksourceview/gtksourcecompletionutils.c
index a605ad0..21dd39b 100644
--- a/gtksourceview/gtksourcecompletionutils.c
+++ b/gtksourceview/gtksourcecompletionutils.c
@@ -32,7 +32,7 @@
*
* Returns: %TRUE if @ch is a separator.
*/
-gboolean
+static gboolean
gtk_source_completion_utils_is_separator (const gunichar ch)
{
if (g_unichar_isprint(ch) &&
@@ -100,21 +100,6 @@ gtk_source_completion_utils_get_word_iter (GtkSourceBuffer *source_buffer,
}
}
-/**
- * gtk_source_completion_utils_get_word:
- * @source_buffer: a #GtkSourceBuffer.
- *
- * Returns: the current word.
- */
-gchar *
-gtk_source_completion_utils_get_word (GtkSourceBuffer *source_buffer)
-{
- GtkTextIter start;
- GtkTextIter end;
-
- return gtk_source_completion_utils_get_word_iter (source_buffer, NULL, &start, &end);
-}
-
static void
get_iter_pos (GtkSourceView *source_view,
GtkTextIter *iter,
@@ -149,7 +134,7 @@ get_iter_pos (GtkSourceView *source_view,
*height = location.height;
}
-void
+static void
gtk_source_completion_utils_replace_word (GtkSourceBuffer *source_buffer,
GtkTextIter *iter,
const gchar *text,
diff --git a/gtksourceview/gtksourcecompletionutils.h b/gtksourceview/gtksourcecompletionutils.h
index 6d44aba..b749db1 100644
--- a/gtksourceview/gtksourcecompletionutils.h
+++ b/gtksourceview/gtksourcecompletionutils.h
@@ -28,24 +28,12 @@
G_BEGIN_DECLS
G_GNUC_INTERNAL
-gboolean gtk_source_completion_utils_is_separator (gunichar ch);
-
-G_GNUC_INTERNAL
gchar *gtk_source_completion_utils_get_word_iter (GtkSourceBuffer *source_buffer,
GtkTextIter *current,
GtkTextIter *start_word,
GtkTextIter *end_word);
G_GNUC_INTERNAL
-gchar *gtk_source_completion_utils_get_word (GtkSourceBuffer *text_view);
-
-G_GNUC_INTERNAL
-void gtk_source_completion_utils_replace_word (GtkSourceBuffer *source_buffer,
- GtkTextIter *iter,
- const gchar *text,
- gint len);
-
-G_GNUC_INTERNAL
void gtk_source_completion_utils_replace_current_word (GtkSourceBuffer *source_buffer,
const gchar *text,
gint len);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]