You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Datatables has an extension that allows a table to scroll and dynamically update its data. I would like to see something like this as an extension to QDataGrid2.
Scrolling:
Two possible approaches:
To use the built-in scrolling ability of a div, Javascript has to be able to calculate the height of the entire table. This implies each cell being the same height. Inside the scrolling div is the painting div, which shows just the data that is visible, and possibly some data before and after the visible area.
Or, to be able to do a table with variable height items, we would also need to create custom scroll bar. The scrollbar scrolls by items, rather than pixels. Drag scrolling would scroll by pixels. Complex, but doable.
This would also imply a change to how the grid is drawn. Instead of drawing the entire table in html, an approach similar to data tables would be needed that first draws a shell of the table, and then uses ajax to ask the server for the data in the cells corresponding to particular rows. This has the added benefit that if the data is watched, the entire table does not need to be redrawn, but just the data inside the table. Doing this would preserve the scroll setting.
The text was updated successfully, but these errors were encountered:
Datatables has an extension that allows a table to scroll and dynamically update its data. I would like to see something like this as an extension to QDataGrid2.
Scrolling:
Two possible approaches:
This would also imply a change to how the grid is drawn. Instead of drawing the entire table in html, an approach similar to data tables would be needed that first draws a shell of the table, and then uses ajax to ask the server for the data in the cells corresponding to particular rows. This has the added benefit that if the data is watched, the entire table does not need to be redrawn, but just the data inside the table. Doing this would preserve the scroll setting.
The text was updated successfully, but these errors were encountered: