fixed font setup, added test script
This commit is contained in:
6
scripts/listallFonts.py
Executable file
6
scripts/listallFonts.py
Executable file
@ -0,0 +1,6 @@
|
||||
#!/usr/bin/python
|
||||
|
||||
from mapnik import register_fonts, FontEngine
|
||||
custom_fonts_dir = '/usr/share/fonts'
|
||||
register_fonts(custom_fonts_dir)
|
||||
for face in FontEngine.face_names(): print face
|
||||
@ -7,7 +7,6 @@
|
||||
from math import pi,cos,sin,log,exp,atan
|
||||
from subprocess import call
|
||||
import sys, os
|
||||
#import mapnik2 as mapnik
|
||||
import multiprocessing
|
||||
import psycopg2
|
||||
from shapely.geometry import Polygon
|
||||
@ -18,11 +17,8 @@ import getpass
|
||||
import argparse
|
||||
import mapnik
|
||||
|
||||
#try:
|
||||
# import mapnik2 as mapnik
|
||||
#except:
|
||||
# import mapnik
|
||||
|
||||
custom_fonts_dir = '/usr/share/fonts/'
|
||||
mapnik.register_fonts(custom_fonts_dir)
|
||||
|
||||
DEG_TO_RAD = pi/180
|
||||
RAD_TO_DEG = 180/pi
|
||||
|
||||
Reference in New Issue
Block a user