From 77b5b7e2bb71fddab5b36dca25d99e7ff784cc68 Mon Sep 17 00:00:00 2001 From: liuwei Date: Mon, 3 Mar 2025 15:34:54 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8A=A0=E5=85=A5=E5=88=86=E9=A1=B5=EF=BC=8C?= =?UTF-8?q?=E9=80=86=E5=BA=8F=E6=8E=92=E5=88=97=E5=B8=96=E5=AD=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sehuatang/shehuatang.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sehuatang/shehuatang.py b/sehuatang/shehuatang.py index 19aea58..fe16a4f 100644 --- a/sehuatang/shehuatang.py +++ b/sehuatang/shehuatang.py @@ -84,6 +84,7 @@ def fetch_and_create_pdf(url): normal_style = styles['Normal'] normal_style.fontName = 'SimHei' + normal_style.fontSize = 13 content = [] @@ -128,7 +129,7 @@ def fetch_and_create_pdf(url): # 添加磁力链接 if magnet_links: for magnet_link in magnet_links: - content.append(Paragraph(f"

{magnet_link}

", normal_style)) + content.append(Paragraph(f"
{magnet_link}
", normal_style)) content.append(Spacer(1, 12)) # 添加图片 @@ -148,7 +149,7 @@ def fetch_and_create_pdf(url): image_height = int((img_height / img_width) * image_width) img_stream = BytesIO(image.getvalue()) content.append(Image(img_stream, width=image_width, height=image_height)) - content.append(Spacer(1, 12)) + content.append(Spacer(1, 4)) # 在每个帖子后添加分页符(除了最后一页) if post != today_posts[-1]: