python - Reportlab:Platypus 是否可以有内部链接?

标签 python reportlab platypus

我知道我可以在内部链接 canvas,但我的整个文档都设置了 Platypus。 Platypus 是否支持内部链接?如果不迁移到 Canvas 有多难?

提前致谢!

最佳答案

您可以使用段落内标记来创建 anchor (<a> 标记)和链接(<link> 标记),如 6.3 段落内标记 部分(第 6 章,页面)中所述72) 的 ReportLab 2.6 User Manual PDF ,其中还包含以下示例:

This <a href="#MYANCHOR" color="blue">is a link to</a> an
anchor tag ie <a name="MYANCHOR"/><font color="green">here</font>.
This <link href="#MYANCHOR" color="blue" fontName="Helvetica">is
another link to</link> the same anchor tag.

关于python - Reportlab:Platypus 是否可以有内部链接?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13898593/

相关文章:

python - Platypus - 在页面模板中使用多个框架

python - 如何通过 reportlab 将表格定位在特定的 x 和 y 坐标处

python - 查询多个 between 子句

python - 合并 strip 时间戳

python - 使用 Django 和 Reportlab 从 HTML 生成 PDF

python - ReportLab - 无法屏蔽图像 [Google App Engine]

python - 解析 Redis MONITOR 消息

python - 是否有一种用引号格式化字符串的智能方法?

python - django View 中的简单 for 循环创建 pdf 文件

Python Reportlab 段落不跨越下一页