Это статический xml, который у меня есть:
<LinearLayout
android:id="@+id/LinearLayout"
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<RelativeLayout
android:id="@+id/Header"
android:layout_width="fill_parent"
android:layout_height="0dp"
android:layout_weight="1.5"
android:background="@drawable/header_bg"
android:padding="0dp"
>
<ImageView
android:id="@+id/hLogo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:src="@drawable/logo"
/>
<TextView
android:id="@+id/hActiveCategory"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:text="Today"
android:textSize="18sp"
android:textColor="#FFFFFF"
/>
<Button
android:id="@+id/hRefreshButton"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:drawableRight="@drawable/refresh"
android:layout_alignParentRight="true"
android:padding="0dp"
/>
</RelativeLayout>
</LinearLayout>
Что происходит? - когда я пытаюсь выровнять кнопку с id = hRefreshButton справа от его родителя ( RelativeLayout с id = Заголовок ) между кнопкой и правой границей экрана все еще есть место. Почему это происходит? Какие-либо предложения? Также я должен подчеркнуть, что я тестирую на эмуляторе AVD.