Revision: b4d44a26dcb4
Author: sfle...@gmail.com
Date: Thu Nov 3 09:45:52 2011
Log: fixing typo in staticmap docs
http://code.google.com/p/marinemap/source/detail?r=b4d44a26dcb4
Revision: 25da54d34bca
Author: sfle...@gmail.com
Date: Thu Nov 3 16:04:43 2011
Log: changing the percentage templatetag so it handles precision
parameter
http://code.google.com/p/marinemap/source/detail?r=25da54d34bca
Revision: 655b5bd636c9
Author: sfle...@gmail.com
Date: Thu Nov 3 16:05:03 2011
Log: merge
http://code.google.com/p/marinemap/source/detail?r=655b5bd636c9
==============================================================================
Revision: b4d44a26dcb4
Author: sfle...@gmail.com
Date: Thu Nov 3 09:45:52 2011
Log: fixing typo in staticmap docs
http://code.google.com/p/marinemap/source/detail?r=b4d44a26dcb4
Modified:
/docs/staticmap.rst
=======================================
--- /docs/staticmap.rst Wed Apr 27 09:31:45 2011
+++ /docs/staticmap.rst Thu Nov 3 09:45:52 2011
@@ -46,7 +46,7 @@
Adding Datasets
**********************
-The staticmap application uses `Mapnik <http://mapnik.org>`_ to render map
images from spatial data. Specifically, we use the `mapnik XML files
<http://trac.mapnik.org/wiki/XMLConfigReference>`_ to configure the spatial
data sources and their styling. If you are unfamiliar with Mapnik, we
suggest going over the the `XML Configuration Tutorial
<http://trac.mapnik.org/wiki/XMLGettingStarted>`_ first.
+The staticmap application uses `Mapnik <http://mapnik.org>`_ to render map
images from spatial data. Specifically, we use the `mapnik XML files
<http://trac.mapnik.org/wiki/XMLConfigReference>`_ to configure the spatial
data sources and their styling. If you are unfamiliar with Mapnik, we
suggest going over the `XML Configuration Tutorial
<http://trac.mapnik.org/wiki/XMLGettingStarted>`_ first.
The default mapnik XML config file (<MEDIA_ROOT>/staticmap/socal.xml) is a
good starting point. You will need to add two main XML elements in order to
set up any additional data for the staticmap
==============================================================================
Revision: 25da54d34bca
Author: sfle...@gmail.com
Date: Thu Nov 3 16:04:43 2011
Log: changing the percentage templatetag so it handles precision
parameter
http://code.google.com/p/marinemap/source/detail?r=25da54d34bca
Modified:
/lingcod/common/templatetags/percentage.py
=======================================
--- /lingcod/common/templatetags/percentage.py Fri Oct 14 15:33:18 2011
+++ /lingcod/common/templatetags/percentage.py Thu Nov 3 16:04:43 2011
@@ -2,7 +2,8 @@
register = template.Library()
-def percentage(value):
- return '{0:.0%}'.format(value)
+def percentage(decimal, precision=0):
+ format_string = "." + str(precision) + "%"
+ return format(decimal, format_string)
register.filter('percentage', percentage)
==============================================================================
Revision: 655b5bd636c9
Author: sfle...@gmail.com
Date: Thu Nov 3 16:05:03 2011
Log: merge
http://code.google.com/p/marinemap/source/detail?r=655b5bd636c9