提交 8038b50b 编写于 作者: 之一Yo's avatar 之一Yo

更新 gallery 主页的示例卡片

上级 f3570e7f
......@@ -43,22 +43,6 @@ class DialogInterface(GalleryInterface):
'https://github.com/zhiyiYo/PyQt-Fluent-Widgets/blob/master/examples/color_dialog/demo.py'
)
self.teachingButton = PushButton(self.tr('Show teaching tip'))
self.teachingButton.clicked.connect(self.showBottomTeachingTip)
self.addExampleCard(
self.tr('A teaching tip'),
self.teachingButton,
'https://github.com/zhiyiYo/PyQt-Fluent-Widgets/blob/master/examples/teaching_tip/demo.py'
)
self.teachingRightButton = PushButton(self.tr('Show teaching tip'))
self.teachingRightButton.clicked.connect(self.showLeftBottomTeachingTip)
self.addExampleCard(
self.tr('A teaching tip with image and button'),
self.teachingRightButton,
'https://github.com/zhiyiYo/PyQt-Fluent-Widgets/blob/master/examples/teaching_tip/demo.py'
)
self.simpleFlyoutButton = PushButton(self.tr('Show flyout'))
self.simpleFlyoutButton.clicked.connect(self.showSimpleFlyout)
self.addExampleCard(
......@@ -75,6 +59,21 @@ class DialogInterface(GalleryInterface):
'https://github.com/zhiyiYo/PyQt-Fluent-Widgets/blob/master/examples/flyout/demo.py'
)
self.teachingButton = PushButton(self.tr('Show teaching tip'))
self.teachingButton.clicked.connect(self.showBottomTeachingTip)
self.addExampleCard(
self.tr('A teaching tip'),
self.teachingButton,
'https://github.com/zhiyiYo/PyQt-Fluent-Widgets/blob/master/examples/teaching_tip/demo.py'
)
self.teachingRightButton = PushButton(self.tr('Show teaching tip'))
self.teachingRightButton.clicked.connect(self.showLeftBottomTeachingTip)
self.addExampleCard(
self.tr('A teaching tip with image and button'),
self.teachingRightButton,
'https://github.com/zhiyiYo/PyQt-Fluent-Widgets/blob/master/examples/teaching_tip/demo.py'
)
def showDialog(self):
title = self.tr('This is a frameless message dialog')
......
......@@ -252,11 +252,18 @@ class HomeInterface(ScrollArea):
index=2
)
dialogView.addSampleCard(
icon=":/gallery/images/controls/ColorPicker.png",
icon=":/gallery/images/controls/Flyout.png",
title="Flyout",
content=self.tr("Shows contextual information and enables user interaction."),
routeKey="dialogInterface",
index=3
)
dialogView.addSampleCard(
icon=":/gallery/images/controls/TeachingTip.png",
title="TeachingTip",
content=self.tr("A content-rich flyout for guiding users and enabling teaching moments."),
routeKey="dialogInterface",
index=3
index=5
)
self.vBoxLayout.addWidget(dialogView)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册