pythonV1V2/第29讲身份二维码/课堂成果/课后作业-别出心裁的信件.py
sairate 7df250638d chore: 添加项目基础结构和示例代码
- 创建 .idea 目录和相关配置文件,设置项目结构
- 添加多个课堂成果示例代码,涵盖不同主题和功能
- 创建和配置 .gitignore 文件,忽略特定文件和目录
2025-07-05 09:36:00 +08:00

26 lines
891 B
Python
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

'''
【课后作业要求】
别出心裁的信件
P仔的小学弟博克斯最近很烦恼。他跟同桌莱丝吵架了不知道该怎么和好请帮博克斯制作一封独特的二维码信件向莱丝表达歉意。
小小建议:
1. 可以跳转到道歉的图片或者逗莱丝开心的图片
2. 可以选用有纪念意义的照片作为背景图
3. 其他可选参数自行设置,无标准答案'''
from MyQR import myqr
myqr.run(
words="Sorry!", # 跳转到的页面待定(必须是英文字符串)
version = 7, # 二维码版本
level = 'Q', # 纠错等级“H”表示最高等级
picture = 'budinggou.gif', # 指定背景图片路径
colorized = True, # 是否彩色二维码
contrast = 1.2, # 对比度,根据需求调整
brightness = 0.9, # 亮度,根据需求调整
save_name = '作业.gif',
)