2

Android experience level: Novice.

<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
        android:layout_width="fill_parent"
        android:layout_height="wrap_content"
        android:orientation="vertical"
        android:layout_marginTop="?android:attr/actionBarSize"
        android:padding="10dp"
        android:fillViewport="false">

I have applied top margin to the ScrollView which is the height of actionBar. That works well in two of my physical devices properly but not in one. Why the one device does not utilize the value?

Screenshots attached.

Lenovo A7000 with Marshmallow 6.0 Stock ROM:

Below the action bar, one or two lines are not visible. Probably behind the actionBar.

Lenovo A7000 with Marshmallow 6.0 Stock ROM

HTC phone and Samsung tablet: The text appears fine.

HTC Desire 620G with KitKat Stock ROM Samsung Galaxy Tab 2

Sarvap Praharanayuthan
  • 4,212
  • 7
  • 47
  • 72

1 Answers1

1

Try changing attribute value to ?attr/actionBarSize rather than using ?android:attr/actionBarSize

Rafay Ali
  • 723
  • 7
  • 15