widgets.py 文件源码

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

项目:BigBrotherBot-For-UrT43 作者: ptitbigorneau 项目源码 文件源码
def initUI(self):
        """
        Initialize the MainWindow layout.
        """
        self.setWindowTitle(B3_TITLE)
        self.setFixedSize(614, 512)
        ## INIT SUBCOMPONENTS
        self.setStatusBar(StatusBar(self))
        self.setMenuBar(MainMenuBar(self))
        self.setCentralWidget(CentralWidget(self))

        ## INIT SYSTEM TRAY ICON
        if b3.getPlatform() != 'linux':
            self.system_tray = SystemTrayIcon(self)
            self.system_tray.show()

        ## MOVE TO CENTER SCREEN
        screen = QDesktopWidget().screenGeometry()
        position_x = (screen.width() - self.geometry().width()) / 2
        position_y = (screen.height() - self.geometry().height()) / 2
        self.move(position_x, position_y)

    ############################################# EVENTS HANDLERS ######################################################
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号