ISchwarz23 / SortableTableView

An Android library containing a simple TableView and an advanced SortableTableView providing a lot of customisation possibilities to fit all needs.
Apache License 2.0
1.05k stars 239 forks source link

Setting a dynamic width for horizontal scrolling #184

Open mandretis opened 5 years ago

mandretis commented 5 years ago

This is surely an amazing library and i'm interested in the pro version, but i'm not sure if it does support dynamic width or if i'm just using it the wrong way.

What i want to do is, render all my views with 'wrap-content' as their widths so it can be scrolled horizontally. (To work exactly as .net gridview).

I made some progress with it (by Wrapping a horizontal scrollview around it) but the problem is that the table has to have a fixed size, either match_parent or 1000dp for example.

So Is there a correct way for the table to calculate its width dynamically according to its content's width(preferably by the 'longest row content') ? or perhaps columns to be recycled if 'match_parent' is used to imitate a horizontal scroll behavior?

Thanks in advance.