1782 Commits

Author SHA1 Message Date
Matthias Kuhn
acbfb424b8 [joins] Disable caching if editing is enabled
Fixes https://github.com/qgis/QGIS/issues/35403
2020-03-27 10:59:25 +01:00
Nyall Dawson
320fecce00 [processing] Add method to encode and decode a combined provider key and uri
to a single string

We need this to allow processing inputs to load non gdal/ogr/mdal sources, such
as being able to directly read postgis layers without loading them into a project first
2020-03-26 11:55:45 +10:00
Alessandro Pasotti
5b965ce704 PyQgis: don't crash on invalid provider
Related to #35354
2020-03-26 10:52:32 +10:00
Ivan Ivanov
6a0ae060bc Added new static QgsFieldModel::fieldToolTipExtended 2020-03-26 09:05:49 +10:00
Ivan Ivanov
050dfce89a FIX #15144 add tooltip on fields in identify window / attribute window / feature form
- added new `QString QgsField::displayType( const bool showConstraints = false )` to unify the display of field types whenever length or precision are present
- added new argument `expression` to `QgsFieldModel::fieldToolTip( const QgsField &field, const QString &expression = QStringLiteral() )`. Now the tooltip shows "<alias> (<field>)\n<type>\n<comment>\n<expression>" with appropriate formatting
- added meaningful field tooltips in the "Identify Results" dialog
- field tooltips show the same content in "Feature Attributes" form, "Attribute Table" and "Identify Tool"

Fixes #15144
2020-03-26 09:05:49 +10:00
Nyall Dawson
1915a16bf3 Port extent parameter to new c++ API widget wrapper 2020-03-25 19:25:40 +10:00
Nyall Dawson
488c8c739a Fix loss of callback when invalid geometry handling method is set through
source definition
2020-03-25 09:42:17 +10:00
Nyall Dawson
afbe727c1a Allow serialization of QgsProcessingFeatureSourceDefinition through QgsXmlUtils 2020-03-25 09:42:17 +10:00
Nyall Dawson
6e2c21eb55 [processing] Cleanup handling of "iterate over source" buttons, move
creation completely to widget wrapper
2020-03-25 09:42:17 +10:00
Vincent Cloarec
34d44c08ed
[MESH] Resampling from vertex values to face values (#35264)
[FEATURE] Implements resampling from values on vertices to values on faces with the neighbor average method. (note that resampling method for datasets defined on faces, e.g., the value on vertices is calculated from value on faces was added in the previous QGIS release)

The default method is set to "none" for resampling from vertices to faces and to "neighbor average" for resampling from faces to vertices. Then the default rendering is now always smooth.
2020-03-24 10:03:54 +01:00
Vincent Cloarec
20a7ed44ac
[FEATURE][MESH] coloring mesh vector dataset with color ramp shader (#35216)
fixes #33978 Allows user to color the mesh layer vector dataset (arrow, stream lines, traces) with color ramp shader depending on the magnitude of the vector.
2020-03-24 09:58:48 +01:00
Nyall Dawson
28467f2ad0 Sipify 2020-03-24 10:53:50 +10:00
Nyall Dawson
b0474d7fd3 [processing] Hookup backend API allowing features sources to be
limited to a specific maximum number of features, and allowing
per-source overriding of the default "invalid geometry" handling behavior
2020-03-24 10:53:50 +10:00
Nyall Dawson
78d445ee65 [FEATURE] Add numeric formatter "fraction" style
This style represents decimal numbers as vulgar fractions, e.g.
"3/4" instead of 0.75.

Options include using Unicode superscript and subscript characters
for nicer typography, e.g. ¹⁷/₂₃ (this is the default mode, disabling
this option uses the "17/23" format). An option also exists for
using dedicated unicode characters for specific fractions (where
a unicode character exists), e.g. ½ or ¾

Ultimately this allows for creation of scalebars with fractional
representations of distances, e.g. 0 ----- ½ ----- 1 km
(instead of 0 ------ 0.5 ------ 1km)

Fixes #21289

Sponsored by SLYR
2020-03-23 14:24:37 +10:00
Nyall Dawson
b63018520e Cleanup scalebar widget enabling code by adding flags to QgsScaleBarRenderer
subclasses, so that the subclass itself can indicate what settings
it respects and we can avoid all the hardcoded logic in the configuration
widget
2020-03-23 03:08:50 +10:00
Nyall Dawson
4079878dfb Rename API methods as requested 2020-03-23 03:08:50 +10:00
Nyall Dawson
1887846a5c [FEATURE][layouts] Add "hollow" scalebar style
This matches the "hollow" scalebar style from ArcMap, and is a style
used in South African mapping standards

Fixes #20390

Sponsored by SLYR
2020-03-23 03:08:50 +10:00
Nyall Dawson
e7cc8307e4 [FEATURE][layouts] Add "Stepped Line" scalebar style
Designed to match the appearance and behavior of the ArcMap equivalent,
this was a scalebar format which was previously impossible to replicate
in QGIS.

Also fixes #26589

Sponsored by SLYR
2020-03-23 03:08:50 +10:00
Nyall Dawson
2c01373d1a Fix build 2020-03-22 16:41:31 +10:00
Nyall Dawson
1e3e205a98 Fix deprecation warning 2020-03-22 16:41:31 +10:00
Nyall Dawson
e82a2e4df1 [FEATURE][layouts] Also allow full fill symbols to be used for single box
and double box fill styles

Sponsored by SLYR
2020-03-22 16:41:31 +10:00
Nyall Dawson
9378dcd73f [FEATURE][layouts] Allow scalebar line style to be set using
standard QGIS line symbols

Instead of the previous settings of scalebar line color/width/cap styles,
we now expose the option as a full line symbol for more advanced styling

Also some code cleanups

Sponsored by SLYR
2020-03-22 16:41:31 +10:00
Mathieu Pellerin
f3e2ef1fe7
[FEATURE][symbology] Add data-defined property to font family/style for font markers (#35224) 2020-03-22 12:24:09 +07:00
Mathieu Pellerin
07570562fc
[FEATURE][symbology] Add a font style setting for font markers (#35197) 2020-03-21 12:11:16 +07:00
Nyall Dawson
7994490336 Sipify 2020-03-21 08:32:39 +10:00
Nyall Dawson
b45203a6c4 Make a proper registry for scalebar renderers 2020-03-21 03:45:24 +10:00
lbartoletti
364dc3fd4f
Fix multi split for multilinestring (#34510)
* Fix multi split for multilinestring
2020-03-20 13:23:11 +01:00
Alexander Bruy
4284cc19d9 fix mesh layer SIP bindings 2020-03-19 11:49:31 +02:00
Nyall Dawson
880874bfb6 [layouts][FEATURE] Rework picture item UI and behavior
Adds an explicit choice between SVG or raster image sources,
which allows us to clean up the configuration panel for layout pictures
by hiding options which don't apply to a certain picture source. Also permits
us to:
- Reuse the standard svg selector tree widget, which loads images
in a background thread and fixes #17061
- Uses the standard SVG and image selector line edit, which permit
drag and drop of images and expose options to embed images
and link to online sources

Ultimately this is motivated by a desire to allow users to embed
images in layouts and layout templates

Sponsored by SLYR
2020-03-19 13:18:47 +10:00
David Signer
81317996be reading of all the custom properties to e.g. copy them to the offline project 2020-03-18 10:48:25 +10:00
Denis Rouzaud
ac40ed4fe6 fix sip 2020-03-18 10:04:52 +10:00
Ivan Ivanov
9dc1ade0b5 Reorder the code; Add more context to the algorithm locator; Add more tests 2020-03-18 03:02:28 +10:00
Ivan Ivanov
9e75e3b542 Add fuzzy search to all possible locator filters; Move to StringUtils::fuzzySearch; Add some tests (that helped!) 2020-03-18 03:02:28 +10:00
Ivan Ivanov
5241d64dcb code formatting 2020-03-18 03:02:28 +10:00
Nyall Dawson
dee6f3f30d Add flag to allow a child algorithm's results to prune back the remaining model branches
When an algorithm returns this flag, and after executing it in a model it doesn't set a
certain output which remaining model algorithms depend on, then these branches are
pruned back and don't get executed for the model run.

Allows for creation of algorithms which impact the overall model flow.
2020-03-18 02:52:37 +10:00
Matthias Kuhn
2770e2c327
Merge pull request #35035 from m-kuhn/value_relation_description
Add description to value relation widget
2020-03-17 15:32:46 +01:00
Nyall Dawson
cb883b0610 Add capability for determining whether a spatial index exists (implemented
for GPKG, spatialite) and deleting a spatial index (implemented for GPKG)
to database connection
2020-03-17 15:10:53 +10:00
Nyall Dawson
6a4b67f770 Add API for creating spatial indexes to QgsAbstractDatabaseProviderConnection 2020-03-17 15:10:53 +10:00
Harrissou Sant-anna
50c4efb6ca Fix corresponding dox and update debug message 2020-03-17 10:21:30 +10:00
Harrissou Sant-anna
21f39d127e Fix deprecated method redirection 2020-03-17 10:21:30 +10:00
Nyall Dawson
517aa9667b [processing] Port DestinationSelectionPanel to c++
This is basically a 1:1 port (+some fixes relating to incorrect signal
emissions and many more tests)
2020-03-17 07:24:40 +10:00
Nyall Dawson
40d5efce9b Add QgsConnectionRegistry
This registry provides a convenient place to add API relating
to generic connection fetching and handling methods

Currently contains a single method, which allows for retrieving
matching connections using a "provider://name" format (e.g.
"postgres://my connection")
2020-03-16 19:34:25 +10:00
Nyall Dawson
edd0635fe3 [processing] Move responsiblity for creation of file filter strings from python to c++ 2020-03-16 10:08:46 +10:00
Nyall Dawson
51f40f7180 Add interface class QgsFileFilterGenerator for classes which can generate a file filter string 2020-03-16 10:08:46 +10:00
Alexander Bruy
47070a7d7b
Merge pull request #35076 from alexbruy/maplayer-datatype
Data type support for QgsProcessingParameterMapLayer
2020-03-15 16:14:20 +02:00
Nyall Dawson
7b1975ba83 Optionally allow entry of new table names in table name parameter 2020-03-14 16:57:14 +10:00
Nyall Dawson
30fbf24f8f Add API to show empty entries in QgsDatabaseTableComboBox 2020-03-14 16:57:14 +10:00
Nyall Dawson
513966ca80 [feature][processing] Add dedicated parameter type for database tables
Allows selection of an existing database table for a specific
database provider connection (the provider must implement the connections API)
2020-03-14 16:57:14 +10:00
Nyall Dawson
cf310c5d45 Add API to show empty entries in QgsDatabaseSchemaComboBox 2020-03-14 16:57:14 +10:00
Nyall Dawson
93c917f7b6 [feature][processing] Add dedicated parameter type for database schemas
Allows selection from the existing database schema for a specific
database provider connection (the provider must implement the connections API)
2020-03-14 16:57:14 +10:00