[Contents] [Back] [Prev] [Up] [Next] [Forward]

# Package Gtk.Text`_`Tag`_`Table

A table is a collection of tags where you can Add, Remove, Lookup or traverse (Foreach) a tag.

- Gtk.Text_Tag_Table Widget Hierarchy
- Gtk.Text_Tag_Table Signals
- Gtk.Text_Tag_Table Types
- Gtk.Text_Tag_Table Subprograms

## Widget Hierarchy

    GObject                       (see section Package Glib.Object)
    Gtk_Object                    (see section Package Gtk.Object)
       \___ Gtk_Text_Tag_Table    (see section Package Gtk.Text_Tag_Table)

## Signals

- "tag_added" procedure Handler
  (Widget : access Gtk_Text_Tag_Table_Record'Class;
  Tag : access Gtk.Text_Tag.Gtk_Text_Tag_Record'Class);
- "tag_changed" procedure Handler
  (Widget : access Gtk_Text_Tag_Table_Record'Class;
  Tag : access Gtk.Text_Tag.Gtk_Text_Tag_Record'Class;
  Size_Changed : Boolean);
- "tag_removed" procedure Handler
  (Widget : access Gtk_Text_Tag_Table_Record'Class;
  Tag : access Gtk.Text_Tag.Gtk_Text_Tag_Record'Class);

## Types

    type Data_Type is private;

    type Data_Type_Access is access all Data_Type;

    type Gtk_Text_Tag_Table_Proc is access procedure
        (Tag  : access Gtk_Text_Tag_Table_Record'Class;
         Data : Data_Type_Access);

## Subprograms

    procedure Gtk_New
      (Table              : out    Gtk_Text_Tag_Table);

| Create a new Text_Tag_Table.

    function Get_Type              return Glib.GType;

| Return the internal value associated with a Gtk_Text_Tag_Table.

    procedure Add
      (Table              : access Gtk_Text_Tag_Table_Record;
       Tag                : access Gtk.Text_Tag.Gtk_Text_Tag_Record'Class);

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

    procedure Remove
      (Table              : access Gtk_Text_Tag_Table_Record;
       Tag                : access Gtk.Text_Tag.Gtk_Text_Tag_Record'Class);

| 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.

    function Lookup
      (Table              : access Gtk_Text_Tag_Table_Record;
       Name               :        String)
       return Gtk.Text_Tag.Gtk_Text_Tag;

| Look up a named tag. Return the tag or null if none by that name is in the table.

    function Get_Size
      (Table              : access Gtk_Text_Tag_Table_Record)
       return Gint;

| Return the size of the table (number of tags).

    procedure Foreach
      (Table              : access Gtk_Text_Tag_Table_Record;
       Proc               :        Gtk_Text_Tag_Table_Proc;
       Data               :        Data_Type_Access);

| Call Proc on each tag in Table, with user data Data.

[Contents] [Back] [Prev] [Up] [Next] [Forward]