3 * Copyright (C) 2006 Imendio AB
4 * Contact: Michael Natterer <mitch@imendio.com>
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Library General Public License for more details.
16 * You should have received a copy of the GNU Library General Public
17 * License along with this library; if not, write to the
18 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
19 * Boston, MA 02111-1307, USA.
22 #if defined(GTK_DISABLE_SINGLE_INCLUDES) && !defined (__GTK_H_INSIDE__) && !defined (GTK_COMPILATION)
23 #error "Only <gtk/gtk.h> can be included directly."
26 #ifndef __GTK_TEXT_BUFFER_RICH_TEXT_H__
27 #define __GTK_TEXT_BUFFER_RICH_TEXT_H__
29 #include <gtk/gtktextbuffer.h>
33 typedef guint8 * (* GtkTextBufferSerializeFunc) (GtkTextBuffer *register_buffer,
34 GtkTextBuffer *content_buffer,
35 const GtkTextIter *start,
36 const GtkTextIter *end,
39 typedef gboolean (* GtkTextBufferDeserializeFunc) (GtkTextBuffer *register_buffer,
40 GtkTextBuffer *content_buffer,
48 GdkAtom gtk_text_buffer_register_serialize_format (GtkTextBuffer *buffer,
49 const gchar *mime_type,
50 GtkTextBufferSerializeFunc function,
52 GDestroyNotify user_data_destroy);
53 GdkAtom gtk_text_buffer_register_serialize_tagset (GtkTextBuffer *buffer,
54 const gchar *tagset_name);
56 GdkAtom gtk_text_buffer_register_deserialize_format (GtkTextBuffer *buffer,
57 const gchar *mime_type,
58 GtkTextBufferDeserializeFunc function,
60 GDestroyNotify user_data_destroy);
61 GdkAtom gtk_text_buffer_register_deserialize_tagset (GtkTextBuffer *buffer,
62 const gchar *tagset_name);
64 void gtk_text_buffer_unregister_serialize_format (GtkTextBuffer *buffer,
66 void gtk_text_buffer_unregister_deserialize_format (GtkTextBuffer *buffer,
69 void gtk_text_buffer_deserialize_set_can_create_tags (GtkTextBuffer *buffer,
71 gboolean can_create_tags);
72 gboolean gtk_text_buffer_deserialize_get_can_create_tags (GtkTextBuffer *buffer,
75 GdkAtom * gtk_text_buffer_get_serialize_formats (GtkTextBuffer *buffer,
77 GdkAtom * gtk_text_buffer_get_deserialize_formats (GtkTextBuffer *buffer,
80 guint8 * gtk_text_buffer_serialize (GtkTextBuffer *register_buffer,
81 GtkTextBuffer *content_buffer,
83 const GtkTextIter *start,
84 const GtkTextIter *end,
86 gboolean gtk_text_buffer_deserialize (GtkTextBuffer *register_buffer,
87 GtkTextBuffer *content_buffer,
96 #endif /* __GTK_TEXT_BUFFER_RICH_TEXT_H__ */