Quantcast
Channel: Recent Discussions — DataTables forums
Viewing all articles
Browse latest Browse all 82127

Head/Body misalignment when both horizontal/vertical scrolling is enabled

$
0
0
Hi guys,
When both sScrollY and sScrollX are used, if you scroll horizontally up to the limit then the head and the body of the table get misaligned because when the vertical scrollbar appears next to the body it's included in the body's width.

You can see this in the example in the site:
http://datatables.net/release-datatables/examples/basic_init/scroll_xy.html

When you scroll up to the limit at the right you'll see that at some point the header stays fixed and the body keeps scrolling.

The problem is that if you CSS the table and user lines for separating columns this is too visible.

I think that 2 potential solutions would be either (a) make the viewport of the body wider so the scrollbar is out of it; or (b) make the header wider so the header's width = body's width + scrollbar's width. But not sure (didn't look into the code).

Thanks!
Martin

Viewing all articles
Browse latest Browse all 82127

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>