Re: scrolling logs in GtkTextView to the end (Re: scrolling windo ws)
- From: Owen Taylor <otaylor redhat com>
- To: Havoc Pennington <hp redhat com>
- Cc: martyn 2 russell bt com, tim master vcisp net, gtk-app-devel-list gnome org
- Subject: Re: scrolling logs in GtkTextView to the end (Re: scrolling windo ws)
- Date: 06 Mar 2003 15:10:13 -0500
On Thu, 2003-03-06 at 12:15, Havoc Pennington wrote:
On Thu, Mar 06, 2003 at 05:11:39PM -0000, martyn 2 russell bt com wrote:
I meant in relation to the statement (which TP Muller commented on):
"Note that line heights are computed in an idle handler; so this function
may not have the desired effect if it's called before the height
computations."
I too have experienced the problem where by adding text to a text buffer and
then scrolling to the end iter (by using gtk_text_buffer_get_bounds())
doesn't scroll fully and half the line is missed.
Surely scrolling to the iter should do exactly that without needing a hack
(as provided by TP Muller) which scrolls on an idle timeout?
You don't need that hack, you just need to use scroll_to_mark.
Scroll to iter *does* do exactly that. However, then the size of the
buffer changes and you need to re-scroll. So what you have to do is
save a mark which is scrolled to later.
Wouldn't it be possible to make scroll-to-iter create an anonymous
mark and do this behind-the-scenes in the case where the tree is
not fully validated?
Owen
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]