The previous approach was severely broken, because the default
CRS for new projects setting was ignored as soon as a layer
was added to the project.
Instead, refine the setting to add options
- "Use CRS from first layer added": same as previous behavior,
the project CRS is set to match the first layer added to a new
project
- "Use a default CRS": CRS for a new project is set to a preset
default CRS, and is left unchanged when adding layers to the
project
Also update qgis_global_settings.ini to reflect these changes.
Fixes#27516
If they are deleted, any other python wrappers which have been parented to these singletons are deleted too.
One of the most common issues with this is, that subclasses of registry items are deleted and lost.
These providers will be used to control how the browser data items
behave within GUI, and to allow separation of GUI related
properties of browser items from the core code.
A new registry QgsDataItemGuiProviderRegistry has been created
(modeled off QgsDataItemProviderRegistry), with an application
wide instance available from QgsGui::instance()->dataItemGuiProviderRegistry()
With implementation in app. This allows GUI library classes to
re-use standard dialogs which are created in app. The initial
use-case is to allow the GUI library symbol list widget to
focus/open an existing Style Manager dialog (created in app),
instead of opening a new modal style manager dialog.
Side benefit - moves some code out of the monolithic qgisapp.cpp
file.