General :  K-Meleon Forum
General discussion about K-Meleon. 
Experimental Spell Checking macro for K-Meleon
Posted by: www_ngtech_gr
Date: August 16, 2007 10:25PM

Hello,
I have written an experimental spell checking macro for K-Meleon :
Spell checking macro for K-Meleon using Autoit & Aspell which uses Aspell for Win32.
Spell checking has been the most important feature I am missing from K-Meleon and this macro somewhat resolves its absence.



Edited 1 time(s). Last edit at 08/18/2007 04:50AM by www_ngtech_gr.

Options: ReplyQuote
Re: Experimental Spell Checking macro for K-Meleon
Posted by: James
Date: August 18, 2007 12:57AM

I got an error when I tried spell check. I downloaded the zip file and un-zipped it. I placed the kmm file and the folder into my user macro folder. The ngtech_gr_spell_chk folder has six files. The error message I get is:

Line 0 (File "C:\Program Files\k-meleon\Profiles\default\ae3wngxv.slt\macros\ngtech_gr_spell_chk\spell_chk.rxr"):
RunWait($Aspell_cmd_Line,@ScriptDir,@SW_SHOWNORMAL)
Error: Unable to execute the external program.
The system cannot find the file specified.

Did I not follow the directions correctly? I don't think there is a spell_chk.rxr but there is a spell_chk.exe

Options: ReplyQuote
Re: Experimental Spell Checking macro for K-Meleon
Posted by: www_ngtech_gr
Date: August 18, 2007 04:41AM

Have you downloaded and installed aspell for Win 32?

The script assumes that
aspell.exe existis at @ProgramFilesDir & "\Aspell\bin\aspell.exe

The .rxr part seems puzzling...

For faster response post your comments in my blog using the same link
You can download AutoIt and use the source code of spell_chk.exe (spell_chk.au3) to get a detailed look on what is going on.



Edited 1 time(s). Last edit at 08/18/2007 04:55AM by www_ngtech_gr.

Options: ReplyQuote
Re: Experimental Spell Checking macro for K-Meleon
Posted by: James
Date: August 18, 2007 05:56AM

I think the rxr was a typo on my part. Sure wish I could cut and paste from error messages. Aspell did not go to "bin" by default. I have to un-install and re-install it.

Options: ReplyQuote
Re: Experimental Spell Checking macro for K-Meleon
Posted by: www_ngtech_gr
Date: August 18, 2007 03:11PM

Hello James,
You must also download the Aspell binaries installer:
http://ftp.gnu.org/gnu/aspell/w32/Aspell-0-50-3-3-Setup.exe
I have updated the instructions to clarify this point...
Thanks for your feedback!

Options: ReplyQuote
Re: Experimental Spell Checking macro for K-Meleon
Posted by: JujuLand
Date: September 03, 2007 05:35PM

I have made a version which allows change the language used, and the path of aspell binary.

This version use no more tools to wait after the end of the spelling check.

A little bug corrected.(if downloaded before 03/09/2007 17:00, please download again)

The only problem is now for languages with accents (french, german, spanish,...) where the result text is coded in OEM format, which is not really good.

A+


Mozilla/5.0 (x11; U; Linux x86_64; fr-FR; rv:31.0) Gecko/20100101 Ubuntu/12.04 K-Meleon/75.0

Web: http://jujuland.pagesperso-orange.fr/
Mail : alain [dot] aupeix [at] wanadoo [dot] fr





Edited 2 time(s). Last edit at 09/03/2007 11:04PM by JujuLand.

Options: ReplyQuote
Re: Experimental Spell Checking macro for K-Meleon
Posted by: JamesD
Date: September 04, 2007 12:56AM

@ JujuLand

I have loaded the extension, Aspell, and the English dictionary. I set the dictionary to en_US but when I try to set a path to Aspell I get a message the "The systen cannot find the specified path." I am not given a chance to set a path. I am sure that I did something in a wrong order or place but I don't know what. I installed Aspell and the dictionary in their default places per the installer.

Options: ReplyQuote
Re: Experimental Spell Checking macro for K-Meleon
Posted by: JujuLand
Date: September 04, 2007 02:38AM

If you have installed Aspell with the setup, the extension ought to find automatically the path. When the path is found, the right menu ought not to be grayed. In this case, you have not to set the path.

If you set it manually, don't forget that \ is the escape character and to enter \ in a path you must enter \\.

If you have used the setup to install Aspell, try to set $_Aspell_Path to "" and restart K-Meleon, it ought to be ok.

A+


Mozilla/5.0 (x11; U; Linux x86_64; fr-FR; rv:31.0) Gecko/20100101 Ubuntu/12.04 K-Meleon/75.0

Web: http://jujuland.pagesperso-orange.fr/
Mail : alain [dot] aupeix [at] wanadoo [dot] fr




Options: ReplyQuote
Re: Experimental Spell Checking macro for K-Meleon
Posted by: JamesD
Date: September 04, 2007 06:58AM

Maybe I installed things in the wrong order. I installed the extension first and then I installed Aspell and the dictionary. Under TOOLS - SPELL CHECKING - ASPELL I have two items. The first is Set Aspell dictionary. When I do that the "en_US" is pre-entered so I click OK. The second option is Set Aspell path. I get the error message as soon as I click on that. No chance to enter anything. A untitled notepad is opened. I don't know what to do with that.

Where do I put the $_Aspell_Path to "" ? My aspell is located at C:\Program Files\Aspell\bin\aspell.exe

Options: ReplyQuote
Re: Experimental Spell Checking macro for K-Meleon
Posted by: JujuLand
Date: September 04, 2007 02:47PM

I have found a bug on menugrayed line which hasn't be moved and duplicate in Aspell_Check1() and Aspell_Check2()
I have notice some problem to open the macro, I haven't find why. If the menu entry doesn't work, open the file Aspell.kmm located in K-Meleon\macros with an editor (notepad or another editor)

$_Aspell_Path will be for you:

"C:\\Program Files\\Aspell"

I have put a new version, but it seems there is always some problems.
Try it

A+


Mozilla/5.0 (x11; U; Linux x86_64; fr-FR; rv:31.0) Gecko/20100101 Ubuntu/12.04 K-Meleon/75.0

Web: http://jujuland.pagesperso-orange.fr/
Mail : alain [dot] aupeix [at] wanadoo [dot] fr




Options: ReplyQuote
Re: Experimental Spell Checking macro for K-Meleon
Posted by: JamesD
Date: September 05, 2007 03:44AM

@ JujuLand

I am not sure how to use Aspell. I can get the macro to run from the right click and it correctly highlights the misspelled word. The right spelling is at >1. What do I do then? I have tried typing a "1" and a "r" but nothing is replaced in the text field in KM. The "i" does go on to the next misspelled word.

Options: ReplyQuote
Re: Experimental Spell Checking macro for K-Meleon
Posted by: JujuLand
Date: September 05, 2007 12:42PM

Aspell purposes words when it doesn't know a word in a sentence you write.

You have then some choices:

1,2,...0 = replace the word by the one you choose
i = ignore the word
I ignore all the words (you do nothing)
r = you enter then the word you want, because the good word hasn't been purposed
R = idem as r, but for all the misspelled words
a = add the word you're going to enter to your personnal directory
l = add lower (not tested)
b = abort (you stop and loose the spelling ckeck already made)
x = quit (the job is finished)


Important:
---------
Due to the way I use to wait the end of the checking phase, it's important to quit Aspell by using the keys expected for. Never use the windows button to close the window.
I use a batch file which, after spelling check, delete a file created just before launching the batch. The presence of this file is tested by the macro to know if the operation is finished.
If you close the window by using the close button, you stop the batch, and not only Aspell, and the file is never deleted, and K-Meleon is always waiting the deletion, and is blocked. The only ways are then to manually delete the file (located in profile folder (aspell.flg) or to kill K-Meleon.

So,

. ALWAYS QUIT USING X OR B, NEVER USE THE CLOSE BUTTON.

A+


Mozilla/5.0 (x11; U; Linux x86_64; fr-FR; rv:31.0) Gecko/20100101 Ubuntu/12.04 K-Meleon/75.0

Web: http://jujuland.pagesperso-orange.fr/
Mail : alain [dot] aupeix [at] wanadoo [dot] fr




Options: ReplyQuote


K-Meleon forum is powered by Phorum.