GtkSourceStyleManager

GtkSourceStyleManager

Synopsis


#include <gtksourceview/gtksourcestylemanager.h>


                    GtkSourceStyleManager;
GtkSourceStyleManager* gtk_source_style_manager_new     (void);
GtkSourceStyleManager* gtk_source_style_manager_get_default
                                                        (void);
void                gtk_source_style_manager_set_search_path
                                                        (GtkSourceStyleManager *manager,
                                                         gchar **path);
void                gtk_source_style_manager_append_search_path
                                                        (GtkSourceStyleManager *manager,
                                                         const gchar *path);
void                gtk_source_style_manager_prepend_search_path
                                                        (GtkSourceStyleManager *manager,
                                                         const gchar *path);
const gchar* const * gtk_source_style_manager_get_search_path
                                                        (GtkSourceStyleManager *manager);
void                gtk_source_style_manager_force_rescan
                                                        (GtkSourceStyleManager *manager);
GtkSourceStyleScheme* gtk_source_style_manager_get_scheme
                                                        (GtkSourceStyleManager *manager,
                                                         const gchar *scheme_id);

Object Hierarchy


  GObject
   +----GtkSourceStyleManager

Properties


  "scheme-ids"               GStrv                 : Read
  "search-path"              GStrv                 : Read / Write

Description

Details

GtkSourceStyleManager

typedef struct _GtkSourceStyleManager GtkSourceStyleManager;

GtkSourceStyleManager structure contains only private members and should not be accessed directly.


gtk_source_style_manager_new ()

GtkSourceStyleManager* gtk_source_style_manager_new     (void);

Creates a new style manager. If you do not need more than one style manager then use gtk_source_style_manager_get_default() instead.

Returns : a GtkSourceStyleManager.

gtk_source_style_manager_get_default ()

GtkSourceStyleManager* gtk_source_style_manager_get_default
                                                        (void);

Returns the default GtkSourceStyleManager instance.

Returns : a GtkSourceStyleManager. Return value is owned by GtkSourceView library and must not be unref'ed.

gtk_source_style_manager_set_search_path ()

void                gtk_source_style_manager_set_search_path
                                                        (GtkSourceStyleManager *manager,
                                                         gchar **path);

Sets the list of directories where the manager looks for style scheme files. If dirs is NULL, the search path is reset to default.

manager : a GtkSourceStyleManager.
path : a NULL-terminated array of strings or NULL.

gtk_source_style_manager_append_search_path ()

void                gtk_source_style_manager_append_search_path
                                                        (GtkSourceStyleManager *manager,
                                                         const gchar *path);

Appends path to the list of directories where the manager looks for style scheme files. See gtk_source_style_manager_set_search_path() for details.

manager : a GtkSourceStyleManager.
path : a directory or a filename.

gtk_source_style_manager_prepend_search_path ()

void                gtk_source_style_manager_prepend_search_path
                                                        (GtkSourceStyleManager *manager,
                                                         const gchar *path);

Prepends path to the list of directories where the manager looks for style scheme files. See gtk_source_style_manager_set_search_path() for details.

manager : a GtkSourceStyleManager.
path : a directory or a filename.

gtk_source_style_manager_get_search_path ()

const gchar* const * gtk_source_style_manager_get_search_path
                                                        (GtkSourceStyleManager *manager);

Returns the current search path for the manager. See gtk_source_style_manager_set_search_path() for details.

manager : a GtkSourceStyleManager.
Returns : a NULL-terminated array of string containing the search path. The array is owned by the manager and must not be modified.

gtk_source_style_manager_force_rescan ()

void                gtk_source_style_manager_force_rescan
                                                        (GtkSourceStyleManager *manager);

Mark any currently cached information about the available style scehems as invalid. All the available style schemes will be reloaded next time the manager is accessed.

manager : a GtkSourceStyleManager

gtk_source_style_manager_get_scheme ()

GtkSourceStyleScheme* gtk_source_style_manager_get_scheme
                                                        (GtkSourceStyleManager *manager,
                                                         const gchar *scheme_id);

Looks up style scheme by id.

manager : a GtkSourceStyleManager
scheme_id : style scheme id to find
Returns : a GtkSourceStyleScheme object. Returned value is owned by manager and must not be unref'ed.

Property Details

The "scheme-ids" property

  "scheme-ids"               GStrv                 : Read

List of the ids of the available style schemes.


The "search-path" property

  "search-path"              GStrv                 : Read / Write

List of directories and files where the style schemes are located.

See Also

GtkSourceStyleScheme