code: def register_plugin(self):
          
          self.focus_changed.connect(self.main.plugin_focus_changed)
          self.main.add_dockwidget(self)
          self.ipyconsole = self.main.ipyconsole
          self.create_new_client(give_focus=False)
          icon_path = os.path.join(PACKAGE_PATH, 'images', 'icon.svg')
          self.main.add_to_fileswitcher(self, self.tabwidget, self.clients,
                                        QIcon(icon_path))
          self.recent_notebook_menu.aboutToShow.connect(self.setup_menu_actions)
docs: Register plugin in Spyder's main window.