Element activation

inputfieldsandbuttons.C shows an example of specifying what action to take in response when a button gets activated by a pointer click or a key press, using on_activate().

on_activate()'s parameter is a lambda that gets executed when the button gets activated. Note that the lambda gets invoked by the execution thread, see the section called “Callbacks” and the section called “Containers own references to the elements in the container” for more information.

The lambda receives the following parameters.