Library main namespace.
More...
|
auto | append_default_dir_paths (vector< fs_path > &paths) -> void |
| Append the paths of the default directories to be searched for dictionaries.
|
|
auto | append_libreoffice_dir_paths (vector< fs_path > &paths) -> void |
| Append the paths of the LibreOffice's directories to be searched for dictionaries.
|
|
auto | search_dirs_for_one_dict (const vector< fs_path > &dir_paths, const fs_path &dict_name_stem) -> fs_path |
| Serach the directories for only one dictionary.
|
|
auto | search_dirs_for_dicts (const vector< fs_path > &dir_paths, vector< fs_path > &dict_list) -> void |
| Search the directories for dictionaries.
|
|
auto | search_default_dirs_for_dicts () -> vector< fs_path > |
| Search the default directories for dictionaries.
|
|
◆ append_default_dir_paths()
auto nuspell::append_default_dir_paths |
( |
vector< fs_path > & |
paths | ) |
-> void |
Append the paths of the default directories to be searched for dictionaries.
- Parameters
-
[out] | paths | vector that receives the directory paths |
◆ append_libreoffice_dir_paths()
auto nuspell::append_libreoffice_dir_paths |
( |
vector< fs_path > & |
paths | ) |
-> void |
Append the paths of the LibreOffice's directories to be searched for dictionaries.
- Warning
- This function shall not be called from LibreOffice or modules that may end up being used by LibreOffice. It is mainly intended to be used by the CLI tool.
- Parameters
-
[out] | paths | vector that receives the directory paths |
◆ search_default_dirs_for_dicts()
auto nuspell::search_default_dirs_for_dicts |
( |
| ) |
-> vector< fs_path > |
◆ search_dirs_for_dicts()
auto nuspell::search_dirs_for_dicts |
( |
const vector< fs_path > & |
dir_paths, |
|
|
vector< fs_path > & |
dict_list |
|
) |
| -> void |
Search the directories for dictionaries.
This function searches the directories for files that represent dictionaries and for each found dictionary it appends the path of the .aff file to dict_list
. One dictionary consts of two files, .aff and .dic, and both need to exist, but only the .aff is added.
- Parameters
-
[in] | dir_paths | list of paths to directories |
[out] | dict_list | vector that receives the paths of the found dictionaries |
◆ search_dirs_for_one_dict()
auto nuspell::search_dirs_for_one_dict |
( |
const vector< fs_path > & |
dir_paths, |
|
|
const fs_path & |
dict_name_stem |
|
) |
| -> fs_path |
Serach the directories for only one dictionary.
This function is more efficient than search_dirs_for_dicts() because it does not iterate whole directories, it only checks the existance of .dic and .aff files. Useful for some CLI tools. GUI apps generally need a list of all dictionaries.
- Parameters
-
[in] | dir_paths | list of directories |
[in] | dict_name_stem | dictionary name, filename without extension (stem) |
- Returns
- path to the .aff file of the dictionary or empty object if not found