always scroll to the bottom line of a SimpleList
- From: Dirk Koopman <djk tobit co uk>
- To: gtk-perl-list gnome org
- Subject: always scroll to the bottom line of a SimpleList
- Date: Thu, 20 Jul 2006 00:40:01 +0100
How do I make sure that I am always scrolled to the bottom of a
Gtk2::SimpleList within a Gtk2::ScrolledWindow?
# The command list
my $cmdlist = Gtk2::SimpleList->new(
RxTime => 'tt',
Information => 'tt',
);
my $cmdscroll = Gtk2::ScrolledWindow->new (undef, undef);
$cmdscroll->set_shadow_type ('etched-out');
$cmdscroll->set_policy ('never', 'automatic');
#$cmdscroll->set_size_request (700, 400);
$cmdscroll->add($cmdlist);
$cmdscroll->set_border_width(5);
When I add something, eg:
push @{$cmdlist->{data}}, [$ts, $s];
How do I ensure that I am scrolled to the bottom (last input) line? I
know how to do this for a TextView but I can't make anything work for
a SimpleList.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]