From aa75976b2eeef8ca973f9b13371737716c39d6b1 Mon Sep 17 00:00:00 2001 From: Sanj Date: Wed, 6 Jul 2011 19:30:50 +0530 Subject: [PATCH] ok, that broke --- edgware/editor/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/edgware/editor/views.py b/edgware/editor/views.py index 36ffb0b..60c5c01 100644 --- a/edgware/editor/views.py +++ b/edgware/editor/views.py @@ -650,7 +650,7 @@ def article_pdf(request): article = get_object_or_404_json(Article, pk=a_id) dpi = request.GET.get('dpi', 600) width_mm = request.GET.get('width', article.typ.print_width) - height_mm = int(round(width_mm / article.typ.aspect_ratio)) + height_mm = math.ceil(width_mm / article.typ.aspect_ratio) pages = Page.objects.filter(article=article).order_by('page_no') m = article.get_print_multiplier(dpi) url = SITE_BASE + "/edit/view_article/%d/?m=%f" % (article.id, m)