mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-29 06:51:10 +00:00
Merge branch 'docs-escape-xml-tag' into 'main'
Escape GtkBuilder XML tag in comment with backtick Closes #5312 See merge request GNOME/gtk!5429
This commit is contained in:
commit
55baa1f2e1
@ -962,7 +962,7 @@ gtk_css_parser_parse_url_arg (GtkCssParser *parser,
|
|||||||
* gtk_css_parser_consume_url:
|
* gtk_css_parser_consume_url:
|
||||||
* @self: a `GtkCssParser`
|
* @self: a `GtkCssParser`
|
||||||
*
|
*
|
||||||
* If the parser matches the <url> token from the [CSS
|
* If the parser matches the `<url>` token from the [CSS
|
||||||
* specification](https://drafts.csswg.org/css-values-4/#url-value),
|
* specification](https://drafts.csswg.org/css-values-4/#url-value),
|
||||||
* consumes it, resolves the URL and returns the resulting `GFile`.
|
* consumes it, resolves the URL and returns the resulting `GFile`.
|
||||||
* On failure, an error is emitted and %NULL is returned.
|
* On failure, an error is emitted and %NULL is returned.
|
||||||
|
@ -59,8 +59,8 @@ G_GNUC_BEGIN_IGNORE_DEPRECATIONS
|
|||||||
* ## GtkComboBoxText as GtkBuildable
|
* ## GtkComboBoxText as GtkBuildable
|
||||||
*
|
*
|
||||||
* The `GtkComboBoxText` implementation of the `GtkBuildable` interface supports
|
* The `GtkComboBoxText` implementation of the `GtkBuildable` interface supports
|
||||||
* adding items directly using the <items> element and specifying <item>
|
* adding items directly using the `<items>` element and specifying `<item>`
|
||||||
* elements for each item. Each <item> element can specify the “id”
|
* elements for each item. Each `<item>` element can specify the “id”
|
||||||
* corresponding to the appended text and also supports the regular
|
* corresponding to the appended text and also supports the regular
|
||||||
* translation attributes “translatable”, “context” and “comments”.
|
* translation attributes “translatable”, “context” and “comments”.
|
||||||
*
|
*
|
||||||
|
@ -47,8 +47,8 @@ G_GNUC_BEGIN_IGNORE_DEPRECATIONS
|
|||||||
* ## GtkTreeStore as GtkBuildable
|
* ## GtkTreeStore as GtkBuildable
|
||||||
*
|
*
|
||||||
* The GtkTreeStore implementation of the `GtkBuildable` interface allows
|
* The GtkTreeStore implementation of the `GtkBuildable` interface allows
|
||||||
* to specify the model columns with a <columns> element that may contain
|
* to specify the model columns with a `<columns>` element that may contain
|
||||||
* multiple <column> elements, each specifying one model column. The “type”
|
* multiple `<column>` elements, each specifying one model column. The “type”
|
||||||
* attribute specifies the data type for the column.
|
* attribute specifies the data type for the column.
|
||||||
*
|
*
|
||||||
* An example of a UI Definition fragment for a tree store:
|
* An example of a UI Definition fragment for a tree store:
|
||||||
|
@ -80,7 +80,7 @@ gtk_buildable_set_buildable_id (GtkBuildable *buildable,
|
|||||||
* Gets the ID of the @buildable object.
|
* Gets the ID of the @buildable object.
|
||||||
*
|
*
|
||||||
* `GtkBuilder` sets the name based on the ID attribute
|
* `GtkBuilder` sets the name based on the ID attribute
|
||||||
* of the <object> tag used to construct the @buildable.
|
* of the `<object>` tag used to construct the @buildable.
|
||||||
*
|
*
|
||||||
* Returns: (nullable): the ID of the buildable object
|
* Returns: (nullable): the ID of the buildable object
|
||||||
**/
|
**/
|
||||||
@ -193,7 +193,7 @@ gtk_buildable_construct_child (GtkBuildable *buildable,
|
|||||||
* @data: (out): return location for user data that will be passed in
|
* @data: (out): return location for user data that will be passed in
|
||||||
* to parser functions
|
* to parser functions
|
||||||
*
|
*
|
||||||
* This is called for each unknown element under <child>.
|
* This is called for each unknown element under `<child>`.
|
||||||
*
|
*
|
||||||
* Returns: %TRUE if an object has a custom implementation, %FALSE
|
* Returns: %TRUE if an object has a custom implementation, %FALSE
|
||||||
* if it doesn't.
|
* if it doesn't.
|
||||||
|
@ -109,14 +109,14 @@ struct _GtkBuildableParser
|
|||||||
* interface is created.
|
* interface is created.
|
||||||
* @construct_child: Constructs a child of a buildable that has been
|
* @construct_child: Constructs a child of a buildable that has been
|
||||||
* specified as “constructor” in the UI definition. This can be used to
|
* specified as “constructor” in the UI definition. This can be used to
|
||||||
* reference a widget created in a <ui> tag which is outside
|
* reference a widget created in a `<ui>` tag which is outside
|
||||||
* of the normal GtkBuilder UI definition hierarchy. A reference to the
|
* of the normal GtkBuilder UI definition hierarchy. A reference to the
|
||||||
* constructed object is returned and becomes owned by the caller.
|
* constructed object is returned and becomes owned by the caller.
|
||||||
* @custom_tag_start: Implement this if the buildable needs to parse
|
* @custom_tag_start: Implement this if the buildable needs to parse
|
||||||
* content below <child>. To handle an element, the implementation
|
* content below `<child>`. To handle an element, the implementation
|
||||||
* must fill in the @parser and @user_data and return %TRUE.
|
* must fill in the @parser and @user_data and return %TRUE.
|
||||||
* `GtkWidget` implements this to parse accessible attributes specified
|
* `GtkWidget` implements this to parse accessible attributes specified
|
||||||
* in <accessibility> elements.
|
* in `<accessibility>` elements.
|
||||||
* Note that @user_data must be freed in @custom_tag_end or @custom_finished.
|
* Note that @user_data must be freed in @custom_tag_end or @custom_finished.
|
||||||
* @custom_tag_end: Called for the end tag of each custom element that is
|
* @custom_tag_end: Called for the end tag of each custom element that is
|
||||||
* handled by the buildable (see @custom_tag_start).
|
* handled by the buildable (see @custom_tag_start).
|
||||||
|
@ -192,9 +192,9 @@
|
|||||||
*
|
*
|
||||||
* Beyond this general structure, several object classes define their
|
* Beyond this general structure, several object classes define their
|
||||||
* own XML DTD fragments for filling in the ANY placeholders in the DTD
|
* own XML DTD fragments for filling in the ANY placeholders in the DTD
|
||||||
* above. Note that a custom element in a <child> element gets parsed by
|
* above. Note that a custom element in a `<child>` element gets parsed by
|
||||||
* the custom tag handler of the parent object, while a custom element in
|
* the custom tag handler of the parent object, while a custom element in
|
||||||
* an <object> element gets parsed by the custom tag handler of the object.
|
* an `<object>` element gets parsed by the custom tag handler of the object.
|
||||||
*
|
*
|
||||||
* These XML fragments are explained in the documentation of the
|
* These XML fragments are explained in the documentation of the
|
||||||
* respective objects.
|
* respective objects.
|
||||||
|
@ -57,7 +57,7 @@ typedef enum { /*< prefix=GTK_BUILDER_CLOSURE >*/
|
|||||||
* correct function name for registering the type and then use dlsym() to load it.
|
* correct function name for registering the type and then use dlsym() to load it.
|
||||||
* The default implementation just tries g_type_from_name() and otherwise fails.
|
* The default implementation just tries g_type_from_name() and otherwise fails.
|
||||||
* @get_type_from_function: Try to lookup a `GType` via the given function name, specified
|
* @get_type_from_function: Try to lookup a `GType` via the given function name, specified
|
||||||
* explicitly in a GtkBuilder file, like via the "type-func" attribute in the "<object>" tag.
|
* explicitly in a GtkBuilder file, like via the "type-func" attribute in the `<object>` tag.
|
||||||
* This function is very rarely used.
|
* This function is very rarely used.
|
||||||
* The C implementation will use dlsym() and call the resulting function as a `GTypeFunc`.
|
* The C implementation will use dlsym() and call the resulting function as a `GTypeFunc`.
|
||||||
* The default implementation will fail and just return %G_TYPE_INVALID.
|
* The default implementation will fail and just return %G_TYPE_INVALID.
|
||||||
|
@ -37,7 +37,7 @@
|
|||||||
*
|
*
|
||||||
* The `GtkCenterBox` implementation of the `GtkBuildable` interface
|
* The `GtkCenterBox` implementation of the `GtkBuildable` interface
|
||||||
* supports placing children in the 3 positions by specifying “start”, “center”
|
* supports placing children in the 3 positions by specifying “start”, “center”
|
||||||
* or “end” as the “type” attribute of a <child> element.
|
* or “end” as the “type” attribute of a `<child>` element.
|
||||||
*
|
*
|
||||||
* # CSS nodes
|
* # CSS nodes
|
||||||
*
|
*
|
||||||
|
@ -135,8 +135,8 @@
|
|||||||
* # GtkEntry as GtkBuildable
|
* # GtkEntry as GtkBuildable
|
||||||
*
|
*
|
||||||
* The `GtkEntry` implementation of the `GtkBuildable` interface supports a
|
* The `GtkEntry` implementation of the `GtkBuildable` interface supports a
|
||||||
* custom <attributes> element, which supports any number of <attribute>
|
* custom `<attributes>` element, which supports any number of `<attribute>`
|
||||||
* elements. The <attribute> element has attributes named “name“, “value“,
|
* elements. The `<attribute>` element has attributes named “name“, “value“,
|
||||||
* “start“ and “end“ and allows you to specify `PangoAttribute` values for
|
* “start“ and “end“ and allows you to specify `PangoAttribute` values for
|
||||||
* this label.
|
* this label.
|
||||||
*
|
*
|
||||||
|
@ -79,8 +79,8 @@
|
|||||||
*
|
*
|
||||||
* The `GtkExpander` implementation of the `GtkBuildable` interface supports
|
* The `GtkExpander` implementation of the `GtkBuildable` interface supports
|
||||||
* placing a child in the label position by specifying “label” as the
|
* placing a child in the label position by specifying “label” as the
|
||||||
* “type” attribute of a <child> element. A normal content child can be
|
* “type” attribute of a `<child>` element. A normal content child can be
|
||||||
* specified without specifying a <child> type attribute.
|
* specified without specifying a `<child>` type attribute.
|
||||||
*
|
*
|
||||||
* An example of a UI definition fragment with GtkExpander:
|
* An example of a UI definition fragment with GtkExpander:
|
||||||
*
|
*
|
||||||
|
@ -51,8 +51,8 @@
|
|||||||
*
|
*
|
||||||
* The `GtkFrame` implementation of the `GtkBuildable` interface supports
|
* The `GtkFrame` implementation of the `GtkBuildable` interface supports
|
||||||
* placing a child in the label position by specifying “label” as the
|
* placing a child in the label position by specifying “label” as the
|
||||||
* “type” attribute of a <child> element. A normal content child can
|
* “type” attribute of a `<child>` element. A normal content child can
|
||||||
* be specified without specifying a <child> type attribute.
|
* be specified without specifying a `<child>` type attribute.
|
||||||
*
|
*
|
||||||
* An example of a UI definition fragment with GtkFrame:
|
* An example of a UI definition fragment with GtkFrame:
|
||||||
* ```xml
|
* ```xml
|
||||||
|
@ -61,7 +61,7 @@
|
|||||||
*
|
*
|
||||||
* The `GtkHeaderBar` implementation of the `GtkBuildable` interface supports
|
* The `GtkHeaderBar` implementation of the `GtkBuildable` interface supports
|
||||||
* adding children at the start or end sides by specifying “start” or “end” as
|
* adding children at the start or end sides by specifying “start” or “end” as
|
||||||
* the “type” attribute of a <child> element, or setting the title widget by
|
* the “type” attribute of a `<child>` element, or setting the title widget by
|
||||||
* specifying “title” value.
|
* specifying “title” value.
|
||||||
*
|
*
|
||||||
* By default the `GtkHeaderBar` uses a `GtkLabel` displaying the title of the
|
* By default the `GtkHeaderBar` uses a `GtkLabel` displaying the title of the
|
||||||
|
@ -94,7 +94,7 @@
|
|||||||
* # GtkLabel as GtkBuildable
|
* # GtkLabel as GtkBuildable
|
||||||
*
|
*
|
||||||
* The GtkLabel implementation of the GtkBuildable interface supports a
|
* The GtkLabel implementation of the GtkBuildable interface supports a
|
||||||
* custom <attributes> element, which supports any number of <attribute>
|
* custom `<attributes>` element, which supports any number of `<attribute>`
|
||||||
* elements. The <attribute> element has attributes named “name“, “value“,
|
* elements. The <attribute> element has attributes named “name“, “value“,
|
||||||
* “start“ and “end“ and allows you to specify [struct@Pango.Attribute]
|
* “start“ and “end“ and allows you to specify [struct@Pango.Attribute]
|
||||||
* values for this label.
|
* values for this label.
|
||||||
|
@ -90,8 +90,8 @@
|
|||||||
* # GtkLevelBar as GtkBuildable
|
* # GtkLevelBar as GtkBuildable
|
||||||
*
|
*
|
||||||
* The `GtkLevelBar` implementation of the `GtkBuildable` interface supports a
|
* The `GtkLevelBar` implementation of the `GtkBuildable` interface supports a
|
||||||
* custom <offsets> element, which can contain any number of <offset> elements,
|
* custom `<offsets>` element, which can contain any number of `<offset>` elements,
|
||||||
* each of which must have name and value attributes.
|
* each of which must have "name" and "value" attributes.
|
||||||
*
|
*
|
||||||
* # CSS nodes
|
* # CSS nodes
|
||||||
*
|
*
|
||||||
|
@ -378,10 +378,10 @@ gtk_list_base_get_allocation_across (GtkListBase *self,
|
|||||||
* @pos: item to select
|
* @pos: item to select
|
||||||
* @modify: %TRUE if the selection should be modified, %FALSE
|
* @modify: %TRUE if the selection should be modified, %FALSE
|
||||||
* if a new selection should be done. This is usually set
|
* if a new selection should be done. This is usually set
|
||||||
* to %TRUE if the user keeps the <Shift> key pressed.
|
* to %TRUE if the user keeps the `<Shift>` key pressed.
|
||||||
* @extend_pos: %TRUE if the selection should be extended.
|
* @extend_pos: %TRUE if the selection should be extended.
|
||||||
* Selections are usually extended from the last selected
|
* Selections are usually extended from the last selected
|
||||||
* position if the user presses the <Ctrl> key.
|
* position if the user presses the `<Ctrl>` key.
|
||||||
*
|
*
|
||||||
* Selects the item at @pos according to how GTK list widgets modify
|
* Selects the item at @pos according to how GTK list widgets modify
|
||||||
* selections, both when clicking rows with the mouse or when using
|
* selections, both when clicking rows with the mouse or when using
|
||||||
|
@ -66,7 +66,7 @@
|
|||||||
*
|
*
|
||||||
* The `GtkListBox` implementation of the `GtkBuildable` interface supports
|
* The `GtkListBox` implementation of the `GtkBuildable` interface supports
|
||||||
* setting a child as the placeholder by specifying “placeholder” as the “type”
|
* setting a child as the placeholder by specifying “placeholder” as the “type”
|
||||||
* attribute of a <child> element. See [method@Gtk.ListBox.set_placeholder]
|
* attribute of a `<child>` element. See [method@Gtk.ListBox.set_placeholder]
|
||||||
* for info.
|
* for info.
|
||||||
*
|
*
|
||||||
* # CSS nodes
|
* # CSS nodes
|
||||||
|
@ -77,14 +77,14 @@
|
|||||||
*
|
*
|
||||||
* The `GtkNotebook` implementation of the `GtkBuildable` interface
|
* The `GtkNotebook` implementation of the `GtkBuildable` interface
|
||||||
* supports placing children into tabs by specifying “tab” as the
|
* supports placing children into tabs by specifying “tab” as the
|
||||||
* “type” attribute of a <child> element. Note that the content
|
* “type” attribute of a `<child>` element. Note that the content
|
||||||
* of the tab must be created before the tab can be filled.
|
* of the tab must be created before the tab can be filled.
|
||||||
* A tab child can be specified without specifying a <child>
|
* A tab child can be specified without specifying a `<child>`
|
||||||
* type attribute.
|
* type attribute.
|
||||||
*
|
*
|
||||||
* To add a child widget in the notebooks action area, specify
|
* To add a child widget in the notebooks action area, specify
|
||||||
* "action-start" or “action-end” as the “type” attribute of the
|
* "action-start" or “action-end” as the “type” attribute of the
|
||||||
* <child> element.
|
* `<child>` element.
|
||||||
*
|
*
|
||||||
* An example of a UI definition fragment with `GtkNotebook`:
|
* An example of a UI definition fragment with `GtkNotebook`:
|
||||||
*
|
*
|
||||||
|
@ -64,8 +64,8 @@
|
|||||||
*
|
*
|
||||||
* # GtkScale as GtkBuildable
|
* # GtkScale as GtkBuildable
|
||||||
*
|
*
|
||||||
* `GtkScale` supports a custom <marks> element, which can contain multiple
|
* `GtkScale` supports a custom `<marks>` element, which can contain multiple
|
||||||
* <mark\> elements. The “value” and “position” attributes have the same
|
* `<mark\>` elements. The “value” and “position” attributes have the same
|
||||||
* meaning as [method@Gtk.Scale.add_mark] parameters of the same name. If
|
* meaning as [method@Gtk.Scale.add_mark] parameters of the same name. If
|
||||||
* the element is not empty, its content is taken as the markup to show at
|
* the element is not empty, its content is taken as the markup to show at
|
||||||
* the mark. It can be translated with the usual ”translatable” and
|
* the mark. It can be translated with the usual ”translatable” and
|
||||||
|
@ -555,22 +555,22 @@ gtk_shortcuts_shortcut_class_init (GtkShortcutsShortcutClass *klass)
|
|||||||
* by separating them with a space, but keep in mind that the available width
|
* by separating them with a space, but keep in mind that the available width
|
||||||
* is limited.
|
* is limited.
|
||||||
*
|
*
|
||||||
* It is also possible to specify ranges of shortcuts, using "..." between
|
* It is also possible to specify ranges of shortcuts, using `...` between
|
||||||
* the keys. Sequences of keys can be specified using a "+" or "&" between
|
* the keys. Sequences of keys can be specified using a `+` or `&` between
|
||||||
* the keys.
|
* the keys.
|
||||||
*
|
*
|
||||||
* Examples:
|
* Examples:
|
||||||
*
|
*
|
||||||
* - A single shortcut: <ctl><alt>delete
|
* - A single shortcut: `<ctl><alt>delete`
|
||||||
* - Two alternative shortcuts: <shift>a Home
|
* - Two alternative shortcuts: `<shift>a Home`
|
||||||
* - A range of shortcuts: <alt>1...<alt>9
|
* - A range of shortcuts: `<alt>1...<alt>9`
|
||||||
* - Several keys pressed together: Control_L&Control_R
|
* - Several keys pressed together: `Control_L&Control_R`
|
||||||
* - A sequence of shortcuts or keys: <ctl>c+<ctl>x
|
* - A sequence of shortcuts or keys: `<ctl>c+<ctl>x`
|
||||||
*
|
*
|
||||||
* Use "+" instead of "&" when the keys may (or have to be) pressed
|
* Use "+" instead of "&" when the keys may (or have to be) pressed
|
||||||
* sequentially (e.g use "t+t" for 'press the t key twice').
|
* sequentially (e.g use "t+t" for 'press the t key twice').
|
||||||
*
|
*
|
||||||
* Note that <, > and & need to be escaped as <, > and & when used
|
* Note that `<`, `>` and `&` need to be escaped as `<`, `>`; and `&`; when used
|
||||||
* in .ui files.
|
* in .ui files.
|
||||||
*/
|
*/
|
||||||
properties[PROP_ACCELERATOR] =
|
properties[PROP_ACCELERATOR] =
|
||||||
|
@ -79,10 +79,10 @@
|
|||||||
*
|
*
|
||||||
* # GtkSizeGroup as GtkBuildable
|
* # GtkSizeGroup as GtkBuildable
|
||||||
*
|
*
|
||||||
* Size groups can be specified in a UI definition by placing an <object>
|
* Size groups can be specified in a UI definition by placing an `<object>`
|
||||||
* element with `class="GtkSizeGroup"` somewhere in the UI definition. The
|
* element with `class="GtkSizeGroup"` somewhere in the UI definition. The
|
||||||
* widgets that belong to the size group are specified by a <widgets> element
|
* widgets that belong to the size group are specified by a `<widgets>` element
|
||||||
* that may contain multiple <widget> elements, one for each member of the
|
* that may contain multiple `<widget>` elements, one for each member of the
|
||||||
* size group. The ”name” attribute gives the id of the widget.
|
* size group. The ”name” attribute gives the id of the widget.
|
||||||
*
|
*
|
||||||
* An example of a UI definition fragment with `GtkSizeGroup`:
|
* An example of a UI definition fragment with `GtkSizeGroup`:
|
||||||
|
@ -38,8 +38,8 @@
|
|||||||
* # GtkStringList as GtkBuildable
|
* # GtkStringList as GtkBuildable
|
||||||
*
|
*
|
||||||
* The `GtkStringList` implementation of the `GtkBuildable` interface
|
* The `GtkStringList` implementation of the `GtkBuildable` interface
|
||||||
* supports adding items directly using the <items> element and
|
* supports adding items directly using the `<items>` element and
|
||||||
* specifying <item> elements for each item. Each <item> element
|
* specifying `<item>` elements for each item. Each `<item>` element
|
||||||
* supports the regular translation attributes “translatable”,
|
* supports the regular translation attributes “translatable”,
|
||||||
* “context” and “comments”.
|
* “context” and “comments”.
|
||||||
*
|
*
|
||||||
|
@ -50,7 +50,7 @@
|
|||||||
*
|
*
|
||||||
* The `GtkTextTagTable` implementation of the `GtkBuildable` interface
|
* The `GtkTextTagTable` implementation of the `GtkBuildable` interface
|
||||||
* supports adding tags by specifying “tag” as the “type” attribute
|
* supports adding tags by specifying “tag” as the “type” attribute
|
||||||
* of a <child> element.
|
* of a `<child>` element.
|
||||||
*
|
*
|
||||||
* An example of a UI definition fragment specifying tags:
|
* An example of a UI definition fragment specifying tags:
|
||||||
* ```xml
|
* ```xml
|
||||||
|
@ -119,7 +119,7 @@
|
|||||||
*
|
*
|
||||||
* The `GtkWindow` implementation of the [iface@Gtk.Buildable] interface supports
|
* The `GtkWindow` implementation of the [iface@Gtk.Buildable] interface supports
|
||||||
* setting a child as the titlebar by specifying “titlebar” as the “type”
|
* setting a child as the titlebar by specifying “titlebar” as the “type”
|
||||||
* attribute of a <child> element.
|
* attribute of a `<child>` element.
|
||||||
*
|
*
|
||||||
* # CSS nodes
|
* # CSS nodes
|
||||||
*
|
*
|
||||||
|
Loading…
Reference in New Issue
Block a user