I have just updated to Android Studio version 3, however it I am unable to see my layouts in the preview window as each element is just a grey box like this: Blank layout
The error in the Issues window says
Exception Details java.lang.ClassNotFoundException: android.support.v4.view.TintableBackgroundView
along with several other classes that are unable to be found
and here are the relevant parts of the build.gradle for my app:
apply plugin: 'com.android.application'
apply plugin: 'me.tatarka.retrolambda'
apply plugin: 'kotlin-android'
android {
compileSdkVersion 23
buildToolsVersion '25.0.3'
defaultConfig {
applicationId "com.myapp.app"
minSdkVersion 16
targetSdkVersion 23
versionCode 123
versionName "1.2.3"
vectorDrawables.useSupportLibrary = true
}
dexOptions {
javaMaxHeapSize "6g"
}
packagingOptions {
exclude 'META-INF/rxjava.properties'
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
}
repositories {
mavenCentral()
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile "org.jetbrains.kotlin:kotlin-stdlib-jre7:$kotlin_version"
compile 'com.android.support:appcompat-v7:23.4.0'
compile 'com.android.support:design:23.4.0'
compile 'com.google.android.gms:play-services-appindexing:8.3.0'
compile 'com.google.android.gms:play-services-gcm:8.3.0'
compile 'com.android.support:recyclerview-v7:23.4.0'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
compile 'com.android.support:customtabs:23.4.0'
compile 'com.android.support:support-v4:23.4.0'
testCompile 'junit:junit:4.12'
testCompile 'com.squareup.leakcanary:leakcanary-android-no-op:1.5.1'
debugCompile 'com.facebook.stetho:stetho:1.5.0'
debugCompile 'com.facebook.stetho:stetho-urlconnection:1.5.0'
debugCompile 'com.squareup.leakcanary:leakcanary-android:1.5.1'
releaseCompile 'com.squareup.leakcanary:leakcanary-android-no-op:1.5.1'
debugCompile "com.github.brianPlummer:tinydancer:0.1.2"
releaseCompile "com.github.brianPlummer:tinydancer-noop:0.1.2"
testCompile "com.github.brianPlummer:tinydancer-noop:0.1.2"
}
apply plugin: 'com.google.gms.google-services'