Android 支持库 23.2.0 错误设置 style="@style/Widget.AppCompat.Button.Colored"

Android support library 23.2.0 error in setting style="@style/Widget.AppCompat.Button.Colored"

我正在使用所有最新的工具和 gradle 版本来实现我的应用程序。 以前,一切正常,但现在彩色按钮样式在低于 Lollipop 的版本中会导致错误。

我正在使用的父主题-

Theme.AppCompat.Light.NoActionBar

和主题中定义的颜色-

"colorPrimary", "colorPrimaryDark", "colorAccent", "colorButtonNormal", colorControlNormal", "colorControlActivated", "colorControlHighlight"

这是按钮视图--

line:114 <android.support.v7.widget.AppCompatButton
    android:id="@+id/act_first_lock_btn_next"
    style="@style/Widget.AppCompat.Button.Colored"
    android:layout_width="200dp"
    android:layout_height="wrap_content"
    android:layout_gravity="center_horizontal"
    android:layout_marginBottom="20dp"
    android:text="@string/next" />

这是 kitkat 4.4.4 中的崩溃-

Caused by: android.view.InflateException: Binary XML file line #114: Error inflating class android.support.v7.widget.AppCompatButton

如果我删除样式 style="@style/Widget.AppCompat.Button.Colored",错误就消失了但按钮上没有颜色。

我在错误发生之前更改的最后一件事已更新为支持 lib 版本 23.2.0。

--更新--

这绝对是支持库 23.2.0 的一个错误。 在这里报告错误- https://code.google.com/p/android/issues/detail?id=201937

Chris Banes(google 开发人员)已将问题合并到-

https://code.google.com/p/android/issues/detail?id=201817

我在其他机器上测试过,它是支持库版本 23.2.0 中的一个错误

所以我已经举报了 AOSP issue tracker here.

如果您遇到同样的问题...请在上面 link.

加注星标

谢谢。

更新 支持库版本 23.2.1 来了... 很有魅力!!

更新 支持库 23.3.0 来了... 魅力消失了...... 完整故事 .

我想支持库需要在最终发布之前进行很好的测试..

尝试将 style="..." 更改为 android:theme="..."