ClosureExpression#
- class ClosureExpression(*args, **kwargs)#
Superclasses: Expression
An expression using a custom GClosure
to compute the value from
its parameters.
Constructors#
- class ClosureExpression
- classmethod new(value_type: type, closure: Callable[[...], Any], params: Sequence[Expression] | None = None) ClosureExpression #
Creates a
GtkExpression
that callsclosure
when it is evaluated.closure
is called with thethis
object and the results of evaluating theparams
expressions.- Parameters:
value_type – the type of the value that this expression evaluates to
closure – closure to call when evaluating this expression. If closure is floating, it is adopted
params – expressions for each parameter