BTW, if you wanna try my snippet you have to have a log.txt file in the same directory as the script. I have this logmaker.sh bash script that fills it.
2010/9/22 Juanjo Conti <[email protected]> > 2010/9/22 Mariusz Kruk <[email protected]> > > If I understand you right, you want the newly appended content to appear on >> the screen and the whole listbox to automaticaly scroll accodringly. >> You'd have to call set_focus() from the ListBox. >> > > I see. Great. I changed the __call__ method in ReadFile class like this: > > def __call__(self, loop, data): > line = self.fd.readline() > if line: > line = line.strip() > self.walker.append(urwid.Text(line)) > self.listbox.set_focus(self.walker.focus + 1) > loop.set_alarm_in(1, self) > > It's ok to use walker.focus or should I use walker.get_focus()[1] instead? > > BTW, if i hit the up and down keys the behaviour is a little weird. The > auto scroll stops until I use again the keys to go to the button of the > "stream". > > I'll keep playing with this and let you know any new. > > Thanks, > > -- > Juanjo Conti > blog: http://www.juanjoconti.com.ar > -- Juanjo Conti blog: http://www.juanjoconti.com.ar
README
Description: Binary data
README
Description: Binary data
_______________________________________________ Urwid mailing list [email protected] http://lists.excess.org/mailman/listinfo/urwid
