Results 1 to 9 of 9

Thread: Spell checking LaTeX

  1. #1
    Join Date
    Nov 2006
    Location
    New Zealand
    Beans
    422

    Spell checking LaTeX

    SOLVED

    I am doing the final spell-check on my thesis (in LaTeX) before handing it in, but am finding it difficult to check it in British english - everything defaults to US english.

    I am using aspell, with the command
    Code:
    aspell --lang=en_GB -c document.tex
    However this says that the words "faeces" and "practice" are incorrect, while they are clearly correctly spelled according to the Oxford dictionary.

    This is concerning as it means the word "feces" for example must be entered in the British english dictionary, yet I would want to change it to "faeces". Adding "faeces" to the dictionary won't change the fact that aspell probably won't pick up the American spelling "feces" if I have written it anywhere. It could well be missing other words I don't realise.

    Does anyone have any good ideas for how to spell-check a document while
    - ignoring LaTeX coding
    - removing all words in US spelling?
    Last edited by samden; May 26th, 2009 at 04:45 AM.

  2. #2
    Join Date
    Apr 2007
    Beans
    Hidden!

    Re: Spell checking LaTeX

    Have you tried with GUI editors like Kile or Texmaker? Last Texmaker even has inline spellchecker and it does skip codes.

    Do you use babel with "british" for British english?

    In Kile, you can select text, run spellchecker and choose a dictionary (british). However, Kile doesn't skip LaTeX code

    In Texmaker, you may choose spelling dictionary in Options > Configure Texmaker > Editor. Dictionaries are usually located in /usr/share/myspell/dicts

    I hope this will help.
    Last edited by meho_r; May 26th, 2009 at 02:25 AM.
    ...

  3. #3
    Join Date
    Nov 2006
    Location
    New Zealand
    Beans
    422

    Re: Spell checking LaTeX

    I am using Gedit, but the inbuilt spellchecker doesn't recognise LaTeX code.

    I would love a stand-alone spellchecker I could just feed all my files through, rather than fussing around with the GUI spellchecker in Gedit. I'll muddle along somehow without one of course, but I just thought there might be a standalone tool already available.

    I have not been using babel, what does it do and how would that help? I thought it just dealt with hyphenation, special characters and that sort of thing.

  4. #4
    Join Date
    Apr 2007
    Beans
    Hidden!

    Re: Spell checking LaTeX

    I'm not sure about stand-alone spellchecker, but I think you should give Texmaker 1.9 a try since it does recognize LaTeX code and skips it while doing a spellcheck.

    As for babel, it's a multilingual package for use with LaTeX. It takes care of all language specific tasks, sectioning, TOC, hyphenations etc. I don't know how deep differences between american and british english go, but just to be sure, I would use babel with "british" or "UKbritish" options. Check babel documentation for more infos.

    I would recommend you to visit LaTeX Community Forum where you can get more thorough explanations and advices in this regard
    Last edited by meho_r; May 26th, 2009 at 04:10 AM.
    ...

  5. #5
    Join Date
    Nov 2006
    Location
    New Zealand
    Beans
    422

    Re: Spell checking LaTeX

    Thanks for the help.

    Rather than install Texmaker and get into clunky GUI stuff I've kept using aspell, it works very well. I was frustrated with particular words, but I think that is just an issue with the default dictionaries used by aspell and I am unlikely to find any improvement with other software - they mostly seem to use the aspell dictionaries anyway.

    Having just solved the problem myself and got used to the tools I probably shouldn't have bothered starting this thread, I'll mark it solved now.

    I'd recommend aspell to anyone else in my situation.

    EDIT: Well, I would mark it solved if I could figure out how to!
    Last edited by samden; May 26th, 2009 at 05:20 AM.

  6. #6
    Join Date
    Oct 2009
    Beans
    380
    Distro
    Ubuntu Development Release

    Re: Spell checking LaTeX

    To ignore latex code and specially the *labels*, how did you do?

  7. #7
    Join Date
    Nov 2006
    Location
    New Zealand
    Beans
    422

    Re: Spell checking LaTeX

    <removed by author>
    Last edited by samden; November 25th, 2009 at 08:44 PM. Reason: Incorrect advice

  8. #8
    Join Date
    Jul 2006
    Location
    Germany
    Beans
    1,805

    Re: Spell checking LaTeX

    Quote Originally Posted by leorolla View Post
    To ignore latex code and specially the *labels*, how did you do?
    Use the tex mode,
    Code:
    aspell check --mode=tex document.tex
    ...

  9. #9
    Join Date
    Oct 2009
    Beans
    380
    Distro
    Ubuntu Development Release

    Re: Spell checking LaTeX

    Thank you!

    I also found the solution in aspell manual and here:

    http://ubuntuforums.org/showthread.php?t=1259557

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •