gaction: Improve docs formatting for g_action_parse_detailed_name()

Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
This commit is contained in:
Philip Withnall 2022-11-15 17:45:40 +00:00
parent 5ac06ac8ea
commit 4748db5fd3

View File

@ -449,23 +449,23 @@ g_action_name_is_valid (const gchar *action_name)
*
* The first format is used to represent an action name with no target
* value and consists of just an action name containing no whitespace
* nor the characters ':', '(' or ')'. For example: "app.action".
* nor the characters `:`, `(` or `)`. For example: `app.action`.
*
* The second format is used to represent an action with a target value
* that is a non-empty string consisting only of alphanumerics, plus '-'
* and '.'. In that case, the action name and target value are
* separated by a double colon ("::"). For example:
* "app.action::target".
* that is a non-empty string consisting only of alphanumerics, plus `-`
* and `.`. In that case, the action name and target value are
* separated by a double colon (`::`). For example:
* `app.action::target`.
*
* The third format is used to represent an action with any type of
* target value, including strings. The target value follows the action
* name, surrounded in parens. For example: "app.action(42)". The
* name, surrounded in parens. For example: `app.action(42)`. The
* target value is parsed using g_variant_parse(). If a tuple-typed
* value is desired, it must be specified in the same way, resulting in
* two sets of parens, for example: "app.action((1,2,3))". A string
* target can be specified this way as well: "app.action('target')".
* For strings, this third format must be used if * target value is
* empty or contains characters other than alphanumerics, '-' and '.'.
* two sets of parens, for example: `app.action((1,2,3))`. A string
* target can be specified this way as well: `app.action('target')`.
* For strings, this third format must be used if target value is
* empty or contains characters other than alphanumerics, `-` and `.`.
*
* Returns: %TRUE if successful, else %FALSE with @error set
*