The routines in this module provide a way to load and save files in
the format expected by the panel to create the menus and applet
definitions.
Details
struct GnomeDesktopEntry
typedef struct {
char *name; /* These contain the translated name/comment */
char *comment;
int exec_length; /* Length of `exec' vector. Does not
include the NULL terminator. */
char **exec; /* Command to execute. Must be NULL
terminated. */
char *tryexec; /* Test program to execute */
char *icon; /* Icon name */
char *docpath; /* Path to the documentation */
int terminal; /* flag: requires a terminal to run */
char *type; /* type of this dentry */
char *location; /* path of this dentry */
char *geometry; /* geometry for this icon */
unsigned int multiple_args:1;
unsigned int is_kde:1; /* If this is a .kdelink file */
} GnomeDesktopEntry;
a newly created desktop entry loaded from file or NULL
if the file does not exist or contains stale data.
gnome_desktop_entry_load_flags ()
GnomeDesktopEntry* gnome_desktop_entry_load_flags
(const char *file,
int clean_from_memory_after_load);
file :
a file name that contains a desktop entry.
clean_from_memory_after_load :
flag
Returns :
a newly created desktop entry loaded from file or NULL
if the file does not exist or contains stale data.
if clean_from_memory_after_load is TRUE, then any data cached used by loading
process is discarded after loading the desktop entry.
gnome_desktop_entry_load_flags_conditional ()
GnomeDesktopEntry* gnome_desktop_entry_load_flags_conditional
(const char *file,
int clean_from_memory_after_load,
int unconditional);
file :
a file name that contains a desktop entry.
clean_from_memory_after_load :
flag
unconditional :
flag
Returns :
a newly created desktop entry loaded from file or NULL
if the file does not exist.
if unconditional is TRUE then the desktop entry is loaded even if
it contains stale data, otherwise, NULL is returned if stale data
is found (like, the program referenced not existing).
if clean_from_memory_after_load is TRUE, then any data cached used by loading
process is discarded after loading the desktop entry.