Added support to change the spell-checking language.

Bug 720335

* src/client/composer/spell-check-popover.vala
  Implemented a GtkPopover allowing the user to select a
  subset of the currently installed dictionaries for the spell
  checking in the composer widget.

* src/client/util/util-international-vala
  Added detection of installed dictionaries and proper
  translation of the available languages. This requires
  Enchant as an additional dependency.

* src/client/application/geary-config.vala
  Added keys spell-check-visible-languages and
  spell-check-languages in GSettings.
This commit is contained in:
Leonardo Robol 2016-05-16 19:10:24 +02:00 committed by Michael James Gratton
parent 32a7f76360
commit cae4b443c6
10 changed files with 651 additions and 16 deletions

View file

@ -23,6 +23,32 @@ set(VERSION "0.11.0")
set(VERSION_INFO "Release")
set(LANGUAGE_SUPPORT_DIRECTORY ${CMAKE_INSTALL_PREFIX}/share/locale)
if (NOT ISO_CODE_639_XML)
find_path(ISOCODES_DIRECTORY NAMES iso_639.xml PATHS ${CMAKE_INSTALL_PREFIX} /usr/share/xml/iso-codes)
if (ISOCODES_DIRECTORY)
set(ISO_CODE_639_XML ${ISOCODES_DIRECTORY}/iso_639.xml)
else ()
message(WARNING "File iso_639.xml not found. Please specify it manually using cmake -DISO_CODE_639_XML=/path/to/iso_639.xml")
endif ()
else ()
if (NOT EXISTS ${ISO_CODE_639_XML})
message(WARNING "The path to iso_639.xml specified in ISO_CODE_639_XML is not valid.")
endif ()
endif ()
if (NOT ISO_CODE_3166_XML)
find_path(ISOCODES_DIRECTORY NAMES iso_3166.xml PATHS ${CMAKE_INSTALL_PREFIX} /usr/share/xml/iso-codes)
if (ISOCODES_DIRECTORY)
set(ISO_CODE_3166_XML ${ISOCODES_DIRECTORY}/iso_3166.xml)
else ()
message(WARNING "File iso_3166.xml not found. Please specify it manually using cmake -DISO_CODE_3166_XML=/path/to/iso_3166.xml")
endif ()
else ()
if (NOT EXISTS ${ISO_CODE_3166_XML})
message(WARNING "The path to iso_3166.xml specified in ISO_CODE_3166_XML is not valid.")
endif ()
endif ()
# Packaging filenamesnames.
set(ARCHIVE_BASE_NAME ${CMAKE_PROJECT_NAME}-${VERSION})
set(ARCHIVE_FULL_NAME ${ARCHIVE_BASE_NAME}.tar.xz)
@ -58,6 +84,8 @@ find_package(PkgConfig)
pkg_check_modules(LIBUNITY QUIET unity>=5.12.0)
pkg_check_modules(LIBMESSAGINGMENU QUIET messaging-menu>=12.10.2)
pkg_check_modules(ENCHANT QUIET enchant)
pkg_check_modules(SQLITE311 QUIET sqlite3>=3.11.0)
pkg_check_modules(SQLITE312 QUIET sqlite3>=3.12.0)
if (SQLITE311_FOUND AND NOT SQLITE312_FOUND)