mapbox / mapbox/mapbox-maps-android
Automirrored vector drawables do not get mirrored when layout is RTL
Nobody has claimed this yet.
- Dominant language
- Kotlin
- Stars
- 578
- Forks
- 161
- PR merge metrics
- No merged PRs in 30d
Description
## Environment
- Android OS version: 14
- Devices affected: Pixel 5
- Maps SDK Version: 11.4.0
## Observed behavior and steps to reproduce
Mapbox doesn't seem to honor the `autoMirrored` attribute on vector drawables when rendering, which result in icons not being mirrored when the layout is RTL.
Map used is mapbox compose and images are displayed with point annotations.
## Expected behavior
Icons should be mirrored
## Notes / preliminary analysis
Now that I think about it, images are added with `style.addImage` which takes a bitmap... Could it be that the auto mirror info is lost when doing Drawable -> Bitmap?
## Additional links and references
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue on Android 14 with Maps SDK 11.4.0 using Mapbox Compose and point annotations in an RTL layout. Start by tracing how the drawable is passed through style.addImage and converted to a bitmap, then verify whether the autoMirrored information is preserved. Done means vector drawable icons render mirrored when the layout direction is RTL.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, kotlin
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100