File indexing completed on 2024-05-12 04:38:07

0001 /*
0002     SPDX-FileCopyrightText: 2007-2008 David Nolden <david.nolden.kdevelop@art-master.de>
0003     SPDX-FileCopyrightText: 2006 Hamish Rodda <rodda@kde.org>
0004     SPDX-FileCopyrightText: 2009 Milian Wolff <mail@milianw.de>
0005 
0006     SPDX-License-Identifier: LGPL-2.0-or-later
0007 */
0008 
0009 #ifndef KDEVPLATFORM_CONFIGURABLECOLORS_H
0010 #define KDEVPLATFORM_CONFIGURABLECOLORS_H
0011 
0012 #include "codehighlighting.h"
0013 
0014 #include <language/languageexport.h>
0015 
0016 #include <KTextEditor/Attribute>
0017 
0018 namespace KTextEditor
0019 {
0020 class View;
0021 }
0022 
0023 namespace KDevelop {
0024 class ColorCache;
0025 
0026 class KDEVPLATFORMLANGUAGE_EXPORT ConfigurableHighlightingColors
0027 {
0028 public:
0029     explicit ConfigurableHighlightingColors();
0030     ~ConfigurableHighlightingColors();
0031 
0032     void reset(ColorCache* cache, KTextEditor::View* view);
0033 
0034     KTextEditor::Attribute::Ptr attribute(CodeHighlightingType type) const;
0035 
0036 private:
0037     QHash<CodeHighlightingType, KTextEditor::Attribute::Ptr> m_attributes;
0038 };
0039 }
0040 
0041 #endif // KDEVPLATFORM_CONFIGURABLECOLORS_H