Thanks, KA, for the advice. But (1) TE_RICH and TE_RICH2 seem to be relevant only to Windows ("this style is ignored under other platforms"), and (2) I can't find anything about StyledTextCtrl in any of the wxPython docs. Am I looking in the wrong place?
···
Subject: Re: [wxPython-users] Newbie: writing big text to DC
From: Kevin Altis
Date: Mon, 30 Aug 2004 11:11:25 -0700
On Aug 30, 2004, at 11:05 AM, Charles Hartman wrote:
>
> I'm just getting started with wxPython on Mac OS 10.3. Can anyone
> point me toward sample code that will show me the nuts and bolts of
> writing large text files to the screen?
>
> A wxScrolledWindow (two, rather, inside wxPanels inside a wxFrame, all
> with wxBoxSizers) looks like the right place, but I can't find
> anything in the demos or docs on the details of using it--the DC and
> so on. TextCtrl is very nice, but the 32Kb limit is way too low for my
> current project. I haven't done a lot of GUI programming (especially
> in recent years); the guts of my program are nifty enough, but the
> face is missing!
>
> Charles Hartman
>
Use the wx.TE_RICH or wx.TE_RICH2 styles and then size limit goes way
up. I don't remember the exact numbers for each platform, but there is
no reason for you to be using a DC to draw text. You can also use the
StyledTextCtrl which is based on Scintilla.
Thanks, KA, for the advice. But (1) TE_RICH and TE_RICH2
seem to be relevant only to Windows
So is the 32k limit.
So am I to understand that wx.TextCtrl on Windows is limited to 32K? Even with wx.TE_MULTILINE?
Yes, unless you specify one of the wx.TE_RICH styles.
But not on Mac or Linux?
That was my understanding, but it sounds like that may not be the case on wxMac. They've just changed which native contol is used there so that may have some impact on it.
···
--
Robin Dunn
Software Craftsman http://wxPython.org Java give you jitters? Relax with wxPython!