Android TextView textColor不';t更改(应用程序兼容)

Android TextView textColor不';t更改(应用程序兼容),android,android-layout,Android,Android Layout,你好,斯塔克弗劳尔斯兄弟,我需要你的帮助 我正在移动应用程序中使用主题.AppCompat.Light.darkaActionBar.NoActionBar主题 <style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar"> <!-- Customize your theme here. --> <item name="colorPrimary"

你好,斯塔克弗劳尔斯兄弟,我需要你的帮助

我正在移动应用程序中使用
主题.AppCompat.Light.darkaActionBar.NoActionBar
主题

<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
            <!-- Customize your theme here. -->
            <item name="colorPrimary">@color/colorPrimary</item>
            <item name="colorPrimaryDark">@color/colorPrimaryDark</item>
            <item name="colorAccent">@color/colorAccent</item>
        </style>

        <style name="AppTheme.NoActionBar">
            <item name="windowActionBar">false</item>
            <item name="windowNoTitle">true</item>
        </style>
更令人惊讶的是,当我设置
android:background“
时,背景会按预期显示。但这是我想要使用的文本颜色


谢谢。

确保主题已应用于AndroidManifest.xml中的应用程序

如果这一点不起作用,请尝试将其插入片段的onCreateView()


使用此充气器1充气片段的视图。

确保主题应用于AndroidManifest.xml中的应用程序

如果这一点不起作用,请尝试将其插入片段的onCreateView()


使用此充气器1充气片段的视图。

你好,Harsha,我这么做了,现在按钮的文本颜色只改变了。TextView仍然是灰色的。这不是很奇怪吗?TextView有什么特别之处。John。不要在文本视图内覆盖主题。只需删除TextView内的主题。嗨,Harsha,我已经解决了我的问题。看来我已经解决了s正在使用android:hint=“客户端名称”“提示的默认颜色为灰色。将提示改为文本有效:)愚蠢的错误谢谢你的帮助。你好,哈莎,我做到了,现在按钮的文本颜色只改变了。文本视图仍为灰色。这不是很奇怪吗?文本视图有什么特别之处。约翰。不要在文本视图中隐藏主题。只需删除文本视图中的主题。嗨,哈莎,我已经解决了我的问题。看起来我使用的是android:hint=“Client Name”提示的默认颜色是灰色。将提示改为文本有效:)愚蠢的错误谢谢你的帮助。
<style name="textView">           
            <item name="android:textColor">@color/colorIcons</item>          
        </style>

  <TextView
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:hint="Client Name"
            android:paddingLeft="5dp"
            android:theme="@style/textView"
            />
final Context context = new ContextThemeWrapper(getActivity,R.style.textView)
final LayoutInflater inflater1 = inflater.cloneInContext(context);