code: def setup_toolbar(self):
          
          load_button = create_toolbutton(self, text=_('Import data'),
                                          icon=ima.icon('fileimport'),
                                          triggered=lambda: self.import_data())
          self.save_button = create_toolbutton(self, text=_("Save data"),
                              icon=ima.icon('filesave'),
                              triggered=lambda: self.save_data(self.filename))
          self.save_button.setEnabled(False)
          save_as_button = create_toolbutton(self,
                                             text=_("Save data as..."),
                                             icon=ima.icon('filesaveas'),
                                             triggered=self.save_data)
          reset_namespace_button = create_toolbutton(
                  self, text=_("Remove all variables"),
                  icon=ima.icon('editdelete'), triggered=self.reset_namespace)
  
          return [load_button, self.save_button, save_as_button,
                  reset_namespace_button]
docs: Setup toolbar