Package: gobject

Function gobject:type-next-base

Lambda List

gobject:type-next-base (leaf root)

Arguments

leaf -- a g:type-t type ID descendant of root and the type to be returned
root -- a g:type-t type ID immediate parent of the returned type

Return Value

Immediate g:type-t child type ID of root and anchestor of leaf.

Details

Given a leaf and a root which is contained in its anchestry, return the type that root is the immediate parent of. In other words, this function determines the type that is derived directly from root which is also a base class of leaf. Given a root type and a leaf type, this function can be used to determine the types and order in which the leaf type is descended from the root type.

Examples

(g:type-next-base "GtkToggleButton" "GtkWidget")
=> #<GTYPE :name "GtkButton" :id 94607001843920>    
 

See also

2024-12-8