wxTextCtrl maximum length?

If you are using the main C++ distribution of wxWidgets, Feel free to ask any question related to wxWidgets development here. This means questions regarding to C++ and wxWidgets, not compile problems.
Post Reply
birdman
In need of some credit
In need of some credit
Posts: 5
Joined: Thu Jan 13, 2005 7:02 am

wxTextCtrl maximum length?

Post by birdman »

On windows with wxWidgets 2.4.2 wxTextCtrl seems to have a maximum length of 30,000 chars - after that, any Append()s just disappear into oblivion. I am trying to use a multiline textctrl as a log window but the log fills up in short bursts that often surpass 30,000 chars.

I can't find a way to set the max length or what-not. A possible solution, since the log goes to a file as well, is to run the textctrl as a queue and shred the oldest when the newest is appended. By selecting the first X characters of the text and deleting it I should be able to append onto the end, correct?

But what I'd REAAAAALLLLLLY like is to just be able to keep writing to the dang thing till my App is done. Any ideas or feedback please lemme know.
User avatar
myukew
Earned a small fee
Earned a small fee
Posts: 14
Joined: Thu Jan 13, 2005 6:33 pm

Post by myukew »

use wxTE_RICH as style
Use rich text control under Win32, this allows to have more than 64KB of text in the control even under Win9x. This style is ignored under other platforms.
http://www.wxwidgets.org/manuals/2.5.3/ ... wxtextctrl
birdman
In need of some credit
In need of some credit
Posts: 5
Joined: Thu Jan 13, 2005 7:02 am

Post by birdman »

use wxTE_RICH as style
God I feel like an a**. I swore I thouroughly scoured the documentation... I guess you miss obvious things at 3am. Thanks! :)
User avatar
myukew
Earned a small fee
Earned a small fee
Posts: 14
Joined: Thu Jan 13, 2005 6:33 pm

Post by myukew »

no problem, I started learning the stuff like 3 days ago... I read the documentation all day...
Post Reply