[英]Showing map inside a circle
我正在做一個需要在圓圈內顯示地圖的項目。如何在圓圈內顯示mapview。
您可以使用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>
既然你寫了這么一個壞問題。 請允許我以相同的方式回答。
進行mapview。
圓角樣式
我什至會給你一個圓角鏈接
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.