Broken context-sensitive spell check in Evolution (Greek, Hebrew)

Bug #10713 reported by Giorgos Logiotatidis
52
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Evolution
Won't Fix
Medium
gtkhtml3.14 (Ubuntu)
Fix Released
Medium
Ubuntu Desktop Bugs

Bug Description

I installed aspell greek packages and evolution found them
successfully. When I compose mails greek misspelled words are being underlined
but when I run spell checked evolution claims that everything is ok.
Right click on misspelled words doesn't help either. English dictionary
works without problems. Greek is selected in edit->current languages

I am testing in hoary

thnx in advance

Gnome Bug 344008 – Broken greek spell check in evolution: http://bugzilla.gnome.org/show_bug.cgi?id=344008

Related branches

Revision history for this message
Sebastien Bacher (seb128) wrote :

is greek selected in Tools -> Settings -> Composer preferences -> Spell Checking ?

Revision history for this message
Giorgos Logiotatidis (seadog) wrote :

yes of course it's selected!

forgot to mention that greek spell checking work like a charm in other
applications like gedit, gaim etc. It's an evolution bug.

Revision history for this message
Sebastien Bacher (seb128) wrote :

and in the Edit -> Current Languages of the compose window, what's selected ?

Revision history for this message
Giorgos Logiotatidis (seadog) wrote :

both greek and english (american). I 've also tried with only greek selected and
still doesn't work

Revision history for this message
Sebastien Bacher (seb128) wrote :

I've opened a bug upstream about this:
http://bugzilla.ximian.com/show_bug.cgi?id=70548

Revision history for this message
Simos Xenitellis  (simosx) wrote :

The spell-checker is working, as the words which are mispelled are underlined
with the red jagged line.
However, in the popup menu, there is no menu item that allows you to make the
correction.

I verified that libgtkspell is installed. In the preferences, Greek is ticked
for spelling correction. The same goes
with the individual window setting for spelling correction.

It appears that rectangle in which you can right-click to get the spelling
correction option for Greek,
is somehow to small, so one cannot get it to appear. I tried right-clicking
around the mispelled greek word,
but without success. As if the rectangle has zero dimensions.

It appears that other languages would be affected by this. Anyone with cyrillic,
arabic, ???

If someone has garnome or jhbuild with GNOME 2.10, they could test this issue to
see whether
it's a configuration issue with Ubuntu or an upstream problem.

I am attaching some screenshots for demonstration purposes.

So far, two users have noticed this issue (for one languag, Greek).

Revision history for this message
Simos Xenitellis  (simosx) wrote :

Created an attachment (id=1851)
Shows Greek text, some words are ok, other are incorrect and marked as such. So
spelling works!

Revision history for this message
Simos Xenitellis  (simosx) wrote :

Created an attachment (id=1852)
On english text (greek dictionary, so any english incorrect), the pop-up menu
comes up with spelling option.

Revision history for this message
Simos Xenitellis  (simosx) wrote :

Created an attachment (id=1853)
For the Greek text, wherever you click does not bring up the spelling
correction menu item.

Revision history for this message
Sebastien Bacher (seb128) wrote :

thanks, I've forwarded your comments in the upstream bug.

Revision history for this message
Konstantinos Togias (ktogias) wrote :

I encounter exactly the same bug in evolution at dapper (evolution 2.6.0-0ubuntu5, gnome-spell 1.0.7-1ubuntu1, ispell 3.1.20.0-4). The spelling errors of greek text are marked by the red curly line, but the menu popped up when right-clicking on the error does not contain any spelling options or suggestions. Also running spellchecking (F7) reports that no errors are found.

When I also add english text with spelling errors at the same message then right-click-on-the-misspelled-word menu has the spelling options and running spellchecking wthi F7 locates the english misspelled words but ignores the greek misspelled words.

Also when I type a "word" that contains both greek and english characters then right-clicking this "word" gives spellchecking options, but spellchecker run by pressing F7 fails to locate it.

Finally, related to this spellchecker bug may be the fact that also find (CTRL+F) fails to locate any greek word in the message, while correctly locating any english (latin characters) word.

Revision history for this message
Carthik Sharma (carthik) wrote :

Changing to Confirmed since Konstantinos can reproduce the same bug.

Thank you for reporting this bug.

Changed in evolution:
status: Unconfirmed → Confirmed
Changed in evolution:
assignee: seb128 → desktop-bugs
Revision history for this message
Simos Xenitellis  (simosx) wrote :

This upstream entry refers to Ximian Bugzilla which is deprecated. Bug reports have been moved to GNOME Bugzilla, so we are updating here.

Revision history for this message
Simos Xenitellis  (simosx) wrote :

I would like to link this bug report to the correct upstream bug,
http://bugzilla.gnome.org/show_bug.cgi?id=344008

I cannot figure out how to remove the obsolete Ximian Bugzilla entry. Any help would be appreciated.

In addition, we would like to have someone try out the above test case and report if the bug still persists in Ubuntu 6.06.

Revision history for this message
Konstantinos Togias (ktogias) wrote :

The bug still persists in Ubuntu 6.06 . I tested on a fresh 6.06 installation (evolution 2.6.1-0ubuntu7) and the behaviour is that described above.

Changed in evolution:
status: Unknown → Unconfirmed
Revision history for this message
Thanos Lefteris (alefteris) wrote :

The bug persists in Ubuntu 6.10 as well . I tried it with evolution 2.8.1-0ubuntu4 and the behavior is the same with what is described above.

Additionally now, when right clicking an English misspelled word (with Edit ->current languages -> Greek selected), a "Greek" menu entry appears and suggests Greek words of no more that 2 characters. In a Greek misspelled word this menu entry does not appear at all.

When edit->current languages -> English is selected, right clicking an english misspelled word appears with english suggestions (as it should). Right clicking a Greek misspelled word has no suggestions menu (as it should, because the english language was used for editing).

Revision history for this message
Roma Yandolin (roma-yandolin) wrote :

The same bug with russian language. Ubuntu 6.10, Evolution 2.8.1.

Changed in evolution:
status: Unconfirmed → Confirmed
Revision history for this message
Simos Xenitellis  (simosx) wrote : Re: Broken context-sensitive spell check in evolution (Greek, Russian, etc)

Thanks Athanasios for the update, thanks Roma for the verification for Russian.
I updated the description of the report to reflect the new information.

Also, the upstream report on GNOME Bugzilla has been updated,
http://bugzilla.gnome.org/show_bug.cgi?id=344008
You can find this link at the top of this page, under the column "Assigned To".

Changed in gnome-spell:
status: Confirmed → Triaged
Revision history for this message
Yotam Benshalom (benshalom) wrote :

Still broken in Evolution 2.12.0 on gutsy.

Revision history for this message
Evgeny Kuznetsov (nekr0z) wrote :

I cannot see this bug for Russian or Swedish in Evolution 2.22.1

Looks like the bug is solved completely. Perhaps it should be marked "fix released"?

Revision history for this message
Yotam Benshalom (benshalom) wrote :

Still broken for Hebrew in Evolution 2.22.1 in ubuntu Hardy.
Hebrew spelling mistakes are marked with red underline, but no corrections are suggested.
It seems like one of those forever-bugs, never getting fixed.

Revision history for this message
Evgeny Kuznetsov (nekr0z) wrote :

Thanks, Yotam. I think I'll update the bug's header and remove Russian (it is definitely solved) and keep Hebrew and Greek. Is any other language affected, anybody?

Revision history for this message
Simos Xenitellis  (simosx) wrote :

What would be the difference between languages, whether the spell checker works or not?

It is weird that it works for Russian but does not work for other languages.

Revision history for this message
Giannis Katsampirhs (juankats) wrote :

Greek spelling has fixed now!! The bug is solved... thanks

Revision history for this message
Evgeny Kuznetsov (nekr0z) wrote : Re: Broken context-sensitive spell check in Evolution (Hebrew)

Yotam, what happens when you run spellcheck in Hebrew? Does Evolution report that there are no mistakes, despite the underlined words?

Simos, I have checked this bug with 7 languages, including German, Russian, Swedish, Esperanto, Ukrainian, Lithuanian and, naturally, English. All those work correctly, and now Γιάννης reports that Greek is not a problem any more, too. Looks like the only language suffering at the moment is Hebrew.

Revision history for this message
Giorgos Logiotatidis (seadog) wrote :

I do NOT confirm for Greek. The problem persists, evolution underlines mispelled words but provides no suggestions for Greek. Γιάννης are you sure that you get suggestions when right-clicking on mispelled greek words or/and when you press F7 to do a spell check?

Tested on gutsy with latest updates as of apr 16th.

Revision history for this message
Evgeny Kuznetsov (nekr0z) wrote :

Giorgos, would you be so kind as to test in Hardy Beta (LiveCD will do)? Hardy features a newer version of Evolution and will be released in 8 days, so it is vital to know that the bug is solved there (or otherwise, of course).

Revision history for this message
Yotam Benshalom (benshalom) wrote :

When I run spell check using F7 on a Hebrew text which contains marked errors, I get the response : "No misspelled word found."

Revision history for this message
Giorgos Logiotatidis (seadog) wrote :

Evegny,
I checked using hardy with latest update as of Apr 16th. I mentioned gutsy by mistake, sorry for that.

-g

Revision history for this message
Giannis Katsampirhs (juankats) wrote :

I'm very sorry, I didn't understand exactly where was the problem, yesterday... so today i had same problems with Giorgos, underlines the wrong woed, but doesn't return suggestions.. sorry again!

Revision history for this message
Simos Xenitellis  (simosx) wrote :

Evgeny, would it be possible to check on your system for Greek or Hebrew?

It is quite weird that it works for all languages you checked. Did you manage to find a language that did not work?

When you check in different languages, I suppose you clicked on System/Administration/Language support and you ticked all these languages.
After the packages were downloaded, you logged out, then logged in setting each time one of the new languages as your system language.
Then, you clicked to compose an e-mail in Evolution.

a. When you right-click on a mistyped word (red-jagged line under the word), you get a context sensitive menu with usable suggestions (sometimes you get single character words which is some mistake).
b. When you click for a full spell checking, it picks up valid typos and offers suggestions.

For Greek, you can try

Αυτά είναι ελληνικάρ.

The last word should appear as a typo, possible giving as options "ελληνικά" or something similar.

Revision history for this message
Evgeny Kuznetsov (nekr0z) wrote :

Simos, I did not exactly follow the way you've described, I used the way I usually add to get spellchecking support for various languages. Anyway, I was able to reproduce this bug with Greek. Here's what was done:

a. I don't install full support for all the languages, since I'm quite comfortable with Russian as a system language. Instead, I install aspell packages for corresponding languages, since GNOME (and Evolution as a part of it) relies on aspell to do spellchecks. So I did "sudo aptitude install aspell-el" for Greek, restarted Evolution, opened a new message, activated Greek spellchecking in Edit -> Current languages menu, and then pasted the example phrase you've provided into the editor. The last word appeared underlined as a mistype.

1. F7 did not found any misspelled words, despite the fact that last word was marked as such.
2. Secondary click on the underlined word did not bring in any suggestions at all.

b. After that, I have typed in a phrase in Russian, "проверка русской арфографии". This phrase contains a mistype in last word (should read "орфографии"), and this word was underlined as mistyped. After that, I tried to explore the bug again.

1. F7 ignores Greek mistype, and only shows Russian one (with valid suggestions).
2. Secondary click on underlined words brings no suggestions, neither for Greek nor for Russian mistypes.

c. Then, I turned Greek spellchecking off in menu, leaving other languages on. After that, all words in Greek phrase were underlined (as expected, since Greek dictionary was no longer active), as well as the last (actually mistyped) word in Russian phrase. In this situation:

1. F7 ignores Greek words and shows Russian mistyped word with valid suggestions.
2. Secondary click on underlined words brings no suggestions, not even for Russian.

d. Then, I created a new message, kept Greek spellchecking disabled, and typed in the Russian example (no Greek in this letter).

1. F7 works as intended.
2. Secondary click works as intended.

e. Then, I pasted the Greek example into the second message. Secondary click got broken, repeating situation [c].

f. After a few more tests, Russian was stably producing situation [a] (both F7 and secondary click don't work) with all the mistypes I have previously used. Removing Greek support totally (sudo aptitude remove aspell-el) didn't help fix Russian back again: the examples I have used when Greek was installed produce situation [a], while some other Russian mistypes work correctly. All other languages I use (Swedish, German, English, Esperanto, Ukrainian and Lithuanian) work correctly.

So here is my conclusion: Greek spellchecking in Evolution is buggy and effectively breaks other languages as well. Right now, I even have no clue how to repair Russian back again...

Revision history for this message
Simos Xenitellis  (simosx) wrote :

Evgeny, many thanks for the detailed testing and reporting.
Sorry for messing up your Russian spell checking in Evolution.

This gives a hint that something might be wrong in the Greek spelling package.
If someone from the fellow Greeks can dissect the aspell-el .deb file, it would be really great.
My crude guess is that the problem might be related to text encodings.

I'll update the upstream report as well.

Revision history for this message
Evgeny Kuznetsov (nekr0z) wrote :

The sensible thing to do would be as well to try to contact someone from aspell development. This bug could be aspell problem alltogether.

And keep in mind that there's a problem with Hebrew, too. Maybe some of the Hebrew-speaking guys here could investigate that?

Simos, that's OK, Russian's my native, and I've no problems writing correctly in it. If I broke Swedish or Lithuanian, that would be the real pain. Thank you anyway.

Revision history for this message
krizz (krizz) wrote :

Reporting same problem here with Greek in Evolution 2.22.2 (Ubuntu Hardy).

Any progress on that bug?

Revision history for this message
Pedro Villavicencio (pedro) wrote :

you can take a look to the upstream one to see what's the progress of it, thanks.

Revision history for this message
Giorgos Logiotatidis (seadog) wrote :

The problem is still there on Ibex using evolution-2.24.0-0ubuntu2 :(

Revision history for this message
Alkis Georgopoulos (alkisg) wrote :

Confirming for Intrepid - evolution 2.24.0-0ubuntu2.

I don't think it's an aspell problem, because gedit and the rest apps that use it work without problems.
Evgeny, now that your Russian spelling is broken, does it work in gedit?

What other gtkhtml apps are there, to test them and see if all gtkhtml apps are affected?

Kind regards,
Alkis Georgopoulos

Revision history for this message
Evgeny Kuznetsov (nekr0z) wrote :

Alkis, I have to say that my once-broken Russian spellchecking seems to work again, but as I don't use spellchecking too much, I cannot tell at which point it got repaired. Maybe is has something to do with Gutsy-to-Hardy-to-Intrepid upgrade, maybe some other things, I honestly don't know.

Revision history for this message
Evgeny Kuznetsov (nekr0z) wrote :

Oops, sorry, I got it wrong. If I use that specific mistypes I used for Russian when researching this bug (and those were the mistypes that showed incorrect behaviour for Russian), they are still broken - in Evolution, but not in Gedit.

Revision history for this message
Yotam Benshalom (benshalom) wrote :

Still broken for Hebrew in Intrepid. It seems to be one of those eternal bugs never to be fixed.

Revision history for this message
Alkis Georgopoulos (alkisg) wrote :

Spelling suggestion in Greek works for me under special circumstances, i.e. in fake words like "αβγαnd", with English letters stacked right before or after the Greek letters. And *only* when I click on these English letters ("nd") do I get a spelling menu. I don't get a spelling menu when I click on the Greek letters ("αβγα") of the same word.

More detailed description on my post upstream:
http://bugzilla.gnome.org/show_bug.cgi?id=344008#c17

Evgeny, Yotam, can you reproduce something similar in your languages?

Revision history for this message
Alkis Georgopoulos (alkisg) wrote :

It seems that *all* languages that contain non-ascii symbols are affected by this.
E.g. write Hööörz and click on the middle ö. No spell suggestions.
But if you click on "H" or "rz", you get spell suggestions.

Revision history for this message
Evgeny Kuznetsov (nekr0z) wrote :

Well, Russian uses Cyrillic letters (that are not ASCII at all), so your guess, Alkis, is definitely wrong.

Revision history for this message
Alkis Georgopoulos (alkisg) wrote :

Evgeny, I *did* try with Russian, with the words you posted above:
проверка русской арфографии

The first two words weren't underlined, the third one was.

But *it matters where you click* on the third word. If you click between:
ар => no (spell suggestion)
рф => yes
фо => yes
ог => no
гр => no
ра => no
аф => yes
фи => yes
ии => yes

So my guess is you clicked on one of those "yes" combinations.
If you don't see the same behavior, then maybe we have different settings or evolution version?
(I did install aspell-ru and my evolution version is 2.24.0-0ubuntu2).

You're right about the ASCII range though, e.g. if I write
аааааааааа (Russian а) => no suggestion
рррррррррр (Russian р) => no
ффффффф => *yes*

I'll check with more letters, to see if I can find any logic. I don't think dictionaries have to be installed to see which letters are "significant" and recognized by F7 and which not, so it should be ease (yet boring)...

Revision history for this message
Alkis Georgopoulos (alkisg) wrote :

I got something more specific:

Cyrillic а = U+0430 => no suggestion
Cyrillic р = U+0440 => no suggestion
Cyrillic ф = U+0444 => suggestion

Look at the least significant bytes.
ASCII 30 = character 0 => not a letter
ASCII 40 = character @ => not a letter
ASCII 44 = character D => it's a letter

The same happens with Greek, i.e. the least significant byte is not an ASCII letter.

So this explains everything, somewhere in the code a non-utf-8 aware function (or part of code) is used.
If it's not fixed soon, I'll have a look at the code.

Revision history for this message
Evgeny Kuznetsov (nekr0z) wrote :

Alkis, now it looks like you're totally and completely right. I have the same experience with the word "арфографии", and I have tested some more Russian mistypes in long words, including both the letters that should work according to your theory, and the letters that shouldn't - and indeed they demonstrate the behaviour you've described.

The only thing that still gets me puzzled is: the mistypes I have used for test while I had Greek dictionary installed are not shown in F7-run, while all the other mistypes I have tested are, no matter what letters they include.

Revision history for this message
Alkis Georgopoulos (alkisg) wrote :

> the mistypes I have used for test while I had Greek dictionary installed are not shown in F7-run
Evgeny, perhaps you 've added them in the user dictionary?
Have a look at ~/.config/enchant

Revision history for this message
Evgeny Kuznetsov (nekr0z) wrote :

I didn't. And mind that those mistypes are still underlined and still do react to right-click (when clinking on appropriate letters). But on F7 they don't show up.

Revision history for this message
Alkis Georgopoulos (alkisg) wrote :

Evgeny, you're good, you found out that there are two bugs, not one: one concerning forward scanning of the text, and one concerning backward scanning (like when you right click in the middle of a word and the speller needs to find out the beginning and the end of the word).

You may get a better view of it by pasting this:
aaaa
ααααaaaa
aaaaαααα
αααaaaaααααaaaaαααα
aaaa

Press F7 and try playing with the "Skip" and "Back" buttons.
In forward checking, it bypasses the 3rd and 4th word.
In backwards checking, it bypasses the 4th and 2nd word.

So the words you're having problems with, should have "non-significant" cyrillic letters at their ends.

Tip of the day: Evgeny is a Greek word (Ευ-γενής) meaning someone of noble family! ;-)

Revision history for this message
Evgeny Kuznetsov (nekr0z) wrote :

Once again you're almost totally right, Alkis. The only point where you are wrong is that I've only noticed some strange behaviour, and you were the one to actually find that there are two bugs.

And thanks for the tip, though I know that a lot of Russian names are of Greek origin, and I already knew the approximate meaning of mine. ;-)

Revision history for this message
Panagiotis Minos (pminos) wrote :

Spelling suggestion for Greek words have been stopped working for several months because in the file "gtkhtml/htmlengine.c", function "html_engine_spell_word_is_valid", the following code returns a gunichar but the result is truncated to gchar.

prev = html_cursor_get_prev_char (e->cursor);
curr = html_cursor_get_current_char (e->cursor);

This means that the spelling suggestions should stop working for all words that contain Non-ASCII Characters.

the local variables gchar prev, curr;
must be replaced by gunichar prev, curr;

I have tested this on Ubuntu 9.04 (jaunty) and it seems to work.

I will attach a patch.

Revision history for this message
Sebastien Bacher (seb128) wrote :

> Spelling suggestion for Greek words have been stopped working for several months because

The bug you are commenting on is not new from several months, could you open a new one?

Revision history for this message
Panagiotis Minos (pminos) wrote :

> The bug you are commenting on is not new from several months, could you open a new one?

You are right. Spelling suggestion for Greek words is not working for years.
I will prepare a report and open a new bug.

Thank you for your reply.

Revision history for this message
Sebastien Bacher (seb128) wrote :

did it work before or not? if it didn't that's probably the same bug and no need to open a new one

Revision history for this message
Sebastien Bacher (seb128) wrote :

could somebody give an easy testcase too?

Revision history for this message
Alkis Georgopoulos (alkisg) wrote :

Easy test case:
1) Open evolution and create a new mail

2) Edit > Current languages > verify that *any, but at least one* dictionary, e.g. English is checked. You don't have to install the Greek dictionary to see the problem.

3) Paste the following two lines:
aaaaa
ααααα
Notice that both of them have a wavy underline (=are spelled wrong).

4) Right click on the first word. You may get a spelling suggestion (Aaron if you enabled the English dictionary) *and* you'll get a menu item saying "Ignore Misspelled Word".

5) (Here's the bug):
Right click on the second word. You won't get the menu item saying "Ignore Misspelled Word", and of course you won't get any spelling suggestions.

I'm gonna test the patch that Panagiotis sent, and if it works, I'll upload an updated evolution package to my ppa. Thanks a lot Panagiotis, that was a really long standing bug! :)

Revision history for this message
Alkis Georgopoulos (alkisg) wrote :

Yup, Panagiotis fixed the bug. A single line that gave people frustration for more than 5 years!
Please get this into Karmic.
Let me say again that this affects *many* non-English languages (e.g. German, French, Russian etc), not just Greek and Hebrew as the bug title says.

For anyone interested, I've uploaded a patched version for jaunty in my PPA:
https://launchpad.net/~alkisg/+archive/ppa/+sourcepub/764207/+listing-archive-extra

You only need to install libgtkhtml3.14-19_3.26.0-0ubuntu2+ppa1_i386.deb
(it hasn't finished building yet, it'll be ready in some minutes/hours).

Thanks again Panagiotis!

Revision history for this message
Giorgos Logiotatidis (seadog) wrote :

Great news! I hope the patch gets into Karmic. Thank you Panagiotis!

affects: gnome-spell (Ubuntu) → gtkhtml3.14 (Ubuntu)
Changed in gtkhtml3.14 (Ubuntu):
status: Triaged → Fix Committed
Revision history for this message
Sebastien Bacher (seb128) wrote :

Thanks for tracking the issue and testing, do you think you could add your patch on the GNOME bug too?

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gtkhtml3.14 - 1:3.28.0-0ubuntu2

---------------
gtkhtml3.14 (1:3.28.0-0ubuntu2) karmic; urgency=low

  * debian/patches/01_use_correct_type_fix_non_ascii_spell_checking.patch:
    - don't mix gchar and gunichar use and fix non-ascii spell checking,
      thank to Panagiotis Minos for the change (lp: #10713)

 -- Sebastien Bacher <email address hidden> Thu, 08 Oct 2009 23:07:47 +0200

Changed in gtkhtml3.14 (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Panagiotis Minos (pminos) wrote :

I added the patch to GNOME Bugzilla. (https://bugzilla.gnome.org/show_bug.cgi?id=344008)

It seems it will be added for GtkHtml 2.28.1.

Revision history for this message
Simos Xenitellis  (simosx) wrote :
Changed in evolution:
importance: Unknown → Medium
Changed in evolution:
status: Confirmed → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.