Skip to content

Commit

Permalink
Merge branch 'master' into 3d-view-dock-undock
Browse files Browse the repository at this point in the history
  • Loading branch information
NEDJIMAbelgacem committed Jan 12, 2022
2 parents 34594bc + 66b481a commit 3638da1
Show file tree
Hide file tree
Showing 203 changed files with 10,173 additions and 8,672 deletions.
1 change: 1 addition & 0 deletions .docker/docker-qgis-build.sh
Expand Up @@ -80,6 +80,7 @@ cmake \
-DWITH_ASTYLE=OFF \
-DWITH_BINDINGS=${WITH_QT5} \
-DWITH_SERVER=${WITH_QT5} \
-DWITH_SERVER_LANDINGPAGE_WEBAPP=${WITH_QT5} \
-DWITH_ORACLE=${WITH_QT5} \
-DWITH_PDAL=${WITH_QT5} \
-DWITH_QT5SERIALPORT=${WITH_QT5} \
Expand Down
5 changes: 5 additions & 0 deletions .docker/qgis3-qt5-build-deps.dockerfile
Expand Up @@ -102,6 +102,11 @@ RUN apt-get update \
hdbcli \
&& apt-get clean

# Node.js and Yarn for server landingpage webapp
RUN curl -fsSL https://deb.nodesource.com/setup_lts.x | bash -
RUN apt-get install -y nodejs
RUN corepack enable

# Oracle : client side
RUN curl https://download.oracle.com/otn_software/linux/instantclient/199000/instantclient-basic-linux.x64-19.9.0.0.0dbru.zip > instantclient-basic-linux.x64-19.9.0.0.0dbru.zip
RUN curl https://download.oracle.com/otn_software/linux/instantclient/199000/instantclient-sdk-linux.x64-19.9.0.0.0dbru.zip > instantclient-sdk-linux.x64-19.9.0.0.0dbru.zip
Expand Down
8 changes: 8 additions & 0 deletions .github/workflows/mingw64.yml
Expand Up @@ -39,6 +39,14 @@ jobs:
- name: Install build dependencies
run: ./ms-windows/mingw/mingwdeps.sh

# Node.js and Yarn for server landingpage webapp
- uses: actions/setup-node@v2
with:
node-version: '17'

- name: Make yarn available
run: corepack enable

- name: Create ccache dir
run: mkdir -p /w/.ccache/QGIS

Expand Down
2 changes: 2 additions & 0 deletions CMakeLists.txt
Expand Up @@ -198,6 +198,8 @@ if(WITH_CORE)
# server disabled default because it needs FastCGI (which is optional dependency)
set (WITH_SERVER FALSE CACHE BOOL "Determines whether QGIS server should be built")
if(WITH_SERVER)
set (WITH_SERVER_LANDINGPAGE_WEBAPP FALSE CACHE BOOL "Determines whether QGIS server landingpage webapp should be built (requires nodejs and yarn)")

set (SERVER_SKIP_ECW FALSE CACHE BOOL "Determines whether QGIS server should disable ECW (ECW in server apps requires a special license)")

set (WITH_SERVER_PLUGINS ${WITH_BINDINGS} CACHE BOOL "Determines whether QGIS server support for python plugins should be built")
Expand Down
15 changes: 15 additions & 0 deletions INSTALL.md
Expand Up @@ -192,6 +192,13 @@ See [debian-ubuntu](https://qgis.org/en/site/forusers/alldownloads.html#debian-u
currently supported distributions (plain xenial's GDAL for instance is too old
and we build with GDAL2 from ubuntugis).

To build [QGIS server landing page/catalog webapp](https://docs.qgis.org/latest/en/docs/server_manual/services.html#qgis-server-catalog) additional dependencies are required:

Node.js (current LTS recommended): https://nodejs.org/en/download/<br>
Yarn Package Manager: https://yarnpkg.com/getting-started/install

Additionally, the cmake flag `WITH_SERVER_LANDINGPAGE_WEBAPP` needs to be turned on.

## 3.4. Setup ccache (Optional, but recommended)

You should also setup ccache to speed up compile times:
Expand Down Expand Up @@ -435,6 +442,14 @@ To build QGIS server additional dependencies are required:
dnf install fcgi-devel
```

And for building [QGIS server landing page/catalog webapp](https://docs.qgis.org/latest/en/docs/server_manual/services.html#qgis-server-catalog):

```bash
dnf install nodejs yarnpkg
```

Additionally, the cmake flag `WITH_SERVER_LANDINGPAGE_WEBAPP` needs to be turned on.

Make sure that your build directory is completely empty when you enter the
following command. Do never try to "re-use" an existing Qt5 build directory.
If you want to use `ccmake` or other interactive tools, run the following
Expand Down
6 changes: 4 additions & 2 deletions README.md
Expand Up @@ -33,7 +33,7 @@ QGIS is a full-featured, user-friendly, free-and-open-source (FOSS) geographical

- Supports raster, vector, mesh, and point cloud data in a range of industry-standard formats
- *Raster formats include*: GeoPackage, GeoTIFF, GRASS, ArcInfo binary and ASCII grids, ERDAS Imagine SDTS, WMS, WCS, PostgreSQL/PostGIS, and [other GDAL supported formats](https://gdal.org/drivers/raster/index.html).
- *Vector formats include*: GeoPackage, ESRI Shapefiles, GRASS, SpatiaLite, PostgreSQL/PostGIS, MSSQL, Oracle, WFS, Vector Tiles and [other OGR supported formats](http://www.gdal.org/ogr_formats.html).
- *Vector formats include*: GeoPackage, ESRI shapefiles, GRASS, SpatiaLite, PostgreSQL/PostGIS, MSSQL, Oracle, WFS, Vector Tiles and [other OGR supported formats](http://www.gdal.org/ogr_formats.html).
- *Mesh formats include*: NetCDF, GRIB, 2DM, and [other MDAL supported formats](https://github.com/lutraconsulting/MDAL#supported-formats).
- *Point-cloud format*: LAS/LAZ and EPT datasets.
- Access and display local files, spatial databases (PostGIS, SpatiaLite, SQL Server, Oracle, SAP HANA), web services (WMS, WCS, WFS, ArcGIS REST services), tile services, etc. <!-- removed DB2 due to https://github.com/qgis/QGIS/pull/41178 -->
Expand All @@ -52,6 +52,7 @@ QGIS is a full-featured, user-friendly, free-and-open-source (FOSS) geographical
### 2. Beautiful cartography
- Large variety of rendering options in 2D and 3D
- Fine control over symbology, labeling, legends and additional graphical elements for beautifully rendered maps
- Near-complete replication (and significant extension) of symbology options that are available in proprietary software by ESRI
- Advanced styling using data-defined overrides, blending modes, and draw effects
- 500+ built-in color ramps (cpt-city, ColorBrewer, etc.)
- Create and update maps with specified scale, extent, style, and decorations via saved layouts
Expand Down Expand Up @@ -87,7 +88,8 @@ For more maps created with QGIS, visit the [QGIS Map Showcase Flickr Group](http

- Fully customizable user experience, including user interface and application settings that cater to power-users and beginners alike
- Rich [expression engine](https://docs.qgis.org/testing/en/docs/user_manual/working_with_vector/expression.html) for maximum flexibility in visualization and processing
- Broad and varied [plugin ecosystem](https://plugins.qgis.org/) that includes data connectors, digitizing aids, advanced analysis and charting tools, in-the-field data capture, etc.
- Broad and varied [plugin ecosystem](https://plugins.qgis.org/) that includes data connectors, digitizing aids, advanced analysis and charting tools,
in-the-field data capture, conversion of ESRI style files, etc.
- Style manager for creating, storing, and managing styles
- [QGIS style hub](https://plugins.qgis.org/styles/) for easy sharing of styles
- Python and C++ API for standalone (headless) applications as well as in-application comprehensive scripting (PyQGIS)
Expand Down
1 change: 1 addition & 0 deletions debian/qgis-providers.install
Expand Up @@ -6,6 +6,7 @@ usr/lib/qgis/plugins/libauthmethod_identcert.so
usr/lib/qgis/plugins/libauthmethod_pkcs12.so
usr/lib/qgis/plugins/libauthmethod_pkipaths.so
usr/lib/qgis/plugins/libauthmethod_apiheader.so
usr/lib/qgis/plugins/libauthmethod_maptilerhmacsha256.so
usr/lib/qgis/plugins/libprovider_arcgisfeatureserver.so
usr/lib/qgis/plugins/libprovider_arcgismapserver.so
usr/lib/qgis/plugins/libprovider_db2.so
Expand Down
1 change: 1 addition & 0 deletions ms-windows/mingw/build.sh
Expand Up @@ -95,6 +95,7 @@ mkdir -p "$BUILDDIR"
-DBINDINGS_GLOBAL_INSTALL=ON \
-DSIP_GLOBAL_INSTALL=ON \
-DWITH_SERVER=ON \
-DWITH_SERVER_LANDINGPAGE_WEBAPP=ON \
-DTXT2TAGS_EXECUTABLE= \
..
)
Expand Down
1 change: 1 addition & 0 deletions ms-windows/osgeo4w/package.cmd
Expand Up @@ -313,6 +313,7 @@ for %%i in (%packages%) do (
"apps/%PACKAGENAME%/plugins/provider_mdal.dll" ^
"apps/%PACKAGENAME%/plugins/provider_hana.dll" ^
"apps/%PACKAGENAME%/plugins/authmethod_oauth2.dll" ^
"apps/%PACKAGENAME%/plugins/authmethod_maptilerhmacsha256.dll" ^
"apps/%PACKAGENAME%/resources/qgis.db" ^
"apps/%PACKAGENAME%/resources/spatialite.db" ^
"apps/%PACKAGENAME%/resources/srs.db" ^
Expand Down
8 changes: 8 additions & 0 deletions python/3d/auto_generated/qgs3dmapsettings.sip.in
Expand Up @@ -604,6 +604,14 @@ Sets whether the 2D terrain surface will be rendered in.
%End

signals:

void settingsChanged();
%Docstring
Emitted when one of the configuration settings has changed

.. versionadded:: 3.24
%End

void backgroundColorChanged();
%Docstring
Emitted when the background color has changed
Expand Down
11 changes: 11 additions & 0 deletions python/core/auto_additions/qgis.py
Expand Up @@ -1200,3 +1200,14 @@
Qgis.HistoryProviderBackend.baseClass = Qgis
Qgis.HistoryProviderBackends.baseClass = Qgis
HistoryProviderBackends = Qgis # dirty hack since SIP seems to introduce the flags in module
QgsCoordinateReferenceSystem.Format = Qgis.CrsDefinitionFormat
# monkey patching scoped based enum
QgsCoordinateReferenceSystem.FormatWkt = Qgis.CrsDefinitionFormat.Wkt
QgsCoordinateReferenceSystem.FormatWkt.is_monkey_patched = True
QgsCoordinateReferenceSystem.FormatWkt.__doc__ = "WKT format (always recommended over proj string format)"
QgsCoordinateReferenceSystem.FormatProj = Qgis.CrsDefinitionFormat.Proj
QgsCoordinateReferenceSystem.FormatProj.is_monkey_patched = True
QgsCoordinateReferenceSystem.FormatProj.__doc__ = "Proj string format"
Qgis.CrsDefinitionFormat.__doc__ = 'CRS definition formats.\n\n.. versionadded:: 3.24\n\n' + '* ``FormatWkt``: ' + Qgis.CrsDefinitionFormat.Wkt.__doc__ + '\n' + '* ``FormatProj``: ' + Qgis.CrsDefinitionFormat.Proj.__doc__
# --
Qgis.CrsDefinitionFormat.baseClass = Qgis
5 changes: 4 additions & 1 deletion python/core/auto_additions/qgsproject.py
Expand Up @@ -12,7 +12,10 @@
QgsProject.FlagDontStoreOriginalStyles = QgsProject.ReadFlag.FlagDontStoreOriginalStyles
QgsProject.FlagDontStoreOriginalStyles.is_monkey_patched = True
QgsProject.ReadFlag.FlagDontStoreOriginalStyles.__doc__ = "Skip the initial XML style storage for layers. Useful for minimising project load times in non-interactive contexts."
QgsProject.ReadFlag.__doc__ = 'Flags which control project read behavior.\n\n.. versionadded:: 3.10\n\n' + '* ``FlagDontResolveLayers``: ' + QgsProject.ReadFlag.FlagDontResolveLayers.__doc__ + '\n' + '* ``FlagDontLoadLayouts``: ' + QgsProject.ReadFlag.FlagDontLoadLayouts.__doc__ + '\n' + '* ``FlagTrustLayerMetadata``: ' + QgsProject.ReadFlag.FlagTrustLayerMetadata.__doc__ + '\n' + '* ``FlagDontStoreOriginalStyles``: ' + QgsProject.ReadFlag.FlagDontStoreOriginalStyles.__doc__
QgsProject.FlagDontLoad3DViews = QgsProject.ReadFlag.FlagDontLoad3DViews
QgsProject.FlagDontLoad3DViews.is_monkey_patched = True
QgsProject.ReadFlag.FlagDontLoad3DViews.__doc__ = ""
QgsProject.ReadFlag.__doc__ = 'Flags which control project read behavior.\n\n.. versionadded:: 3.10\n\n' + '* ``FlagDontResolveLayers``: ' + QgsProject.ReadFlag.FlagDontResolveLayers.__doc__ + '\n' + '* ``FlagDontLoadLayouts``: ' + QgsProject.ReadFlag.FlagDontLoadLayouts.__doc__ + '\n' + '* ``FlagTrustLayerMetadata``: ' + QgsProject.ReadFlag.FlagTrustLayerMetadata.__doc__ + '\n' + '* ``FlagDontStoreOriginalStyles``: ' + QgsProject.ReadFlag.FlagDontStoreOriginalStyles.__doc__ + '\n' + '* ``FlagDontLoad3DViews``: ' + QgsProject.ReadFlag.FlagDontLoad3DViews.__doc__
# --
# monkey patching scoped based enum
QgsProject.FileFormat.Qgz.__doc__ = "Archive file format, supports auxiliary data"
Expand Down
1 change: 1 addition & 0 deletions python/core/auto_generated/labeling/qgspallabeling.sip.in
Expand Up @@ -218,6 +218,7 @@ Contains settings for how a map layer will be labeled.
// (data defined only)
PositionX,
PositionY,
PositionPoint,
Hali,
Vali,
Rotation,
Expand Down
Expand Up @@ -159,6 +159,7 @@ Does not take ownership of the object.




int renderingTime() const;
%Docstring
Returns the total time it took to finish the job (in milliseconds).
Expand Down
Expand Up @@ -189,12 +189,6 @@ both flavors.
EpsgCrsId
};

enum Format
{
FormatWkt,
FormatProj,
};

QgsCoordinateReferenceSystem();
%Docstring
Constructs an invalid CRS object
Expand Down Expand Up @@ -982,7 +976,7 @@ Update proj.4 parameters in our database from proj.4
This is used internally and should not be necessary to call in client code
%End

long saveAsUserCrs( const QString &name, Format nativeFormat = FormatWkt );
long saveAsUserCrs( const QString &name, Qgis::CrsDefinitionFormat nativeFormat = Qgis::CrsDefinitionFormat::Wkt );
%Docstring
Saves the CRS as a new custom ("USER") CRS.

Expand All @@ -1001,6 +995,19 @@ definition. FormatWkt is recommended as it is a lossless format.
Since QGIS 3.18, internally this calls :py:func:`QgsCoordinateReferenceSystemRegistry.addUserCrs()`.
%End

QgsCoordinateReferenceSystem toGeographicCrs() const;
%Docstring
Returns the geographic CRS associated with this CRS object.

May return an invalid CRS if the geographic CRS could not be determined.

.. note::

This method will always return a longitude, latitude ordered CRS.

.. versionadded:: 3.24
%End

QString geographicCrsAuthId() const;
%Docstring
Returns auth id of related geographic CRS
Expand Down
Expand Up @@ -64,7 +64,7 @@ Returns a list containing the details of all registered
custom (user-defined) CRSes.
%End

long addUserCrs( const QgsCoordinateReferenceSystem &crs, const QString &name, QgsCoordinateReferenceSystem::Format nativeFormat = QgsCoordinateReferenceSystem::FormatWkt );
long addUserCrs( const QgsCoordinateReferenceSystem &crs, const QString &name, Qgis::CrsDefinitionFormat nativeFormat = Qgis::CrsDefinitionFormat::Wkt );
%Docstring
Adds a new ``crs`` definition as a custom ("USER") CRS.

Expand All @@ -83,7 +83,7 @@ definition. FormatWkt is recommended as it is a lossless format.
.. seealso:: :py:func:`userCrsAdded`
%End

bool updateUserCrs( long id, const QgsCoordinateReferenceSystem &crs, const QString &name, QgsCoordinateReferenceSystem::Format nativeFormat = QgsCoordinateReferenceSystem::FormatWkt );
bool updateUserCrs( long id, const QgsCoordinateReferenceSystem &crs, const QString &name, Qgis::CrsDefinitionFormat nativeFormat = Qgis::CrsDefinitionFormat::Wkt );
%Docstring
Updates the definition of the existing user CRS with matching ``id``.

Expand Down
95 changes: 95 additions & 0 deletions python/core/auto_generated/project/qgsmapviewsmanager.sip.in
@@ -0,0 +1,95 @@
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/project/qgsmapviewsmanager.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/




class QgsMapViewsManager : QObject
{
%Docstring(signature="appended")

Manages storage of a set of views.

:py:class:`QgsMapViewsManager` handles the storage, serializing and deserializing
of views. Usually this class is not constructed directly, but rather
accessed through a :py:class:`QgsProject` via :py:func:`QgsProject.get3DViewsManager()` for example.

.. versionadded:: 3.24
%End

%TypeHeaderCode
#include "qgsmapviewsmanager.h"
%End
public:

explicit QgsMapViewsManager( QgsProject *project );
%Docstring
Constructor for QgsMapViewsManager. The project will become the parent object for this
manager.
%End

bool readXml( const QDomElement &element, const QDomDocument &doc );
%Docstring
Reads the manager's state from a DOM element, restoring all views
present in the XML document

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

QDomElement writeXml( QDomDocument &doc ) const;
%Docstring
Returns a DOM element representing the state of the manager.

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

void clear();
%Docstring
Removes and deletes all views from the manager.
%End





void remove3DView( const QString &name );
%Docstring
Removes the configuration of the 3D view named ``name``
%End

void rename3DView( const QString &oldTitle, const QString &newTitle );
%Docstring
Renames the 3D view named ``oldTitle`` to ``newTitle``
%End

void set3DViewInitiallyVisible( const QString &name, bool visible );
%Docstring
Sets whether the 3D view named ``name`` will be initially visible when the project is opened
%End

bool is3DViewOpen( const QString &name );
%Docstring
Returns whether the 3D view named ``name`` will is opened
%End

signals:
void views3DListChanged();
%Docstring
Emitted when the views list has changed (whenever a view was removed, added, renamed..)
%End

};


/************************************************************************
* This file has been generated automatically from *
* *
* src/core/project/qgsmapviewsmanager.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/
11 changes: 10 additions & 1 deletion python/core/auto_generated/project/qgsproject.sip.in
Expand Up @@ -15,7 +15,6 @@




class QgsProject : QObject, QgsExpressionContextGenerator, QgsExpressionContextScopeGenerator, QgsProjectTranslator
{
%Docstring(signature="appended")
Expand Down Expand Up @@ -43,6 +42,7 @@ open within the main QGIS application.
FlagDontLoadLayouts,
FlagTrustLayerMetadata,
FlagDontStoreOriginalStyles,
FlagDontLoad3DViews,
};
typedef QFlags<QgsProject::ReadFlag> ReadFlags;

Expand Down Expand Up @@ -745,6 +745,15 @@ the project.
%End


QgsMapViewsManager *getViewsManager();
%Docstring
Returns the project's views manager, which manages map views (including 3d maps)
in the project.

.. versionadded:: 3.24
%End


QgsBookmarkManager *bookmarkManager();
%Docstring
Returns the project's bookmark manager, which manages bookmarks within
Expand Down
6 changes: 6 additions & 0 deletions python/core/auto_generated/qgis.sip.in
Expand Up @@ -773,6 +773,12 @@ The development version
typedef QFlags<Qgis::HistoryProviderBackend> HistoryProviderBackends;


enum class CrsDefinitionFormat
{
Wkt,
Proj,
};

static const double DEFAULT_SEARCH_RADIUS_MM;

static const float DEFAULT_MAPTOPIXEL_THRESHOLD;
Expand Down
7 changes: 7 additions & 0 deletions python/core/auto_generated/qgsmaplayermodel.sip.in
Expand Up @@ -54,6 +54,13 @@ populate the model.
void setItemsCheckable( bool checkable );
%Docstring
setItemsCheckable defines if layers should be selectable in the widget
%End

void setProject( QgsProject *project );
%Docstring
Sets the :py:class:`QgsProject` from which map layers are shown

.. versionadded:: 3.24
%End

void setItemsCanBeReordered( bool allow );
Expand Down

0 comments on commit 3638da1

Please sign in to comment.