Main.initWithArgs

This function does the same work as gtk_init_check(). Additionally, it allows you to add your own commandline options, and it automatically generates nicely formatted --help output. Note that your program will be terminated after writing out the help output. Since 2.6

class Main
static
int
initWithArgs

Parameters

argv string[]

a pointer to the array of command line arguments. inout[array length=argc]

parameterString string

a string which is displayed in the first line of --help output, after programname OPTION...

entries GOptionEntry[]

a NULL-terminated array of GOptionEntrys describing the options of your program. [array zero-terminated=1]

translationDomain string

a translation domain to use for translating the --help output for the options in entries with gettext(), or NULL

Return Value

Type: int

TRUE if the GUI has been successfully initialized, FALSE otherwise.

Throws

GException on failure.

Meta