help - gtk_scrolled_window_get_hadjustment
- From: "Greatrix, Mark - ctr" <mgreatrix europe dg com>
- To: "'gtk-app-devel-list redhat com'" <gtk-app-devel-list redhat com>, "'gtk-list redhat com'" <gtk-list redhat com>
- Subject: help - gtk_scrolled_window_get_hadjustment
- Date: Mon, 10 Jan 2000 18:14:26 -0000
Hello,
I have a scrolled window, and want to scroll this within code, I've had a
look at the docs for gtk_scrolled_window_get_hadjustment & set_hadjustment
and this is what I've come up with...
gint CheckVal(GtkScrolledWindow *win) {
GtkAdjustment *adj;
adj = gtk_scrolled_window_get_hadjustment((GtkScrolledWindow *)win);
printf("scrolledwin - lower %.2f ", adj->lower);
printf("upper %.2f ", adj->upper);
printf("value %.2f\n", adj->value);
adj->value += 10;
if(adj->value >= adj->upper) {
adj->value = adj->lower;
}
gtk_scrolled_window_set_hadjustment((GtkScrolledWindow *)win, adj);
return(TRUE);
}
The code is fired off from a gtk_timeout_add function and *does* appear to
be updating the value correctly, but the scroll bar doesn't move.
Am I doing something wrong, can this be done, or am I missing something???
Thanks in advance,
Mark.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]