I have the following code that displays two textviews and below I have a fragment where I display a map of Google Maps. But still I'm not able to display them in this way:
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context="${relativePackage}.${activityClass}" >
<TextView
android:id="@+id/textView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:layout_alignParentTop="true"
android:layout_marginLeft="27dp"
android:layout_marginTop="35dp"
android:layout_alignParentBottom="true"
android:text="@string/pos_actual" />
<TextView
android:id="@+id/txtGeoposition"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignTop="@+id/textView1"
android:layout_toRightOf="@+id/textView1"
android:layout_alignParentBottom="true"
android:layout_above="@+id/map"
android:textAppearance="?android:attr/textAppearanceLarge" />
<fragment
android:id="@+id/map"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_above="@+id/textView1"
class="com.google.android.gms.maps.MapFragment" />
Also I want to limit the height of the fragment for not to fill the rest of the parent layout, just a few pixels of height, because below the map I want to put other controls to display.
How can I achieve this controls to put them in this way?
Thank you in advance
0 comments:
Post a Comment