oxt_import module reference

gtkspellcheck.oxt_import.deflate_oxt(oxt_path, extract_path, override=False, move_path=None)

Uncompress, read and install LibreOffice .oxt dictionaries extensions.

  • oxt_path – path to a directory containing the .oxt extensions.
  • extract_path – path to extract Hunspell dictionaries files.
  • override – override files.
  • move_path – Optional path to move the .oxt files after processing.
Return type:


This function extracts the Hunspell dictionaries (.dic and .aff files) from all the .oxt extensions found on oxt_path directory to the extract_path directory.

Extensions like the ones found here:

In detail, this functions does the following:

  1. Find all the .oxt extension files within oxt_path
  2. Open (unzip) each extension.
  3. Find the dictionary definition file within (dictionaries.xcu)
  4. Parse the dictionary definition file and locate the dictionaries files.
  5. Uncompress those files to extract_path.

By default file overriding is disabled, set override parameter to True if you want to enable it. As and additional option, each processed extension can be moved to move_path.