我有一个使用wkhtmltopdf的Django应用程序我生成了一个pdf文档。我有一个部分,如下面的代码。我想在每一边都是4个文本(对象)。但每个人都是不同的,文字出来不均匀安排。 CSS没有帮助。怎么做?
<table width="90%" border="0" align="center" cellpadding="0" cellspacing="0" style="margin-top:50px;">
<h3>{% trans 'In progress' %}</h3>
{% for worked_on in worker.worked_on.all %}
<tr>
<td width="33%" align="left" valign="top"> </td>
<td width="67%" class="project-name">
//CONTENT
</td>
</tr>
<tr>
<td class="project-image" width="33%" align="left" valign="top">
//CONTENT
</td>
<td class="project-description" valign="top">
//CONTENT
</td>
</tr>
{% if forloop.counter|divisibleby:"4" %}
<tr>
<td class="project-description" style="margin-bottom:80px;">
<div style="page-break-after: always;"></div>
</td>
</tr>
{% endif %}
{% endfor %}
</table>