简体   繁体   English

如何在android中实现圆形菜单

[英]How to implement circular menu in android

I started customizing circular widget on my android application.我开始在我的 android 应用程序上自定义圆形小部件。 i got something similar to my requirements by converting recycler view into a curved shape.通过将回收器视图转换为弯曲形状,我得到了与我的要求类似的东西。 but the problem is multiple layers are overlapping each other.但问题是多层相互重叠。 how to make layers independently clickable.如何使图层可独立点击。 please help me out.请帮帮我。 Thanks in advance.提前致谢。

look at this This is how recycler views are overlapping each other看看这个 这是回收者视图如何相互重叠

the expected design looks like this预期的设计是这样的

Use this in your drawable file.在您的可绘制文件中使用它。 it will be make right curve.这将是正确的曲线。

<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
    android:shape="rectangle">
    <solid android:color="@color/colorPrimary" />
    <corners android:topRightRadius="150dp" />
</shape>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM