1

我正在做一个项目,我需要在圆圈内显示地图。如何在圆圈内显示地图视图。 在此处输入图像描述

4

2 回答 2

1

您可以使用 FrameLayout 组合布局。第一项必须是 MapView,然后是 ImageView,该 ImageView 引用了具有该圆圈透明的 png。希望有帮助。

编辑添加一个例子:

<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent" >

    <com.google.android.maps.MapView
        android:id="@+id/mapview"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent"
        android:clickable="true"
        android:apiKey="whateverYourApiKeyIs"/>

    <ImageView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:src="@drawable/fullSizeImageWithTransparentCircle"/>

</FrameLayout>
于 2012-11-28T09:22:28.010 回答
0

既然你写了这么糟糕的问题。请允许我以同样的方式回答。
取一张地图。
圆角造型

我什至会给你一个圆角的链接

于 2012-11-28T09:14:10.223 回答