This repository has been archived by the owner on Aug 8, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
MGLMapView contentInset top is ignored for compass positioning #11068
Comments
Is there any workaround? |
@dmdeller can you confirm that |
@julianrex Confirmed, |
Making a note that the ideal solution here should involve integrating the Adopt layout anchors #12147 PR. |
3 tasks
Noting that this issue should be addressed by #13911 which is currently in review. /cc @chloekraw |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Platform: iOS
Mapbox SDK version: 3.7.3
Hi there,
We have been using
contentInset.top
to position the compass on ourMGLMapView
, in order to move it out of the way of some other views that we place on top of the map view. This has worked fine until recently, but was broken in Mapbox 3.7.2.Steps to trigger behavior
Our usage looks like this: (Swift; edited for clarity)
Expected behavior
The compass should be positioned at least 60 points below the top of the
MGLMapView
.Actual behavior
The compass is positioned at the top of
MGLMapView
. SettingcontentInset
makes no difference to the vertical positioning.More info
I regression tested it on these Mapbox versions:
3.6.4: ✅ as expected
3.7.0: ✅ as expected
3.7.1: ✅ as expected
3.7.2: ❌ not as expected
3.7.3: ❌ not as expected
I think this commit may have been the breaking change: d650b91
Note that the left side of the diff references
contentInset.top
but the right side does not.Question
Is this a bug, or was this change intentional? If the latter, do you have another recommendation for how to position the compass?
Thanks!
The text was updated successfully, but these errors were encountered: