Nyall Dawson
7ba5998db2
Calculate correct legend size when using expression based labels
2019-01-18 20:36:30 +11:00
Nyall Dawson
d70b60d48f
[FEATURE][layouts] Allow expressions to be embedded inside legend item text
...
This feature allows for expressions to be embedded directly inside
legend item text (e.g. group, subgroup and item text). The expressions
are evaluated at render time, with full knowledge of the legend's
expression context (so can utilise variables from the layout/layout item/
etc)
There's no UI for this yet (that will come in 3.8), but expressions are
entered using the standard [% 1 + 2 %] format.
E.g. a legend item text of
My layer (rendered at 1:[% @map_scale %])
will show in the output as
My layer (renderer at 1:1000)
2019-01-18 20:36:30 +11:00
Alex
b43943a9b0
[FEATURE] New expression variables for legend items
...
Adds new variables for use in data defined expressions for layout legend items, including
- @legend_title
- @legend_column_count
- @legend_split_layers
- @legend_wrap_string
- @legend_filter_by_map
- @legend_filter_out_atlas
Additionally, if the legend is linked to a map, then expressions used in that legend will also have access to the linked variables, including @map_scale, @map_extent, etc.
2019-01-18 13:38:21 +11:00
Nyall Dawson
a0e91f3798
Add API to read/write QgsExpressionContextScope from/to XML
2019-01-18 12:56:05 +11:00
Denis Rouzaud
5fa5631bbd
add enum value to key and reverse helpers ( #8879 )
...
* add enum value to key and reverse helpers
* cast cont char* to QString
* use QStringLiteral
2019-01-17 09:40:13 -05:00
Marco Hugentobler
0f3c39deb7
Server: throw exception in GetMap if DB connection is not ok
2019-01-17 08:55:18 +01:00
Nyall Dawson
2aab28380c
[browser] Don't show gdal/ogr layer items for QGIS style xml files
...
These aren't layers, so the extra entries are just distracting noise.
2019-01-16 12:10:25 +11:00
lbartoletti
c885cd7267
add toString and repr for qgsvector
2019-01-16 01:10:33 +11:00
Alex
004d6bae5f
Add QgsRenderContext to QgsLayerTreeModelLegendNode::ItemContext
2019-01-15 13:37:36 +11:00
lbartoletti
edadcb773f
Refactoring of rectangle maptools
...
Adds a new geometry class QgsQuadrilateral, for 4 sided geometries.
2019-01-15 10:24:16 +11:00
Peter Petrik
cd9a84e11c
[feature] [mesh] Mesh Calculator
...
Similarly to raster calculator, mesh calculator can take dataset groups from current mesh layer and
combine them with various aritmentic/logical operators to new dataset group.
2019-01-14 12:32:36 +01:00
Raymond Nijssen
0ba9a326ec
Add API to calculate innerTangents for 2 circles
2019-01-14 05:27:19 +10:00
Nyall Dawson
ac10769809
Move method for detecting project colors to QgsProperty
2019-01-12 18:11:44 +10:00
Nyall Dawson
f7745c94d9
Add a signal to QgsProject for when project color scheme changes
2019-01-12 18:11:44 +10:00
Nyall Dawson
7b664ea9a8
Fix see also link
2019-01-12 05:31:00 +10:00
Nyall Dawson
021f5ea366
[needs-docs][api] Rename QgsDistanceArea methods to change "date line"
...
to "antimeridian"
Because the date line =/= +/-180 degree longitude, which is what
we were incorrectly using it to mean.
2019-01-12 05:31:00 +10:00
Nyall Dawson
a8bd12c4e3
[FEATURE][API] Add method to QgsDistanceArea to split a (multi)line geometry
...
at the antimeridian
Whenever line segments in the input geometry cross the antimeridian, they
will be split into two segments, with the latitude of the breakpoint being
determined using a geodesic line connecting the points either side of this
segment.
If the geometry contains M or Z values, these will be linearly interpolated
for the new vertices created at the antimeridian.
2019-01-12 05:31:00 +10:00
Nyall Dawson
938adb8c17
[api] Add PyQGIS helpers to QgsGeometry.asMultiPoint(), asMultiPolyline()
...
and asMultiPolygon()
- raise ValueError when these methods are called with null geometries
- raise TypeError when these methods are called with incompatible
geometry types, instead of silently returning empty lists
2019-01-11 21:31:14 +10:00
Nyall Dawson
b80829ce59
Remove leftover QObject inheritance
2019-01-11 09:51:04 +10:00
Matthias Kuhn
fd00cd54fe
Merge pull request #8705 from arnaud-morvan/server_diagrams_filter
...
Apply featureFilterProvider in QgsVectorLayerDiagramProvider
2019-01-10 18:02:36 +01:00
Nyall Dawson
32126ca2b8
Add missing since annotation
2019-01-10 19:54:26 +10:00
Nyall Dawson
5c2b39438b
Dox++
2019-01-10 19:54:26 +10:00
Nyall Dawson
c7d09a3261
Fix typo
2019-01-10 19:54:26 +10:00
Nyall Dawson
2a2995aad4
Sipify
2019-01-10 19:54:26 +10:00
Alex
f0ffbeb7be
change bindings again
2019-01-10 19:54:26 +10:00
Alex
12273fa83a
Change bindings
...
Manually inserting the proper binding
2019-01-10 19:54:26 +10:00
Matthias Kuhn
e32c739b47
Make use of QgsProject::mapLayer<QgsVectorLayer *> template
2019-01-09 16:25:45 +01:00
arnaud.morvan@camptocamp.com
948048cd4d
Do not overwrite renderContext in QgsMapRendererJob::drawLabeling
...
Dedicated QgsRenderContext is already created and configured in prepareLabelingJob.
2019-01-09 15:08:37 +01:00
Nyall Dawson
eaad71e0c9
Tweak API
...
Better to use QVector here, because the QgsLineString/QgsGeometry
methods all use QVector too, and we want to avoid unnecessary
list->vector conversions.
2019-01-08 19:48:15 +10:00
Matthias Kuhn
5df5c3763e
Merge pull request #8507 from signedav/basicfix
...
Delete selected tables as DataItem action
2019-01-08 10:42:03 +01:00
signedav
37eec198a8
put message in log instead of message box
2019-01-08 10:15:53 +01:00
Nyall Dawson
13ac907198
latitudeGeodesicCrossesDateLine also returns fraction of segment
...
along which the crossing occurs
2019-01-08 12:32:50 +10:00
Nyall Dawson
adc5c17456
Expose method for calculating latitude geodesic crosses date line to public QgsDistanceArea API
2019-01-08 12:32:50 +10:00
Nyall Dawson
ebd104466e
Add method to retrieve destination CRS from QgsDistanceArea
2019-01-08 12:32:50 +10:00
Nyall Dawson
fdea61a97c
Add method to calculate the geodesic line joining two points to QgsDistanceArea
...
Using geographiclib to calculate the line
2019-01-08 12:32:50 +10:00
Nyall Dawson
63204cfdb5
Fix travis
2019-01-08 11:10:40 +10:00
Nyall Dawson
224df0a273
Add missing documentation for QgsCategorizedRenderer
2019-01-08 11:10:40 +10:00
Nyall Dawson
d32714c899
[API] Allow categorized renderer category values to be lists of values
...
When a category is a list of values, that category will apply to
any of the values from the list
2019-01-08 11:10:40 +10:00
Nyall Dawson
74b96ce955
Dox++
2019-01-08 11:10:40 +10:00
Juernjakob Dugge
c09b379fc7
Rename member variables, remove "forceCartesian" arguments
2019-01-08 09:36:33 +10:00
Juernjakob Dugge
bf5a077e33
Fix typos
2019-01-08 09:36:33 +10:00
Juernjakob Dugge
3e05c99c11
Add centimeter and millimeter based units to Project Properties and Map Tools Options
...
Fix the "map units" option in distance measurements when using geographic coordinate systems
2019-01-08 09:36:33 +10:00
Nyall Dawson
e99072b161
Add method to QgsStatisticalSummary to get a short name corresponding to a stat
...
Returns a short name, suitable for use in a field name
2019-01-04 05:01:40 +10:00
Nyall Dawson
5f817b4db3
Allow QgsStatisticalSummary to calculate first/last value
...
Trivial, but simplifies other code which desires to expose
a choice between first/last/min/max/mean/etc...
2019-01-04 05:01:40 +10:00
signedav
666f95998d
Merge branch 'master' into basicfix
2019-01-03 12:43:20 +01:00
signedav
0373fe73a2
autogenerated sip in file
2019-01-03 12:00:53 +01:00
Nyall Dawson
a441e2b14b
[layouts] Add API allowing drawing map overviews under map layers
...
or under map labels
2019-01-03 04:53:28 +10:00
Nyall Dawson
12da3afa85
[layouts] Add method to alter list of map layers to render to include
...
overview layers
2019-01-03 04:53:28 +10:00
Nyall Dawson
1b309c6810
[layouts] Add setters/getters for map item stacking positions
2019-01-03 04:53:28 +10:00
Nyall Dawson
6eb49feddc
[layouts] Add method to get overview item extent as a vector layer
...
The layer contains a single feature representing the linked map
extent, and set to render using the overview's symbol
2019-01-03 04:53:28 +10:00