工具栏未显示带有Scrollview的消息

时间:2016-09-01 09:39:30

标签: android android-layout

<ScrollView
 xmlns:android="http://schemas.android.com/apk/res/android"
 xmlns:tools="http://schemas.android.com/tools"
 android:layout_width="match_parent"
 android:background="@drawable/ph_bg"
 android:layout_height="match_parent"
 tools:context=".Profile_Activity"
 >
 <LinearLayout
    android:orientation="vertical"
    android:layout_height="match_parent"
    android:layout_width="match_parent">
 <android.support.v7.widget.Toolbar
        android:id="@+id/profile_appbar1"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:background="@color/theme_color"
        android:minHeight="?attr/actionBarSize" />

活动代码

profile_toolbar = (Toolbar) findViewById(R.id.profile_appbar1); setSupportActionBar(profile_toolbar); getSupportActionBar().setDisplayShowTitleEnabled(false); profile_toolbar.setTitle(Html.fromHtml("<font color='#ffffff'>AppTitle</font>")); getSupportActionBar().setDisplayHomeAsUpEnabled(true); getSupportActionBar().setDisplayShowHomeEnabled(true);

我在Scroll视图中有工具栏,但它没有显示标题 白色我在活动中有上面的代码

0 个答案:

没有答案