Android预览仅显示带有文本“ android ... ConstraintLayout”的灰屏

时间:2019-05-15 06:49:19

标签: java android android-studio android-layout

    

<TextView
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:text="Hello World!"
    app:layout_constraintBottom_toBottomOf="parent"
    app:layout_constraintLeft_toLeftOf="parent"
    app:layout_constraintRight_toRightOf="parent"
    app:layout_constraintTop_toTopOf="parent" />

`

Android Studio IDE突然停止在预览屏幕上显示小部件,无论我拖动到那里,它都会将所有内容拉向屏幕左上方,也表明缺少约束。

我已经解决了缺少的约束错误,渲染问题,IDE甚至显示构建成功。 gradle已全部设置,没有错误。但是似乎没有任何解决灰色预览问题的方法。文件→无效/重新启动缓存无效。

enter image description here

0 个答案:

没有答案