Optionalproperties: Partial<{}>Since 4.22defaultReplays the node using the default method.
The default method calls Gsk.RenderReplay.filter_node on all its child nodes and the filter functions for all its properties. If none of them are changed, it returns the passed in node. Otherwise it constructs a new node with the changed children and properties.
It may not be possible to construct a new node when any of the callbacks return NULL. In that case, this function will return NULL, too.
the node to replay
The replayed node
Since 4.22filter_Since 4.22filter_Replays a node using the replay's filter function.
After the replay the node may be unchanged, or it may be
removed, which will result in null being returned.
If no filter node is set, Gsk.RenderReplay.default is called instead.
the node to replay
The replayed node
Since 4.22filter_Since 4.22freeSince 4.22set_Sets a filter function to be called by Gsk.RenderReplay.default for nodes that contain fonts.
You can call GskRenderReplay.filter_font to filter a font yourself.
the font filter function
Since 4.22set_Sets the function to use as a node filter.
This is the most complex function to use for replaying nodes. It can either:
keep the node and just return it unchanged
create a replacement node and return that
discard the node by returning NULL
call Gsk.RenderReplay.default to have the default handler run for this node, which calls your function on its children
the function to call to replay nodes
Since 4.22set_Sets a filter function to be called by Gsk.RenderReplay.default for nodes that contain textures.
You can call GskRenderReplay.filter_texture to filter a texture yourself.
the texture filter function
Staticnew
A facility to replay a Gsk.RenderNode and its children, potentially modifying them.
This is a utility tool to walk a rendernode tree. The most powerful way is to provide a function via Gsk.RenderReplay.set_node_filter to filter each individual node and then run Gsk.RenderReplay.filter_node on the nodes you want to filter.
If you want to just walk the node tree and extract information without any modifications, you can also use Gsk.RenderNode.get_children.
Here is a little example application that redacts text in a node file:
Since
4.22