Ardour  8.7-14-g57a6773833
Gtk::TextTagTable Class Reference

#include <texttagtable.h>

Inheritance diagram for Gtk::TextTagTable:
[legend]

Public Types

typedef sigc::slot< void, const Glib::RefPtr< TextTag > & > SlotForEach
 

Public Member Functions

virtual ~TextTagTable ()
 
GtkTextTagTablegobj ()
 Provides access to the underlying C GObject. More...
 
const GtkTextTagTablegobj () const
 Provides access to the underlying C GObject. More...
 
GtkTextTagTablegobj_copy ()
 Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs. More...
 
void add (const Glib::RefPtr< TextTag > &tag)
 
void remove (const Glib::RefPtr< TextTag > &tag)
 
Glib::RefPtr< TextTaglookup (const Glib::ustring &name)
 
Glib::RefPtr< const TextTaglookup (const Glib::ustring &name) const
 
void foreach (const SlotForEach &slot)
 
int get_size () const
 
Glib::SignalProxy2< void, const Glib::RefPtr< TextTag > &, bool > signal_tag_changed ()
 
Glib::SignalProxy1< void, const Glib::RefPtr< TextTag > & > signal_tag_added ()
 
Glib::SignalProxy1< void, const Glib::RefPtr< TextTag > & > signal_tag_removed ()
 

Static Public Member Functions

static GType get_type () G_GNUC_CONST
 
static Glib::RefPtr< TextTagTablecreate ()
 

Protected Member Functions

 TextTagTable ()
 
virtual void on_tag_changed (const Glib::RefPtr< TextTag > &tag, bool size_changed)
 This is a default handler for the signal signal_tag_changed(). More...
 
virtual void on_tag_added (const Glib::RefPtr< TextTag > &tag)
 This is a default handler for the signal signal_tag_added(). More...
 
virtual void on_tag_removed (const Glib::RefPtr< TextTag > &tag)
 This is a default handler for the signal signal_tag_removed(). More...
 

Related Functions

(Note that these are not member functions.)

Glib::RefPtr< Gtk::TextTagTablewrap (GtkTextTagTable *object, bool take_copy=false)
 

Detailed Description

Typedefed as Gtk::TextBuffer::TagTable. A Collection of Gtk::TextBuffer::Tags that can be used together.

A tag table defines a set of Gtk::TextBuffer::Tags that can be used together. Each buffer has one tag table associated with it; only tags from that tag table can be used with the buffer. A single tag table can be shared between multiple buffers, however.

Definition at line 60 of file texttagtable.h.

Member Typedef Documentation

◆ SlotForEach

typedef sigc::slot<void, const Glib::RefPtr<TextTag>&> Gtk::TextTagTable::SlotForEach

Definition at line 150 of file texttagtable.h.

Constructor & Destructor Documentation

◆ ~TextTagTable()

virtual Gtk::TextTagTable::~TextTagTable ( )
virtual

◆ TextTagTable()

Gtk::TextTagTable::TextTagTable ( )
protected

Member Function Documentation

◆ add()

void Gtk::TextTagTable::add ( const Glib::RefPtr< TextTag > &  tag)

Add a tag to the table. The tag is assigned the highest priority in the table.

tag must not be in a tag table already, and may not have the same name as an already-added tag.

Parameters
tagA Gtk::TextTag.

◆ create()

static Glib::RefPtr<TextTagTable> Gtk::TextTagTable::create ( )
static

◆ foreach()

void Gtk::TextTagTable::foreach ( const SlotForEach slot)

◆ get_size()

int Gtk::TextTagTable::get_size ( ) const

Returns the size of the table (number of tags)

Returns
Number of tags in table.

◆ get_type()

static GType Gtk::TextTagTable::get_type ( )
static

Get the GType for this class, for use with the underlying GObject type system.

◆ gobj() [1/2]

GtkTextTagTable* Gtk::TextTagTable::gobj ( )
inline

Provides access to the underlying C GObject.

Definition at line 99 of file texttagtable.h.

◆ gobj() [2/2]

const GtkTextTagTable* Gtk::TextTagTable::gobj ( ) const
inline

Provides access to the underlying C GObject.

Definition at line 102 of file texttagtable.h.

◆ gobj_copy()

GtkTextTagTable* Gtk::TextTagTable::gobj_copy ( )

Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs.

◆ lookup() [1/2]

Glib::RefPtr<TextTag> Gtk::TextTagTable::lookup ( const Glib::ustring &  name)

Look up a named tag.

Parameters
nameName of a tag.
Returns
The tag, or 0 if none by that name is in the table.

◆ lookup() [2/2]

Glib::RefPtr<const TextTag> Gtk::TextTagTable::lookup ( const Glib::ustring &  name) const

Look up a named tag.

Parameters
nameName of a tag.
Returns
The tag, or 0 if none by that name is in the table.

◆ on_tag_added()

virtual void Gtk::TextTagTable::on_tag_added ( const Glib::RefPtr< TextTag > &  tag)
protectedvirtual

This is a default handler for the signal signal_tag_added().

◆ on_tag_changed()

virtual void Gtk::TextTagTable::on_tag_changed ( const Glib::RefPtr< TextTag > &  tag,
bool  size_changed 
)
protectedvirtual

This is a default handler for the signal signal_tag_changed().

◆ on_tag_removed()

virtual void Gtk::TextTagTable::on_tag_removed ( const Glib::RefPtr< TextTag > &  tag)
protectedvirtual

This is a default handler for the signal signal_tag_removed().

◆ remove()

void Gtk::TextTagTable::remove ( const Glib::RefPtr< TextTag > &  tag)

Remove a tag from the table. This will remove the table's reference to the tag, so be careful - the tag will end up destroyed if you don't have a reference to it.

Parameters
tagA Gtk::TextTag.

◆ signal_tag_added()

Glib::SignalProxy1< void,const Glib::RefPtr<TextTag>& > Gtk::TextTagTable::signal_tag_added ( )
Slot Prototype:
void on_my_tag_added(const Glib::RefPtr<TextTag>& tag)

◆ signal_tag_changed()

Glib::SignalProxy2< void,const Glib::RefPtr<TextTag>&,bool > Gtk::TextTagTable::signal_tag_changed ( )
Slot Prototype:
void on_my_tag_changed(const Glib::RefPtr<TextTag>& tag, bool size_changed)

◆ signal_tag_removed()

Glib::SignalProxy1< void,const Glib::RefPtr<TextTag>& > Gtk::TextTagTable::signal_tag_removed ( )
Slot Prototype:
void on_my_tag_removed(const Glib::RefPtr<TextTag>& tag)

Friends And Related Function Documentation

◆ wrap()

Glib::RefPtr< Gtk::TextTagTable > wrap ( GtkTextTagTable object,
bool  take_copy = false 
)
related

A Glib::wrap() method for this object.

Parameters
objectThe C instance.
take_copyFalse if the result should take ownership of the C instance. True if it should take a new copy or ref.
Returns
A C++ instance that wraps this C instance.

The documentation for this class was generated from the following file: