GeditTab

## GeditTab GeditTab |

## Synopsis

    enum                GeditTabState;
                        GeditTabPrivate;
                        GeditTab;
    GeditView *         gedit_tab_get_view                  (GeditTab *tab);
    GeditDocument *     gedit_tab_get_document              (GeditTab *tab);
    GeditTab *          gedit_tab_get_from_document         (GeditDocument *doc);
    GeditTabState       gedit_tab_get_state                 (GeditTab *tab);
    gboolean            gedit_tab_get_auto_save_enabled     (GeditTab *tab);
    void                gedit_tab_set_auto_save_enabled     (GeditTab *tab,
                                                             gboolean enable);
    gint                gedit_tab_get_auto_save_interval    (GeditTab *tab);
    void                gedit_tab_set_auto_save_interval    (GeditTab *tab,
                                                             gint interval);

## Object Hierarchy

      GObject
       +----GInitiallyUnowned
             +----GtkObject
                   +----GtkWidget
                         +----GtkContainer
                               +----GtkBox
                                     +----GtkVBox
                                           +----GeditTab

## Implemented Interfaces

GeditTab implements AtkImplementorIface, GtkBuildable and GtkOrientable.

## Properties

      "autosave"                 gboolean              : Read / Write
      "autosave-interval"        gint                  : Read / Write
      "name"                     gchar*                : Read
      "state"                    GeditTabState         : Read

## Description

## Details

### enum GeditTabState

    typedef enum
    {
    	GEDIT_TAB_STATE_NORMAL = 0,
    	GEDIT_TAB_STATE_LOADING,
    	GEDIT_TAB_STATE_REVERTING,
    	GEDIT_TAB_STATE_SAVING,
    	GEDIT_TAB_STATE_PRINTING,
    	GEDIT_TAB_STATE_PRINT_PREVIEWING,
    	GEDIT_TAB_STATE_SHOWING_PRINT_PREVIEW,
    	GEDIT_TAB_STATE_GENERIC_NOT_EDITABLE,
    	GEDIT_TAB_STATE_LOADING_ERROR,
    	GEDIT_TAB_STATE_REVERTING_ERROR,
    	GEDIT_TAB_STATE_SAVING_ERROR,
    	GEDIT_TAB_STATE_GENERIC_ERROR,
    	GEDIT_TAB_STATE_CLOSING,
    	GEDIT_TAB_STATE_EXTERNALLY_MODIFIED_NOTIFICATION,
    	GEDIT_TAB_NUM_OF_STATES /* This is not a valid state */
    } GeditTabState;

### GeditTabPrivate

    typedef struct _GeditTabPrivate GeditTabPrivate;

### GeditTab

    typedef struct _GeditTab GeditTab;

### gedit_tab_get_view ()

    GeditView *         gedit_tab_get_view                  (GeditTab *tab);

Gets the GeditView inside `tab`.

`tab` : | a GeditTab
Returns : | the GeditView inside `tab`

### gedit_tab_get_document ()

    GeditDocument *     gedit_tab_get_document              (GeditTab *tab);

Gets the GeditDocument associated to `tab`.

`tab` : | a GeditTab
Returns : | the GeditDocument associated to `tab`

### gedit_tab_get_from_document ()

    GeditTab *          gedit_tab_get_from_document         (GeditDocument *doc);

Gets the GeditTab associated with `doc`.

`doc` : | a GeditDocument
Returns : | the GeditTab associated with `doc`

### gedit_tab_get_state ()

    GeditTabState       gedit_tab_get_state                 (GeditTab *tab);

Gets the GeditTabState of `tab`.

`tab` : | a GeditTab
Returns : | the GeditTabState of `tab`

### gedit_tab_get_auto_save_enabled ()

    gboolean            gedit_tab_get_auto_save_enabled     (GeditTab *tab);

Gets the current state for the autosave feature

`tab` : | a GeditTab
Returns : | `TRUE` if the autosave is enabled, else `FALSE`

### gedit_tab_set_auto_save_enabled ()

    void                gedit_tab_set_auto_save_enabled     (GeditTab *tab,
                                                             gboolean enable);

Enables or disables the autosave feature. It does not install an autosave timeout if the document is new or is read-only

`tab` : | a GeditTab
`enable` : | enable (`TRUE`) or disable (`FALSE`) auto save

### gedit_tab_get_auto_save_interval ()

    gint                gedit_tab_get_auto_save_interval    (GeditTab *tab);

Gets the current interval for the autosaves

`tab` : | a GeditTab
Returns : | the value of the autosave

### gedit_tab_set_auto_save_interval ()

    void                gedit_tab_set_auto_save_interval    (GeditTab *tab,
                                                             gint interval);

Sets the interval for the autosave feature. It does nothing if the interval is the same as the one already present. It removes the old interval timeout and adds a new one with the autosave passed as argument.

`tab` : | a GeditTab
`interval` : | the new interval

## Property Details

### The `"autosave"` property

      "autosave"                 gboolean              : Read / Write

Autosave feature.

Default value: TRUE

### The `"autosave-interval"` property

      "autosave-interval"        gint                  : Read / Write

Time between two autosaves.

Allowed values: >= 0

Default value: 0

### The `"name"` property

      "name"                     gchar*                : Read

The tab's name.

Default value: NULL

### The `"state"` property

      "state"                    GeditTabState         : Read

The tab's state.

Default value: GEDIT_TAB_STATE_NORMAL