21 #ifndef LANGUAGEUTILS_H
22 #define LANGUAGEUTILS_H
24 #include "Utils/Macros.h"
30 template<
typename A,
typename B>
192 #ifdef SAYONARA_WITH_TESTS
194 void setLanguageVersion(
const QString& fourLetter,
const QString& version);
Definition: org_mpris_media_player2_adaptor.h:21
void updateLanguageVersion(const QString &fourLetter)
Update language version in translations/versions file to current Sayonara Version.
QString getSharePath(const QString &fourLetter)
get the complete path to a language file out of the share directory
QString getLanguageVersion(const QString &fourLetter)
Get the language version out of translations/versions file in home dir.
QString getChecksum(const QString &fourLetter)
calculates the checksum for the currently used language file (either home or share directory)
QString getChecksumFtpPath()
Returns the path where checksums can be fetched from.
QString getUsedLanguageFile(const QString &fourLetter)
Returns the correct language file either from share dir or home dir.
QString extractLanguageCode(const QString &languageFile)
Extracts the language Code out of a sayonara_lang string.
QString getIconPath(const QString &fourLetter)
Returns the icon path in share directory.
QString getSimilarLanguage4(const QString &fourLetter)
get_similar_language_4
QString getFtpPath(const QString &fourLetter)
get the complete path to a language file out of the ftp directory
QString getChecksumHttpPath()
Returns the path where checksums can be fetched from.
QString getHttpPath(const QString &fourLetter)
get the complete http url to a language file
QString getHomeTargetPath(const QString &fourLetter)
get_home_target_path
bool isOutdated(const QString &fourLetter)
Returns if the language version in translations/versions file is smaller than the current sayonara ve...
QString convertOldLanguage(const QString &languageCode)
Converts two letter into four letter.
QStringList getCurrentQtTranslationPaths()
get all qt paths which include translations
QMap< QString, QLocale > availableLanguages()
Returns all languages located in user path and all languages in sayonara path.
bool importLanguageFile(const QString &filename)
Imports a qm file. The filename must contain a valid four or two letter code.
QLocale getCurrentLocale()
get the current selected locale based on the current language file
Helper functions.
Definition: GenreView.h:36