Bug 120859 - spell check color underline kwrite
Summary: spell check color underline kwrite
Status: RESOLVED DUPLICATE of bug 33857
Alias: None
Product: kate
Classification: Applications
Component: kwrite (show other bugs)
Version: unspecified
Platform: unspecified Linux
: NOR normal
Target Milestone: ---
Assignee: KWrite Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-01-27 11:45 UTC by Eleonora
Modified: 2008-02-13 19:35 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Eleonora 2006-01-27 11:45:42 UTC
Version:           4.4 (using KDE KDE 3.5.1)
Installed from:    I Don't Know
OS:                Linux

I'd like to have spell check on the fly for kwrite with erroneouls words underlined or marked with different color. The check box is rather unproductive.  This I'd like both for kate and kwrite. Thanks, Eleonora
Comment 1 Anders Lund 2006-01-27 20:15:07 UTC
Why open a new bug when there is already one?

And now, some reasons for why it's not implemented yet:
Even though painting a text in a different style is not extremely difficult, we need a style that is special, so that it can't be duplicate in the highlight systems. And the coloring according to language syntax has properties that can't be used for spell checking, as the values are used by the parser. We do by now have the arbitrary highlighting which can be used for that though.

The other big issues is that we need a way to know which strings to check, so we need to add properties to the syntax files that defines either contexts or attributes for which text should be checked. And implement a engine that selects those strings and passes them to the checker.

With the improvements that is on the way in the editor component for KDE 4.0 this should be relatively easy to achieve though. So there is hope :-)

*** This bug has been marked as a duplicate of 33857 ***
Comment 2 Eleonora 2006-01-27 22:02:41 UTC
I think following: There could be an (on the fly) spell checking mode. In spell checking mode, the good words are black, the bad ones are red. 

The Oo spell checker myspell or hunspell or even aspell or ispell provides perfect means to show for each word, if it is good or bad.

I added this issue, because 33857 speaks only about kate, and I should like an on the fly spell check also in kwrite. 

Havong an on the fly spell checker would improve the present spell check method at least by 1000%.

Eleonora
Comment 3 Anders Lund 2006-01-27 22:46:32 UTC
On Friday 27 January 2006 22:02, Eleonora wrote:
> I think following: There could be an (on the fly) spell checking mode. In
> spell checking mode, the good words are black, the bad ones are red.


Because we do highlight, we can't just make misspelled words red. Red is 
already used for something else in many cases. In fact, we need a style that 
is not used in the syntax highlighting.

> The Oo spell checker myspell or hunspell or even aspell or ispell provides
> perfect means to show for each word, if it is good or bad.


As I tried to explain, we do not want to check ALL words in many cases. For 
example in programming code you would only want to check text strings and 
some types of comment. In some text types you wouldn't want it at all. So 
it's a bit more complex.

> I added this issue, because 33857 speaks only about kate, and I should like
> an on the fly spell check also in kwrite.

Spell checking is provided by the editor component. We talk about katepart, 
which is used in Kate allways, and usually in kwrite as well.
Comment 4 Eleonora 2006-01-27 23:35:38 UTC
>Because we do highlight, we can't just make misspelled words red. Red is
>already used for something else in many cases. In fact, we need a style that
>is not used in the syntax highlighting.

I think of a mode, that does nothing else than spell checking on a text. In spell checking mode there are only 2 colors: black for good and red for bad words.

>As I tried to explain, we do not want to check ALL words in many cases. For
>example in programming code you would only want to check text strings and
>some types of comment. In some text types you wouldn't want it at all. So
>it's a bit more complex.

That is not a requirement from my side. I'd like to test texts, that's all. And that effectively and fast. The box that exist today is completely unsuitable for me.  However, if it is easy to implement such complicated things, I have nothing against that, but I would never use it. 

Ideally you could implement the easy spell checking first, and later on the complicated one. I assume, 99% of the users would be happy with the - black/red check all words on the fly- method I suggest. It would be a great improvement, and it is almost present in the existing editors. Almost. 

Comment 5 Anders Lund 2006-01-28 09:43:45 UTC
On Friday 27 January 2006 23:35, Eleonora wrote:
> That is not a requirement from my side. I'd like to test texts, that's all.
> And that effectively and fast. The box that exist today is completely
> unsuitable for me. 
Comment 6 Eleonora 2006-01-28 10:06:55 UTC
>Out of curiosity, for what do you use Kate?
I use kwrite, kate and gedit for:
- writing letters to friend/relatives, also emails
- prepare html/css pages
- write c, c++, perl and perl/tk programs
- work with large dictionary files
  one my pages in www is http://tkltrans.sf.net
  I also have a perl/tk spell check editor there,
  ptkspell, that I use for spell check and grammar check.
  It has a very nice on the fly coloring method.
  If kate/kwrite knew the same, that would be very nice.

>In any way, we *need* to have the basic things working, even if we only can
>offer to work on the entire text, otherwise there is no perspective.

Yes, exactly that is also my feeling. And you would make happy 99% of your users with a basic spell checker.
Even the coding and markup using users would definitively use for their texts the black/red on the fly spell checker. Spell checking is absolutely a must for web pages, man pages. And it is completely enough to spell check flat text files. They can be converted to html after spell check. That is my experience.

For documents we have a very nice spell checker, the Open Office one, but neither kwrite, nor kate, nor gedit can spell check flat text files on the fly, which is really a pity. Oo is again not useful at all (it is counterproductive)  for simple flat text files. 
Comment 7 Eleonora 2006-01-28 20:02:10 UTC
I just learned, that gedit knows this miracle: if tools/autocheck spelling is activated, it underlines bad words with a red winding-line on the fly. Excellent! Regards, Eleonora 
Comment 8 Anders Lund 2006-01-28 20:14:20 UTC
On Saturday 28 January 2006 20:02, Eleonora wrote:
> I just learned, that gedit knows this miracle: if tools/autocheck spelling
> is activated, it underlines bad words with a red winding-line on the fly.
> Excellent! Regards, Eleonora


So, go use gnome.
Comment 9 willem wakker 2008-02-13 19:35:43 UTC
>Because we do highlight, we can't just make misspelled words red. Red is
>already used for something else in many cases. In fact, we need a style that
>is not used in the syntax highlighting. 

Why not underline like in MS office, Open Office, and the Firefox box that I use to type this comment? 

>As I tried to explain, we do not want to check ALL words in many cases. For
>example in programming code you would only want to check text strings and
>some types of comment. In some text types you wouldn't want it at all. So
>it's a bit more complex. 

As an intermediate solution I would not mind that some (latex)code is marked as erroneous. I know which parts of my document are code and which parts are text, so I can ignore wriggly lines under the code parts. 

By the way: I use  Kwrite mostly for C, Matlabcode, and Latex. For the last application I really miss the in-line spelling check. Especially since I need to write texts in two different languages that are both not my own.