32183 Commits

Author SHA1 Message Date
Matthias Kuhn
9b9377fa87 Fixup b6aee93 2016-04-08 19:23:57 +02:00
Even Rouault
d30836ea1a Fix thread-unsafe initialization of QgsExpression::Functions()
The method initializes the gmFunctions static member, without any mutex protection.
This turned out to cause random crashes in the tests of the WFS provider since the downloader
thread may evaluate an expression, in parallel of the main thread, which does the same.
This was mainly seen on Mac Travis (2 crashes + 1 failures, over 50 iterations), when
parallelizing tests so as to get particular scheduling :
https://travis-ci.org/rouault/Quantum-GIS/builds/121720556.
But I could finally reproduce it systematically on my Linux box when inserting the following sleep.

diff --git a/src/providers/wfs/qgswfsshareddata.cpp b/src/providers/wfs/qgswfsshareddata.cpp
index adc7042..e9e4577 100644
--- a/src/providers/wfs/qgswfsshareddata.cpp
+++ b/src/providers/wfs/qgswfsshareddata.cpp
@@ -426,6 +426,7 @@ int QgsWFSSharedData::registerToCache( QgsWFSFeatureIterator* iterator, QgsRecta
     connect( mDownloader, SIGNAL( ready() ), &loop, SLOT( quit() ) );
     mDownloader->start();
     loop.exec( QEventLoop::ExcludeUserInputEvents );
+    usleep( 100 * 1000 );
   }
   if ( mDownloadFinished )
     return -1;

After applying this commit, the Mac builder is fine:
https://travis-ci.org/rouault/Quantum-GIS/builds/121756158
2016-04-08 19:19:49 +02:00
Matthias Kuhn
b6aee93563 Align raster code improvements
* Fix x/y mismatch
 * Improve strings for translation
 * Remove unrequired cast
2016-04-08 18:48:59 +02:00
rldhont
a6aa855631 [BUGFIX] QGIS Server segfault when features does not have the same fields as the layer.
In some WFS GetFeature request, with Filter or FeatureId, all the fields are not well loaded in the feature.

To fix it, we just verifying that the attribute index is lesser than the feature fields count.

Fixes #14619
2016-04-08 15:26:59 +02:00
Matthias Kuhn
e3bfec0d57 Merge pull request #2954 from tomchadwin/master
New custom CSS for https://qgis.org/api/
2016-04-08 14:12:29 +02:00
Denis Rouzaud
c397ae652e allow sorting relations in project properties 2016-04-08 08:22:19 +02:00
Denis Rouzaud
31e6d2853a be sure that layer exists 2016-04-08 07:03:18 +02:00
Denis Rouzaud
54cc56ff41 rename protected variable (starts with m), remove old comment 2016-04-08 07:00:13 +02:00
Denis Rouzaud
3c53817988 regroup duplicated code 2016-04-08 06:57:47 +02:00
Nyall Dawson
85d472e680 Merge pull request #2981 from nirvn/symbol_label_diagram_sync
[ui] add missing icons for no labels and no diagram
2016-04-08 14:13:46 +10:00
nirvn
f0a2d60c81 [ui] make symbol/label/diagram title case consistent 2016-04-08 09:48:11 +07:00
nirvn
7c3ec07aca [ui] add missing icons for no labels and no diagram 2016-04-08 09:48:11 +07:00
Matthias Kuhn
a6a77ee46b Remove remainders of buggy pg test 2016-04-07 22:51:43 +02:00
Matthias Kuhn
5cd2319c3f Also retrieve generated values for pktInt 2016-04-07 21:26:43 +02:00
Matthias Kuhn
eecd77a324 Fix postgres unit test 2016-04-07 21:24:01 +02:00
Matthias Kuhn
e98e16f1b2 Unit test for 4ec97c33 2016-04-07 15:59:22 +02:00
Matthias Kuhn
4ec97c3362 [postgres] Update primary key on insert with pktFidMap
Helps to retrieve generated keys with views
2016-04-07 15:03:41 +02:00
Denis Rouzaud
40f214b415 Revert "add todo QGIS 3: add /In,Out/ to QgsVectorLayer.addFeature (python)"
this works already, features are updated.

This reverts commit bf3f8b5920bc43cf528c9569a3d6b1000f0eef9f.
2016-04-07 14:25:42 +02:00
Matthias Kuhn
5376cbf35e Followup 297f466 pep8 2016-04-07 14:11:03 +02:00
volaya
cc50157ab8 [processing] make gdal algorithms honor selection
fixes #14622
2016-04-07 14:02:25 +02:00
Denis Rouzaud
bf3f8b5920 add todo QGIS 3: add /In,Out/ to QgsVectorLayer.addFeature (python)
https://github.com/qgis/qgis3.0_api/issues/45
2016-04-07 13:29:43 +02:00
Matthias Kuhn
27afd6c4f3 Fix headers 2016-04-07 13:21:23 +02:00
Matthias Kuhn
5e89058921 Followup 297f466 Add missing CMakeLists.txt 2016-04-07 13:21:20 +02:00
volaya
45cb80a0ff [processing] fixed wild import 2016-04-07 12:32:46 +02:00
Nyall Dawson
55301616a2 Merge pull request #2980 from nirvn/diagram_ui_improvement
[diagram] synchronize enabling UI to match labelling
2016-04-07 20:25:34 +10:00
volaya
794ef72520 [processing] added support for QGIS variables in python scripts 2016-04-07 12:03:41 +02:00
volaya
3e4e08bc6f [processing] fixed header 2016-04-07 12:03:40 +02:00
volaya
297f4669fd [processing] added preconfigured algorithms 2016-04-07 12:03:39 +02:00
nirvn
4f87525eec [diagram] synchronize enabling UI to match labelling 2016-04-07 16:23:32 +07:00
Nyall Dawson
9d5df4efb7 Fix indentation 2016-04-07 18:47:01 +10:00
Nyall Dawson
846c6183ca Initially set focus to text in new name dialog 2016-04-07 18:47:01 +10:00
Nyall Dawson
39d0ba5781 [composer] Fix crash setting table columns from python 2016-04-07 18:47:01 +10:00
Nyall Dawson
fde77d35aa Remove use of c style function(void) 2016-04-07 18:47:01 +10:00
Jürgen Fischer
19b91032bd Merge pull request #2977 from rouault/wfs
First part of QEP 35: WFS provider enhancements
2016-04-07 10:18:22 +02:00
Juergen E. Fischer
5895780553 fix internal future install (fixes #14577, take II) 2016-04-07 09:08:02 +02:00
Jürgen Fischer
60ada1185e Merge pull request #2946 from sebastic/debian
Debian packaging improvements
2016-04-07 08:59:58 +02:00
Bas Couwenberg
100c96c3a8 Add python-shapely to python-qgis-common dependencies.
Closes Debian Bug #820281 (https://bugs.debian.org/820281).
2016-04-07 07:15:48 +02:00
Nyall Dawson
99980bea0c Fix windows build 2016-04-07 09:14:16 +10:00
Nyall Dawson
3ba3986ae2 Fix calculation of diagram size in map units when using scale limits 2016-04-06 22:27:07 +10:00
Nyall Dawson
ece46d1c43 Fix margins on photo and web view edit widgets 2016-04-06 21:05:00 +10:00
Nyall Dawson
76282d5022 Fix layout issues with color button editor widget
- widget was not left aligned
- widget would shrink to a small vertical height in crowded forms
2016-04-06 21:04:51 +10:00
Nyall Dawson
4c704be606 Add geometry methods for calculating the distance to a specified
vertex from the start of the geometry
2016-04-06 20:55:26 +10:00
Nyall Dawson
d464f86290 [FEATURE] Null ("No symbol") renderer
Using this renderer no symbol will be drawn for features, but labeling,
diagrams and other non-symbol parts will still be shown.

Selections can still be made on the layer in the canvas and selected
features will be rendered with a default symbol. Features being edited
will also be shown.

This is intended as a handy shortcut for layers which you only want
to show labels or diagrams for, and avoids the need to render
symbols with totally transparent fill/border to achieve this.

(fix #12131)
2016-04-06 20:55:26 +10:00
Nyall Dawson
86ec27e08e Use real values when interpolating color components in gradients 2016-04-06 20:55:26 +10:00
Nyall Dawson
fd7a4bd900 [FEATURE] New project(point, distance, bearing) expression function
Projects a point geometry by the specified distance and bearing
2016-04-06 20:55:26 +10:00
Nyall Dawson
2e44c11914 Some QgsPoint improvements
- Modernize QgsVector, improve docs, add some methods missing from
Python bindings
- Add method to QgsPoint to project a point by a specified distance
and bearing
- Add distance methods to complement existing sqrDist squared distance
methods
- Rename QgsVector::normal to normalized (avoid confusion with normal
vectors)
- Add more QgsPoint operators
- Add some more QgsPoint and QgsVector tests
2016-04-06 20:55:26 +10:00
Nyall Dawson
3a1f6c429d Improve documentation for QgsGeometry::closestVertex 2016-04-06 20:55:26 +10:00
Nyall Dawson
5247673cda Add some provider tests for empty rectangles 2016-04-06 20:55:26 +10:00
Nyall Dawson
619b32de5b Fix build with Qt5 <5.5 2016-04-06 20:55:26 +10:00
Matthias Kuhn
4586a787b0 Move AutoTransaction setting to project properties
Was in global app settings
2016-04-06 12:17:38 +02:00