On 6 apr 2006, at 18.56, Vincent Kroll wrote:
Hi,
I've created a little exercise project, which is marking some
keywords of pasted or typed text in an editfield. An easy thing.
The code runs perfect without errors. If I'm pasting some text with
hundreds of lines, there is no problem. So I tried some text with
4293 lines, yes, it needs some time for parsing the text. But
suddenly after line 2339 no text will be marked, and at the
beginning of the text some random characters will be highlighted,
which not need to be highlighted (???). I debugged intensively my
code, there isn't any mistake in it, really.
For highlighting the text I'm using StyledText:
me.StyledText.TextColor( efWordStart-2, LineWordLength) = &c0000ff
I know, it's difficult to check it without the small project.
Perhaps someone could help me to understand this behavior, or is it
a bug? So for testing this small project and its behavior, I
released it at http://realopen.org/projects/texthighlighter/
This project was created in REALBasic 2006r1.
--
Have fun 8)
vincent
Hi, I think the problem is how you calculate the 'StartColor' and
'EndColor' Positions?
Using Len/Mid/Instr or LenB/MidB/InstrB ?
I saw in your e-mail address .de? Are the text ASCII only or what?
Sven E
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>