小编Nik*_*aye的帖子

创建磨损应用 XML 时遇到问题:AAPT:错误:未找到属性 android:boxedEdges

在下面的 XML 中,我在android:boxedEdges="all". 我试图删除这条线但没有解决它。

我仍然收到 AAPT:错误:找不到属性 android:boxedEdges

 <?xml version="1.0" encoding="utf-8"?>
    <androidx.wear.widget.BoxInsetLayout
        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"
        android:background="@color/dark_grey"
        android:padding="@dimen/box_inset_layout_padding"
        tools:context=".MainActivity"
        tools:deviceIds="wear">

        <FrameLayout
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:padding="@dimen/inner_frame_layout_padding"
            android:boxedEdges="all">

            <TextView
                android:id="@+id/text"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_gravity="center_horizontal"
                android:text="@string/hello_world" />

            <Button
                android:layout_width="wrap_content"
                android:layout_gravity="center"
                android:layout_height="wrap_content"
                android:text="Press Here" />

        </FrameLayout>
    </androidx.wear.widget.BoxInsetLayout>
Run Code Online (Sandbox Code Playgroud)

这是一个简单的wear OS 项目。我是新手,所以任何帮助或链接都会很感激。

xml android kotlin

3
推荐指数
1
解决办法
1241
查看次数

标签 统计

android ×1

kotlin ×1

xml ×1