[wxPython-users] wxTextCtrl buffering/jumping problem

Robin Dunn robin at alldunn.com
Thu Aug 3 10:40:58 PDT 2006


Chris Ashurst wrote:

> Whilst I have that part working fine, the only problem I'm left with is the
> fact that the debug output gets appended into a textctrl when there is
> output available. I know it doesn't *sound* like a problem, but I suppose
> really it's more of a superficial thing. When the current vertical space of
> the textctrl is filled up, instead of just scrolling down to a new line and
> appending text, the whole textctrl seems to "jump" back to the top of the
> textctrl like it had just cleared any other output and continues to append
> text. However, if I then activate the scroll bar via the mousewheel or just
> manually sliding the scrollbar, the previous text appears along with the new
> text, and the scrollbars adjust themselves correctly.
> 
> So basically, it's like the textctrl is paginating, whereas I would like it
> to behave more like a MSW command prompt window.

> ---snip---
> self.output = wxTextCtrl(self, -1, "", style =
> wxTE_MULTILINE|wxTE_READONLY|wxHSCROLL|wxTE_RICH|wxTE_RICH2)
> 

Try using just one or the other of the wxTE_RICH and wxTE_RICH2 flags. 
I don't remember which, but I think one of them has this pagedown on 
append behavior and the other works as you expect.


-- 
Robin Dunn
Software Craftsman
http://wxPython.org  Java give you jitters?  Relax with wxPython!





More information about the wxpython-users mailing list