def disable_widget( self, widget_id ) :
        """Change state of a widget from NORMAL to DISABLED
        Widget must not be both currently be displayed and ACTIVE
        (NORMAL is OK even if the widget is displayed)
        Arguments: widget id (the number returned by add_xxx call)
        Returns: nothing"""
        for i in range( len( self._wdicts ) ) :
            if self._wdicts[ i ][ 'widget_id' ] == widget_id :
                break
        else :
            return

        wdict = self._wdicts[ i ]
        if not self.is_posted :
            wdict[ 'kw' ].setdefault( 'state', DISABLE )
            return

        # remove this widget from the selectables list and remove any
        # keybindings for it
        for w in self._menubuttons :
            if w.wdict == wdict :
                break
        else :
            # this should never happen, it implies there is a dictionary
            # for a widget which was not created when posting the menu
            return

        if w.cget( 'state' ) != NORMAL :
            return
        w.configure( state = DISABLED )

        for  sw, event, id in self._bindings :
            if sw != w :
                continue
                sw.unbind( event, id )

        self._bindings = [ x for x in self._bindings if x[ 0 ] != w ]
        self._selectables = [ x for x in self._selectables if x != w ]
        self._bind_traversal( w )
        self._link_arrows( False )
Change state of a widget from NORMAL to DISABLED
        Widget must not be both currently be displayed and ACTIVE
        (NORMAL is OK even if the widget is displayed)
        Arguments: widget id (the number returned by add_xxx call)
        Returns: nothing
recipes/Python/442500_ExtraMenu__TkInter_menu_arbitrary_widgets/recipe-442500.py