Questions tagged [staggered-gridview]

An Android staggered grid view which supports multiple columns with rows of varying sizes.

An Android staggered gridView which supports multiple columns with rows of varying sizes.

The StaggeredGridView was developed due to requirements for the Etsy app not met by any existing Android libraries. Namely a stable implementation with the ability to have a different number of columns in landscape & portrait, to sync grid position across orientation changes and support for headers & footers.

The most famous example of a staggered gridview is probably the one from etsy: https://github.com/etsy/AndroidStaggeredGrid

195 questions
5
votes
1 answer

Multiple number of columns in a single StaggeredGridView?

Can we have multiple number of columns in a single StaggeredGridView? For example 1 column in the first row, 3 columns in second row and 2 columns in 3rd? Actually, I want to achieve something close to the functionality of Google calendar in which…
5
votes
3 answers

How to find cell width from StaggeredGridLayoutManager?

I have a StaggeredGrid in a RecyclerView and I am trying to dynamically set the image height in the onBindViewHolder. I thought the StaggeredGrid was supposed to handle all this automatically, so I set android:layout_width="match_parent and…
5
votes
0 answers

Android 5.0, how to scroll grid to a fixed position using Etsy StaggeredGridView

i've been working with Etsy's StaggeredGridView for a while, and i'm quite happy with it, but now i have a problem which i am not able to solve. I need to scroll to a fixed position (in pixels or in adapter position) within the list and i am using…
Hugo
  • 1,662
  • 18
  • 35
5
votes
3 answers

How to reflow items in a RecyclerView with the StaggeredGridLayoutManager

I'm playing around with the StaggeredGridLayoutManager and have something close to what I want. I have a horizontal staggered grid with 2 rows, where some items are the height of 1 row, and others span both rows. I want the single row height items…
Niraj
  • 5,270
  • 2
  • 13
  • 19
5
votes
0 answers

Android Staggered/Multi-line Linear Layout?

For my app, I'm trying to have a section listing the tags in an article but I wasn't able to find an Android Layout that can achieve this. Basically, I have an array of strings which contains anywhere from 1 to 5 elements. I want to be able to list…
5
votes
0 answers

Android StaggeredGridView inside ListView height

When i place StaggeredGridView in ListView item its height becomes zero. I tried to modify onMeasure like in this answer, but it has no effect. Modified StaggeredGridView: public void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { int…
Pavel M.
  • 263
  • 1
  • 9
5
votes
2 answers

How to use PullToRefresh in StaggeredGridView?

I am using Staggeredgridview in my Project. I've downloaded StaggeredGridView library and demo from here: https://github.com/maurycyw/StaggeredGridViewDemo https://github.com/maurycyw/StaggeredGridView I need to PullToRefresh for that entire…
Gioan Doan
  • 112
  • 8
4
votes
1 answer

Flutter “RenderFlex children have non-zero flex but incoming height constraints are unbounded.” when using Staggered Grid View~ @_@

@_@ I was thinking to make the widgets inside the GridView to have a different height according to their dynamic content height. The widget looks like this: Container( decoration: BoxDecoration( …
Ryan Wang
  • 418
  • 7
  • 23
4
votes
1 answer

Jumbled tiles in itemTouchHelperCallback in StaggeredGridLayoutManager

I am using StaggeredGridLayoutManager in my code. Take a look at this first: I am facing these problems: In 1st attempt, I move the tile '1' directly upwards by one step and then stop. Everything looks good and the tile labled as '1' replaces…
4
votes
1 answer

Android Studio: Unable to find explicit activity class but activity already declared in AndroidManifest.xml

New to Android Studio here. I am trying to make it so when I click on an image from a ViewHolder in a RecyclerView, it would open up another activity that opens up another layout. However, I am getting this error even though I already declared the…
CLORO
  • 37
  • 2
  • 7
4
votes
3 answers

StaggeredLayout with FlexboxLayoutManager

I there any way to implement a staggered layout using google's Flexbox library similar to this The above layout is created using StaggeredLayoutManger also maintaining the aspect ratio of the image I have tried the code: recyclerView.apply { …
Prithvi Bhola
  • 3,041
  • 1
  • 16
  • 32
4
votes
0 answers

Can staggered manage view based on the content's width and scroll as vertical?

I am using staggered view to create view tag which will contain text-view but I am facing a problem to manage my content If I am using Staggered Horizontal Manager this is managing my tags based on content's width as I want but the scrollable is…
Abdul Rizwan
  • 3,904
  • 32
  • 31
4
votes
3 answers

Android - StaggeredGrid wrong items disposition

I have a problem with my Recycler view and StaggeredGrid which cut the width by 2. I load images into items with Picasso and when I load image first time, they are disposed strangely in the recycler view. After reloading, everything seems good. I…
Okn
  • 698
  • 10
  • 21
3
votes
1 answer

Android how can I achieve a arrow based layout?

I want to know how is possible to achieve a arrow-based layout like this : Any idea about what Layout is using this app in order to achieve that layout ? It seems like a kind of Staggered Grid Layout maybe ? Or maybe is using a library or a…
3
votes
3 answers

Display tag like structure in Staggered Recyclerview

I am working on a tag structure currently and to display that I have used Staggeredgrid layout manager of Recyclerview to get the required result as below image: But when I used StaggeredGrid, It is providing result as below: My code to display…
1
2
3
12 13