Messagelib

defaultrenderer.h
1 /*
2  SPDX-FileCopyrightText: 2016 Sandro KnauƟ <[email protected]>
3 
4  SPDX-License-Identifier: LGPL-2.0-or-later
5 */
6 
7 #pragma once
8 
9 #include <QSharedPointer>
10 
11 #include <functional>
12 
13 namespace KMime
14 {
15 class Message;
16 }
17 
18 namespace MimeTreeParser
19 {
20 class MessagePart;
21 using MessagePartPtr = QSharedPointer<MessagePart>;
22 }
23 
24 namespace MessageViewer
25 {
26 class DefaultRendererPrivate;
27 class HtmlWriter;
28 class AttachmentStrategy;
29 class CSSHelperBase;
30 
31 class DefaultRenderer
32 {
33 public:
34  explicit DefaultRenderer(CSSHelperBase *cssHelder);
35  ~DefaultRenderer();
36 
37  void setShowOnlyOneMimePart(bool onlyOneMimePart);
38  void setAttachmentStrategy(const AttachmentStrategy *strategy);
39  void setShowEmoticons(bool showEmoticons);
40  void setIsPrinting(bool isPrinting);
41  void setShowExpandQuotesMark(bool showExpandQuotesMark);
42  void setShowSignatureDetails(bool showSignatureDetails);
43  void setLevelQuote(int levelQuote);
44  void setHtmlLoadExternal(bool htmlLoadExternal);
45  void setCreateMessageHeader(const std::function<QString(KMime::Message *)> &);
46  void render(const MimeTreeParser::MessagePartPtr &msgPart, HtmlWriter *writer);
47  void setShowEncryptionDetails(bool showEncryptionDetails);
48 
49 private:
50  std::unique_ptr<DefaultRendererPrivate> const d;
51 };
52 }
This file is part of the KDE documentation.
Documentation copyright © 1996-2021 The KDE developers.
Generated on Fri Nov 26 2021 23:16:41 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.