main.py 文件源码

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

项目:PyF9 作者: Saren-Arterius 项目源码 文件源码
def set_associate(self):
        if not ASSOCIATE_ENABLED:
            self.reset_associate()
            return
        self.button_function.configure(text='(??)')
        self.associate_count = 0
        for i, btn in enumerate(self.input_buttons):
            char = self.find_associate(self.last_char, i)
            self.current_associate[i] = char
            image = PImage.new("RGBA", (48, 48),
                               (255, 255, 255, 255) if platform.system() == "Darwin" else (255, 255, 255, 0))
            d = ImageDraw.Draw(image)
            d.text((0, 0), char, font=font, fill=(255, 255, 255, 255))
            photo = ImageTk.PhotoImage(image)
            btn.image = photo
            btn.configure(image=photo)
        self.is_associate = True
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号