[QGIS Commit] r8448 - in trunk/qgis: src/core/renderer src/core/symbology tests/testdata

svn_qgis at osgeo.org svn_qgis at osgeo.org
Sat May 17 07:45:55 EDT 2008


Author: mhugent
Date: 2008-05-17 07:45:55 -0400 (Sat, 17 May 2008)
New Revision: 8448

Modified:
   trunk/qgis/src/core/renderer/qgscontinuouscolorrenderer.cpp
   trunk/qgis/src/core/symbology/qgssymbol.cpp
   trunk/qgis/tests/testdata/lines_continuous_symbol.qml
   trunk/qgis/tests/testdata/lines_graduated_symbol.qml
   trunk/qgis/tests/testdata/lines_single_symbol.qml
   trunk/qgis/tests/testdata/lines_uniquevalue_symbol.qml
   trunk/qgis/tests/testdata/points_continuous_symbol.qml
   trunk/qgis/tests/testdata/points_graduated_symbol.qml
   trunk/qgis/tests/testdata/points_single_symbol.qml
   trunk/qgis/tests/testdata/points_uniquevalue_symbol.qml
   trunk/qgis/tests/testdata/polys_continuous_symbol.qml
   trunk/qgis/tests/testdata/polys_graduated_symbol.qml
   trunk/qgis/tests/testdata/polys_single_symbol.qml
   trunk/qgis/tests/testdata/polys_uniquevalue_symbol.qml
Log:
Fix for continuous color rendering of points, changed test qml files to mm units

Modified: trunk/qgis/src/core/renderer/qgscontinuouscolorrenderer.cpp
===================================================================
--- trunk/qgis/src/core/renderer/qgscontinuouscolorrenderer.cpp	2008-05-17 09:58:15 UTC (rev 8447)
+++ trunk/qgis/src/core/renderer/qgscontinuouscolorrenderer.cpp	2008-05-17 11:45:55 UTC (rev 8448)
@@ -140,7 +140,7 @@
       }
       brush.setStyle ( Qt::SolidPattern );
 
-      *img = QgsMarkerCatalogue::instance()->imageMarker ( mMinimumSymbol->pointSymbolName(), mMinimumSymbol->pointSize(),
+      *img = QgsMarkerCatalogue::instance()->imageMarker ( mMinimumSymbol->pointSymbolName(), mMinimumSymbol->pointSize() *widthScale * rasterScaleFactor,
           pen, brush);
     } 
     else if ( mVectorType == QGis::Line )

Modified: trunk/qgis/src/core/symbology/qgssymbol.cpp
===================================================================
--- trunk/qgis/src/core/symbology/qgssymbol.cpp	2008-05-17 09:58:15 UTC (rev 8447)
+++ trunk/qgis/src/core/symbology/qgssymbol.cpp	2008-05-17 11:45:55 UTC (rev 8448)
@@ -337,7 +337,7 @@
   QImage preRotateImage;
   QPen pen = mPen;
   double newWidth = mPen.widthF() * widthScale * scale;
-  pen.setWidth(mPen.widthF() * widthScale * scale);
+  pen.setWidth(newWidth);
 
   if ( selected )
   {

Modified: trunk/qgis/tests/testdata/lines_continuous_symbol.qml
===================================================================
--- trunk/qgis/tests/testdata/lines_continuous_symbol.qml	2008-05-17 09:58:15 UTC (rev 8447)
+++ trunk/qgis/tests/testdata/lines_continuous_symbol.qml	2008-05-17 11:45:55 UTC (rev 8448)
@@ -37,7 +37,7 @@
           <scaleclassificationfield>-1</scaleclassificationfield>
           <outlinecolor red="133" blue="50" green="45" />
           <outlinestyle>SolidLine</outlinestyle>
-          <outlinewidth>3</outlinewidth>
+          <outlinewidth>1.2</outlinewidth>
           <fillcolor red="0" blue="0" green="0" />
           <fillpattern>NoBrush</fillpattern>
           <texturepath></texturepath>
@@ -54,7 +54,7 @@
           <scaleclassificationfield>-1</scaleclassificationfield>
           <outlinecolor red="48" blue="156" green="50" />
           <outlinestyle>SolidLine</outlinestyle>
-          <outlinewidth>3</outlinewidth>
+          <outlinewidth>1.2</outlinewidth>
           <fillcolor red="0" blue="0" green="0" />
           <fillpattern>NoBrush</fillpattern>
           <texturepath></texturepath>

Modified: trunk/qgis/tests/testdata/lines_graduated_symbol.qml
===================================================================
--- trunk/qgis/tests/testdata/lines_graduated_symbol.qml	2008-05-17 09:58:15 UTC (rev 8447)
+++ trunk/qgis/tests/testdata/lines_graduated_symbol.qml	2008-05-17 11:45:55 UTC (rev 8448)
@@ -35,7 +35,7 @@
         <scaleclassificationfield>-1</scaleclassificationfield>
         <outlinecolor red="107" blue="111" green="98" />
         <outlinestyle>DashLine</outlinestyle>
-        <outlinewidth>5</outlinewidth>
+        <outlinewidth>2</outlinewidth>
         <fillcolor red="0" blue="0" green="0" />
         <fillpattern>NoBrush</fillpattern>
         <texturepath></texturepath>
@@ -50,7 +50,7 @@
         <scaleclassificationfield>-1</scaleclassificationfield>
         <outlinecolor red="134" blue="99" green="120" />
         <outlinestyle>SolidLine</outlinestyle>
-        <outlinewidth>3</outlinewidth>
+        <outlinewidth>1.2</outlinewidth>
         <fillcolor red="0" blue="0" green="0" />
         <fillpattern>NoBrush</fillpattern>
         <texturepath></texturepath>
@@ -65,7 +65,7 @@
         <scaleclassificationfield>-1</scaleclassificationfield>
         <outlinecolor red="124" blue="143" green="171" />
         <outlinestyle>DashDotDotLine</outlinestyle>
-        <outlinewidth>1</outlinewidth>
+        <outlinewidth>0.4</outlinewidth>
         <fillcolor red="0" blue="0" green="0" />
         <fillpattern>NoBrush</fillpattern>
         <texturepath></texturepath>

Modified: trunk/qgis/tests/testdata/lines_single_symbol.qml
===================================================================
--- trunk/qgis/tests/testdata/lines_single_symbol.qml	2008-05-17 09:58:15 UTC (rev 8447)
+++ trunk/qgis/tests/testdata/lines_single_symbol.qml	2008-05-17 11:45:55 UTC (rev 8448)
@@ -33,7 +33,7 @@
         <scaleclassificationfield>-1</scaleclassificationfield>
         <outlinecolor red="159" blue="98" green="113" />
         <outlinestyle>DashLine</outlinestyle>
-        <outlinewidth>2</outlinewidth>
+        <outlinewidth>0.8</outlinewidth>
         <fillcolor red="0" blue="0" green="0" />
         <fillpattern>NoBrush</fillpattern>
         <texturepath></texturepath>

Modified: trunk/qgis/tests/testdata/lines_uniquevalue_symbol.qml
===================================================================
--- trunk/qgis/tests/testdata/lines_uniquevalue_symbol.qml	2008-05-17 09:58:15 UTC (rev 8447)
+++ trunk/qgis/tests/testdata/lines_uniquevalue_symbol.qml	2008-05-17 11:45:55 UTC (rev 8448)
@@ -35,7 +35,7 @@
         <scaleclassificationfield>-1</scaleclassificationfield>
         <outlinecolor red="165" blue="74" green="36" />
         <outlinestyle>DashLine</outlinestyle>
-        <outlinewidth>5</outlinewidth>
+        <outlinewidth>2</outlinewidth>
         <fillcolor red="0" blue="0" green="0" />
         <fillpattern>NoBrush</fillpattern>
         <texturepath></texturepath>
@@ -50,7 +50,7 @@
         <scaleclassificationfield>-1</scaleclassificationfield>
         <outlinecolor red="12" blue="96" green="151" />
         <outlinestyle>SolidLine</outlinestyle>
-        <outlinewidth>7</outlinewidth>
+        <outlinewidth>2.8</outlinewidth>
         <fillcolor red="0" blue="0" green="0" />
         <fillpattern>NoBrush</fillpattern>
         <texturepath></texturepath>

Modified: trunk/qgis/tests/testdata/points_continuous_symbol.qml
===================================================================
--- trunk/qgis/tests/testdata/points_continuous_symbol.qml	2008-05-17 09:58:15 UTC (rev 8447)
+++ trunk/qgis/tests/testdata/points_continuous_symbol.qml	2008-05-17 11:45:55 UTC (rev 8448)
@@ -32,12 +32,12 @@
           <uppervalue></uppervalue>
           <label></label>
           <pointsymbol>hard:circle</pointsymbol>
-          <pointsize>10</pointsize>
+          <pointsize>4</pointsize>
           <rotationclassificationfield>-1</rotationclassificationfield>
           <scaleclassificationfield>-1</scaleclassificationfield>
           <outlinecolor red="216" blue="30" green="210" />
           <outlinestyle>SolidLine</outlinestyle>
-          <outlinewidth>1</outlinewidth>
+          <outlinewidth>0.4</outlinewidth>
           <fillcolor red="0" blue="0" green="0" />
           <fillpattern>NoBrush</fillpattern>
           <texturepath></texturepath>
@@ -49,12 +49,12 @@
           <uppervalue></uppervalue>
           <label></label>
           <pointsymbol>hard:circle</pointsymbol>
-          <pointsize>10</pointsize>
+          <pointsize>4</pointsize>
           <rotationclassificationfield>-1</rotationclassificationfield>
           <scaleclassificationfield>-1</scaleclassificationfield>
           <outlinecolor red="46" blue="206" green="43" />
           <outlinestyle>SolidLine</outlinestyle>
-          <outlinewidth>1</outlinewidth>
+          <outlinewidth>0.4</outlinewidth>
           <fillcolor red="0" blue="0" green="0" />
           <fillpattern>NoBrush</fillpattern>
           <texturepath></texturepath>

Modified: trunk/qgis/tests/testdata/points_graduated_symbol.qml
===================================================================
--- trunk/qgis/tests/testdata/points_graduated_symbol.qml	2008-05-17 09:58:15 UTC (rev 8447)
+++ trunk/qgis/tests/testdata/points_graduated_symbol.qml	2008-05-17 11:45:55 UTC (rev 8448)
@@ -31,12 +31,12 @@
         <uppervalue>7.333</uppervalue>
         <label></label>
         <pointsymbol>hard:circle</pointsymbol>
-        <pointsize>10</pointsize>
+        <pointsize>4</pointsize>
         <rotationclassificationfield>1</rotationclassificationfield>
         <scaleclassificationfield>2</scaleclassificationfield>
         <outlinecolor red="0" blue="0" green="0" />
         <outlinestyle>SolidLine</outlinestyle>
-        <outlinewidth>1</outlinewidth>
+        <outlinewidth>0.4</outlinewidth>
         <fillcolor red="0" blue="0" green="255" />
         <fillpattern>SolidPattern</fillpattern>
         <texturepath></texturepath>
@@ -46,12 +46,12 @@
         <uppervalue>13.667</uppervalue>
         <label></label>
         <pointsymbol>hard:rectangle</pointsymbol>
-        <pointsize>18</pointsize>
+        <pointsize>7</pointsize>
         <rotationclassificationfield>1</rotationclassificationfield>
         <scaleclassificationfield>2</scaleclassificationfield>
         <outlinecolor red="0" blue="0" green="0" />
         <outlinestyle>SolidLine</outlinestyle>
-        <outlinewidth>1</outlinewidth>
+        <outlinewidth>0.4</outlinewidth>
         <fillcolor red="169" blue="108" green="102" />
         <fillpattern>SolidPattern</fillpattern>
         <texturepath></texturepath>
@@ -61,12 +61,12 @@
         <uppervalue>20.001</uppervalue>
         <label></label>
         <pointsymbol>hard:star</pointsymbol>
-        <pointsize>22</pointsize>
+        <pointsize>9</pointsize>
         <rotationclassificationfield>1</rotationclassificationfield>
         <scaleclassificationfield>2</scaleclassificationfield>
         <outlinecolor red="0" blue="0" green="0" />
         <outlinestyle>SolidLine</outlinestyle>
-        <outlinewidth>1</outlinewidth>
+        <outlinewidth>0.4</outlinewidth>
         <fillcolor red="0" blue="171" green="84" />
         <fillpattern>SolidPattern</fillpattern>
         <texturepath></texturepath>

Modified: trunk/qgis/tests/testdata/points_single_symbol.qml
===================================================================
--- trunk/qgis/tests/testdata/points_single_symbol.qml	2008-05-17 09:58:15 UTC (rev 8447)
+++ trunk/qgis/tests/testdata/points_single_symbol.qml	2008-05-17 11:45:55 UTC (rev 8448)
@@ -30,12 +30,12 @@
         <uppervalue></uppervalue>
         <label></label>
         <pointsymbol>hard:triangle</pointsymbol>
-        <pointsize>12</pointsize>
+        <pointsize>5</pointsize>
         <rotationclassificationfield>1</rotationclassificationfield>
         <scaleclassificationfield>2</scaleclassificationfield>
         <outlinecolor red="140" blue="60" green="82" />
         <outlinestyle>SolidLine</outlinestyle>
-        <outlinewidth>1</outlinewidth>
+        <outlinewidth>0.4</outlinewidth>
         <fillcolor red="193" blue="122" green="145" />
         <fillpattern>SolidPattern</fillpattern>
         <texturepath></texturepath>

Modified: trunk/qgis/tests/testdata/points_uniquevalue_symbol.qml
===================================================================
--- trunk/qgis/tests/testdata/points_uniquevalue_symbol.qml	2008-05-17 09:58:15 UTC (rev 8447)
+++ trunk/qgis/tests/testdata/points_uniquevalue_symbol.qml	2008-05-17 11:45:55 UTC (rev 8448)
@@ -32,12 +32,12 @@
         <uppervalue></uppervalue>
         <label></label>
         <pointsymbol>svg:/Applications/qgis0.9.2.app/Contents/MacOS/share/qgis/svg/gpsicons/plane.svg</pointsymbol>
-        <pointsize>18</pointsize>
+        <pointsize>6</pointsize>
         <rotationclassificationfield>1</rotationclassificationfield>
         <scaleclassificationfield>2</scaleclassificationfield>
         <outlinecolor red="0" blue="0" green="0" />
         <outlinestyle>SolidLine</outlinestyle>
-        <outlinewidth>1</outlinewidth>
+        <outlinewidth>0.4</outlinewidth>
         <fillcolor red="231" blue="132" green="129" />
         <fillpattern>SolidPattern</fillpattern>
         <texturepath></texturepath>
@@ -47,12 +47,12 @@
         <uppervalue></uppervalue>
         <label></label>
         <pointsymbol>svg:/Applications/qgis0.9.2.app/Contents/MacOS/share/qgis/svg/gpsicons/plane_orange.svg</pointsymbol>
-        <pointsize>14</pointsize>
+        <pointsize>5</pointsize>
         <rotationclassificationfield>1</rotationclassificationfield>
         <scaleclassificationfield>2</scaleclassificationfield>
         <outlinecolor red="0" blue="0" green="0" />
         <outlinestyle>SolidLine</outlinestyle>
-        <outlinewidth>1</outlinewidth>
+        <outlinewidth>0.4</outlinewidth>
         <fillcolor red="82" blue="126" green="252" />
         <fillpattern>SolidPattern</fillpattern>
         <texturepath></texturepath>
@@ -62,12 +62,12 @@
         <uppervalue></uppervalue>
         <label></label>
         <pointsymbol>svg:/Applications/qgis0.9.2.app/Contents/MacOS/share/qgis/svg/gpsicons/plane.svg</pointsymbol>
-        <pointsize>14</pointsize>
+        <pointsize>5</pointsize>
         <rotationclassificationfield>1</rotationclassificationfield>
         <scaleclassificationfield>2</scaleclassificationfield>
         <outlinecolor red="0" blue="0" green="0" />
         <outlinestyle>SolidLine</outlinestyle>
-        <outlinewidth>1</outlinewidth>
+        <outlinewidth>0.4</outlinewidth>
         <fillcolor red="68" blue="242" green="24" />
         <fillpattern>SolidPattern</fillpattern>
         <texturepath></texturepath>

Modified: trunk/qgis/tests/testdata/polys_continuous_symbol.qml
===================================================================
--- trunk/qgis/tests/testdata/polys_continuous_symbol.qml	2008-05-17 09:58:15 UTC (rev 8447)
+++ trunk/qgis/tests/testdata/polys_continuous_symbol.qml	2008-05-17 11:45:55 UTC (rev 8448)
@@ -37,7 +37,7 @@
           <scaleclassificationfield>-1</scaleclassificationfield>
           <outlinecolor red="0" blue="0" green="0" />
           <outlinestyle>SolidLine</outlinestyle>
-          <outlinewidth>1</outlinewidth>
+          <outlinewidth>0.4</outlinewidth>
           <fillcolor red="94" blue="213" green="172" />
           <fillpattern>SolidPattern</fillpattern>
           <texturepath></texturepath>
@@ -54,7 +54,7 @@
           <scaleclassificationfield>-1</scaleclassificationfield>
           <outlinecolor red="0" blue="0" green="0" />
           <outlinestyle>SolidLine</outlinestyle>
-          <outlinewidth>1</outlinewidth>
+          <outlinewidth>0.4</outlinewidth>
           <fillcolor red="59" blue="134" green="49" />
           <fillpattern>SolidPattern</fillpattern>
           <texturepath></texturepath>

Modified: trunk/qgis/tests/testdata/polys_graduated_symbol.qml
===================================================================
--- trunk/qgis/tests/testdata/polys_graduated_symbol.qml	2008-05-17 09:58:15 UTC (rev 8447)
+++ trunk/qgis/tests/testdata/polys_graduated_symbol.qml	2008-05-17 11:45:55 UTC (rev 8448)
@@ -35,7 +35,7 @@
         <scaleclassificationfield>-1</scaleclassificationfield>
         <outlinecolor red="13" blue="166" green="110" />
         <outlinestyle>SolidLine</outlinestyle>
-        <outlinewidth>1</outlinewidth>
+        <outlinewidth>0.4</outlinewidth>
         <fillcolor red="124" blue="221" green="186" />
         <fillpattern>Dense1Pattern</fillpattern>
         <texturepath></texturepath>
@@ -50,7 +50,7 @@
         <scaleclassificationfield>-1</scaleclassificationfield>
         <outlinecolor red="26" blue="177" green="173" />
         <outlinestyle>SolidLine</outlinestyle>
-        <outlinewidth>1</outlinewidth>
+        <outlinewidth>0.4</outlinewidth>
         <fillcolor red="95" blue="188" green="144" />
         <fillpattern>SolidPattern</fillpattern>
         <texturepath></texturepath>
@@ -65,7 +65,7 @@
         <scaleclassificationfield>-1</scaleclassificationfield>
         <outlinecolor red="152" blue="93" green="84" />
         <outlinestyle>SolidLine</outlinestyle>
-        <outlinewidth>1</outlinewidth>
+        <outlinewidth>0.4</outlinewidth>
         <fillcolor red="171" blue="136" green="130" />
         <fillpattern>SolidPattern</fillpattern>
         <texturepath></texturepath>

Modified: trunk/qgis/tests/testdata/polys_single_symbol.qml
===================================================================
--- trunk/qgis/tests/testdata/polys_single_symbol.qml	2008-05-17 09:58:15 UTC (rev 8447)
+++ trunk/qgis/tests/testdata/polys_single_symbol.qml	2008-05-17 11:45:55 UTC (rev 8448)
@@ -33,7 +33,7 @@
         <scaleclassificationfield>-1</scaleclassificationfield>
         <outlinecolor red="11" blue="195" green="124" />
         <outlinestyle>DashLine</outlinestyle>
-        <outlinewidth>2</outlinewidth>
+        <outlinewidth>0.8</outlinewidth>
         <fillcolor red="104" blue="222" green="152" />
         <fillpattern>Dense5Pattern</fillpattern>
         <texturepath></texturepath>

Modified: trunk/qgis/tests/testdata/polys_uniquevalue_symbol.qml
===================================================================
--- trunk/qgis/tests/testdata/polys_uniquevalue_symbol.qml	2008-05-17 09:58:15 UTC (rev 8447)
+++ trunk/qgis/tests/testdata/polys_uniquevalue_symbol.qml	2008-05-17 11:45:55 UTC (rev 8448)
@@ -37,7 +37,7 @@
           <scaleclassificationfield>-1</scaleclassificationfield>
           <outlinecolor red="0" blue="0" green="0" />
           <outlinestyle>SolidLine</outlinestyle>
-          <outlinewidth>1</outlinewidth>
+          <outlinewidth>0.4</outlinewidth>
           <fillcolor red="94" blue="213" green="172" />
           <fillpattern>SolidPattern</fillpattern>
           <texturepath></texturepath>
@@ -54,7 +54,7 @@
           <scaleclassificationfield>-1</scaleclassificationfield>
           <outlinecolor red="0" blue="0" green="0" />
           <outlinestyle>SolidLine</outlinestyle>
-          <outlinewidth>1</outlinewidth>
+          <outlinewidth>0.4</outlinewidth>
           <fillcolor red="59" blue="134" green="49" />
           <fillpattern>SolidPattern</fillpattern>
           <texturepath></texturepath>



More information about the QGIS-commit mailing list