6559 Commits

Author SHA1 Message Date
nirvn
c6425338ee [FEATURE] Raster image marker 2018-12-05 15:44:44 +07:00
nirvn
60442980dd Add dox comment, fix travis 2018-12-05 11:14:13 +07:00
nirvn
ad4b876866 Add opacity parameter to image cache 2018-12-05 11:14:13 +07:00
nirvn
ce5636afed Allow passing {width,height}-only size to the image cache 2018-12-05 11:14:13 +07:00
Nyall Dawson
c1df802769 Add method to QgsImageCache to retrieve original image size 2018-12-05 11:14:13 +07:00
Nyall Dawson
84838d1ec6 [FEATURE][API] Add a content cache for raster images
This new class QgsImageCache is the equivalent of QgsSvgCache
but for raster images.

QgsImageCache stores pre-rendered resampled versions of raster
image files, allowing efficient reuse without incurring the
cost of resampling on every render.

Additionally, it offers the other benefits QgsSvgCache has,
such as thread safety, ability to transparently download remote
images, and support for base64 encoded strings.
2018-12-05 11:14:13 +07:00
Nyall Dawson
ff786f2223 Add group method to QgsSettings
Is present in the QSettings API, but missing from QgsSettings
2018-12-05 04:46:58 +10:00
Nyall Dawson
4bca7838bf [processing] Add method for providers to specify a different list
of supported output formats when an output has no geometry
2018-12-03 18:11:24 +10:00
Nyall Dawson
583b602e76 [processing] Fix hasGeometry() method when output is a geometry-less vector table
From the dox for QgsProcessing.TypeVector: "When used for a sink this indicates
the sink has no geometry.". If an algorithm is using this value to indicate
"maybe has geometry" for an output, then that algorithm is incorrect and
should be using TypeVectorAnyGeometry instead.
2018-12-03 18:11:24 +10:00
Alessandro Pasotti
a471934e56 Fix build warning and cl-std for 2.x builds 2018-11-30 16:14:28 +01:00
Alessandro Pasotti
6176159a00 [opencl] Support for platforms > 1.1 2018-11-30 13:41:35 +01:00
Alessandro Pasotti
0af1ce40a8
Merge pull request #8571 from elpaso/bugfix-20601-rastercalc-duplicated-layer-names
Fix rastercalc duplicated layer names
2018-11-30 10:17:38 +01:00
Denis Rouzaud
dde309439c
Merge pull request #8560 from 3nids/locator_context
Add context menu for locator filter results
2018-11-29 15:28:30 -04:00
Nyall Dawson
d72c4d001f [processing] Allow parameter metadata to set the number of decimal places
to show in numeric/distance widgets

E.g. to only show 2 decimal places:

  # only show two decimal places in parameter's widgets, not 6:
  param.setMetadata( {'widget_wrapper':
    { 'decimals': 2 }
  })
2018-11-30 05:02:59 +10:00
Blottiere Paul
b03d8a7f0e
Merge pull request #8551 from pblottiere/bugfix_wms
[server] OGC WMS 1.3.0
2018-11-29 16:36:37 +00:00
Blottiere Paul
51a27b31b1 Update tests 2018-11-29 11:49:58 +00:00
Alessandro Pasotti
49da1c3be9 Return a vector instead of a list and deprecate rasterEntries 2018-11-29 12:46:30 +01:00
Alessandro Pasotti
18854dc7b6 Do not add duplicates in raster calc layers list
Related to #20601
2018-11-29 12:26:57 +01:00
Denis Rouzaud
7bce9342e5 [sipify] fix initializer in strcuts 2018-11-28 07:46:24 -04:00
Alessandro Pasotti
e329fb5b97 Scanline implementation 2018-11-28 10:11:33 +01:00
Alessandro Pasotti
3801e9e28b Added findNodes method and tests 2018-11-28 10:11:09 +01:00
Nyall Dawson
c5549bea48 Update test mask 2018-11-28 08:27:22 +10:00
Nyall Dawson
f595d53d0a Negative indices count from back of linestring 2018-11-27 09:29:13 +10:00
Nyall Dawson
1e5479964f [FEATURE][API] Add some nice PyQGIS methods and exceptions to QgsLineString
- len(QgsCurve) returns number of points in curve
- raise IndexErrors when calling pointN, xAt, yAt, zAt, mAt, setXAt, setYAt,
setMAt, setZAt with invalid vertex indices
- Add [] getter for retrieving specific vertices, eg. ls[0] returns QgsPoint(...)
- Add [] setter for setting specific (existing) vertices, e.g. ls[1] = QgsPoint(1,2)
- Add del support for removing vertices, e.g. del ls[1] removes the second vertex
2018-11-27 09:29:13 +10:00
swiss-knight
b5ad33f639 Add ACCEPT_USE_OF_DEPRECATED_PROJ_API_H macro for proj_api.h to work with new release of proj4.
(cherry picked from commit 6a7e951442d4f4ce57cb7816d9a4e513c4415fba)
2018-11-27 08:44:42 +10:00
Nyall Dawson
1072ebb621 [browser] Add API to access the drive data items 2018-11-26 18:20:08 +10:00
Alessandro Pasotti
256b58085d
Merge pull request #8526 from elpaso/bugfix-20579-ogr-db-layers-name
[ogr] Use table name as base layer name when adding ogr database layers
2018-11-22 12:49:26 +01:00
Alessandro Pasotti
7094ddf18e Use isValid instead of isNull and add a test for gpkg 2018-11-22 11:00:26 +01:00
Martin Dobias
d4ef55dadb
Merge pull request #8509 from wonder-sk/terrain-map-themes
[FEATURE] Optionally use a map theme to render terrain textures
2018-11-22 09:24:27 +01:00
Alessandro Pasotti
84eed010fe [ogr] Use table name as base layer name when adding ogr database layers
Fixes #20579 - Improve layer name rendering for MySQL connections
2018-11-21 19:23:21 +01:00
Martin Dobias
afd3525297 Add test for terrain theme + do not use project singleton 2018-11-21 16:29:42 +01:00
Mathieu Pellerin
d257cf0776 Add a project properties dialog test case 2018-11-21 21:46:50 +07:00
Mathieu Pellerin
4e1d6841ae Avoid more needless project dirtying 2018-11-21 21:46:50 +07:00
Alessandro Pasotti
5171e4e64d
Merge pull request #8520 from elpaso/bugfix-20549-invalid-xml-gfi
[server] Fix invalid xml in getfeatureinfo
2018-11-21 13:32:35 +01:00
Alessandro Pasotti
bb44e2b60b
Merge pull request #8512 from elpaso/docker-testing-env-tests
Docker testing env tests
2018-11-21 13:27:02 +01:00
Denis Rouzaud
d1d3a51efb
Merge pull request #8429 from lbartoletti/extendMapTool
[needs-docs][FEATURE] Trim/extend
2018-11-21 06:36:08 +01:00
Nyall Dawson
e21ea25c66 Add method to set QgsFeature geometry directly from QgsAbstractGeometry
Allows

    feat.setGeometry(QgsPoint(1,2))

instead of the more obscure

    feat.setGeometry(QgsGeometry(QgsPoint(1,2)))
2018-11-21 08:48:55 +11:00
Alessandro Pasotti
0d696ef1e5 [server] Fix invalid xml in getfeatureinfo
Fixes #20549 - error in parsing WMS GetFeatureInfo as XML

Also s/meta/META/ for consistency with all other tags
2018-11-20 18:26:49 +01:00
Alessandro Pasotti
7e00afc2c7
Merge pull request #8510 from signedav/fix_providerIndex
Don't handle defaultValueClause as not unique value
2018-11-20 11:16:28 +01:00
Alessandro Pasotti
ed9709b4fa Copy updated test runner into the docker
Handle -e and do not exit on error
2018-11-20 10:31:05 +01:00
Alessandro Pasotti
e8e66d086b Fix the python test runner and add a test for it 2018-11-20 10:31:05 +01:00
Nyall Dawson
34c217cd46 Fix crash when calculating offset on certain single curves which become multilinestrings when offset 2018-11-20 05:06:06 +11:00
Nyall Dawson
a22422c4bf [FEATURE][API] Add parts iterators to QgsGeometry
This allows easy iteration over all the parts of a geometry,
regardless of the geometry's type. E.g.

geometry = QgsGeometry.fromWkt( 'MultiPoint( 0 0, 1 1, 2 2)' )
for part in geometry.parts():
  print(part.asWkt())

geometry = QgsGeometry.fromWkt( 'LineString( 0 0, 10 10 )' )
for part in geometry.parts():
  print(part.asWkt())

There are two iterators available. QgsGeometry.parts() gives
a non-const iterator, allowing the parts to be modified in place:

geometry = QgsGeometry.fromWkt( 'MultiPoint( 0 0, 1 1, 2 2)' )
for part in geometry.parts():
   part.transform(ct)

For a const iteration, calling .const_parts() gives a const
iterator, which cannot edit the parts but avoids a potentially expensive
QgsGeometry detach and clone

geometry = QgsGeometry.fromWkt( 'MultiPoint( 0 0, 1 1, 2 2)' )
for part in geometry.const_parts():
   print(part.x())
2018-11-20 05:05:37 +11:00
Nyall Dawson
f5a6aef55f Raise IndexError in PyQGIS when calling geometryN on a collection
with an invalid geometry index

And add len operator to QgsGeometryCollection
2018-11-20 05:05:37 +11:00
signedav
32b7d7e5dd check uniqueCheck before overwrite defaultValueClause
and some tests for it
this fixes #20397 and fixes #20431
2018-11-19 16:54:28 +01:00
Denis Rouzaud
b089b57681
Merge pull request #8480 from lbartoletti/rectangle3PointsProjected
[FEATURE][needs-docs]Add map tool: rectangle 3 points (projected)
2018-11-19 15:21:46 +01:00
Blottiere Paul
50e2b76ae7
Merge pull request #8005 from lbartoletti/bugfix_18902
Fixes #18902 Snapping and tracing inconsistent behaviour
2018-11-19 04:49:03 +00:00
Blottiere Paul
0a42a101c4
Merge pull request #8063 from tudorbarascu/test_server
test server rendering debian buster bug
2018-11-16 08:28:28 +00:00
Matthias Kuhn
438a1daf6a
Merge pull request #8442 from signedav/textfield_null
Range widget: Remove null representator during editing
2018-11-16 09:03:13 +01:00
Tudor Bărăscu
2cf8f74c71 test server rendering debian buster bug #18988 2018-11-16 08:49:55 +02:00