scroll bars

Page: 1

Author Post
Member
Registered: Aug 2012
Posts: 22
Location: Bondi Beach Sydney Australia
hi,

removeScrollbars: true,

i would like to deactivate the host scrollbar without removing it because the overlayed content on my page beneath my floatbox shifts when the page becomes slightly wider as the scrollbar is removed. then it shifts again when the scrollbar returns.

this is undesired effect for me
but i do want to disable the host scroll bar

instead can the dark overlay effect on the host page be extended over the host scrollbars making them inactive by some other command?


thanks david d
Administrator
Registered: Aug 2008
Posts: 3382
It's been ages since I've had reason to look at the removeScrollbars option. I had to do research. :)

First, no, there is no possibility to position any html elements such that they appear over top of and obscure the scrollbars. Forget trying to get the translucent overlay to cover them.

The removeScrollbars option is available only when disableScroll is set to true and in effect. The disableScroll option assigns fixed positioning to the floatbox. This causes the floatbox to stay put on the screen if the user scrolls the page, and may be sufficient for your purposes. However, be aware that just because disableScroll might be set to true doesn't guarantee that it is in effect. Not all browsers have well-behaved fixed-positioning support and fixed positioning won't be applied if the floatbox is larger than the visible screen viewport.

As for removeScrollbars: this works by assigning a right-margin the size of the measured scrollbar width to the page's html element and then setting overflow:hidden on that element. The assignment of the right margin is intended to prevent the page from shifting when the scrollbar is removed. I've never seen any page shifting in my testing of this option. I wonder if your page might already have a margin of some size set on the html element and that this accounts for the shift you are seeing? If you want to link me in to a page that has this shifty behaviour, I'd love to poke around and see why it happens there.

It occurs to me that you might be viewing the page from a Mac. On some browsers on the Mac platform (the standard Safari included), scrollbars are abnormal in the sense that they overlay the document content and don't displace the space available for that content. I should probably adjust the removeScrollbars option so that it does not add a margin when running under these browsers as that might account for the page shift you are reporting.

A rambling response, with no concrete action for you to take. If you've got a page I can see, great. If you've got margins on the html element, you'll probably get better behaviour with that option if you remove those margins (maybe move them to the body). No, I don't know of another way in which the scrollbars can be incapacitated.

Page: 1