| Extracted from Pike v7.8 release 866 at 2018-02-09.

[Top]
GTK
GTK.SpinButton

# Method GTK.SpinButton()->set_update_policy()

Method set_update_policy

  `GTK.SpinButton set_update_policy(int policy)`

Description

  The possible values of policy are either GTK.UpdateAlways or GTK.UpdateIfValid.

  These policies affect the behavior of a Spin Button when parsing inserted text and syncing its value with the values of the Adjustment.

  In the case of GTK.UpdateIfValid the Spin Button value only gets changed if the text input is a numeric value that is within the range specified by the Adjustment. Otherwise the text is reset to the current value.

  In case of GTK.UpdateAlways errors are ignored while converting text into a numeric value.