My project can't render the layout in preview. My Android Studio version 3.1.2. Im using API 28. This my activity_main.xml
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity"
android:id="@+id/frame_container">
<TextView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:text="Hello World"
android:gravity="center"/>
</android.support.constraint.ConstraintLayout>
It's simple, just to print Hello World to layout, but it can't show. The error like below :
I search the solve problem, the solution is using API 26. And i try, everything is normal, preview success. But i create Fragment Activity, the problems come back, preview can't show. If you have new solution, please help me!