summaryrefslogtreecommitdiff
path: root/glib/glib.h
diff options
context:
space:
mode:
authorPaolo Molaro <lupus@src.gnome.org>1998-05-19 10:17:31 +0000
committerPaolo Molaro <lupus@src.gnome.org>1998-05-19 10:17:31 +0000
commit4d3f6feb37912de4a227eb3f647034e9ecd26e20 (patch)
treec217673693826970d1f82850220e2bcad300bfee /glib/glib.h
parentabce9666421dd83848047a6e72390a35bc74df4a (diff)
downloadgdk-pixbuf-4d3f6feb37912de4a227eb3f647034e9ecd26e20.tar.gz
Tue, 19 May 1998 11:51:02 +0200 Paolo Molaro <lupus@debian.org>
* added generic functions for completion in glib. * used the above functions in the gtkcombo widget.
Diffstat (limited to 'glib/glib.h')
-rw-r--r--glib/glib.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/glib/glib.h b/glib/glib.h
index 282288c97..92fba23a5 100644
--- a/glib/glib.h
+++ b/glib/glib.h
@@ -1065,6 +1065,33 @@ void g_scanner_warn (GScanner *scanner,
gint g_scanner_stat_mode (const gchar *filename);
+/* Completion */
+
+typedef gchar* (*GCompletionFunc)(gpointer);
+
+typedef struct _GCompletion GCompletion;
+
+struct _GCompletion {
+ GList* items;
+ GCompletionFunc func;
+
+ gchar* prefix;
+ GList* cache;
+
+};
+
+GCompletion* g_completion_new (GCompletionFunc func);
+void g_completion_add_items (GCompletion* cmp,
+ GList* items);
+void g_completion_remove_items (GCompletion* cmp,
+ GList* items);
+void g_completion_clear_items (GCompletion* cmp);
+GList* g_completion_complete (GCompletion* cmp,
+ gchar* prefix,
+ gchar** new_prefix);
+void g_completion_free (GCompletion* cmp);
+
+
#ifdef __cplusplus
}