I want to create InfoWindow with custom margins. It's possible when I override getInfoWindow() from InfoWindowAdapter, but I have to maintain tooltip background by myself. I'd like to use original, default background.
Where this .xml/9-path resource can be found?
Related
I have already implemented Search Interface for my app following the steps outlined in the guide below:
https://developer.android.com/guide/topics/search/search-dialog
I want to create custom styling for the SearchView as used in Google Chrome app and Google Photos app
How can we style Android SearchView embedded in Toolbar using Android Support Library?
I've already seen the following answer but that's limited to icons and text styling. I want to create custom borders and backgrounds.
https://stackoverflow.com/a/28018439/4419474
You can create a drawable XML with shape rectangle and add the tags of corner radius, solid colour to define your background shape.
Then add this drawable XML as background to the cardView. Inside this cardview add your SearchView widget.
Please let me know if you need any more help.
Just like for marker where we can put drawable for its icon, such as with Marker's .SetIcon(), how to do the same with Mapbox's polyline?
I've searched Google but, CMIIW, seems like there isn't a way to do that yet? Some links I think are related:
Github - Dotted Polyline on Android
Runtime Styling API
Any suggestion?
Unfortunately, Polyline doesn't support custom patterns. What I'd suggest is using LineLayer with PropertyFactory.linePattern() where you pass ID of an image previously added to the map via MapboxMap#addImage().
Here is an example activity that uses LineLayer.
So far it seems like the API is limited to just being able to change the icon, but it would be nice if you could define a layout file or add a label above the icon that shows the title for instance, instead of requiring a tap interaction to show the info window. It's possible with Google Maps to define a layout and use that to create a cluster item to achieve this, but is it possible with MapBox since it is based on Mapbox GL?
Is this what you are trying to accomplish using Mapbox, bubble icons? They take in a string (in the image it is a price) and creates a bitmap icon for you to use as a marker icon.
I'll edit my answer with code if this is what you want.
Is there a way, to change the standard grey background color of google maps, if the map type is selected as Map_Type_None.
Thanks for help
Two ways to do this.
Add a custom overlay to the map.
Change the hierarchy of your layout(View Group), so that google map will be below other views!
Is there a way to add shadow conveniently as in V3? Otherwise my solution is to add another marker to the same location with its icon the shadow of the original marker's icon.. and with click listener disabled.. That seems bad though. Any idea? Thanks in advance!:)
Create a Bitmap that contains both marker and its shadow and assign it using BitmapDescriptorFactory.fromBitmap or simply create a png file that contains all you need and use BitmapDecriptorFactory.fromResource.