14 using GraphicsLayout::GraphicsLayout;
17 void addTab(QString tab);
18 int currentIndex()
const noexcept {
return m_currentIndex; }
19 void setCurrentIndex(
int index);
20 void setTabBarVisible(
bool visible)
noexcept { m_showTabBar = visible; }
21 std::function<void(
int)> onCurrentIndexChanged;
23 void layout()
override;
26 QVariant itemChange(GraphicsItemChange change,
const QVariant& value)
override;
29 bool m_showTabBar{
true};
31 std::vector<QGraphicsItem*> m_pages;
32 std::vector<QString> m_tabs;