Skip to content

New FlexibleItemDecoration #382

@davideas

Description

@davideas

The new item decorator should implement identical drawing technique of DividerItemDecorator (from Android API); Should have equal item offset; Section gap offset; Should work with all layouts and orientations.

For item spacing technique, the open source decorator ibosong/CommonItemDecoration can be merged.

Details of the functionalities:

  • Supports all RecyclerView LayoutManagers that implement (Linear, Grid or StaggeredGrid).
  • Can add equal space offset at all sides of an item.
  • Can customize the offset for each view type.
  • Can customize the offset at the 4 edges: first and last column / first and last row.
  • Recognizes the sections of FlexibleAdapter and can add gap offset between them.
  • Recognizes the orientation of the current Layout.
  • Supports the default Android divider android.R.attr.listDivider.
  • Supports a custom divider by DrawableRes id.
  • Supports drawing the divider over or underneath the items.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions