from fpdf import FPDF
# Create PDF instance
pdf = FPDF()
pdf.set_auto_page_break(auto=True, margin=15)
pdf.add_page()
# Set Title
pdf.set_font("Arial", size=16, style='B')
pdf.cell(0, 10, "Annual Health Risk Assessment Flyer", ln=True, align='C')
pdf.ln(10)
# Add Flyer Description Text
pdf.set_font("Arial", size=12)
flyer_text = (
"Take Charge of Your Health Today!\n\n"
"Participate in our Annual Health Risk Assessment program to prioritize your well-being. "
"Complete the assessment online using the Wellsource platform and review your personal health "
"report with your provider at WeCare TLC.\n\n"
"Benefits of Completing Your HRA:\n"
"- Gain insights into your current health status.\n"
"- Access personalized recommendations for a healthier lifestyle.\n"
"- Receive ongoing support through your HealthShelf library.\n\n"
"How to Get Started:\n"
"1. Visit the Wellsource portal at:\n"
" https://wecaretlc.iv.wellsuite.com/WsWebAppWellSuite/index.html?g=34092379-655e-40ed-9ab3-0a04b653207b\n"
"2. Log in using your unique credentials provided by your healthcare team.\n"
"3. Complete the assessment and schedule a follow-up appointment to discuss your results.\n\n"
"Questions? Contact your health center nurse for assistance.\n\n"
"Your health journey starts here. Thank you for prioritizing your well-being!"
)
pdf.multi_cell(0, 10, flyer_text)
pdf.ln(10)
# Add Image (Flyer Image)
image_path = "/mnt/data/A_professional_and_engaging_flyer_design_for_an_an.png"
pdf.image(image_path, x=10, y=pdf.get_y(), w=190) # Adjusted to fit page width
# Save the PDF
output_path = "/mnt/data/Annual_Health_Risk_Assessment_Flyer.pdf"
pdf.output(output_path)
output_path
从fpdf导入FPDF
# 创建PDF实例
pdf = FPDF()
pdf.set_auto_page_break(auto = True, margin = 15)
pdf.add_page()
# 设置标题
pdf.set_font("Arial", size = 16, style = 'B')
pdf.cell(0,10,“年度健康风险评估传单”,ln = True,align = 'C')
pdf.ln(10)
# 添加传单描述文本
pdf.set_font("Arial", size = 12)
flyer_text = (
“今天负责你的健康!\ n”
“参与我们的年度健康风险评估计划,优先考虑您的健康。
“使用Wellsource平台在线完成评估并查看您的个人健康状况”
"在WeCare TLC向您的提供商报告。\ n"
"完成HRA的好处: \ n"
"-深入了解您当前的健康状况。\ n"
"-访问更健康的生活方式的个性化建议。\ n"
"-通过您的HealthShelf库获得持续支持。\ n"
"如何开始: \ n"
"1.访问Wellsource门户网站: \ n"
" https://wecaretlc.iv.wellsuite.com/WsWebAppWellSuite/index.html?g= "
"2.使用您的医疗保健团队提供的唯一凭据登录。\ n"
“3.完成评估并安排后续预约以讨论您的结果。\ n”
"有问题吗?请联系您的健康中心护士寻求帮助。\ n"
“您的健康之旅从这里开始。感谢您优先考虑您的健康!”
)
pdf.multi_cell(0