No custom scrollbars on Lion, Gmail, Google Reader

By bfred.it Last update Nov 3, 2011 — Installed 733 times.

Script Summary: This disables custom WebKit scrollbars everywhere, especially on Google Reader and Gmail. Ideal for Lion users



Version: 1.00

Custom scrollbars? Ew!

This scripts disables the custom scrollbars we find on websites like Gmail and Google Reader. Unfortunately I was only able to hide them rather than replace them with the default ones, but it's better than nothing

Before and after picture

If the scrollbars are still there try to refresh the page (this might happen in Gmail).

Why doesn't replace them with the default ones? (technical)

Because it's basically impossible.

::-webkit-scrollbar cannot be simply overridden to get the default style, the only way to do it is to remove all ::-webkit-scrollbar rules from the code. At that point, scrollable areas have to be forced to redraw the scrollbars. To do that you either quickly add and remove display:none; from <html> or do the same thing with overflow:hidden; on scrollable elements. The problem with the first one is that the page flashes white at every page load; the second one is resource-intensive as it would have to whether check any element on the page overflows—not ideal.

So what does this script do? (technical)

It reduces the width and height of the scrollbars to 0 to make them invisible.