Theme.AppCompat在Android Studio中找不到

ppcbkaq5  于 2023-05-23  发布在  Android
关注(0)|答案(1)|浏览(218)

我需要使用Theme.AppCompat.Light.NoActionBar,但在Android Studio how it looks中找不到Theme.AppCompat
我添加了实现'com.android.support:appcompat-v7:28.0.0'到gradle,但问题仍然是一样的
Gradle中的依赖项:

dependencies {

    implementation 'androidx.core:core-ktx:1.10.1'
    //
    implementation 'androidx.room:room-ktx:2.5.1'
    kapt "androidx.room:room-compiler:2.5.1"
    implementation 'androidx.lifecycle:lifecycle-livedata-ktx:2.6.1'
    implementation 'androidx.lifecycle:lifecycle-viewmodel-ktx:2.6.1'
    implementation 'androidx.preference:preference-ktx:1.2.0'
    implementation(platform("org.jetbrains.kotlin:kotlin-bom:1.8.0"))
    implementation 'com.android.support:design:28.0.0'
    implementation 'com.google.android.material:material:1.9.0'
    implementation 'com.android.support:appcompat-v7:28.0.0'
    implementation 'com.google.android.material:material:1.10.0-alpha03'
    //
    implementation 'com.google.android.material:material:1.9.0'
    implementation 'androidx.lifecycle:lifecycle-runtime-ktx:2.6.1'
    implementation 'androidx.activity:activity-compose:1.7.1'
    implementation platform('androidx.compose:compose-bom:2022.10.00')
    implementation 'androidx.compose.ui:ui'
    implementation 'androidx.compose.ui:ui-graphics'
    implementation 'androidx.compose.ui:ui-tooling-preview'
    implementation 'androidx.compose.material3:material3'
    implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
    testImplementation 'junit:junit:4.13.2'
    androidTestImplementation 'androidx.test.ext:junit:1.1.5'
    androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1'
    androidTestImplementation platform('androidx.compose:compose-bom:2022.10.00')
    androidTestImplementation 'androidx.compose.ui:ui-test-junit4'
    debugImplementation 'androidx.compose.ui:ui-tooling'
    debugImplementation 'androidx.compose.ui:ui-test-manifest'
}

我添加了实现'com.android.support:appcompat-v7:28.0.0'到gradle,但问题仍然是一样的

ymdaylpp

ymdaylpp1#

添加此库
实现'androidx.appcompat:appcompat:1.6.1'
确保最新的应该实施它将解决这个问题。同时也评论了旧图书馆
实现'com.android.support:appcompat-v7:28.0.0'

相关问题