Qt 6.11 is out! See what's new in the release
blog
MapQuickItem + MapboxGl ignores item stack ordering
-
I've noticed a strange behavior when using
MapboxGLplugin with QML maps (Qt 5.15.2, Ubuntu). I slightly modified MinimalMap example in order to reproduce that:import QtQuick 2.0 import QtQuick.Window 2.14 import QtLocation 5.6 import QtPositioning 5.6 Window { width: 512 height: 512 visible: true Plugin { id: mapPlugin name: "osm" // "mapboxgl", "esri", "osm", ... } Map { anchors.fill: parent plugin: mapPlugin center: QtPositioning.coordinate(0, 0) zoomLevel: 14 MapQuickItem { coordinate: QtPositioning.coordinate(0, 0) opacity: 1 sourceItem: Rectangle { width: 600 height: width color: "blue" } } MapRectangle { color: "red" topLeft: QtPositioning.coordinate(0, 0) bottomRight: topLeft.atDistanceAndAzimuth(1000, 135) } } }Running this code with
osmplugin is ok:

But when it comes toMapboxGLstack ordering is ignored:

Stack ordering is only broken whenMapQuickItemstacks belowMapRectangle. Is it a bug?