[PATCH] KSpell2 improvement

Mashrab Kuvatov kmashrab at sat.physik.uni-bremen.de
Mon Mar 13 14:01:20 GMT 2006

On Monday 13 March 2006 10:06, Thiago Macieira wrote:

> Finally, "tet" is Tetum. But I'm not sure we have the 3-alpha translations
> mapped.

nds (Low Saxon) and hsb (Upper Sorbian) are treated properly.

Is anybody going to add no, tl and tet?

> >One todo is left. One has to translate dictionary cryptic extension
> > names into English and i18n'ify it. I have no idea how to do it.
> I'd recommend we use the form "Language (Region) Variant" for English and
> construct it as
> 	i18n("%1 (%2) %3").arg(i18n(language), i18n(region), i18n(variant))
> so that translators get the chance to translate everything tokens.

One doesn't need i18n for language and country. Like I said they are already 

> Do not construct the strings like you did:
> +              localizedDictionary += " (" + cISOName + ")";


> That means: extract all the extensions known to aspell into a file, map
> them to an English name and mark them for translation.

I've never done this so far and I don't know how the messages are extracted. 
If somebody helps me (Nicolas Goutte?), I'll try. Otherwise I leave it to 

> >Would be nice to get it into stable (as it is there are no new
> > messages). KWord and KPresenter users would appreciate it. By the way,
> > one can do the same for dictionary selection combo in KWord's
> > preferences for example.
> We're in feature-freeze. This is KDE 4 code...

Personally, I don't take it as a feature. For me it is a bug and it is fixed 
without introducing any new messages.

Like I mentioned, at the moment KOffice apps are using kspell2 (maybe other 
apps too, I'm not aware of it). So, if KDE thinks that users should wait for 
KOffice 2 to get a change above in a spellchecker dialog, then let it be.

> One other thing: you construct this map every time, including when the
> language is changed. Please cache it somewhere in a variable to avoid
> doing the expensive work whenever the user clicks the drop-down list.

The method is called if the item in that drop-down list is changed. Just 
clicking will do nothing. Anyway, I didn't understand what you mean. Some 
code example would be better.

PGP key: www.uni-bremen.de/~kmashrab/kmashrab.asc
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20060313/c93feb11/attachment.sig>

More information about the kde-core-devel mailing list