Skip to content

Commit 947db1b

Browse files
authored
Merge pull request #123 from asbjornst/fix-printing
Fix printing module - @asbjornst thanks! /cc @sebastic
2 parents 8ded0f7 + 213675a commit 947db1b

3 files changed

Lines changed: 4 additions & 1 deletion

File tree

mapnik/printing/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@ class PDFPrinter(object):
6565
Main class for creating PDF print outs. Basic usage is along the lines of
6666
6767
import mapnik
68+
import mapnik.printing
6869
6970
page = mapnik.printing.PDFPrinter()
7071
m = mapnik.Map(100,100)

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,7 @@ def run(self):
256256
setup(
257257
name="mapnik",
258258
version="0.1",
259-
packages=['mapnik'],
259+
packages=['mapnik','mapnik.printing'],
260260
author="Blake Thompson",
261261
author_email="flippmoke@gmail.com",
262262
description="Python bindings for Mapnik",

test/python_tests/pdf_printing_test.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@ def make_pdf(m, output_pdf, esri_wkt):
3131
page.add_geospatial_pdf_header(m, output_pdf, wkt=esri_wkt)
3232

3333
if mapnik.has_pycairo():
34+
import mapnik.printing
35+
3436
def test_pdf_printing():
3537
source_xml = '../data/good_maps/marker-text-line.xml'.encode('utf-8')
3638
m = make_map_from_xml(source_xml)

0 commit comments

Comments
 (0)