mapFragment issue with match_parent
See original GitHub issueHi, TnQ for this great library. There is a problem in my project. I have an activity contains BottomBar. ( Bellow Activity’s XML )
<CoordinatorLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<NestedScrollView
android:layout_width="match_parent"
android:layout_height="match_parent">
<!-- This is For Replacing Fragment -->
<FrameLayout
android:layout_width="match_parent"
android:layout_height="match_parent" />
</NestedScrollView>
</CoordinatorLayout>
On one of BottomBars Tab has a mapFragment ( Bellow XML )
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent" >
<fragment
android:id="@+id/frag_map"
android:name="com.google.android.gms.maps.SupportMapFragment"
android:layout_width="match_parent"
android:layout_height="match_parent" />
</RelativeLayout>
The first problem is that when i trying to view this mapFragment its height collapses to a small height ( but in xml you see that its height is set to “match_parent”). I change the size of height manually (ex: 400dp. but We cant be sure that it fits the height of any device) and i can see map. But Second problem is that I cant scroll in vertical direction (in map).
Issue Analytics
- State:
- Created 7 years ago
- Comments:11
Top Results From Across the Web
Height MapFragment Layout not work - Stack Overflow
came across this same issue but my map fragment is inside a scrollview and it needs to have a scrollview since there are...
Read more >Bug: Options can't be set on MapFragments included in other ...
android:layout_width="match_parent" ... Same issue here, if the XML has only the Map fragment it works perfectly fine,but if there is a parent layout...
Read more >SupportMapFragment | Maps SDK for Android
A Map component in an app. This fragment is the simplest way to place a map in an application. It's a wrapper around...
Read more >Support map fragment | Maps SDK v9 | Android - Mapbox docs
Include a map fragment within your app using Android support library. ... android:layout_height="match_parent". android:background="@color/md_divider_white".
Read more >MapFragment ArcGis - The specified child already h... - Esri ...
The main content view --> <FrameLayout android:id="@+id/maps_app_activity_content_frame" android:layout_width="match_parent" ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Did it work for you?
@Xstar97 I’ve not tested yet. Tnq for ur concern. i will inform you when i tested this.