Package: gtk

Function gtk-flow-box-bind-model

Lambda List

gtk-flow-box-bind-model (flowbox model func)

Arguments

flowbox -- a gtk-flow-box widget
model -- a g-list-model object to be bound to flowbox
func -- a gtk-flow-box-create-widget-func callback function that creates widgets for items

Details

Binds a model to the flow box. If the flow box was already bound to a model, that previous binding is destroyed.

The contents of the flow box are cleared and then filled with widgets that represent items from the model. The flow box is updated whenever the model changes. If the model argument is nil, the flow box is left empty.

It is undefined to add or remove widgets directly, for example, with the gtk-flow-box-insert or gtk-container-add functions, while the flow box is bound to a model.

Note that using a model is incompatible with the filtering and sorting functionality in the flow box. When using a model, filtering and sorting should be implemented by the model.
 

See also

2021-12-6