KTextAddons

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

KDE's Doxygen guidelines are available online.