On Wed, Jan 31, 2007 at 05:24:26PM +0100, Agustin Martin wrote: > On Wed, Jan 31, 2007 at 03:05:11PM +0100, Rafael Laboissiere wrote: > > * Rafael Laboissiere <[EMAIL PROTECTED]> [2007-01-27 00:42]: > > > > > One possible solution is to introduce squirrelspell support into > > > dictionaries-common. [snip] > > > > Okay, I gave it a try. AgustÃn, you will find below a patch to the current > > CVS sources that introduce SquirrelMail support in dictionaries-common. The > > idea is to generate a PHP file > > (/sid/var/cache/dictionaries-common/sqspell.php) > > that can be sourced during SquirrelMail initialization. The file currently > > generated in my system is attached below. > > Thanks, Rafael. > > Since we are this close to etch release and these changes will not go into > etch, I would wait a bit before committing stuff, so we are sure that this > is what is really wanted.
I have been playing with the sqspell config file, and thought that something like in the attached patch may work in the meantime (or even as a good fix) if the ispell-wrapper approach is, as I expect, correct. Note that the patch is completely untested. I have no experience at all with php, although I suppose that there is no need to escape double quotes when they are between single quotes. Fix as appropriate otherwise. If the proposed patch works and you agree with it, please close this bug report with your upload and reassign it to squirrelmail. -- Agustin
diff -Naur squirrelmail-1.4.9a.thijs/plugins/squirrelspell/sqspell_config.php squirrelmail-1.4.9a/plugins/squirrelspell/sqspell_config.php --- squirrelmail-1.4.9a.thijs/plugins/squirrelspell/sqspell_config.php 2007-01-31 17:46:14.000000000 +0100 +++ squirrelmail-1.4.9a/plugins/squirrelspell/sqspell_config.php 2007-01-31 18:03:20.000000000 +0100 @@ -27,21 +27,21 @@ * 'Spanish' => 'aspell -d spanish -a' ); */ -# Debian: if dictionaries-common >= 2.50 is available, detect the +# Debian: if dictionaries-common >= 0.22.50 is available, detect the # installed dictionaries automatically. if ( is_readable ( '/var/cache/dictionaries-common/ispell-dicts-list.txt' ) ) { $dicts = file( '/var/cache/dictionaries-common/ispell-dicts-list.txt' ); $SQSPELL_APP = array(); foreach ($dicts as $dict) { preg_match('/(\S+)\s+\((.+)\)/', $dict, $dparts); - $SQSPELL_APP[$dparts[2]] = 'ispell -d ' . $dparts[1] . ' -a'; + $SQSPELL_APP[$dparts[2]] = 'ispell-wrapper --language="' . $dparts[2] . '" -a'; } } else { $SQSPELL_APP = array('English' => 'ispell -a', 'Spanish' => 'ispell -d spanish -a'); } -# Debian: if dictionaries-common >= 2.50 is available, detect the +# Debian: if dictionaries-common >= 0.22.50 is available, detect the # default dictionary automatically. if ( is_readable ( '/etc/dictionaries-common/ispell-default' ) ) { $dictdefault = file ( '/etc/dictionaries-common/ispell-default' );