[Psi-devel] Re: a patch for auto-replace

drakosha drakosha at mail15.com
Mon Feb 7 03:56:30 PST 2005


> Kevin Smith <kevin at kismith.co.uk>:

> On Mon, Feb 07, 2005 at 08:48:52AM +0300, Michail
Pishchagin wrote:
> > > >  And rename
> > > > workOnTextChange() to \"public slot:
correctTextEdit()\", or something
> > > > like that.
> > > That function doesn\'t make much sense from a
design point of view. I
> > > would expect an Auto Correction framework to get
a string as input, and
> > > give another string as output. I don\'t understand
why you would pass a
> > > widget to something that has nothing to do with a
user interface.
> > Well... It has not only to replace one string with
another, it also needs
> to 
> > know cursor position, to know what last typed word
was. Also it needs to 
> > reposition the cursor after the successful replace.
> 
> While this is true on the implementation level, it
makes no sense on the
> API level to be passing around arbitrary widgets,
it\'s really the job of
> the chatdlg (or whatever) to do the actual replacing,
and to just have the
> replace function work at the string level.
> 
> /K
> -- 
> Kevin Smith 
> PhD Research Student, Dept. Computer Science,
University Of Exeter
> Taekwon-Do Club Captain, University of Exeter
> 

The reason i didn\'t put it in chatdlg since this
function is also needed in gropupchatdlg, msgdlg, and
maybe in other dialogs also.


More information about the Psi-devel-affinix.com mailing list