reportlab:在 rml 中为 td 设置 colspan [英] reportlab: setting colspan for td in rml

查看:77
本文介绍了reportlab:在 rml 中为 td 设置 colspan的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我找不到任何允许为 rml 中的 td 元素设置 colspan 的选项.这有可能吗?

I can't find any option, that would allow to set colspan for td element in rml. Is that somehow possible?

推荐答案

通常的 ReportLab 方法是使用 Platypus 和 Table flowable.当您设置Table 的样式时,您可以指定一个'SPAN' 命令,它将单元格的任何矩形区域捆绑成一个.您可以在 ReportLab 用户指南,第 7 章中找到更多相关信息,第 81 页.

The normal ReportLab way to do this would be to instead use Platypus and the Table flowable. When you set the style of the Table, you can specify a 'SPAN' command that will bundle any rectangular area of cells into one. You'll find more information on this in the ReportLab User Guide, chapter 7, page 81.

如果您必须使用 RML,我倾向于认为 colspan 根本不可用.它至少不在 ReportLab RML 参考文档中.相反,我认为您应该使用 blockSpan 元素.没有给出示例,但您可以在RML 手册中找到它.

If you must use RML, I'm inclined to think that colspan is simply not available. It's at least not in the ReportLab RML reference document. Instead I think you are supposed to use blockSpan elements. There's no example given, but you'll find it in the RML manual.

这篇关于reportlab:在 rml 中为 td 设置 colspan的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆