Как получить «? Android: attr / actionBarSize» с библиотекой совместимости

Я пытаюсь использовать фрагменты и ActionBar в проекте Android 2.2. При использовании «? Android: attr / actionBarSize» возникает ошибка, как правильно получить и установить это значение?

Пример:

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:orientation="horizontal"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:id="@+id/frags">

    <fragment class="com.example.android.hcgallery.TitlesFragment"
            android:id="@+id/frag_title"
            android:visibility="gone"
            android:layout_marginTop="?android:attr/actionBarSize"
            android:layout_width="@dimen/titles_size"
            android:layout_height="match_parent" />

    <fragment class="com.example.android.hcgallery.ContentFragment"
            android:id="@+id/frag_content"
            android:layout_width="match_parent"
            android:layout_height="match_parent" />

</LinearLayout>

Ошибка: не найден ресурс, который соответствует указанному имени (в 'layout_marginTop' со значением '? Android: attr / actionBarSize').

Ответы на вопрос(2)

Ваш ответ на вопрос