【发布时间】:2017-12-09 07:15:54
【问题描述】:
我将我的 android studio 更新到最新版本 - 3.0.1。从那时起,它在以下代码行中为 Theme 和 ThemeOverlay 抱怨“无法解析符号”。 应用程序运行良好,但在文件中它们被标记为红色。
styles.xml
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar"></style>
<style name="AppTheme.AppBarOverlay" parent="ThemeOverlay.AppCompat.Dark.ActionBar" />
<style name="AppTheme.PopupOverlay" parent="ThemeOverlay.AppCompat.Light" />
build.gradle 已更新为最新版本
dependencies {
classpath 'com.android.tools.build:gradle:3.0.1'
}
【问题讨论】:
-
你需要检查这个:- stackoverflow.com/questions/40822173/…
-
我也是,在 3.0 中面临同样的问题。但是,该应用程序运行良好。
-
您可以提出问题developers.google.com/issue-tracker/guides/create-issue-ui。可能是这背后的原因。
-
我面临同样问题的任何解决方案
-
这里有类似的问题(AS 3.1.3):在清单中,这一行有一个错误(红色):
android:theme="@style/AppTheme.ActionBar">,而在styles.xml中,Theme和@987654327这两个字@ 是红色的,带有错误消息AppTheme.ActionBaris not found。
标签: android build.gradle android-theme android-appcompat