dicogis.utils.texts module

Name: Texts Manager Purpose: Load texts from localized files to display in a parent program

Author: Julien Moura (@geojulien)

class dicogis.utils.texts.TextsManager(locale_folder=None)

Bases: object

Load texts from localized files to display in a parent program

__init__(locale_folder=None)

Manage texts from a file into a dictionary used to custom program display.

load_texts(language_code='EN')

Load texts according to the specified language code.

Parameters:

language_code (str, optional) – 2 letters prefix to pick the correct language. Defaults to “EN”.

Raises:

FileNotFoundError – if language file doesn’t exists

Returns:

dictonary filled by methods

Return type:

dict