KTextAddons

bergamotengineutils.h
1/*
2 SPDX-FileCopyrightText: 2023-2024 Laurent Montel <montel.org>
3
4 SPDX-License-Identifier: GPL-2.0-or-later
5*/
6#pragma once
7#include "libbergamot_export.h"
8#include <QDir>
9#include <QString>
10
11namespace BergamotEngineUtils
12{
13[[nodiscard]] LIBBERGAMOT_EXPORT QString defaultBergamotRepository();
14[[nodiscard]] LIBBERGAMOT_EXPORT QString groupName();
15[[nodiscard]] LIBBERGAMOT_EXPORT QString coreNumberKey();
16[[nodiscard]] LIBBERGAMOT_EXPORT QString memoryByThreadKey();
17[[nodiscard]] LIBBERGAMOT_EXPORT QString storageLanguagePath();
18[[nodiscard]] LIBBERGAMOT_EXPORT QString useLocalCacheKey();
19
20struct LIBBERGAMOT_EXPORT LanguageInstalled {
21 QString from;
22 QString to;
23 QString shortName;
24 QString absoluteLanguageModelPath;
25 int version = -1;
26 [[nodiscard]] bool operator==(const LanguageInstalled &other) const;
27};
28
29[[nodiscard]] LIBBERGAMOT_EXPORT QVector<LanguageInstalled> languageLocallyStored(const QString &path = {});
30struct LIBBERGAMOT_EXPORT SettingsInfo {
31 void loadSettingsInfo();
32 void saveSettingsInfo();
33
34 int numberOfThread = 0;
35 int memoryByThread = 64;
36 bool useLocalCache = false;
37};
38};
39
40LIBBERGAMOT_EXPORT QDebug operator<<(QDebug d, const BergamotEngineUtils::LanguageInstalled &t);
41Q_DECLARE_TYPEINFO(BergamotEngineUtils::LanguageInstalled, Q_MOVABLE_TYPE);
KIOCORE_EXPORT bool operator==(const UDSEntry &entry, const UDSEntry &other)
KTEXTEDITOR_EXPORT QDebug operator<<(QDebug s, const MovingCursor &cursor)
NETWORKMANAGERQT_EXPORT QString version()
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Dec 20 2024 11:49:44 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.