Software: Apache/2.0.54 (Fedora). PHP/5.0.4 uname -a: Linux mina-info.me 2.6.17-1.2142_FC4smp #1 SMP Tue Jul 11 22:57:02 EDT 2006 i686 uid=48(apache) gid=48(apache) groups=48(apache) Safe-mode: OFF (not secure) /usr/share/gtk-doc/html/glib/ drwxr-xr-x |
Viewing file: Select action/file-type:
Synopsis#include <glib.h> GKeyFile; #define G_KEY_FILE_ERROR enum GKeyFileError; enum GKeyFileFlags; GKeyFile* g_key_file_new (void); void g_key_file_free (GKeyFile *key_file); void g_key_file_set_list_separator (GKeyFile *key_file, gchar separator); gboolean g_key_file_load_from_file (GKeyFile *key_file, const gchar *file, GKeyFileFlags flags, GError **error); gboolean g_key_file_load_from_data (GKeyFile *key_file, const gchar *data, gsize length, GKeyFileFlags flags, GError **error); gboolean g_key_file_load_from_data_dirs (GKeyFile *key_file, const gchar *file, gchar **full_path, GKeyFileFlags flags, GError **error); gchar* g_key_file_to_data (GKeyFile *key_file, gsize *length, GError **error); gchar* g_key_file_get_start_group (GKeyFile *key_file); gchar** g_key_file_get_groups (GKeyFile *key_file, gsize *length); gchar** g_key_file_get_keys (GKeyFile *key_file, const gchar *group_name, gsize *length, GError **error); gboolean g_key_file_has_group (GKeyFile *key_file, const gchar *group_name); gboolean g_key_file_has_key (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error); gchar* g_key_file_get_value (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error); gchar* g_key_file_get_string (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error); gchar* g_key_file_get_locale_string (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *locale, GError **error); gboolean g_key_file_get_boolean (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error); gint g_key_file_get_integer (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error); gchar** g_key_file_get_string_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, gsize *length, GError **error); gchar** g_key_file_get_locale_string_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *locale, gsize *length, GError **error); gboolean* g_key_file_get_boolean_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, gsize *length, GError **error); gint* g_key_file_get_integer_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, gsize *length, GError **error); gchar* g_key_file_get_comment (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error); void g_key_file_set_value (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *value); void g_key_file_set_string (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *string); void g_key_file_set_locale_string (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *locale, const gchar *string); void g_key_file_set_boolean (GKeyFile *key_file, const gchar *group_name, const gchar *key, gboolean value); void g_key_file_set_integer (GKeyFile *key_file, const gchar *group_name, const gchar *key, gint value); void g_key_file_set_string_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *const list[], gsize length); void g_key_file_set_locale_string_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *locale, const gchar *const list[], gsize length); void g_key_file_set_boolean_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, gboolean list[], gsize length); void g_key_file_set_integer_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, gint list[], gsize length); void g_key_file_set_comment (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *comment, GError **error); void g_key_file_remove_group (GKeyFile *key_file, const gchar *group_name, GError **error); void g_key_file_remove_key (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error); void g_key_file_remove_comment (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error); DescriptionGKeyFile lets you parse, edit or create files containing groups of key-value pairs, which we call key files for lack of a better name. Several freedesktop.org specifications use key files now, e.g the Desktop Entry Specification and the Icon Theme Specification. The syntax of key files is described in detail in the Desktop Entry Specification, here is a quick summary: Key files consists of groups of key-value pairs, interspersed with comments. # this is just an example # there can be comments before the first group [First Group] Name=Key File Example\tthis value shows\nescaping # localized strings are stored in multiple key-value pairs Welcome=Hello Welcome[de]=Hallo Welcome[fr]=Bonjour Welcome[it]=Ciao [Another Group] Numbers=2;20;-200;0 Booleans=true;false;true;true Lines beginning with a '#' and blank lines are considered comments. Groups are started by a header line containing the group name enclosed in '[' and ']', and ended implicitly by the start of the next group or the end of the file. Each key-value pair must be contained in a group.
Key-value pairs generally have the form Key files can store strings (possibly with localized variants), integers, booleans and lists of these. Lists are separated by a separator character, typically ';' or ','. To use the list separator character in a value in a list, it has to be escaped by prefixing it with a backslash.
This syntax is obviously inspired by the
DetailsGKeyFiletypedef struct _GKeyFile GKeyFile; The GKeyFile struct contains only private fields and should not be used directly. G_KEY_FILE_ERROR#define G_KEY_FILE_ERROR g_key_file_error_quark() Error domain for key file parsing. Errors in this domain will be from the GKeyFileError enumeration. See GError for information on error domains. enum GKeyFileErrortypedef enum { G_KEY_FILE_ERROR_UNKNOWN_ENCODING, G_KEY_FILE_ERROR_PARSE, G_KEY_FILE_ERROR_NOT_FOUND, G_KEY_FILE_ERROR_KEY_NOT_FOUND, G_KEY_FILE_ERROR_GROUP_NOT_FOUND, G_KEY_FILE_ERROR_INVALID_VALUE } GKeyFileError; Error codes returned by key file parsing.
enum GKeyFileFlagstypedef enum { G_KEY_FILE_NONE = 0, G_KEY_FILE_KEEP_COMMENTS = 1 << 0, G_KEY_FILE_KEEP_TRANSLATIONS = 1 << 1 } GKeyFileFlags; Flags which influence the parsing.
g_key_file_new ()GKeyFile* g_key_file_new (void);
Creates a new empty GKeyFile object. Use
Since 2.6 g_key_file_free ()void g_key_file_free (GKeyFile *key_file); Frees a GKeyFile.
Since 2.6 g_key_file_set_list_separator ()void g_key_file_set_list_separator (GKeyFile *key_file, gchar separator); Sets the character which is used to separate values in lists. Typically ';' or ',' are used as separators. The default list separator is ';'.
Since 2.6 g_key_file_load_from_file ()gboolean g_key_file_load_from_file (GKeyFile *key_file, const gchar *file, GKeyFileFlags flags, GError **error);
Loads a key file into an empty GKeyFile structure.
If the file could not be loaded then
Since 2.6 g_key_file_load_from_data ()gboolean g_key_file_load_from_data (GKeyFile *key_file, const gchar *data, gsize length, GKeyFileFlags flags, GError **error);
Loads a key file from memory into an empty GKeyFile structure. If
the object cannot be created then
Since 2.6 g_key_file_load_from_data_dirs ()gboolean g_key_file_load_from_data_dirs (GKeyFile *key_file, const gchar *file, gchar **full_path, GKeyFileFlags flags, GError **error);
This function looks for a key file named
Since 2.6 g_key_file_to_data ()gchar* g_key_file_to_data (GKeyFile *key_file, gsize *length, GError **error);
This function outputs
Since 2.6 g_key_file_get_start_group ()gchar* g_key_file_get_start_group (GKeyFile *key_file); Returns the name of the start group of the file.
Since 2.6 g_key_file_get_groups ()gchar** g_key_file_get_groups (GKeyFile *key_file, gsize *length);
Returns all groups in the key file loaded with
Since 2.6 g_key_file_get_keys ()gchar** g_key_file_get_keys (GKeyFile *key_file, const gchar *group_name, gsize *length, GError **error);
Returns all keys for the group name
Since 2.6 g_key_file_has_group ()gboolean g_key_file_has_group (GKeyFile *key_file, const gchar *group_name);
Looks whether the key file has the group
Since 2.6 g_key_file_has_key ()gboolean g_key_file_has_key (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error);
Looks whether the key file has the key
Since 2.6 g_key_file_get_value ()gchar* g_key_file_get_value (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error);
Returns the value associated with
In the event the key cannot be found,
Since 2.6 g_key_file_get_string ()gchar* g_key_file_get_string (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error);
Returns the value associated with
In the event the key cannot be found,
Since 2.6 g_key_file_get_locale_string ()gchar* g_key_file_get_locale_string (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *locale, GError **error);
Returns the value associated with
If
Since 2.6 g_key_file_get_boolean ()gboolean g_key_file_get_boolean (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error);
Returns the value associated with
If
Since 2.6 g_key_file_get_integer ()gint g_key_file_get_integer (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error);
Returns the value associated with
If
Since 2.6 g_key_file_get_string_list ()gchar** g_key_file_get_string_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, gsize *length, GError **error);
Returns the values associated with
In the event the key cannot be found,
Since 2.6 g_key_file_get_locale_string_list ()gchar** g_key_file_get_locale_string_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *locale, gsize *length, GError **error);
Returns the values associated with
If
Since 2.6 g_key_file_get_boolean_list ()gboolean* g_key_file_get_boolean_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, gsize *length, GError **error);
Returns the values associated with
If
Since 2.6 g_key_file_get_integer_list ()gint* g_key_file_get_integer_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, gsize *length, GError **error);
Returns the values associated with
If
Since 2.6 g_key_file_get_comment ()gchar* g_key_file_get_comment (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error);
Retrieves a comment above
Since 2.6 g_key_file_set_value ()void g_key_file_set_value (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *value);
Associates a new value with
Since 2.6 g_key_file_set_string ()void g_key_file_set_string (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *string);
Associates a new string value with
Since 2.6 g_key_file_set_locale_string ()void g_key_file_set_locale_string (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *locale, const gchar *string);
Associates a string value for
Since 2.6 g_key_file_set_boolean ()void g_key_file_set_boolean (GKeyFile *key_file, const gchar *group_name, const gchar *key, gboolean value);
Associates a new boolean value with
Since 2.6 g_key_file_set_integer ()void g_key_file_set_integer (GKeyFile *key_file, const gchar *group_name, const gchar *key, gint value);
Associates a new integer value with
Since 2.6 g_key_file_set_string_list ()void g_key_file_set_string_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *const list[], gsize length);
Associates a list of string values for
Since 2.6 g_key_file_set_locale_string_list ()void g_key_file_set_locale_string_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *locale, const gchar *const list[], gsize length);
Associates a list of string values for
Since 2.6 g_key_file_set_boolean_list ()void g_key_file_set_boolean_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, gboolean list[], gsize length);
Associates a list of boolean values with
Since 2.6 g_key_file_set_integer_list ()void g_key_file_set_integer_list (GKeyFile *key_file, const gchar *group_name, const gchar *key, gint list[], gsize length);
Associates a list of integer values with
Since 2.6 g_key_file_set_comment ()void g_key_file_set_comment (GKeyFile *key_file, const gchar *group_name, const gchar *key, const gchar *comment, GError **error);
Places a comment above
Since 2.6 g_key_file_remove_group ()void g_key_file_remove_group (GKeyFile *key_file, const gchar *group_name, GError **error);
Removes the specified group,
Since 2.6 g_key_file_remove_key ()void g_key_file_remove_key (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error);
Removes
Since 2.6 g_key_file_remove_comment ()void g_key_file_remove_comment (GKeyFile *key_file, const gchar *group_name, const gchar *key, GError **error);
Removes a comment above
Since 2.6
|
:: Command execute :: | |
--[ c99shell v. 1.0 pre-release build #16 powered by Captain Crunch Security Team | http://ccteam.ru | Generation time: 0.0043 ]-- |