Messagelib

richtextcomposerng.h
1 /*
2  SPDX-FileCopyrightText: 2015-2020 Laurent Montel <[email protected]>
3 
4  SPDX-License-Identifier: GPL-2.0-or-later
5 */
6 
7 #ifndef MESSAGECOMPOSER_RICHTEXTCOMPOSERNG_H
8 #define MESSAGECOMPOSER_RICHTEXTCOMPOSERNG_H
9 
10 #include "messagecomposer_export.h"
11 #include <KPIMTextEdit/RichTextComposer>
12 #include <MessageComposer/PluginEditorConvertTextInterface>
13 #include <KIdentityManagement/Signature>
14 
15 namespace PimCommon {
16 class AutoCorrection;
17 }
18 
19 namespace MessageComposer {
20 class TextPart;
21 class RichTextComposerSignatures;
22 class RichTextComposerNgPrivate;
27 class MESSAGECOMPOSER_EXPORT RichTextComposerNg : public KPIMTextEdit::RichTextComposer
28 {
29  Q_OBJECT
30 public:
31  explicit RichTextComposerNg(QWidget *parent = nullptr);
32  ~RichTextComposerNg() override;
33 
34  Q_REQUIRED_RESULT PimCommon::AutoCorrection *autocorrection() const;
35  void setAutocorrection(PimCommon::AutoCorrection *autocorrect);
36  void setAutocorrectionLanguage(const QString &lang);
37 
38  void fillComposerTextPart(MessageComposer::TextPart *textPart);
39  Q_REQUIRED_RESULT MessageComposer::RichTextComposerSignatures *composerSignature() const;
40 
42  Q_REQUIRED_RESULT QString toCleanHtml() const;
43 
44  void forceAutoCorrection(bool selectedText = false) override;
45 
46  Q_REQUIRED_RESULT virtual MessageComposer::PluginEditorConvertTextInterface::ConvertTextStatus convertPlainText(MessageComposer::TextPart *textPart);
47 
48 protected:
49  bool processModifyText(QKeyEvent *event) override;
50 
51 private:
52  RichTextComposerNgPrivate *const d;
53 };
54 }
55 #endif
The RichTextComposerNg class.
The RichTextComposerSignatures class.
Simple interface that both EncryptJob and SignEncryptJob implement so the composer can extract some e...
The TextPart class.
Definition: textpart.h:20
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Fri Aug 7 2020 23:11:01 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.