This custom QLayout class allows for overlaying child widgets on top
of their parent widget.
It can be used like this:
layout = QgsOverlayWidgetLayout()
parent_widget.setLayout(layout)
layout.setContentsMargins(20,20,20,20)
layout.addWidget(QGroupBox(), Qt.Edge.LeftEdge)
layout.addWidget(QLabel('My label on top of a parent!'), Qt.Edge.TopEdge)
layout.addWidget(QGroupBox(), Qt.Edge.TopEdge)
When checked, only layers with broken sources will be shown in the
tree. This allows users to easily find broken layers in large complex
projects, where they may otherwise escape notice!
The original workaround was only supposed to apply to QList/
QVector of QVariantMaps. By replacing them all in sip we
break mapping of signals defined in c++ which are emitted
by Python code.
Fixes exceptions after running processing algorithms in Qt6
builds.
And make sipify handle this nicely. This means that all our non-flag
style enums correctly map across to IntFlag python enums on Qt 6,
fixing issues with negative enum values for these and providing
a better match for the original c++ enum.
sip6 converts all enums to python Enums, but ONLY creates
Enums with IntFlags types when the c++ type is an enum class : int.
Accordingly we need to patch back in all the operations which treat
enum values as ints, like |, &, bool, etc.
The long term solution here is to move all our c++ enums to enum
class, but that's not always straightforward and can break API
for plugins if it involves the signature of virtual methods.
This ensures that we correctly apply filters to recent projections
too, eg so that a widget showing only vertical crs will ONLY show
recent VERTICAL crs, not every recent crs.
Cleanup QgsProjectionSelectionWidget to use proper models to
drive the combo box. This removes a bunch of very fragile
logic regarding showing and hiding entries on demand, as it
allows us to move all the filtering logic to a single place
in a QSortFilterProxyModel subclass.
This has a few side benefits:
- The combos now dynamically respond to changes like recent
CRS being used in other places in QGIS
- The widget correctly respects horizontal/vertical crs filters
for all entries, including recent crs