ddomingues / X-SlickGrid

An extension of SlickGrid providing Frozen Columns and Rows, Tree Columns, etc.
http://ddomingues.com/X-SlickGrid/
MIT License
48 stars 19 forks source link

Always render frozen columns and filter rendering for non-frozen columns #3

Closed ronnykarlsson closed 9 years ago

ronnykarlsson commented 9 years ago

There was a bug which caused frozen columns cell content to disappear when the non-frozen viewport was too wide and scrolled to the right, content then disappears when scrolling up and down in the grid.

Inside the getRenderedRange function it would calculate incorrect viewport dimensions and filter out frozen columns that were visible. I've updated that bit so it'll render a viewport for what's in the right non-frozen part of the grid and then everything that's frozen for the left viewport.

ddomingues commented 9 years ago

Hi @ronnykarlsson! Sorry for my delay.

Thanks for your contribution. Could you add an example that shows this bug?

ronnykarlsson commented 9 years ago

For an example, look at example-frozen-columns.html (http://jlynch7.github.io/SlickGrid/examples/example-frozen-columns.html) and do this:

  1. Set the width of the grid to 400px. $('#myGrid').css('width', '400px')
  2. Set frozen column to 1
  3. Scroll the grid to the right
  4. Scroll down - now the Title-column will be empty.

This bug is produced when the non-frozen width is greater than the grid width.

Francks11 commented 9 years ago

Hi,

I fix the same bug in my pull request and other bugs : https://github.com/ddomingues/X-SlickGrid/pull/3

You can see this bug in following demo : http://jsfiddle.net/Francks11/0kj44tbn/1/

Then following instructions of @ronnykarlsson .

ddomingues commented 9 years ago

Thank you guys!