bernhard: thuban/Extensions/svgexport TODO, 1.4, 1.5 __init__.py, 1.7, 1.8 svgmapwriter.py, 1.15, 1.16

cvs@intevation.de cvs at intevation.de
Mon Dec 27 18:00:17 CET 2004


Author: bernhard

Update of /thubanrepository/thuban/Extensions/svgexport
In directory doto:/tmp/cvs-serv1044/Extensions/svgexport

Modified Files:
	TODO __init__.py svgmapwriter.py 
Log Message:
	svgexport 1.0.0cvs: Fixed label export.

	* Extensions/svgexport/test/test_svgmapwriter.py:
	class TestSVGRenderer(): New class; new test test_label_font().

	* Extensions/svgexport/svgmapwriter.py
	(SVGRenderer.label_font()): initialised Font size with self.factor now, 
	makes test_label_font happy.

	* Extensions/svgexport/TODO: crossed out fixed label export item.
	Added item for options.

	* Extensions/svgexport/__init__.py: Bumped version to 1.0.0cvs.


Index: TODO
===================================================================
RCS file: /thubanrepository/thuban/Extensions/svgexport/TODO,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- TODO	20 Dec 2004 10:08:58 -0000	1.4
+++ TODO	27 Dec 2004 17:00:14 -0000	1.5
@@ -2,7 +2,6 @@
 
 For 1.0.1:
 
-* Enable label export.
 * Enable Raster file export.
 
 For 1.0.x, x>1:
@@ -30,3 +29,5 @@
   which also asks for a command line to run after each "save".
   The command line can be used to run something like 
   "skencil-remote --updated-thubanmapsvgfile %s"
+
+* Think about adding preferences or options , e.g.: ignore the line Width.

Index: __init__.py
===================================================================
RCS file: /thubanrepository/thuban/Extensions/svgexport/__init__.py,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- __init__.py	18 Dec 2004 02:36:59 -0000	1.7
+++ __init__.py	27 Dec 2004 17:00:14 -0000	1.8
@@ -24,7 +24,7 @@
 
 ext_registry.add(ExtensionDesc(
     name = 'SVG Export',
-    version = '1.0.0',
+    version = '1.0.0cvs',
     authors= [ 'Markus Rechtien', 'Bernhard Reiter' ],
     copyright = '2004 Intevation GmbH',
     desc = _("Export the current map and legend in Thuban-map-SVG format.")))

Index: svgmapwriter.py
===================================================================
RCS file: /thubanrepository/thuban/Extensions/svgexport/svgmapwriter.py,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -d -r1.15 -r1.16
--- svgmapwriter.py	20 Dec 2004 10:08:58 -0000	1.15
+++ svgmapwriter.py	27 Dec 2004 17:00:15 -0000	1.16
@@ -189,8 +189,12 @@
         return Point(x, y)
     
     def label_font(self):
-        """Return the font object for the label layer"""
-        return Font()
+        """Return the font object for the label layer.
+        
+        As we scale stuff, the fontsize also needs to be scaled."""
+        if verbose>1:
+            log("label_font() called.\n")
+        return Font(fsize=12*self.factor)
 
     def tools_for_property(self, prop):
         """Return a pen/brush tuple build from a property object."""





More information about the Thuban-devel mailing list

This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)