Spellcheck option in edit menu not activated- ubuntu 16.04

Hi,

I am new to rednotebook and found it wonderful piece of software. Firstly thanks for creating this.

I have installed it on my fresh ubuntu 16.04 installation (Unity desktop). I have added the stable ppa of rednotebook and updated it to version 1.13. Then, subsequently I have also installed python-gtkspellcheck package on my computer.

However the spell check option in the edit menu does not get activated still. The help document describes also of an option to select the language by right clicking in the edit area and select the language from the entry "languages" in the context menu. But this context menu also has no "Languages" option.

When I start rednotebook from command line, the messages show a warning "For spell checking, please install pygtkspellcheck (python-gtkspellcheck)." But this is already installed!

When I start a python shell and "import gtkspellcheck", I get a message (error?) "No handlers could be found for logger "gtkspellcheck.spellcheck"".

Do I need to install some more packages?

Thanks,
Kodanda

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu rednotebook Edit question
Assignee:
No assignee Edit question
Solved by:
మంగిపూడి కోదండరామ్ (Mangipudi Kodanda Ram)
Solved:
Last query:
Last reply:
Revision history for this message
actionparsnip (andrew-woodhead666) said :
#1

If you are using a PPA instead of the version in the Ubuntu repository then I suggest you contact the PPA maintainer to report the issue with their package

Revision history for this message
మంగిపూడి కోదండరామ్ (Mangipudi Kodanda Ram) (kodanda) said :
#2

Hi Andrew,

Thanks for your reply. In fact the problem was there with the packaged version of ubuntu 16.04. I have upgraded it to ppa:rednotebook/stable to see if it is fixed.

Anyway, I have now purged the ppa, and reverted back to the packaged version of 1.10. I have python-gtkspellcheck installed. It may be useful to note that while installing the packaged version it recommended "python-gtkspell" which is I think renamed to python-gtkspellcheck.

With the packaged version, still the spell check option in Edit menu is inactive.

Thanks
Kodanda

Revision history for this message
మంగిపూడి కోదండరామ్ (Mangipudi Kodanda Ram) (kodanda) said :
#3

Hi,

I fixed it eventually. It seems that the renaming of python module gtkspell to gtkspellcheck is the culprit. The import of module name and the function call for spell check need to be modified. Since there is no way to add a file I am listing contents of the patch file below in case you want to fix the bug with spell check in the version in the repositories.

Cheers,
Kodanda
-----------------------------------------------------------------------------------------------------

*** editor.py 2016-09-03 20:58:36.462628695 +0200
--- editor_new.py 2016-09-03 20:52:04.472764303 +0200
***************
*** 26,34 ****
  import pango

  try:
! import gtkspell
  except ImportError:
! gtkspell = None

  from rednotebook.gui import t2t_highlight
  from rednotebook import undo
--- 26,34 ----
  import pango

  try:
! import gtkspellcheck
  except ImportError:
! gtkspellcheck = None

  from rednotebook.gui import t2t_highlight
  from rednotebook import undo
***************
*** 268,274 ****

      def can_spell_check(self):
          """Return True if spell checking is available."""
! return gtkspell is not None

      def is_spell_check_enabled(self):
          return self._spell_checker is not None
--- 268,274 ----

      def can_spell_check(self):
          """Return True if spell checking is available."""
! return gtkspellcheck is not None

      def is_spell_check_enabled(self):
          return self._spell_checker is not None
***************
*** 286,292 ****
          assert self.can_spell_check()
          assert self._spell_checker is None
          try:
! self._spell_checker = gtkspell.Spell(self.day_text_view)
          except gobject.GError as err:
              logging.error('Spell checking could not be enabled: %s' % err)
              self._spell_checker = None
--- 286,292 ----
          assert self.can_spell_check()
          assert self._spell_checker is None
          try:
! self._spell_checker = gtkspellcheck.SpellChecker(self.day_text_view)
          except gobject.GError as err:
              logging.error('Spell checking could not be enabled: %s' % err)
              self._spell_checker = None

Revision history for this message
Jendrik Seipp (jendrikseipp) said :
#4

This has been fixed in the development version. You could try installing
from the https://launchpad.net/~rednotebook/+archive/ubuntu/daily PPA,
if you like.