GtkTextBuffer serialize/deserialize
- From: Murray Cumming <murrayc murrayc com>
- To: gtk-devel-list gnome org
- Subject: GtkTextBuffer serialize/deserialize
- Date: Tue, 18 Jul 2006 20:09:59 +0200
I'm trying to wrap the gtktextbufferrichtext.h API, but I can't figure
out from the documentation how it's supposed to work. For instance in
the documentation below, I don't understand why there's one buffer that
has a format, and another buffer that's going to be filled with the
data.
Also, as far as I can tell, iter will be set by the function, but what
determines that iter? How can the data know where it should be inserted?
/**
* gtk_text_buffer_deserialize:
* @register_buffer: the #GtkTextBuffer %format is registered with
* @content_buffer: the #GtkTextBuffer to deserialize into
* @format: the rich text format to use for deserializing
* @iter: insertion point for the deserialized text
* @data: data to deserialize
* @length: length of %data
* @error: return loaction for a #GError
*
* This function deserializes rich text in format %format and inserts
* it at %iter.
*
* %format<!-- -->s to be used must be registered using
* gtk_text_buffer_register_deserialize_format() or
* gtk_text_buffer_register_deserialize_tagset() beforehand.
*
* Return value: %TRUE on success, %FALSE otherwise.
*
* Since: 2.10
**/
gboolean
gtk_text_buffer_deserialize (GtkTextBuffer *register_buffer,
GtkTextBuffer *content_buffer,
GdkAtom format,
GtkTextIter *iter,
const guint8 *data,
gsize length,
GError **error)
--
Murray Cumming
murrayc murrayc com
www.murrayc.com
www.openismus.com
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]