TabWidget.py 文件源码

python
阅读 22 收藏 0 点赞 0 评论 0

项目:pyqt5 作者: yurisnm 项目源码 文件源码
def mouseDoubleClickEvent(self, event):
        if event.button() != Qt.LeftButton:
            super(TabBarPlus, self).mouseDoubleClickEvent(event)

        idx = self.currentIndex()
        ok = True
        self.input_dialog = QInputDialog()
        print(type(self.input_dialog.textEchoMode()))

        newName, ok = QInputDialog.getText(self, 'Mudar nome',
                                        'Novo nome:')

        if ok:
            self.setTabText(idx, newName)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号