#ifndef __G_COMPLETION_H__
#define __G_COMPLETION_H__
-#include <glist.h>
+#include <glib/glist.h>
G_BEGIN_DECLS
/* GCompletion
*/
+typedef gint (*GCompletionStrncmpFunc) (const gchar *s1,
+ const gchar *s2,
+ gsize n);
+
struct _GCompletion
{
GList* items;
gchar* prefix;
GList* cache;
+ GCompletionStrncmpFunc strncmp_func;
};
GCompletion* g_completion_new (GCompletionFunc func);
GList* g_completion_complete (GCompletion* cmp,
gchar* prefix,
gchar** new_prefix);
+void g_completion_set_compare (GCompletion *cmp,
+ GCompletionStrncmpFunc strncmp_func);
void g_completion_free (GCompletion* cmp);
G_END_DECLS