![]() |
![]() |
![]() |
![]() |
<GOptionGroup>
A GOptionGroup
struct defines the options in a single
group. The struct has only private fields and should not be directly accessed.
All options in a group share the same translation function. Libraries which
need to parse commandline options are expected to provide a function for
getting a GOptionGroup
holding their options, which
the application can then add to its GOptionContext.
(define-values () (option-group:free self))
Frees a GOptionGroup. Note that you must not free groups which have been added to a GOptionContext.
(define-values (%return) (option-group:ref self))
Increments the reference count of group
by one.
(define-values () (option-group:set-translate-func self func data destroy-notify))
Sets the function which is used to translate user-visible strings,
for --help
output. Different groups can use different
GTranslateFuncs. If func
is NULL
, strings are not translated.
If you are using gettext()
, you only need to set the translation
domain, see g_option_group_set_translation_domain()
.
(define-values () (option-group:set-translation-domain self domain))
A convenience function to use gettext()
for translating
user-visible strings.