Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

idea

1 view
Skip to first unread message

rocal...@gmail.com

unread,
Sep 24, 2007, 5:25:46 AM9/24/07
to
I wonder how much our scrollbar implementation costs us. Each
scrollbar instantiates an XBL binding which creates five anonymous
elements, each of which gets a frame and has other overhead. Every
<select> has one scrollbar, every <textarea> has two, every <iframe>
and top-level document has two, and every overflow:auto element has
two. It would be an interesting experiment to remove the XBL binding
and see what difference that makes to Tp. I'll do it next time I need
to play with Talos. If it's a significant improvement, we could build
a specialized XUL element + frame combination that renders a native
scrollbar.

Rob

smaug

unread,
Sep 24, 2007, 7:21:53 AM9/24/07
to Jonas Sicking

Boris Zbarsky

unread,
Sep 24, 2007, 9:21:45 AM9/24/07
to
rob...@ocallahan.org wrote:
> If it's a significant improvement, we could build
> a specialized XUL element + frame combination that renders a native
> scrollbar.

Didn't we use to do native scrollbars on the Mac and stop doing it because of
z-indexing issues, etc?

Also, how would this play with theming scrollbars?

-Boris

P.S. I think scrollbars do cost us, for what it's worth.

Jonas Sicking

unread,
Sep 24, 2007, 7:23:21 PM9/24/07
to
Boris Zbarsky wrote:
> rob...@ocallahan.org wrote:
>> If it's a significant improvement, we could build
>> a specialized XUL element + frame combination that renders a native
>> scrollbar.
>
> Didn't we use to do native scrollbars on the Mac and stop doing it
> because of z-indexing issues, etc?
>
> Also, how would this play with theming scrollbars?

If we make the native-theme stuff hook in directly on the <scrollbar>
element, rather than on the individual parts, it would still be possible
to theme, by doing what themes do today. I.e. for the default theme we'd
have the following CSS:

scrollbar {
-moz-appearance: scrollbar;
}

but a theme would have

scrollbar {
-moz-binding: myscrollbar.xml#scrollbar;
}

/ Jonas

rocal...@gmail.com

unread,
Sep 25, 2007, 5:44:19 AM9/25/07
to
On Sep 25, 1:21 am, Boris Zbarsky <bzbar...@mit.edu> wrote:
> rob...@ocallahan.org wrote:
> > If it's a significant improvement, we could build
> > a specialized XUL element + frame combination that renders a native
> > scrollbar.
>
> Didn't we use to do native scrollbars on the Mac and stop doing it because of
> z-indexing issues, etc?

Yeah. I didn't mean to use an actual native scrollbar. Just a single
frame with -moz-appearance:scrollbar and all scrollbar behaviour coded
directly into it.

Plus what Jonas said.

Rob

Mike Schroepfer

unread,
Oct 5, 2007, 1:50:45 PM10/5/07
to rocal...@gmail.com
Um Awesome. Are there other areas that could use this treatment?

Damon Sicore

unread,
Oct 5, 2007, 2:19:27 PM10/5/07
to Mike Schroepfer, dev-per...@lists.mozilla.org
Is there a bug for this?

> _______________________________________________
> dev-performance mailing list
> dev-per...@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-performance

sayrer

unread,
Oct 7, 2007, 7:08:10 PM10/7/07
to
On Sep 24, 2:25 am, "rob...@ocallahan.org" <rocalla...@gmail.com>
wrote:

> I wonder how much our scrollbar implementation costs us.

I keep seeing scrollbar.xml::initScrollbars in DTrace profiles, so
maybe it costs a lot.

I filed bug 398941 to find out.

- Rob

0 new messages