iasp / textroom

Automatically exported from code.google.com/p/textroom
Other
0 stars 0 forks source link

Spell check not working correctly. #54

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Start textroom
2. Type some words
3. Press F5 (for spellchecking)

What is the expected output? What do you see instead?
I expect only the misspelled words to underline red, but every word underlines 
red as if they're all misspelled.

The output on the console is:
error: empty dic file
Hash Manager Error : 2

Which led me to believe that the correct dictionary for hunspell wasn't 
installed. I installed an english dictionary package, these are the files:
hunspell-en-us /usr/share/myspell/en_US.aff
hunspell-en-us /usr/share/myspell/en_US.dic

Yet the problem persists. Where exactly is it reading the dictionary files from?

What version of the product are you using? On what operating system?
textroom ver. 0.6.5, on Arch Linux.
hunspell ver. 1.2.12

Please provide any additional information below.
These are the compilation options used in the PKGBUILD:

  cd "$srcdir/$pkgname-$pkgver"

  # hunspell fix
  sed 's+-lhunspell+-lhunspell-1.2+' -i textroom.pro || return 1
  # sound dir fix
  sed 's+/usr/share/sounds+/usr/share/sounds/textroom+g' -i textroom.pro -i src/textroom.cpp || return 1

  # build
  qmake || return 1
  make || return 1
  make INSTALL_ROOT="$pkgdir" \
    install_data install_target install_icon install_mime install_desktop

Original issue reported on code.google.com by vrfeig...@gmail.com on 19 Sep 2010 at 10:57

GoogleCodeExporter commented 8 years ago
Have you selected the English language from options? Please select the document 
language as English and try again. And please report back. 

Thank you for using TextRoom.

Original comment by gordebak on 20 Sep 2010 at 7:56

GoogleCodeExporter commented 8 years ago
Sorry, reporting back late. "US English" is the default document language and 
it's selected. The aforementioned behavior is therefore the same.

Original comment by vrfeig...@gmail.com on 25 Sep 2010 at 7:09

GoogleCodeExporter commented 8 years ago
This is a problem about different distros doing some things different. I use 
Ubuntu for development. hunspell in TextRoom looks for 
"/usr/share/myspell/dicts/" folder for the dictionary files. If you are using 
TextRoom from the source, you can remove the "dicts/" from the followwing lines 
and compile again. 

1045    affFileName = "/usr/share/myspell/dicts/";
1046    dicFileName = "/usr/share/myspell/dicts/";

I will be glad if you report back and tell if it worked. Thank you.

Original comment by gordebak on 25 Sep 2010 at 7:17

GoogleCodeExporter commented 8 years ago
I did as you recommended and changed those lines from the source and 
recompiled, and it now works. Thanks for the help, I've notified the maintainer 
of the fix.

Original comment by vrfeig...@gmail.com on 25 Sep 2010 at 8:26

GoogleCodeExporter commented 8 years ago

Original comment by gordebak on 25 Sep 2010 at 11:18

GoogleCodeExporter commented 8 years ago
Had the same problem and based on the above info, I simply added sym links to 
the dict files in the directory that TextRoom looks for them.  It works. 

Original comment by lashley....@gmail.com on 6 Dec 2010 at 9:17