Re: [bme-develop] Working emoticon code!
Status: Planning
Brought to you by:
sirmik
|
From: Simon T. <sim...@nt...> - 2004-04-12 16:49:24
|
3rd attempt to send this... > aloha fellow bme brothers, Hiya > >Well the handler could create an IconLoader in its constructor. All > > of > >that will be done before any messages are processed anyway. > > > Done! > > The emoticon code is working almost entirely now! it also processes > messages > like "Tim says bladiebla :D..." to a MessageItem that represents this > text, > and the place for the emoticon. The code is in CVS, so have a look at > it. > It's not finished yet, though! I use windowLengths to scan the > string...those windowLengths are the different emoticon string > lengths.... > :D has windowLength 2, whereas :-) has windowLength 3...the code that > adds > those windowLenghts automatically from the read emoticon strings I > still > have to add.... > > and then....it's GUI time!!! Nice work! I will have a look at the code later. What are the window lengths for? Isn't it easier just to do a loop: for each emoticonString if BString::FindFirst(textToScan, emoticonString) != NULL addEmot loop Sorry to say I've been very busy recently, so I've not managed to change the protocol code to use a bigger buffer yet. I may get round to it soon (although exams are now fast approaching, so I will be a bit busier for the next few months :s) > regards, > > Tim > > Btw: I already tested this code in a BWindow + BView! Cool Simon |