Package: gtk

Function gtk-text-buffer-register-serialize-tagset

Lambda List

gtk-text-buffer-register-serialize-tagset (buffer name)

Arguments

buffer -- a gtk-text-buffer object
name -- a string with an optional tagset name, or nil

Return Value

The gdk-atom as a string that corresponds to the newly registered MIME type of the format.

Details

This function registers the internal rich text serialization format of GTK with the passed text buffer. The internal format does not comply to any standard rich text format and only works between gtk-text-buffer objects. It is capable of serializing all tags and embedded pixbufs of the text buffer.

This function is just a wrapper around the gtk-text-buffer-register-serialize-format function. The MIME type used for registering is "application/x-gtk-text-buffer-rich-text", or "application/x-gtk-text-buffer-rich-text;format=tagset_name" if a tagset name was passed.

The name argument can be used to restrict the transfer of rich text to text buffers with compatible sets of tags, in order to avoid unknown tags from being pasted. It is probably the common case to pass an identifier which is not nil here, since the nil tagset requires the receiving text buffer to deal with with pasting of arbitrary tags.
 

See also

2021-11-16