Как разделить экран на пять равных кругов. Я использую файл XML в качестве backgorung для круговРазделить экран на пять равных кругов
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item>
<shape android:shape="oval">
<solid android:color="#59d5fe"/>
</shape>
</item>
</selector>
и это код
LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:id="@+id/img6"
android:weightSum="5"
android:orientation="horizontal" >
<ImageView
android:layout_width="0dp"
android:layout_weight="1"
android:background="@drawable/vectorshape"
android:scaleType="fitXY"
android:id="@+id/img1"
android:layout_height="wrap_content"/>
<ImageView
android:layout_width="0dp"
android:background="@drawable/vectorshape"
android:scaleType="fitCenter"
android:layout_weight="1"
android:id="@+id/img2"
android:layout_height="wrap_content"/>
<ImageView
android:layout_width="0dp"
android:background="@drawable/vectorshape"
android:scaleType="fitCenter"
android:layout_weight="1"
android:id="@+id/img3"
android:layout_height="wrap_content"/>
<ImageView
android:layout_width="0dp"
android:background="@drawable/vectorshape"
android:scaleType="fitCenter"
android:id="@+id/img4"
android:layout_weight="1"
android:layout_height="wrap_content"/>
<ImageView
android:layout_width="0dp"
android:layout_weight="1"
android:scaleType="fitCenter"
android:id="@+id/img5"
android:background="@drawable/vectorshape"
android:layout_height="wrap_content"/>
</LinearLayout>
</LinearLayout>
Особенно я хочу размер высоты, чтобы быть таким же, как размер ширины, но давая пустой экран до тех пор, пока размер не будет определен в dp.
И как соединить его с деятельностью потому что я получил эту ошибку. Android.Views.InflateException: двоичная строка XML-файла # 1: двоичная строка XML-файла # 1: ошибка раздувания класса SharpText_Demo.Sq uareImageView на SetContentView – Merian
Красивое объяснение, вероятно, было связано с тем, что в регистре SharpText_Demo.SquareImageView был с более низким s. Благодарю. – Merian