20074 Commits

Author SHA1 Message Date
Nyall Dawson
1537d393e3 Add framework for retrieving the temporary results of a in-progress
edit operation on an annotation item

This is used for the item to return a representative geometry
of what the item would look like if the operation were to be
applied. It's used to generate a rubber band showing a preview
of the modification during interactive editing operations on
an annotation item.
2021-09-10 15:01:26 +10:00
Nyall Dawson
1fe874315a Add method to apply a annotation item edit operation directly
onto a QgsAnnotationLayer
2021-09-10 15:01:26 +10:00
Nyall Dawson
631343265d Allow QgsAnnotationItemEditOperationMoveNode operations to be
applied to annotation items to move nodes in the item
2021-09-10 15:01:26 +10:00
Nyall Dawson
a87206dbdf Create QgsAbstractAnnotationItemEditOperation as base class for
edit operations on annotation layers, with initial implementation
as QgsAnnotationItemEditOperationMoveNode

This class encapsulates edit operations which apply to annotation
layers/items
2021-09-10 15:01:26 +10:00
Nyall Dawson
5ed05fadca Add an id number to QgsAnnotationItemNode 2021-09-10 15:01:26 +10:00
Martin Dobias
1a8ff84791 [feature] Transactions in MSSQL provider 2021-09-09 08:07:21 -07:00
Vincent Cloarec
be3a9e7564
reindex/renumbering mesh layer (#44969)
[mesh] [feature] reindex/renumbering mesh layer

Co-authored-by: PeterPetrik <zilolv@gmail.com>
2021-09-09 12:18:31 +02:00
Vincent Cloarec
46013949fb
Force mesh by polylines (#44962)
[mesh] [feature] allow modify mesh frame elevation by force/break lines
2021-09-09 10:26:32 +02:00
Vincent Cloarec
45e07dd72f
Select mesh elements by expression UI (#44835)
[mesh] [feature] Select mesh elements by expression
2021-09-09 08:29:45 +02:00
Nyall Dawson
b8f65cbf01 Promote temporal related enums to enum classes, move to Qgis 2021-09-09 14:56:47 +10:00
Richard Duivenvoorde
b5952c1638 Sipify all 2021-09-09 08:07:48 +10:00
Richard Duivenvoorde
9b1894cf46 Sipify and indentation 2021-09-09 08:07:48 +10:00
Nyall Dawson
bd8a8d5744 Spelling 2021-09-08 17:58:08 +10:00
Nyall Dawson
ec9d5268f9 Allow QgsMapToolCapture subclasses to bypass geometry validation 2021-09-08 17:58:08 +10:00
Nyall Dawson
e7ce050e18 Allow QgsMapToolCapture subclasses to create tools which are associated
with a specific map layer, instead of always following the current
canvas layer
2021-09-08 17:58:08 +10:00
Nyall Dawson
e7faf956b6 Remove another restriction on QgsMapToolCapture preventing non-vector
use of this class
2021-09-08 17:58:08 +10:00
Nyall Dawson
c8ac971dd8 Remove -1 return code for QgsMapToolCapture::addVertex
This code corresponded to a "not a vector layer" error, which needlessly
prevents the QgsMapToolCapture class from being usable as a base class
for map tools which operate on non-vector layers.
2021-09-08 17:58:08 +10:00
Nyall Dawson
d43c575ff3 Don't force a vector layer to be used for QgsRubberBand::addGeometry
There's no reason to restrict this call solely to vector layers
-- it's useful to have accessible for adding geometries associated
with other layer types too.
2021-09-08 17:58:08 +10:00
Nyall Dawson
ef25d914e6 Rework API to use composition pattern instead of direct inheritance
If we require all annotation item map tools to inherit from
QgsMapToolAdvancedDigitizing, then we lose the flexibility to
subclasss other map tools for annotation item creation (e.g.
QgsMapToolCapture)
2021-09-08 15:32:15 +10:00
Nyall Dawson
24089aa34a Automatically open annotation properties and focus an appropriate
widget after creating a new annotation
2021-09-08 15:32:15 +10:00
Nyall Dawson
303cb455e0 Point text annotations can be created 2021-09-08 15:32:15 +10:00
Nyall Dawson
01226a3294 [annotations] Add framework for map tools for creating new annotation
items
2021-09-08 15:32:15 +10:00
Alexander Bruy
3a082f5738 tests for r.path algorithms 2021-09-08 07:26:15 +10:00
Giovanni Manghi
e3a159f102 make parameters mandatory 2021-09-08 07:26:15 +10:00
Giovanni Manghi
91b1d2e98e split tool 2021-09-08 07:26:15 +10:00
Giovanni Manghi
dfc2d7408b add GRASS r.path 2021-09-08 07:26:15 +10:00
David Marteau
f7cc194efd xpose single vector tile encoding method 2021-09-07 04:51:34 -07:00
Nyall Dawson
76e20c608e Correctly set context for annotation items (map canvas, message bar) 2021-09-07 18:44:57 +10:00
Nyall Dawson
adcd793b89 Add QgsAnnotationItemCommonPropertiesWidget widget for controlling
common properties of annotation items (e.g. reference scale, z order)

And include this in the point text item configuration widget
2021-09-07 18:44:57 +10:00
Francesco Bursi
d602f77a33
Add if() function to raster calculator (#44839)
* start to work on new branch for conditional statement

* adjust the layout

* some pseudocode

* start to design the type tFunct, that should lead to the conditional statement

* modify the raw with a smart pointer

* change the test method and some other parts in the tFunct type

* complete the conditional statement option and update the test

* change evaluation method

* some optimization in the evaluation method

* minor adjustment

* minor adjustmentto test method

* add the button to the ui and some change to the code

* add a comment

* modify the parser and lexer in order to let the raster calc work with case-insensitive IF/if/If/iF

* change some parts according to the review and simplify the test method

* minor changes

* modify comment

* minor changes to enum type (tFunction)

* add some parts to test toString()  method

* add the possibility to use scalar condition in eveluationFunction() method and the corresponding test code

* update toString method

* update and optimize toString method

Co-authored-by: franc <Franc-Brs>
2021-09-07 09:48:12 +02:00
Nyall Dawson
6d926d4ffe Add method to create rubber band geometry for an annotation item 2021-09-07 15:48:17 +10:00
Nyall Dawson
8d1f2bf7a6 Add a method to transform QgsAnnotationItems using a QTransform
transform
2021-09-07 15:48:17 +10:00
Nyall Dawson
4f1fc3b1a4 Always refetch the current item from the layer and then update it
when we are editing annotation items, as properties of the item
which aren't exposed in the widget (e.g. it's geometry) may
have changed in the meantime and we don't want to lose those.
2021-09-07 15:48:17 +10:00
Nyall Dawson
ac4d252b1a [annotations] Pressing delete while an annotation item is selected
will delete the item
2021-09-07 15:48:17 +10:00
Nyall Dawson
d16254e0a3 Add QgsMapToolModifyAnnotation::selectionCleared signal 2021-09-07 15:48:17 +10:00
Nyall Dawson
46f1957cee [api] Annotation items can have their symbology reference scale set
This is especially important for annotation items, where users will
want to create text items with text which scales up and down with
the map.
2021-09-07 14:57:57 +10:00
Nyall Dawson
837dd24858 Make it easier for annotation item subclasses to correctly
copy/read/write common base class properties
2021-09-07 14:57:57 +10:00
Nyall Dawson
9b477ba10d Fix crash when very large coordinates are stored in
QgsRenderedItemResults spatial index
2021-09-07 12:56:04 +10:00
Nyall Dawson
ae17baa737 Add method to erase results from specific layers to
QgsRenderedItemResults
2021-09-07 12:56:04 +10:00
Nyall Dawson
a8b6f89316 Fix naming clash 2021-09-07 10:35:02 +10:00
Nyall Dawson
77466dadaa Fix doxygen warning 2021-09-07 10:35:02 +10:00
Nyall Dawson
48715202f7 When the modify annotation tool is used to select an annotation item,
show a panel in the layer styling dock allowing users to modify
the appearance of the annotation
2021-09-07 10:35:02 +10:00
Nyall Dawson
38b8b82674 Add method to replace an existing item in an annotation layer 2021-09-07 10:35:02 +10:00
Nyall Dawson
39263a421f Add new class QgsMapLayerConfigWidgetContext
This class encapsulates the context in which a map layer config
widget is being shown (e.g. the corresponding map canvas, message
bar and other properties useful for the config widgets)
2021-09-07 10:35:02 +10:00
Nyall Dawson
c7c7b6dd1e [api] Create annotation item gui registry
This registry is attached to QgsGui and handles registration of
functions which create widgets for modifying QgsAnnotationItems

Modeled heavily off the print layout API
2021-09-07 10:35:02 +10:00
Nyall Dawson
758b33ed2e [api] Add initial framework for QgsMapToolModifyAnnotation
This is the start of a map tool for interactive editing of items
in annotation layers. Currently it supports selecting items, and
pre-highlighting their nodes as the cursor is moved over the items.

(Not exposed in QGIS gui yet)
2021-09-07 10:35:02 +10:00
Germán Carrillo
c1dcb2c717 Plugin dependencies followup: load dependent plugins after their dependencies on QGIS startup 2021-09-07 09:07:50 +10:00
Matthias Kuhn
0555d11042
Merge pull request #44266 from domi4484/labelRotationUnit
[labeling] specify unit for data defined label rotation
2021-09-06 10:45:00 +02:00
Mathieu Pellerin
4d2c24e850 [processing] Adjust st-dbscan algorithm to new duration parameter, change default unit to hours 2021-09-06 16:57:36 +10:00
Damiano Lombardi
3ce3a2bfa1 Better decimals parameter description 2021-09-06 08:33:18 +02:00