Re: Re[2]: Adding custom buttons to a scrolled window



On 12/6/06, Michael 'Mickey' Lauer <mickeyl linuxtogo org> wrote:
> Put two scrollbars plus a viewport in a table and add any other
> buttons you need. Make your work area the child of the viewport.
> Connect the scrollbar adjustments to the viewport.

Will that do everything that embedding a child widget in a
GtkScrolledWindow can do? gtkscrolledwindow.c is twice as large as
gtkviewport.c -- what does it more?

They do different things ... gtkscrolledwindow (usually) uses
gtkviewport to do the scrolling.

You'd be using gtktable to do the layout, not gtkscrolledwindow. The
only thing you lose is the automatic show/hide of scrollbars when the
window is big enough.

Basically what I'd need is to get a GtkScrolledWindow but make it talk
to my scrollbars, not to its.

That's (almost) exactly what happens if you put two scrollbars and a
viewport into a table.

John



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]