FreakOZ
12-18-2002, 11:22 PM
All,
I have spend a bit of time looking at what the best method of colouring a RTB is and basically have come up with this complete control..
It doesn't colour the RTB the traditional way.. ie using the SelStart, SelColor, SelLength properties, but rather pure rtf codes..
Doing it with this method is very very fast!!!
ie. with a 120k file and standard methods of colouring it would take about 12 seconds to colour the entire RTB on my machine ( and thats with a small keyword list).. with the new method on the same machine it does it in 3.5 seconds (including colouring all strings and LOTS of keywords)..
This control is pretty much complete, does keywords, operators and strings in different colours..
Some of the code is built apon from examples on this site from ChiefRedBull and Garret Sever so acknowlegment goes to them also.
Any problems/bugs/comments PM me, i'de like the feedback.
Karl
I have spend a bit of time looking at what the best method of colouring a RTB is and basically have come up with this complete control..
It doesn't colour the RTB the traditional way.. ie using the SelStart, SelColor, SelLength properties, but rather pure rtf codes..
Doing it with this method is very very fast!!!
ie. with a 120k file and standard methods of colouring it would take about 12 seconds to colour the entire RTB on my machine ( and thats with a small keyword list).. with the new method on the same machine it does it in 3.5 seconds (including colouring all strings and LOTS of keywords)..
This control is pretty much complete, does keywords, operators and strings in different colours..
Some of the code is built apon from examples on this site from ChiefRedBull and Garret Sever so acknowlegment goes to them also.
Any problems/bugs/comments PM me, i'de like the feedback.
Karl