django easy_pdf utf-8个字符

时间:2014-07-24 19:58:12

标签: python django

我已经安装了easy_pdf http://django-easy-pdf.readthedocs.org/en/latest/installation.html。我不知道它是否正确安装。一些UTF-8字符(łóżź)渲染不正确。我的模板是:

{% extends "easy_pdf/base.html" %}

{% block content %}
    <div id="content">
        łóżąćęłń
    </div>
{% endblock %}

并查看:

class HelloPDFView(PDFTemplateView):
    template_name = "rhymes.html"

    def get_context_data(self, **kwargs):
        return super(HelloPDFView, self).get_context_data(pagesize="A4", title="PDF", **kwargs)

0 个答案:

没有答案