Re: scrolled window.

Cesar Suarez C. was overheared mumbling something about this on Tue, 20 Jun
2000 12:01:51 -0500 (GMT+5)

>  so I used Count Zero advice..use a vbox to pack the ruler and then the
>  scrolled window.. and now the ruler its always visible..->
>  cool, But now my problem is that I need the ruler to be as long as the
>  CList is (horizontal size), cuz the ruler has an "scale" that defines
>  intervals on the CList..

Ok, here is how I THINK you will have to do this, but to be honest, I am having
a hard time invisioning what you hope to accomplish with this ruler / CList
combo.	But here goes one way to do what you are trying to do:

Pack CList into ScrollPane, use gtk_widget_set_usize() to make the ScrollPane
the same width as the CList. Turn off the horizontal scroll bar in this
ScrollPane.  Pack Ruler and Scrollpane into a VBox. Pack VBox into another
ScrollPane. Use gtk_widget_set_usize() to make this scrollpane the same height
as your VBox (ie: ruler + clist) and turn of the vertical scrollbar in this
scroll pane.

Now, here is the one problem to this plan.  You will end up with a scrollpane
that you can scroll horizontally to view the "hidden" columns of your CList,
and the ruler will extend out as wide as the CList.  Problem is, the verticle
scrollbar for scrolling rows in the CList is gonna be all the way to the right
.. so your user will hafta scroll horizontally all the way to the right to see
it so he can scroll vertically.

This is not the "good" way to do this.

What you really need is a dynamically changing ruler.  Pack the widgets the way
I first told you (in the earlier mail) and attach a callback to the horizontal
scrollbar's "changed" signal.  When the user scrolls, this signal will get
generated, and you can use it to re-draw the ruler correctly...

Version: 3.1
GIT/CM d--(+) s+: a- C++++ UL++++$ P+++ L+++>++++ E--- W+++(--) N+ o? K?
w---(++) O M->-- !V PS+++ PE Y+ PGP t+@ 5? X+ R++ tv-- b+++ DI? D++
G e h r- y+

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