GXmlxText

GXmlxText — Text children of an element, not the tags or attributes.

Functions

Types and Values

#define GXML_TYPE_XTEXT
struct GXmlxText
struct GXmlxTextClass

Description

To create one, use gxml_xdocument_create_text_node().

Describes the text found as children of elements throughout an XML document, like "He who must not be named" betwean two tags With libxml2 as a backend, it should be noted that two adjacent text nodes are always merged into one Text node, so some functionality for Text, like split_text, will not work completely as expected.

Version: DOM Level 1 Core

URL: http://www.w3.org/TR/REC-DOM-Level-1/level-one-core.html#ID-1312295772

Functions

gxml_xtext_split_text ()

GXmlxText *
gxml_xtext_split_text (GXmlxText *self,
                       gulong offset);

Normally, this would split the text into two adjacent sibling Text nodes. Currently, with libxml2, adjacent Text nodes are actually automatically remerged, so for now, we split the text and return the second part as a node outside of the document tree.

WARNING: behaviour of this function will likely change in the future to comply with the DOM Level 1 Core spec.

Version: DOM Level 1 Core

URL: http://www.w3.org/TR/REC-DOM-Level-1/level-one-core.html#ID-38853C1D

Parameters

self

the GXmlxText instance

 

offset

 .

The point at which to split the Text, in number of characters.

.

[in]

Returns

The second half of the split Text node. For now, it is not attached to the tree as a sibling to the first part, as the spec wants.

Types and Values

GXML_TYPE_XTEXT

#define GXML_TYPE_XTEXT (gxml_xtext_get_type ())

The type for GXmlxText.


struct GXmlxText

struct GXmlxText {
	GXmlxCharacterData parent_instance;
	GXmlxTextPrivate * priv;
};

Text children of an element, not the tags or attributes.

To create one, use gxml_xdocument_create_text_node().

Describes the text found as children of elements throughout an XML document, like "He who must not be named" betwean two tags With libxml2 as a backend, it should be noted that two adjacent text nodes are always merged into one Text node, so some functionality for Text, like split_text, will not work completely as expected.

Version: DOM Level 1 Core

URL: http://www.w3.org/TR/REC-DOM-Level-1/level-one-core.html#ID-1312295772


struct GXmlxTextClass

struct GXmlxTextClass {
	GXmlxCharacterDataClass parent_class;
};

The class structure for GXML_TYPE_XTEXT. All the fields in this structure are private and should never be accessed directly.

Members