def METHOD_NAME(self, operation, function):
    '''Return OriginalCommand(operation) after registering function.
    Registration adds an operation: function pair to ._operations.
    It also adds a widget function attribute that masks the Tkinter
    class instance method.  Method masking operates independently
    from command dispatch.
    If a second function is registered for the same operation, the
    first function is replaced in both places.
    '''
    self._operations[operation] = function
    setattr(self.widget, operation, function)
    return OriginalCommand(self, operation)