You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Oct 7, 2024. It is now read-only.
Repository navigation
This repository was archived by the owner on Oct 7, 2024. It is now read-only.
With mapbox/mapbox-gl-native-android#314 we now have support for stretchable icon-images. These are ideal to be used as an 'InfoWindow/Popup`. Would be great to showcase selecting an icon-image on a map and showing a stretchable icon-image with a label as result of it (we no longer need to rely on view -> bitmap generation)
The test app activity in mapbox/mapbox-gl-native-android#314 doesn't apply any type of anchor/offset, which means the middle of the window stays on top of the Feature coordinate, rather than the V bottom tick part of the window sitting right above the anchor coordinate.
I'm still very much exploring this new stretchable core Mapbox API, but I'm finding it hard to work with the stretching + offset/anchor. It might be easy to set ImageStretches values and other stuff, if the specific text is known. However, it seems like it'd be tough to wrap and position icon+text of dynamic data that's coming from a REST get call from a cloud server or something.
Activity
langsmith commentedon May 1, 2020
The test app activity in mapbox/mapbox-gl-native-android#314 doesn't apply any type of anchor/offset, which means the middle of the window stays on top of the
Featurecoordinate, rather than theVbottom tick part of the window sitting right above the anchor coordinate.I'm still very much exploring this new stretchable core Mapbox API, but I'm finding it hard to work with the stretching + offset/anchor. It might be easy to set
ImageStretchesvalues and other stuff, if the specific text is known. However, it seems like it'd be tough to wrap and position icon+text of dynamic data that's coming from a REST get call from a cloud server or something.Worked on this on https://github.com/mapbox/mapbox-android-demo/pull/new/ls-stretchable-icon-example-and-refactor-other-examples in case you wanna' give it a shot yourself. Some of the things I tried are below.
VERSION 1:
Bottom of window stays on the actual anchor coordinate

VERSION 2:
Despite the use of

iconAnchor(ICON_ANCHOR_BOTTOM),, the bottom of the window doesn't respect the actual anchor coordinate.VERSION 3:
The text and window don't even show up