Spell Check

Hello. Gut no spil cheker.

I understand that you need install 2 things.

I do the terminal dance and copy and paste the command into it.

Nothing seems to happen.

I am running elementary luna (ubuntu 12 something) 32 bit.

Everything else with exception of templates seems to runs really well.

Step by step and I will make you a cake. ;O)

There is a step-by-step method here: [url]https://forum.literatureandlatte.com/t/a-mostly-complete-guide-to-installing-scrivener-on-linux/19819/1].

See “D. Spelling”.

I’ve tried all of this but no dice. Still not seeing any spell checking going on. No error messages, but no spell checking either. :frowning:

Ubuntu 13.10 64bit

Is there any way of checking what scrivener is actually using in terms of dictionaries etc. It gives me the option to select dictionaries so that bit looks to have worked. I have to admit to being at a loss right now

I do no know of any way to list the location of dictionaries being used by Scrivener.

The ASPELL_CONF variable can be used to override pretty much all of aspell’s configuration. See http://aspell.net/0.50-doc/man-html/4_Customizing.htmlfor the details.

Basically, there are two possible problems with aspell:

a) the wrong dictionary location is being used
(i.e. /var/lib/aspell instead of /usr/share/scrivener/lib/aspell)
b) the dictionaries are 64-bit instead of 32-bit

You can verify a) by simply moving the dictionary files and seeing if they disappear from the preferences (e.g. mv /var/lib/aspell /var/lib/aspell.old; mkdir /var/lib/aspell). If you find the dictionaries are being read from /var/lib, use ASPELL_CONF to override this.

If the correct location is being used, rebuild the dictionaries in /usr/share/scrivener as follows:

echo '#!/bin/sh' > /tmp/gen_32_aspell_dicts.sh echo "ASPELL_CONF='prefix /usr/share/scrivener'" >> /tmp/gen_32_aspell_dicts.sh echo 'PATH="/usr/share/scrivener/bin:$PATH"' >> /tmp/gen_32_aspell_dicts.sh echo export PATH ASPELL_CONF >> /tmp/gen_32_aspell_dicts.sh chmod +x /tmp/gen_32_aspell_dicts.sh sudo /usr/sbin/aspell-autobuildhash --dry-run --force 2>&1 | grep zcat | sed -e 's/var\/lib/usr\/share\/scrivener\/lib/' -e 's/usr\/lib/usr\/share\/scrivener\/lib/' >> /tmp/gen_32_aspell_dicts.sh sudo bash /tmp/gen_32_aspell_dicts.sh

This is the same command as in the step-by=step post, only it has been modified to use the .deb package path instead of the tarball path.

Done it. I just uninstalled everything and started again this time taking extra care over each step. I also added:

echo 'LD_LIBRARY_PATH="/usr/share/scrivener/lib"' >> /tmp/gen_32_aspell_dicts.sh echo 'AC_CONF="/usr/share/scrivener"' >> /tmp/gen_32_aspell_dicts.sh to the dictionary fix script generator.
I also added the AC_CONF directive to the scrivener,sh launch script as well. Not sure if they made a difference but it worked for me so I’m not complaining! I think the AC_CONF thing is superfluous but I definitely needed the LD_LIBRARY_PATH export as it was picking up the 64 bit libs :slight_smile:

Anyway - it’s all good now! Thanks for your help.

Addendum: It appears that when Scrivener is launched from the unity launchers bar, it ignores the aspell prefix calls and reverts back to the 64bit calls. I’ve been unable to coax it into working from there, so have just reverted to calling it from command line where this problem doesn’t occur. If anyone knows why this happens I’d be delighted to know!

It looks like the .desktop file attempts to execute Scrivener before running scrivener.sh:

bash$ cat /usr/share/applications/Scrivener.desktop[Desktop Entry] Encoding=UTF-8 Version=1.0 Type=Application Name=Scrivener GenericName=Scrivener writing software Comment=Scrivener writing software TryExec=/usr/share/scrivener/bin/Scrivener Exec=/usr/share/scrivener/bin/scrivener.sh %U Path=/usr/share/scrivener/bin Icon=Scrivener Terminal=false Categories=Office

You can try commenting out the TryExec line in order to force it to use the shell script. Also, ensure that the shell script in the Exec line matches the one you modified with the AC_CONF directive (it sounds like it is, but best double-check).

Yeah - first thing I tried was to remove the TryExec bit, but no joy. It’s not a major problem as I’ve just installed it as an icon on the desktop rather than the unity launcher bar and it runs fine from there.

It could be an environment problem. Try creating a shell script in your home dir which sources your .bashrc, and update the Scrivener .desktop file to use that:

[code]#!/bin/sh

. ~/.bashrc
/usr/share/scrivener/bin/scrivener.sh $*
[/code]

Also, you might want to put a line in the shell script to touch a file in /tmp (e.g. ‘touch /tmp/scrivener_called.txt’) in order to verify that Unity is in fact invoking the shell script (and not just failing silently for whatever reason).

Hmm - good thinking. I’ll give it a go when I get a chance to play around a bit. Thanks for the ideas. :slight_smile:

Got the spell check running, thanks for that, but I can’t get the French one :frowning:

I download it without error message, quit Scrivener then restart it, but still no French in the dictionnaries, only English ones.

Somebody has an idea ?

Thanks.

Ok, just solved my problem myself :

I downloaded the French dictionnary from Ubuntu, not from Scrivener :slight_smile:

Thank you guys for the tip to make spell check working :slight_smile:

Just want to say thanks for the libaspell-dev tip.

Installed libaspell-dev from the Linux Mint Software Manager.

Closed Scrivener and restarted it.

Bingo! I now have a working spell checker. :smiley:

I cannot change SpellChecking Language on Russian under Xubuntu 13.10-64.

What must I do to switch Russian spellchecking on?

Oddly enough, I somehow managed to get spellcheck (en) to work on Ubuntu 13.10 64 bits by accident. Following the steps only got me as far as having it find the right dictionaries, but the actual spell check did not work. Now, if I run the actual executable (without the script), it just works.

Attempting to reproduce this on another machine (by copying over the tarball directory to an user, same path, same version, same permissions), but so far, no luck. Finds the dict and that’s it. Odd to say the least.

I’m not running Ubuntu, but when I list the Aspell modules available in my Linux distro I see one for each language. In my case I have aspell-en. There’s one for Russian, aspell-ru. I’m guessing you need that, plus, of course, Aspell itself, if you don’t already have it installed :slight_smile: Also need libaspell-dev.

All installed few years ago…