Next: Chaining Methods Up: Standard Initialization Methods Previous: Standard Initialization Methods

### The InitWidgetRec Method

The purpose of the `InitWidgetRec` method is to initialize the variables of the widget instance. For example, the following implementation of `tixArrowButton:InitWidgetRec` sets the count variable of each newly created instance to zero.

    proc tixArrowButton:InitWidgetRec {w} {
        upvar #0 $w data

        set data(count) 0
    }