Defines a part of a CSS document.
Because sections are nested into one another, you can use
CssSection.get_parent to get the containing region.
Gets the bytes that self was parsed from.
Passed: a <GtkCssSection>.
the section
Returned: a <GBytes>, or #f.
the <GBytes> from which the section was
parsed
Returns the location in the CSS document where this section ends.
Passed: a <GtkCssSection>.
the section
Returned: a <GtkCssLocation>.
The end location of this section
Gets the file that self was parsed from.
If no such file exists, for example because the CSS was loaded via
css-provider:load-from-data,
then NULL is returned.
Passed: a <GtkCssSection>.
the section
Returned: a <GFile>, or #f.
the <GFile> from which the section was
parsed
Gets the parent section for the given section.
The parent section is the section that contains this section. A
special case are sections of type GTK_CSS_SECTION_DOCUMENT. Their
parent will either be NULL if they are the original CSS document
that was loaded by css-provider:load-from-file or a section of type
GTK_CSS_SECTION_IMPORT if it was loaded with an @import
rule from a different file.
Passed: a <GtkCssSection>.
the section
Returned: a <GtkCssSection>, or #f.
the parent section
Returns the location in the CSS document where this section starts.
Passed: a <GtkCssSection>.
the section
Returned: a <GtkCssLocation>.
The start location of this section
Creates a new <GtkCssSection> referring to the
section in the given file from the start location to the
end location.
Passed: a <GFile>, or #f.
The file this section refers to
Passed: a <GtkCssLocation>.
The start location
Passed: a <GtkCssLocation>.
The end location
Returned: a <GtkCssSection>.
a new <GtkCssSection>
Creates a new <GtkCssSection> referring to the
section in the given file or the given bytes from the
start location to the end location.
Passed: a <GFile>, or #f.
The file this section refers to
Passed: a <GBytes>, or #f.
The bytes this sections refers to
Passed: a <GtkCssLocation>.
The start location
Passed: a <GtkCssLocation>.
The end location
Returned: a <GtkCssSection>.
a new <GtkCssSection>
Prints the section into string in a human-readable form.
This is a form like gtk.css:32:1-23 to denote line 32, characters
1 to 23 in the file gtk.css.
Passed: a <GtkCssSection>.
a section
Passed: a <GString>.
a <GString> to print to
Increments the reference count on section.
Passed: a <GtkCssSection>.
Returned: a <GtkCssSection>.
the CSS section itself.
Prints the section into a human-readable text form using
css-section:print.
Passed: a <GtkCssSection>.
Returned: a string.
A new string.
Decrements the reference count on section, freeing the structure
if the reference count reaches 0.
Passed: a <GtkCssSection>.