![]() |
![]() |
![]() |
gedit Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy | Implemented Interfaces | Properties | Signals |
enum GeditWindowState; GeditWindowPrivate; GeditWindow; GeditTab * gedit_window_create_tab (GeditWindow *window
,gboolean jump_to
); GeditTab * gedit_window_create_tab_from_uri (GeditWindow *window
,const gchar *uri
,const GeditEncoding *encoding
,gint line_pos
,gboolean create
,gboolean jump_to
); void gedit_window_close_tab (GeditWindow *window
,GeditTab *tab
); void gedit_window_close_all_tabs (GeditWindow *window
); void gedit_window_close_tabs (GeditWindow *window
,const GList *tabs
); GeditTab * gedit_window_get_active_tab (GeditWindow *window
); void gedit_window_set_active_tab (GeditWindow *window
,GeditTab *tab
); GeditView * gedit_window_get_active_view (GeditWindow *window
); GeditDocument * gedit_window_get_active_document (GeditWindow *window
); GList * gedit_window_get_documents (GeditWindow *window
); GList * gedit_window_get_unsaved_documents (GeditWindow *window
); GList * gedit_window_get_views (GeditWindow *window
); GtkWindowGroup * gedit_window_get_group (GeditWindow *window
); GeditPanel * gedit_window_get_side_panel (GeditWindow *window
); GeditPanel * gedit_window_get_bottom_panel (GeditWindow *window
); GtkWidget * gedit_window_get_statusbar (GeditWindow *window
); GtkUIManager * gedit_window_get_ui_manager (GeditWindow *window
); GeditWindowState gedit_window_get_state (GeditWindow *window
); GeditTab * gedit_window_get_tab_from_location (GeditWindow *window
,GFile *location
); GeditTab * gedit_window_get_tab_from_uri (GeditWindow *window
,const gchar *uri
); GeditMessageBus * gedit_window_get_message_bus (GeditWindow *window
);
GObject +----GInitiallyUnowned +----GtkObject +----GtkWidget +----GtkContainer +----GtkBin +----GtkWindow +----GeditWindow
"active-tab-changed" : Run First "active-tab-state-changed" : Run First "tab-added" : Run First "tab-removed" : Run First "tabs-reordered" : Run First
typedef enum { GEDIT_WINDOW_STATE_NORMAL = 0, GEDIT_WINDOW_STATE_SAVING = 1 << 1, GEDIT_WINDOW_STATE_PRINTING = 1 << 2, GEDIT_WINDOW_STATE_LOADING = 1 << 3, GEDIT_WINDOW_STATE_ERROR = 1 << 4, GEDIT_WINDOW_STATE_SAVING_SESSION = 1 << 5 } GeditWindowState;
GeditTab * gedit_window_create_tab (GeditWindow *window
,gboolean jump_to
);
Creates a new GeditTab and adds the new tab to the GeditNotebook.
In case jump_to
is TRUE
the GeditNotebook switches to that new GeditTab.
|
a GeditWindow |
|
TRUE to set the new GeditTab as active
|
Returns : |
a new GeditTab |
GeditTab * gedit_window_create_tab_from_uri (GeditWindow *window
,const gchar *uri
,const GeditEncoding *encoding
,gint line_pos
,gboolean create
,gboolean jump_to
);
Creates a new GeditTab loading the document specified by uri
.
In case jump_to
is TRUE
the GeditNotebook swithes to that new GeditTab.
Whether create
is TRUE
, creates a new empty document if location does
not refer to an existing file
|
a GeditWindow |
|
the uri of the document |
|
a GeditEncoding |
|
the line position to visualize |
|
TRUE to create a new document in case uri does exist
|
|
TRUE to set the new GeditTab as active
|
Returns : |
a new GeditTab |
void gedit_window_close_tab (GeditWindow *window
,GeditTab *tab
);
Closes the tab
.
|
a GeditWindow |
|
the GeditTab to close |
void gedit_window_close_all_tabs (GeditWindow *window
);
Closes all opened tabs.
|
a GeditWindow |
void gedit_window_close_tabs (GeditWindow *window
,const GList *tabs
);
Closes all tabs specified by tabs
.
|
a GeditWindow |
|
a list of GeditTab |
GeditTab * gedit_window_get_active_tab (GeditWindow *window
);
Gets the active GeditTab in the window
.
|
a GeditWindow |
Returns : |
the active GeditTab in the window .
|
void gedit_window_set_active_tab (GeditWindow *window
,GeditTab *tab
);
Switches to the tab that matches with tab
.
|
a GeditWindow |
|
a GeditTab |
GeditView * gedit_window_get_active_view (GeditWindow *window
);
Gets the active GeditView.
|
a GeditWindow |
Returns : |
the active GeditView |
GeditDocument * gedit_window_get_active_document (GeditWindow *window
);
Gets the active GeditDocument.
|
a GeditWindow |
Returns : |
the active GeditDocument |
GList * gedit_window_get_documents (GeditWindow *window
);
Gets a newly allocated list with all the documents in the window. This list must be freed.
|
a GeditWindow |
Returns : |
a newly allocated list with all the documents in the window |
GList * gedit_window_get_unsaved_documents (GeditWindow *window
);
Gets the list of documents that need to be saved before closing the window.
|
a GeditWindow |
Returns : |
a list of GeditDocument that need to be saved before closing the window |
GList * gedit_window_get_views (GeditWindow *window
);
Gets a list with all the views in the window. This list must be freed.
|
a GeditWindow |
Returns : |
a newly allocated list with all the views in the window |
GtkWindowGroup * gedit_window_get_group (GeditWindow *window
);
Gets the GtkWindowGroup in which window
resides.
|
a GeditWindow |
Returns : |
the GtkWindowGroup |
GeditPanel * gedit_window_get_side_panel (GeditWindow *window
);
Gets the side GeditPanel of the window
.
|
a GeditWindow |
Returns : |
the side GeditPanel. |
GeditPanel * gedit_window_get_bottom_panel (GeditWindow *window
);
Gets the bottom GeditPanel of the window
.
|
a GeditWindow |
Returns : |
the bottom GeditPanel. |
GtkWidget * gedit_window_get_statusbar (GeditWindow *window
);
Gets the GeditStatusbar of the window
.
|
a GeditWindow |
Returns : |
the GeditStatusbar of the window .
|
GtkUIManager * gedit_window_get_ui_manager (GeditWindow *window
);
Gets the GtkUIManager associated with the window
.
|
a GeditWindow |
Returns : |
the GtkUIManager of the window .
|
GeditWindowState gedit_window_get_state (GeditWindow *window
);
Retrieves the state of the window
.
|
a GeditWindow |
Returns : |
the current GeditWindowState of the window .
|
GeditTab * gedit_window_get_tab_from_location (GeditWindow *window
,GFile *location
);
Gets the GeditTab that matches with the given location
.
|
a GeditWindow |
|
a GFile |
Returns : |
the GeditTab that matches with the given location .
|
GeditTab * gedit_window_get_tab_from_uri (GeditWindow *window
,const gchar *uri
);
gedit_window_get_tab_from_uri
has been deprecated since version 2.24 and should not be used in newly-written code. Use gedit_window_get_tab_from_location()
instead.
Gets the GeditTab that matches uri
.
|
a GeditWindow |
|
the uri to get the GeditTab |
Returns : |
the GeditTab associated with uri .
|
GeditMessageBus * gedit_window_get_message_bus (GeditWindow *window
);
Gets the GeditMessageBus associated with window
. The returned reference
is owned by the window and should not be unreffed.
|
a GeditWindow |
Returns : |
the GeditMessageBus associated with window
|
"active-tab-changed"
signalvoid user_function (GeditWindow *geditwindow, GeditTab *arg1, gpointer user_data) : Run First
"active-tab-state-changed"
signalvoid user_function (GeditWindow *geditwindow, gpointer user_data) : Run First
"tab-added"
signalvoid user_function (GeditWindow *geditwindow, GeditTab *arg1, gpointer user_data) : Run First
"tab-removed"
signalvoid user_function (GeditWindow *geditwindow, GeditTab *arg1, gpointer user_data) : Run First
"tabs-reordered"
signalvoid user_function (GeditWindow *geditwindow, gpointer user_data) : Run First