1 /*
2     SPDX-FileCopyrightText: 2008 David Nolden <david.nolden.kdevelop@art-master.de>
3 
4     SPDX-License-Identifier: LGPL-2.0-or-later
5 */
6 
7 #ifndef KDEVPLATFORM_COMPLETIONSETTINGS_H
8 #define KDEVPLATFORM_COMPLETIONSETTINGS_H
9 
10 #include <interfaces/icompletionsettings.h>
11 #include <KConfigGroup>
12 
13 namespace KDevelop
14 {
15 
16 class CompletionSettings : public KDevelop::ICompletionSettings
17 {
18     Q_OBJECT
19 public:
20     CompletionLevel completionLevel() const override;
21 
22     bool automaticCompletionEnabled() const override;
23 
emitChanged()24     void emitChanged() { emit settingsChanged(this); }
25 
26     int localColorizationLevel() const override;
27 
28     int globalColorizationLevel() const override;
29 
30     bool highlightSemanticProblems() const override;
31 
32     bool highlightProblematicLines() const override;
33 
34     ProblemInlineNotesLevel problemInlineNotesLevel() const override;
35 
36     bool boldDeclarations() const override;
37 
38     bool showMultiLineSelectionInformation() const override;
39 
40     int minFilesForSimplifiedParsing() const override;
41 
42     QStringList todoMarkerWords() const override;
43 
44     static CompletionSettings& self();
45 
46 private:
47     CompletionSettings();
48 
49     const CompletionLevel m_level = MinimalWhenAutomatic;
50     const bool m_automatic = true;
51     const bool m_highlightSemanticProblems = true;
52     const bool m_highlightProblematicLines = false;
53     const bool m_showMultiLineInformation = false;
54     const bool m_boldDeclarations = true;
55     const int m_localColorizationLevel = 170;
56     const int m_globalColorizationLevel = 255;
57     const int m_minFilesForSimplifiedParsing = 100000;
58     const QString m_todoMarkerWords;
59 
60     const KConfigGroup m_languageGroup;
61 };
62 }
63 #endif
64