def add_menu(self, name):
        """Add a menu with name `name` to the global menu bar.
        Returns a menu widget.
        """
        if self.menubar is None:
            raise ValueError("No menu bar configured")
        return self.menubar.add_name(name)
def add_menu ( self , name ) : if self . menubar is None : raise ValueError ( "No menu bar configured" ) return self . menubar . add_name ( name )
Add a menu with name `name` to the global menu bar.
        Returns a menu widget.