The Rich Edit window control has a very nice COM interface built in. MSDN documents this Text Object Model (TOM), and it looks quite useful.
However, I don't have most of the .h header files to translate to .asm.
These interfaces consist of:
ITextDocument Top-level editing object
ITextStoryRanges Enumerator for stories in document
ITextRange Primary text interface: range of text
ITextFont Character-attribute interface
ITextPara Paragraph-attribute interface
ITextSelection Screen highlighted text range that
inherits all ITextRange methods
Excepting ITextDocument and ITextSelection, I can't find these, nor any of the interesting defines they must use.
Would someone please do a search in files in their VC\include areas for these interfaces, and send me any relevant headers? (I really don't want to D/L the new SDK over a dial-up).
ThanksErnie,
I have the "h" files from the new SDK.
A quick grep turned up:
ITextDocument
ITextStoryRanges
ITextRange
ITextFont
ITextPara
ITextSelection
in TOM.h (224kb)
I can zip & mail later today if you want.
Thanks anon and everyone else. I now have the headers.
(Who wants to test them) ;-)
I am GAME for testing them.
I was just about to get into
this same stuff.
Ernie, are they the C++ headers?
I have a tom.h (218)Kb on my dive (mostlikely the same). I came with the MS AGENT SDK, as there is an example that makes use of it as well.
My Question is if you are handing out the translated tom.inc i would definiely be intersted.. :)
BTW, I uncovered some really cool stuff with the MS AGENT, i got 2 com's ready and wraper marcros made, for agent characters that speak and anamate, and as well a COM interface to just the speach engine if one doesnt like the see dancing characters.
My newest 'hack' is working on speach recognition COM's, there is a cool C++ example that allows you to command you computer to open menu items etc. (it works surprisingly well.. it would be a neat feature in an IDE.. , you wouldnt need to to reach for your mouse to compile, just say so.. :)
This little project is getting bigger... and bigger... and. ...
NaN
Nan,
Wow, sounds like FUN. I'd be interested in seeing your results, but since I listen to a lot of talk radio while I code, I'd hate to think of the unintended concequesces ;-)
I got TOM.h last week thanks. Would you believe the asm .inc file translate is only 22K long? 1/10th the size? It's also been included in CoLib 1.1, so you probably already have that header. (If not, you know where to go)
Thanx,
And no, I didnt realize it was there...
As for the rest, as soon as i wip up some english to go with the asm I will post what I have gotten hacked out (somewhere ~ maybe i should get a web page ;) )
NaN
Hi Ernie,
If you get the ITextFont interface to work, send me a message.
I tried for some hours to set the ForeColor with the SetForeColor
method, but there was always the error "Text is write protected".
beaster
beaster,
Sorry, no examples on how to use that interface, and I'm new to the RichEdit control too.
In any case, maybe if I knew a bit more about what you are up to I could suggest things to try. Or try asking "how do I change the text color in a rich edit" in the general section.