Announcement

Do not use the forums to submit bug reports, feature requests or patches, submit a New Ticket instead.

#1 2005-03-04 04:06:54

niko
Xinha Authority
From: Salzburg/Austria
Registered: 2005-02-14
Posts: 338

SpellChecker default dictionary

hi there,

i made a little patch for setting the default-dictionary for the spellchecker:
http://xinha.gogo.co.nz/cgi-bin/trac.cgi/ticket/51

now my question:

in spell-check-ui.js when setting the avaliable dictionaries i found this code:

    for (var i = 0; i < dicts.length; ++i) {
      var txt = dicts[i];
      var option = document.createElement("option");
      if (/^@(.*)$/.test(txt)) {
        txt = RegExp.$1;
         option.selected = true;
       }

what is the if (/^@(.*)$/.test(txt)) { good for?
when do we get an @ bevore de dictionary?
why should this one be selected?


my patch changes this into:
      if(txt == activeDictionary) {
         option.selected = true;
       }

and i don't know if this is allright big_smile

thanks
niko


Niko

Offline

#2 2005-03-05 00:33:30

gogo
Xinha Leader
From: New Zealand
Registered: 2005-02-11
Posts: 1,015
Website

Re: SpellChecker default dictionary

niko wrote:

what is the if (/^@(.*)$/.test(txt)) { good for?
when do we get an @ bevore de dictionary?
why should this one be selected?

I don't know on that one, I dont' think we have the spellchecker plugin author here.

I'll look at your patch tonight with a bit of luck.


James Sleeman

Offline

#3 2005-03-07 04:38:21

niko
Xinha Authority
From: Salzburg/Austria
Registered: 2005-02-14
Posts: 338

Re: SpellChecker default dictionary

thanks big_smile


Niko

Offline

Board footer

Powered by FluxBB