我一直在关注如何更改
color的说明,但程序会产生此错误:
06-29 19:20:39.416 7041-7041 / com.example.lucerne.adapter_example_2 E / AndroidRuntime:FATAL EXCEPTION:main
Process: com.example.lucerne.adapter_example_2, PID: 7041
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.lucerne.adapter_example_2/com.example.lucerne.adapter_example_2.MainActivity}: java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this activity.
目前,style.xml如下所示:
@color/colorPrimary
@color/colorPrimaryDark
@color/colorAccent
导致错误的原因是什么,以及如何将颜色更改为其他内容?