Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Import/export 'DXF Export' dialog settings from/to XML #35

Closed
wants to merge 70 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
70 commits
Select commit Hold shift + click to select a range
d515c62
qgswfsgetfeature: Do not invert axis if no SRSNAME is passed
ptitjano Nov 2, 2023
8d1c785
qgswfsgetfeature: Add a comment to explain axis inversion logic
ptitjano Nov 13, 2023
fa34fb7
Browser: fix slow behavior with network drives on windows
elpaso Mar 14, 2024
9beccf3
correcty save cache in GH actions (#56856)
3nids Mar 14, 2024
e0d8666
Bump follow-redirects in /resources/server/src/landingpage
dependabot[bot] Mar 14, 2024
95bae0e
[processing] Avoid non-spatial vector layers in DXF export alg
gacarrillor Mar 12, 2024
124f93b
[tests] Tests for avoiding non-spatial vector layers in DXF export alg
gacarrillor Mar 12, 2024
f1ed461
Apply code review suggestion
gacarrillor Mar 14, 2024
c4272d7
Get rid of leftover lines in DXF Export
gacarrillor Mar 14, 2024
b0f8eed
[plugins manager] Normalize _all_ version references
nirvn Mar 15, 2024
ea27b5a
Merge pull request #56855 from elpaso/bugfix-gh51710-partial-fix-atte…
elpaso Mar 15, 2024
d9a6dc8
Merge pull request #56840 from ptitjano/wfs-feature-axis-invert
elpaso Mar 15, 2024
844f0cc
Switch to conditional protobuf-lite target
m-kuhn Mar 15, 2024
5d29d49
[api] Add virtual QgsRasterRenderer::setInputBand method
nyalldawson Mar 14, 2024
17111a8
Don't crash when calling QgsHillshadeRenderer::setBand if input is no…
nyalldawson Mar 14, 2024
e297f54
Add some see links
nyalldawson Mar 14, 2024
5f4218a
Always check input band
nyalldawson Mar 14, 2024
2556a66
Also add virtual inputBand getter
nyalldawson Mar 14, 2024
4a0bc4a
Deprecated subclass methods
nyalldawson Mar 14, 2024
8426fa2
Move paletted raster renderer tests to own file
nyalldawson Mar 15, 2024
bbf2861
Add tests for paletted renderer input band
nyalldawson Mar 15, 2024
3cb235e
Add unit tests for hillshade renderer
nyalldawson Mar 15, 2024
da79086
Test input band logic for contour renderer
nyalldawson Mar 15, 2024
ac0b0a5
Add some tests for QgsSingleBandColorDataRenderer
nyalldawson Mar 15, 2024
3b8d0b7
Add tests for singleband gray renderer
nyalldawson Mar 15, 2024
2b7e1c5
Add unit tests for psuedo color renderer
nyalldawson Mar 15, 2024
253623f
Introduce fixed elevation range for raster layers
nyalldawson Mar 14, 2024
fca4570
Indentation
nyalldawson Mar 14, 2024
7fc4ed3
Add range limits api to QgsRange
nyalldawson Mar 15, 2024
c46ae9b
Simplify code
nyalldawson Mar 15, 2024
a5b4d97
Microoptimisation
nyalldawson Mar 15, 2024
a91f5bf
Add a fixed range width option to QgsRangeSlider
nyalldawson Mar 14, 2024
f306e55
Fix overlapping text when narrow range is close to top
nyalldawson Mar 14, 2024
2da02f2
Move current range labels to sit on the vertical outside of sliders
nyalldawson Mar 14, 2024
ecc71b4
Add fixed range width option to QgsElevationControllerWidget
nyalldawson Mar 14, 2024
e36e402
[feature] Add option to set a fixed elevation slice width
nyalldawson Mar 14, 2024
9ee09c1
Rename to fixed range size
nyalldawson Mar 15, 2024
a9d2d43
Also rename QgsRangeSlider fixed range size methods
nyalldawson Mar 17, 2024
465d8bd
Use inline settings widget in menu instead of separate dialog
nyalldawson Mar 17, 2024
1673bc2
Update test
nyalldawson Mar 17, 2024
c486cf9
Fix truncated labels
nyalldawson Mar 18, 2024
9a2d8ad
Update test
nyalldawson Mar 18, 2024
71583db
use new settings API in DXF export (#56852)
3nids Mar 18, 2024
1796318
Add a "fixed range per band" elevation mode for rasters
nyalldawson Mar 18, 2024
a3f1f91
Add GUI to configure fixed range per band mode
nyalldawson Mar 18, 2024
b3d3a61
Handle fixed range per band mode in raster renderer
nyalldawson Mar 18, 2024
e9730b1
Add capabilities for raster renderers
nyalldawson Mar 18, 2024
3eb14c2
Don't allow using per-band elevation range mode when layer
nyalldawson Mar 18, 2024
a72c4bb
[layout] Fix hidden coverage layer
agiudiceandrea Mar 17, 2024
0bb3a26
Implement fixed elevation range for mesh layers
nyalldawson Mar 18, 2024
16b637e
Don't identify mesh layers which aren't in visible elevation range
nyalldawson Mar 18, 2024
40847d0
Avoid some unnecessary redraws
nyalldawson Mar 18, 2024
163c513
Fix warning
nyalldawson Mar 18, 2024
d2e3534
[processing] Use correct ellipsoid for network analysis tools
nyalldawson Mar 8, 2024
c997d5a
Fix test
nyalldawson Mar 13, 2024
1815858
Relation reference: Simplify widget for limiting number of entries to…
DelazJ Mar 19, 2024
18bba4b
Use proper labels for buttons in the Organize columns dialog
DelazJ Mar 19, 2024
1ecd122
Add tooltips
DelazJ Mar 19, 2024
988012c
[layouts] Avoid a potential speed regression
agiudiceandrea Mar 19, 2024
c9c62c2
Fix QgsSymbol::drawPreviewIcon
agiudiceandrea Mar 11, 2024
89731a7
Don't store numeric limits as z range for layout maps in project
nyalldawson Mar 19, 2024
0f16492
Use more descriptive default layer names when adding SensorThings
nyalldawson Mar 20, 2024
84f3709
Fix typo
nyalldawson Mar 20, 2024
4d2497b
[layouts] Defer legend item feature count until layout is drawn
nirvn Mar 18, 2024
ec30cab
Add test mask to fix flaky test
nyalldawson Mar 20, 2024
9f25c2d
Export DXF Export dialog's settings to XML file
gacarrillor Mar 15, 2024
d526531
Load DXF Export dialog's settings from XML file
gacarrillor Mar 15, 2024
6716585
Make DXF Export load settings from XML flexible by ignoring elements …
gacarrillor Mar 18, 2024
b8c6bd3
[dxf] Remove 'my' prefixes according to review
gacarrillor Mar 20, 2024
72249d6
[dxf] Use the new Settings API
gacarrillor Mar 20, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/macos-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -135,4 +135,4 @@ jobs:
if: ${{ github.event_name == 'push' }}
with:
path: ${{ env.CCACHE_DIR }}
key: build-ccache-mac-${{ github.ref_name }}
key: build-ccache-mac-${{ github.ref_name }}-${{ github.run_id }}
2 changes: 1 addition & 1 deletion .github/workflows/mingw-w64-msys2.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,4 +91,4 @@ jobs:
if: ${{ github.event_name == 'push' }}
with:
path: build
key: build-ccache-mingw64-msys2-${{ github.ref_name }}
key: build-ccache-mingw64-msys2-${{ github.ref_name }}-${{ github.run_id }}
2 changes: 1 addition & 1 deletion .github/workflows/mingw64.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ jobs:
if: ${{ github.event_name == 'push' }}
with:
path: /w/.ccache/QGIS
key: build-ccache-mingw64-${{ github.ref_name }}
key: build-ccache-mingw64-${{ github.ref_name }}-${{ github.run_id }}

- name: Create Portable zip
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ogc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ jobs:
if: ${{ github.event_name == 'push' }}
with:
path: /home/runner/QGIS/.ccache
key: build-ccache-ogc-${{ github.ref_name }}
key: build-ccache-ogc-${{ github.ref_name }}-${{ github.run_id }}

- name: Install pyogctest
run: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ jobs:
uses: actions/cache/restore@v4
with:
path: /home/runner/QGIS/.ccache
key: build-ccache-${{ matrix.distro-version }}-qt${{ matrix.qt-version }}-${{ github.event.pull_request.base.ref || github.ref_name }}
key: build-ccache-${{ matrix.distro-version }}-qt${{ matrix.qt-version }}-${{ github.event.pull_request.base.ref || github.ref_name }}
restore-keys: |
build-ccache-${{ matrix.distro-version }}-qt${{ matrix.qt-version }}-master

Expand Down Expand Up @@ -173,7 +173,7 @@ jobs:
if: ${{ github.event_name == 'push' }}
with:
path: /home/runner/QGIS/.ccache
key: build-ccache-${{ matrix.distro-version }}-qt${{ matrix.qt-version }}-${{ github.ref_name }}
key: build-ccache-${{ matrix.distro-version }}-qt${{ matrix.qt-version }}-${{ github.ref_name }}-${{ github.run_id }}

- name: Push artifact
id: push_artifact
Expand Down
3 changes: 0 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -375,9 +375,6 @@ if(WITH_CORE)

find_package(Protobuf CONFIG)
find_package(Protobuf REQUIRED)
if(Protobuf_VERSION GREATER_EQUAL 4.23)
set(Protobuf_LITE_LIBRARY protobuf::libprotobuf-lite)
endif()

message(STATUS "Found Protobuf: ${Protobuf_LIBRARIES}")
if (NOT Protobuf_PROTOC_EXECUTABLE)
Expand Down
29 changes: 29 additions & 0 deletions python/PyQt6/core/auto_additions/qgis.py
Original file line number Diff line number Diff line change
Expand Up @@ -1279,6 +1279,14 @@
Qgis.RasterRendererFlags.baseClass = Qgis
RasterRendererFlags = Qgis # dirty hack since SIP seems to introduce the flags in module
# monkey patching scoped based enum
Qgis.RasterRendererCapability.UsesMultipleBands.__doc__ = "The renderer utilizes multiple raster bands for color data (note that alpha bands are not considered for this capability)"
Qgis.RasterRendererCapability.__doc__ = "Raster renderer capabilities.\n\n.. versionadded:: 3.48\n\n" + '* ``UsesMultipleBands``: ' + Qgis.RasterRendererCapability.UsesMultipleBands.__doc__
# --
Qgis.RasterRendererCapability.baseClass = Qgis
Qgis.RasterRendererCapabilities = lambda flags=0: Qgis.RasterRendererCapability(flags)
Qgis.RasterRendererCapabilities.baseClass = Qgis
RasterRendererCapabilities = Qgis # dirty hack since SIP seems to introduce the flags in module
# monkey patching scoped based enum
Qgis.RasterAttributeTableFieldUsage.Generic.__doc__ = "Field usage Generic"
Qgis.RasterAttributeTableFieldUsage.PixelCount.__doc__ = "Field usage PixelCount"
Qgis.RasterAttributeTableFieldUsage.Name.__doc__ = "Field usage Name"
Expand Down Expand Up @@ -3220,6 +3228,27 @@
# --
Qgis.AltitudeBinding.baseClass = Qgis
# monkey patching scoped based enum
Qgis.RangeLimits.IncludeBoth.__doc__ = "Both lower and upper values are included in the range"
Qgis.RangeLimits.IncludeLowerExcludeUpper.__doc__ = "Lower value is included in the range, upper value is excluded"
Qgis.RangeLimits.ExcludeLowerIncludeUpper.__doc__ = "Lower value is excluded from the range, upper value in inccluded"
Qgis.RangeLimits.ExcludeBoth.__doc__ = "Both lower and upper values are excluded from the range"
Qgis.RangeLimits.__doc__ = "Describes how the limits of a range are handled.\n\n.. versionadded:: 3.38\n\n" + '* ``IncludeBoth``: ' + Qgis.RangeLimits.IncludeBoth.__doc__ + '\n' + '* ``IncludeLowerExcludeUpper``: ' + Qgis.RangeLimits.IncludeLowerExcludeUpper.__doc__ + '\n' + '* ``ExcludeLowerIncludeUpper``: ' + Qgis.RangeLimits.ExcludeLowerIncludeUpper.__doc__ + '\n' + '* ``ExcludeBoth``: ' + Qgis.RangeLimits.ExcludeBoth.__doc__
# --
Qgis.RangeLimits.baseClass = Qgis
# monkey patching scoped based enum
Qgis.RasterElevationMode.FixedElevationRange.__doc__ = "Layer has a fixed elevation range"
Qgis.RasterElevationMode.RepresentsElevationSurface.__doc__ = "Pixel values represent an elevation surface"
Qgis.RasterElevationMode.FixedRangePerBand.__doc__ = "Layer has a fixed elevation range per band"
Qgis.RasterElevationMode.__doc__ = "Raster layer elevation modes.\n\n.. versionadded:: 3.38\n\n" + '* ``FixedElevationRange``: ' + Qgis.RasterElevationMode.FixedElevationRange.__doc__ + '\n' + '* ``RepresentsElevationSurface``: ' + Qgis.RasterElevationMode.RepresentsElevationSurface.__doc__ + '\n' + '* ``FixedRangePerBand``: ' + Qgis.RasterElevationMode.FixedRangePerBand.__doc__
# --
Qgis.RasterElevationMode.baseClass = Qgis
# monkey patching scoped based enum
Qgis.MeshElevationMode.FixedElevationRange.__doc__ = "Layer has a fixed elevation range"
Qgis.MeshElevationMode.FromVertices.__doc__ = "Elevation should be taken from mesh vertices"
Qgis.MeshElevationMode.__doc__ = "Mesh layer elevation modes.\n\n.. versionadded:: 3.38\n\n" + '* ``FixedElevationRange``: ' + Qgis.MeshElevationMode.FixedElevationRange.__doc__ + '\n' + '* ``FromVertices``: ' + Qgis.MeshElevationMode.FromVertices.__doc__
# --
Qgis.MeshElevationMode.baseClass = Qgis
# monkey patching scoped based enum
Qgis.NoConstraint = Qgis.BetweenLineConstraint.NoConstraint
Qgis.NoConstraint.is_monkey_patched = True
Qgis.BetweenLineConstraint.NoConstraint.__doc__ = "No additional constraint"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,62 @@ Constructor for QgsMeshLayerElevationProperties, with the specified ``parent`` o

virtual bool showByDefaultInElevationProfilePlots() const;

virtual QgsMapLayerElevationProperties::Flags flags() const;


Qgis::MeshElevationMode mode() const;
%Docstring
Returns the elevation mode.

.. seealso:: :py:func:`setMode`

.. versionadded:: 3.38
%End

void setMode( Qgis::MeshElevationMode mode );
%Docstring
Sets the elevation ``mode``.

.. seealso:: :py:func:`mode`

.. versionadded:: 3.38
%End

QgsDoubleRange fixedRange() const;
%Docstring
Returns the fixed elevation range for the mesh.

.. note::

This is only considered when :py:func:`~QgsMeshLayerElevationProperties.mode` is :py:class:`Qgis`.MeshElevationMode.FixedElevationRange.

.. note::

When a fixed range is set any :py:func:`~QgsMeshLayerElevationProperties.zOffset` and :py:func:`~QgsMeshLayerElevationProperties.zScale` is ignored.


.. seealso:: :py:func:`setFixedRange`

.. versionadded:: 3.38
%End

void setFixedRange( const QgsDoubleRange &range );
%Docstring
Sets the fixed elevation ``range`` for the mesh.

.. note::

This is only considered when :py:func:`~QgsMeshLayerElevationProperties.mode` is :py:class:`Qgis`.MeshElevationMode.FixedElevationRange.

.. note::

When a fixed range is set any :py:func:`~QgsMeshLayerElevationProperties.zOffset` and :py:func:`~QgsMeshLayerElevationProperties.zScale` is ignored.


.. seealso:: :py:func:`fixedRange`

.. versionadded:: 3.38
%End

QgsLineSymbol *profileLineSymbol() const;
%Docstring
Expand Down
31 changes: 31 additions & 0 deletions python/PyQt6/core/auto_generated/qgis.sip.in
Original file line number Diff line number Diff line change
Expand Up @@ -691,6 +691,14 @@ The development version



enum class RasterRendererCapability /BaseType=IntFlag/
{
UsesMultipleBands,
};

typedef QFlags<Qgis::RasterRendererCapability> RasterRendererCapabilities;


enum class RasterAttributeTableFieldUsage /BaseType=IntEnum/
{
Generic,
Expand Down Expand Up @@ -1835,6 +1843,27 @@ The development version
Centroid,
};

enum class RangeLimits /BaseType=IntEnum/
{
IncludeBoth,
IncludeLowerExcludeUpper,
ExcludeLowerIncludeUpper,
ExcludeBoth,
};

enum class RasterElevationMode /BaseType=IntEnum/
{
FixedElevationRange,
RepresentsElevationSurface,
FixedRangePerBand,
};

enum class MeshElevationMode /BaseType=IntEnum/
{
FixedElevationRange,
FromVertices
};

enum class BetweenLineConstraint /BaseType=IntEnum/
{
NoConstraint,
Expand Down Expand Up @@ -2844,6 +2873,8 @@ QFlags<Qgis::ProjectReadFlag> operator|(Qgis::ProjectReadFlag f1, QFlags<Qgis::P

QFlags<Qgis::RasterRendererFlag> operator|(Qgis::RasterRendererFlag f1, QFlags<Qgis::RasterRendererFlag> f2);

QFlags<Qgis::RasterRendererCapability> operator|(Qgis::RasterRendererCapability f1, QFlags<Qgis::RasterRendererCapability> f2);

QFlags<Qgis::RasterTemporalCapabilityFlag> operator|(Qgis::RasterTemporalCapabilityFlag f1, QFlags<Qgis::RasterTemporalCapabilityFlag> f2);

QFlags<Qgis::RelationshipCapability> operator|(Qgis::RelationshipCapability f1, QFlags<Qgis::RelationshipCapability> f2);
Expand Down
31 changes: 31 additions & 0 deletions python/PyQt6/core/auto_generated/qgsrange.sip.in
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,14 @@ whether ranges overlap or during calculation of range intersections.
%Docstring
Constructor for QgsRange. The ``lower`` and ``upper`` bounds are specified,
and optionally whether or not these bounds are included in the range.
%End

QgsRange( T lower, T upper, Qgis::RangeLimits limits );
%Docstring
Constructor for QgsRange. The ``lower`` and ``upper`` bounds are specified,
and whether or not these bounds are included in the range.

.. versionadded:: 3.38
%End

T lower() const;
Expand Down Expand Up @@ -79,6 +87,13 @@ bound is exclusive.
.. seealso:: :py:func:`upper`

.. seealso:: :py:func:`includeLower`
%End

Qgis::RangeLimits rangeLimits() const;
%Docstring
Returns the limit handling of the range.

.. versionadded:: 3.38
%End

bool isEmpty() const;
Expand Down Expand Up @@ -146,6 +161,14 @@ typedef QgsRange<double> QgsRangedoubleBase;
%End
public:

QgsDoubleRange( double lower, double upper, Qgis::RangeLimits limits );
%Docstring
Constructor for QgsDoubleRange. The ``lower`` and ``upper`` bounds are specified,
and whether or not these bounds are included in the range.

.. versionadded:: 3.38
%End


QgsDoubleRange( double lower,
double upper,
Expand Down Expand Up @@ -207,6 +230,14 @@ typedef QgsRange<int> QgsRangeintBase;
%End
public:

QgsIntRange( int lower, int upper, Qgis::RangeLimits limits );
%Docstring
Constructor for QgsIntRange. The ``lower`` and ``upper`` bounds are specified,
and whether or not these bounds are included in the range.

.. versionadded:: 3.38
%End


QgsIntRange( int lower,
int upper,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,21 +56,31 @@ Factory method to create a new renderer

virtual QList<int> usesBands() const;

virtual int inputBand() const;


virtual void toSld( QDomDocument &doc, QDomElement &element, const QVariantMap &props = QVariantMap() ) const;


int band() const;
int band() const /Deprecated/;
%Docstring
Returns the band used by the renderer

.. deprecated:: QGIS 3.38
use :py:func:`~QgsHillshadeRenderer.inputBand` instead
%End

void setBand( int bandNo );
void setBand( int bandNo ) /Deprecated/;
%Docstring
Sets the band used by the renderer.

.. seealso:: :py:func:`band`

.. deprecated:: QGIS 3.38
use :py:func:`~QgsHillshadeRenderer.setInputBand` instead
%End
virtual bool setInputBand( int band );


double azimuth() const;
%Docstring
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,11 +122,19 @@ Returns optional category label
Set category label
%End

int band() const;
int band() const /Deprecated/;
%Docstring
Returns the raster band used for rendering the raster.

.. deprecated:: QGIS 3.38
use :py:func:`~QgsPalettedRasterRenderer.inputBand` instead
%End

virtual int inputBand() const;

virtual bool setInputBand( int band );


virtual void writeXml( QDomDocument &doc, QDomElement &parentElem ) const;

virtual QList< QPair< QString, QColor > > legendSymbologyItems() const;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,16 +50,10 @@ Creates an instance of the renderer based on definition from XML (used by render

virtual QList<QgsLayerTreeModelLegendNode *> createLegendNodes( QgsLayerTreeLayer *nodeLayer ) /Factory/;

virtual int inputBand() const;

virtual bool setInputBand( int band );

int inputBand() const;
%Docstring
Returns the number of the input raster band
%End
void setInputBand( int band );
%Docstring
Sets the number of the input raster band
%End

double contourInterval() const;
%Docstring
Expand Down
Loading
Loading