SkChessView.py 文件源码

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

项目:pythonista-scripts 作者: khilnani 项目源码 文件源码
def __init__(self, game=None):
        self.game = game or ChessGame()
        self.width, self.height = ui.get_screen_size()
        assert self.width > self.height, 'This app only works in landscape mode!!'
        if photos.is_authorized():  # add a photo as the background image
            self.add_subview(self.make_image_view())
        center_frame, left_frame, right_frame, status_frame = screen_frames()
        self.add_subview(self.make_left_side_view(left_frame))
        self.make_buttons(left_frame)
        self.add_subview(self.make_board_scene(center_frame))
        self.info_view = self.make_right_side_view(right_frame)
        self.add_subview(self.info_view)
        self.status_view = self.make_status_view(status_frame)
        self.add_subview(self.status_view)
        self.present(orientations=['landscape'], hide_title_bar=True)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号