24182 Commits

Author SHA1 Message Date
qgis-bot
7d374b248e auto sipify 🍺 2024-11-19 11:09:39 +00:00
Nyall Dawson
2abc9d92ca [sld] Don't try to write rules/categorizes without symbolizers
Only create rules/categorized categories/graduated ranges if the
associated symbol could be converted to SLD, and is not an "empty"
symbol.

Otherwise we do not generate a rule, as SLD spec requires a
Symbolizer element to be present.
2024-11-19 21:06:26 +10:00
qgis-bot
45a0abf3be auto sipify 🍺 2024-11-19 02:43:51 +00:00
Nyall Dawson
f446bda82a [optimisation] Greatly speed up clone of QgsSvgMarkerSymbolLayer
The old method was very inefficient, as it required a re-load and
re-parse of the associated SVG file content with every clone, only
for many of the parsed properties to be immediately overwritten.

Optimise by just directly copying members, avoiding all unnecessary
work.

This is frequently seen as a hotspot when profiling map renders,
as that involves cloning all symbol layers upfront.

Speeds up a benchtest cloning 100k markers from 4.3 seconds to
150ms.
2024-11-19 12:40:44 +10:00
qgis-bot
c3432328fc auto sipify 🍺 2024-11-19 01:18:45 +00:00
Nyall Dawson
7a17557e64 Refactor QgsTextRenderer internal methods, optimise buffer render
Rework internals of QgsTextRenderer horizontal text rendering,
so that:

1. It's easier to read, cleaning up years of accumulated cruft
2. Split out bits into smaller functions
3. Reduce the amount of duplicate code for text layout, so that
there's only one function responsible for horizontal text layout
instead of multiple
4. Add shortcut optimisations for rendering text + buffer/shadow
at the same time, instead of always drawing these completely
independantly of each other and incurring the cost of text path
calculation multiple times for the same bit of text. In a simple
benchtest this reduces the time required for rendering many
text fragments with buffers from 40 seconds to 27 seconds.

There's still more we could do here, but it's a start...
2024-11-19 11:15:34 +10:00
qgis-bot
c41be037d9 auto sipify 🍺 2024-11-15 21:31:40 +00:00
Harrissou Sant-anna
6648c9596c s/if/whether 2024-11-16 07:28:29 +10:00
Harrissou Sant-anna
ac3c06d3ad Rewording and formatting in PyQGIS docs 2024-11-16 07:28:29 +10:00
Denis Rouzaud
3e085e496b move read/write XML for QgsMapThemeCollection::MapThemeRecord inside class 2024-11-16 07:24:58 +10:00
qgis-bot
3958320887 auto sipify 🍺 2024-11-13 23:57:57 +00:00
Nyall Dawson
739b9249c4 Apply suggestions from code review 2024-11-14 09:54:48 +10:00
Yoann Quenach de Quivillic
ea75091351 Switch to QWebEngineView if available 2024-11-14 09:54:48 +10:00
Yoann Quenach de Quivillic
b2f3876e38 Apply suggestions from review 2024-11-14 09:54:48 +10:00
Yoann Quenach de Quivillic
ff2f1f0e3f Remove python parameter and add context menu actions 2024-11-14 09:54:48 +10:00
Yoann Quenach de Quivillic
7e9a098b31 Show API Documentation on F1 2024-11-14 09:54:48 +10:00
Yoann Quenach de Quivillic
08ae213fc0 Add settings 2024-11-14 09:54:48 +10:00
Yoann Quenach de Quivillic
c851835729 add showApiDocumentation method 2024-11-14 09:54:48 +10:00
Yoann Quenach de Quivillic
25480e872c Interactive Help on F1 2024-11-14 09:54:48 +10:00
Yoann Quenach de Quivillic
2067abc02d Add helpRequested signal 2024-11-14 09:54:48 +10:00
qgis-bot
a39e1e37b8 auto sipify 🍺 2024-11-12 07:55:35 +00:00
Nyall Dawson
2889aa375b Fix use-after-free 2024-11-12 08:49:18 +01:00
Nyall Dawson
3e1c84e07e Finalize sinks to get proper error reporting when flushing features
Fixes #59237
2024-11-12 08:49:18 +01:00
Nyall Dawson
20405003aa QgsProxyFeatureSink should forward flushBuffer to underlying sink 2024-11-12 08:49:18 +01:00
Borys Jurgiel
00eccb460f Follow up #fa292ca7d49a50a 2024-11-12 08:36:17 +10:00
Borys Jurgiel
e1de76d763 Make plugin watchdog considering timestamp of last run. Fixes #59370 2024-11-12 08:36:17 +10:00
qgis-bot
5acffdaeda auto sipify 🍺 2024-11-11 03:04:52 +00:00
Nyall Dawson
656eb4ccc6 Add AllNumeric value, QGIS 4.0 todo note 2024-11-11 13:01:42 +10:00
Nyall Dawson
c03f550f0f Maintain API 2024-11-11 13:01:42 +10:00
Nyall Dawson
1a4bd44937 Rename field to extremum_type 2024-11-11 13:01:42 +10:00
Nyall Dawson
ac23e5d7da Address review 2024-11-11 13:01:42 +10:00
Nyall Dawson
2890df089d [feature] Add raster zonal min/max algorithm
This algorithm extracts point features corresponding to the minimum
and maximum pixel values contained within polygon zones.

The output will contain one point feature for the minimum and one
for the maximum raster value for every individual zonal feature
from a polygon layer.
2024-11-11 13:01:42 +10:00
qgis-bot
fda2aa46e9 auto sipify 🍺 2024-11-09 22:55:18 +00:00
Nyall Dawson
cf9007658e Show units in tab position widget 2024-11-10 09:52:14 +11:00
Nyall Dawson
7c2b4e011a Add missing since 2024-11-10 09:52:14 +11:00
Nyall Dawson
40d41ddee3 Add GUI to edit tab stop distances 2024-11-10 09:52:14 +11:00
Nyall Dawson
7badf62596 [api] Add tab positions list for QgsTextFormat
Allows setting a list of custom tab stop distances, instead
of just a single distance
2024-11-10 09:52:14 +11:00
Nyall Dawson
0cccf4c42b Support CSS margins for block elements in HTML labels
Adds support for CSS margin properties for block elements in
the text renderer. Specifically:

- This is available for block type elements only, eg DIV, P, H1-H6.
- Margins are NOT available for spans or other non-block content (due to Qt
  limitations)
- Margins can be specified in pt units only
- Margins can be specified either via "margin-left: 5pt; margin-right:
  10pt" etc, or "margin: 5pt 0pt 10pt 0pt"
- Negative margins are supported for the bottom margin ONLY (due to Qt
  limitations)
2024-11-10 09:51:55 +11:00
Nyall Dawson
5a7fbaac1b Convert block margins to QgsTextBlockFormat margins 2024-11-10 09:51:55 +11:00
Nyall Dawson
e9a51d6806 Add repr for QgsMargins 2024-11-10 09:51:55 +11:00
qgis-bot
f58c6ac345 auto sipify 🍺 2024-11-08 11:47:35 +00:00
Martin Dobias
5a6b07e22a Nyall's review 2024-11-08 12:44:27 +01:00
Martin Dobias
13251c2bf1 Make tessellator not flip axes and use the new option in QGIS code
We add a new setOutputZUp(true) option to QgsTessellator so that
the coordinates on output do not get flipped from [x,y,z] to [x,-z,y].

The default is still the old behavior with flipped axes (to make sure
we do not break the API), but all uses in the QGIS code were upgraded
to use the new option.

This means we do not need to add rotation to polygon / buffered line
symbol's 3D entities in 3D map views (and there's only translation left, yay!)
2024-11-08 12:44:27 +01:00
qgis-bot
b033b2d3e0 auto sipify 🍺 2024-11-06 23:17:04 +00:00
Nyall Dawson
ace375b686 Move raster iteration progress calculation to raster iterator class 2024-11-07 10:13:55 +11:00
Nyall Dawson
a7bd4f3bf2 [processing] Add algorithm to extract min/max pixel from raster
This algorithm extracts extrema (minimum and maximum) values
from a given band of the raster layer.

The output is a vector layer containing point features for
the selected extrema, at the center of the associated pixel.

If multiple pixels in the raster share the minimum or maximum
value, then only one of these pixels will be included in the output.

The algorithm uses raster iterator to remain efficient on huge
rasters, and does not require reading the entire raster to
memory
2024-11-07 10:13:55 +11:00
qgis-bot
ac976be6e5 auto sipify 🍺 2024-11-05 05:45:03 +00:00
Juho Ervasti
47b812bb9b
Don't allow non-polygon avoid intersection layers (#59331) 2024-11-05 06:41:56 +01:00
qgis-bot
342a92c5f9 auto sipify 🍺 2024-11-05 00:11:03 +00:00
Nyall Dawson
f3fb1b87c8 [api] Add methods to find min/maximum value in QgsRasterBlock 2024-11-05 11:07:54 +11:00