Cleveroad / CycleMenu

Custom LayoutManager for the inner RecyclerView

Home Page:https://www.cleveroad.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Menu items do not fit into the view

reversecoder opened this issue · comments

Hello,

Thanks for the beautiful library.

I have used CycleMenu into the activity view. I wanted to add 3 items into view. The parent view is a relative layout-

`

<com.cleveroad.cyclemenuwidget.CycleMenuWidget
    android:id="@+id/cycleMenuView"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:layout_alignParentBottom="true"
    app:cm_autoMaxRadius="180dp"
    app:cm_autoMinRadius="10dp"
    app:cm_corner="right_bottom"
    app:cm_fixedRadius="200dp"
    app:cm_item_background_tint="#6a81fe"
    app:cm_radius_scale_type="auto"
    app:cm_scroll_type="endless" />

`
And Called from activity like thus-

CycleMenuWidget cycleMenuWidget = (CycleMenuWidget) findViewById(R.id.cycleMenuView); cycleMenuWidget.setMenuRes(R.menu.cycle_menu_3);

Finally getting this result-

screenshot_20180114-170703

I have also tried to add this programmatically, but always goes one item under layout from 3 three items. But in recycler view 3 items fit properly.

screenshot_20180114-175513

Thanks in advance for any workaround without recyclerview.

You can use the
cycleMenuWidget.setCurrentItemsAngleOffset(double angle)
method from the library to tackle your issue, just put suitable angle there.

In version 1.0.2 of the library this was fixed.