Please review Scrollbar Paper: an alternative to jScrollPane

829 views
Skip to first unread message

anrikun

unread,
Dec 3, 2009, 5:59:21 AM12/3/09
to jscrollpane
Please review :
http://plugins.jquery.com/project/scrollbarpaper

This plugin is an alternative to jScrollPane.
As Scrollbar Paper's approach is completely different, I have decided
to write a new plugin.

Scrollbar Paper does not replace browser's default scrollbar.
Instead, it covers it with a custom scrollbar, like paper on a wall:
that is why it is called Scrollbar Paper :-)
The benefit of this approach is that the way browser's default
scrollbar behaves is not modified: mouse wheel support, text selection
and scrolling performance are the same as usual.

Besides, Scrollbar Paper's HTML does not wrap itself around its
content, and thus, does not eventually break this content: for
instance, when jScrollPane might reset/break Flash/SWF movies,
Scrollbar Paper will not.

Finally, Scrollbar Paper is updated every 200ms, thus automatically
adapting to its content.

Kelvin Luck

unread,
Dec 8, 2009, 6:25:43 AM12/8/09
to jscro...@googlegroups.com
Hi,

This is an very interesting approach and has a few advantages over
jScrollPane. One case that it deals with which I'm not sure how to deal
with for jScrollPane is when you use the browsers inbuilt "find on page"
command. Your code is also much simplified as you don't need to write
custom code for keyboard navigation, mouse wheel etc.

The main limitation with your approach is that you can't have a
transparent scrollbar which allows the page background to show through.

You also still need to implement the "click on track" and arrow buttons
(as you note on the page).

Re. jScrollPane wrapping the content, there is actually a patch that I
have been meaning to apply which (optionally) avoids this issue. Re. the
timer, I have been trying not to add this to jScrollPane. It is obviously
simple enough to do but I think it is better for people to program using
the event based architecture of JS rather than having a constantly polling
component. That said, lots of things are simplified with a timer and I
might need to drop my philosophical opposition to it from a purely
practical angle...

Anyway - good work, nice bit of lateral thinking to come up with the
different approach,

Kelvin :)
> --
>
> You received this message because you are subscribed to the Google
> Groups "jscrollpane" group.
> To post to this group, send email to jscro...@googlegroups.com.
> To unsubscribe from this group, send email to
> jscrollpane...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/jscrollpane?hl=en.
>
>

anrikun

unread,
Dec 18, 2009, 5:30:17 AM12/18/09
to jscrollpane
Thank you for your review Kelvin!
Yes you're right, Scrollbar Paper doesn't allow transparent
scrollbars.

A thing that would be great to implement is both the plugins, is a way
to keep track of the scrollTop value when leaving a page, so that when
you click "Back" on the browser, the page is displayed again at the
same scrollTop position.
Have you ever thought about that?

Henri

On 8 déc, 12:25, "Kelvin Luck" <kel...@kelvinluck.com> wrote:
> Hi,
>
> This is an very interesting approach and has a few advantages over  
> jScrollPane. One case that it deals with which I'm not sure how to deal  
> with for jScrollPane is when you use the browsers inbuilt "find on page"  
> command. Your code is also much simplified as you don't need to write  
> custom code for keyboard navigation, mouse wheel etc.
>
> The main limitation with your approach is that you can't have a  
> transparent scrollbar which allows the page background to show through.
>
> You also still need to implement the "click on track" and arrow buttons  
> (as you note on the page).
>
> Re. jScrollPane wrapping the content, there is actually a patch that I  
> have been meaning to apply which (optionally) avoids this issue. Re. the  
> timer, I have been trying not to add this to jScrollPane. It is obviously  
> simple enough to do but I think it is better for people to program using  
> the event based architecture of JS rather than having a constantly polling  
> component. That said, lots of things are simplified with a timer and I  
> might need to drop my philosophical opposition to it from a purely  
> practical angle...
>
> Anyway - good work, nice bit of lateral thinking to come up with the  
> different approach,
>
> Kelvin :)
>

Kelvin Luck

unread,
Dec 18, 2009, 6:47:59 AM12/18/09
to jscro...@googlegroups.com
Hi Henri,

I haven't thought of tracking the scrollTop when you leave the page. I
guess the only way to do it would be using a cookie to store the
information. I'm not sure if it would be desired behaviour though - do the
browser's default scrollbars behave like this?

Cheers,

Kelvin :)

anrikun

unread,
Dec 18, 2009, 10:37:19 AM12/18/09
to jscrollpane
Yes browser's default page-scrollbar behaves like this (you can give
it a try!)
I have the case of a site I made where user can scroll down throught a
loooonnnng list of items.
Where user clicks on a item, item's page is displayed.
The problem is that when user clicks "back" to browse the list again,
he is brought back to the top of the list, which can be very
frustrating in the long run.
He has to scroll down the list again to go back to the position he was
before.
That's why I need to figure out a way to keep track of scroll
position.


On 18 déc, 12:47, "Kelvin Luck" <kel...@kelvinluck.com> wrote:
> Hi Henri,
>
> I haven't thought of tracking the scrollTop when you leave the page. I  
> guess the only way to do it would be using a cookie to store the  
> information. I'm not sure if it would be desired behaviour though - do the  
> browser's default scrollbars behave like this?
>
> Cheers,
>
> Kelvin :)
>

Reply all
Reply to author
Forward
0 new messages