Questions about flexibility of TextCtrl/StyledTextControl

Hello Folks

I'm wondering whether I want to use the text controls offered by wxPython.

In some vague future I want my app to display not only text, but widgets inside the text as well. That is all the plethora of wx.Window subclasses.
You think it can be done reliably with wx without too much hassle? How so?

Also how about syntax highlighting? StyledTextControl does it, but documentation on it is sparse so I haven't figured it out yet.
How does the highlighting system work (I'd be thankful for a little workflow overview here)? What steps to add my own syntax?

wildemar

Wildemar Wildenburger wrote:

In some vague future I want my app to display not only text, but widgets inside the text as well.

wxHtml will do that, it could work well for you.

-CHB

···

--
Christopher Barker, Ph.D.
Oceanographer
                                         
NOAA/OR&R/HAZMAT (206) 526-6959 voice
7600 Sand Point Way NE (206) 526-6329 fax
Seattle, WA 98115 (206) 526-6317 main reception

Chris.Barker@noaa.gov

Christopher Barker wrote:

Wildemar Wildenburger wrote:

In some vague future I want my app to display not only text, but widgets inside the text as well.

wxHtml will do that, it could work well for you.

No no no. Sorry, I wasn't clear in that regard. I'm writing sort of a text editor. So html is no option.

Sorry for that
wildemar

Neither the TC nor the STC allow for embedding images in text. If you
are willing to do drawing yourself, you can fake it by creating a
control that is a child of either the TC or STC, and draw over the TC or
STC. This was previously used to draw a TC without a border.

- Josiah

···

Wildemar Wildenburger <wildemar@freakmail.de> wrote:

Christopher Barker wrote:
> Wildemar Wildenburger wrote:
>> In some vague future I want my app to display not only text, but
>> widgets inside the text as well.
>
> wxHtml will do that, it could work well for you.

No no no. Sorry, I wasn't clear in that regard. I'm writing sort of a
text editor. So html is no option.

Wildemar Wildenburger wrote:

Hello Folks

I'm wondering whether I want to use the text controls offered by wxPython.

In some vague future I want my app to display not only text, but widgets inside the text as well. That is all the plethora of wx.Window subclasses.
You think it can be done reliably with wx without too much hassle? How so?

Also how about syntax highlighting? StyledTextControl does it, but documentation on it is sparse so I haven't figured it out yet.
How does the highlighting system work (I'd be thankful for a little workflow overview here)? What steps to add my own syntax?

The RichTextCtrl in 2.7 can have images embedded in the text. Once I get all the container and content classes wrapped and made extendable in Python then you could probably get it to embed a widget too, or at least make a smart-image that activates a real widget when it is clicked on or something like that.

···

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