def add_view(self, view: BaseView) -> None:
        """
        Add a view to this workspace.

        :param view:            The view to add.
        :return:                None
        """
        self._update_view_index_in_category(view)
        self.views_by_category[view.category].append(view)
        self.views_by_activation.insert(0, view)

        dw = QtAds.CDockWidget(view.caption)
        dw.setFeature(QtAds.CDockWidget.DockWidgetDeleteOnClose, True)
        dw.closed.connect(functools.partial(self._on_dock_widget_closed, dw))
        dw.setWidget(view)
        if view.icon:
            dw.setIcon(view.icon)

        area = self.DOCKING_POSITIONS.get(view.default_docking_position, QtAds.RightDockWidgetArea)
        area_widget = self.main_window.dock_manager.addDockWidgetTab(area, dw)
        self.main_window.init_shortcuts_on_dock(dw)

        self.views.append(view)
        self.docks.append(dw)
        self.view_to_dock[view] = dw

        if view.default_docking_position == "center":
            policy = QSizePolicy(QSizePolicy.Policy.Expanding, QSizePolicy.Policy.Expanding)
            policy.setHorizontalStretch(1)
            policy.setVerticalStretch(1)
            area_widget.setSizePolicy(policy)

        Add a view to this workspace.

        :param view:            The view to add.
        :return:                None
        
angrmanagement/ui/view_manager.py