Messagelib

templatestexteditor.h
1 /*
2  SPDX-FileCopyrightText: 2013-2023 Laurent Montel <[email protected]>
3 
4  SPDX-License-Identifier: GPL-2.0-or-later
5 */
6 
7 #pragma once
8 
9 #include <KPIMTextEdit/PlainTextEditor>
10 
11 #include <KSyntaxHighlighting/Repository>
12 
13 class QKeyEvent;
14 namespace KPIMTextEdit
15 {
16 class TextEditorCompleter;
17 }
18 namespace TemplateParser
19 {
20 class TemplatesTextEditor : public KPIMTextEdit::PlainTextEditor
21 {
22  Q_OBJECT
23 public:
24  explicit TemplatesTextEditor(QWidget *parent = nullptr);
25  ~TemplatesTextEditor() override;
26 
27 protected:
28  void initCompleter();
29  void keyPressEvent(QKeyEvent *e) override;
30 
31  void updateHighLighter() override;
32 
33  void clearDecorator() override;
34  void createHighlighter() override;
35 
36 private:
37  KPIMTextEdit::TextEditorCompleter *mTextEditorCompleter = nullptr;
39 };
40 }
Q_OBJECTQ_OBJECT
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Sun Mar 26 2023 04:08:12 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.