• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdeutils API Reference
  • KDE Home
  • Contact Us
 

kgpg

  • sources
  • kde-4.14
  • kdeutils
  • kgpg
  • editor
kgpgeditor.h
Go to the documentation of this file.
1 /***************************************************************************
2  kgpgeditor.h - description
3  -------------------
4  begin : Mon Jul 8 2002
5  copyright : (C) 2002 by Jean-Baptiste Mardelle
6  email : bj@altern.org
7  ***************************************************************************/
8 
9 /***************************************************************************
10  * *
11  * This program is free software; you can redistribute it and/or modify *
12  * it under the terms of the GNU General Public License as published by *
13  * the Free Software Foundation; either version 2 of the License, or *
14  * (at your option) any later version. *
15  * *
16  ***************************************************************************/
17 
18 #ifndef KGPGEDITOR_H
19 #define KGPGEDITOR_H
20 
21 #include <KXmlGuiWindow>
22 #include <KUrl>
23 
24 class KToggleAction;
25 class KAction;
26 class KFind;
27 
28 class KgpgTextEdit;
29 class KGpgItemModel;
30 class KeysManager;
31 class KRecentFilesAction;
32 
33 class KgpgEditor : public KXmlGuiWindow
34 {
35  Q_OBJECT
36  friend class KgpgView;
37 
38  KgpgEditor(); // = delete C++0x
39 public:
40  KgpgEditor(KeysManager *parent, KGpgItemModel *model, Qt::WFlags f);
41  ~KgpgEditor();
42 
43  void openEncryptedDocumentFile(const KUrl& url);
44 
45  KgpgTextEdit * const m_editor;
46  KRecentFilesAction *m_recentfiles;
47 
48 signals:
49  void openChangeFont();
50  void openConfigDialog();
51 
52 public slots:
53  void openDocumentFile(const KUrl& url, const QString &encoding = QString());
54  void slotSetFont(QFont myFont);
55  void closeWindow();
56 
57 protected:
58  void saveOptions();
59  void initActions();
60  bool queryClose();
61  bool saveBeforeClear();
62 
63 private slots:
64  // File menu
65  void slotFileNew();
66  void slotFileOpen();
67  bool slotFileSave();
68  bool slotFileSaveAs();
69  void slotFilePrint();
70  void slotFilePreEnc();
71  void slotFilePreDec();
72  void slotKeyManager();
73  void slotFileClose();
74 
75  // Edit menu
76  void slotundo();
77  void slotredo();
78  void slotEditCut();
79  void slotEditCopy();
80  void slotEditPaste();
81  void slotSelectAll();
82  void slotFind();
83  void slotFindNext();
84  void slotFindPrev();
85  void slotFindText();
86 
87  // Coding menu
88  void slotSetCharset();
89  void slotResetEncoding(bool enc);
90  bool checkEncoding(QTextCodec *codec);
91 
92  // Signing menu
93  void slotPreSignFile();
94  void slotSignFile(const KUrl &url);
95  void slotSignFileFin();
96  void slotPreVerifyFile();
97  void slotVerifyFile(const KUrl &url);
98  void slotCheckMd5();
99  void importSignatureKey(const QString &id, const QString &fileName);
104  void slotVerifyFinished(const QString &id, const QString &message);
105 
106  // Options menu
107  void slotOptions();
108 
109  void slotUndoAvailable(const bool v);
110  void slotRedoAvailable(const bool v);
111  void slotCopyAvailable(const bool v);
112 
113  void modified();
114  void newText();
115 
116  void slotLibraryDone();
117 
118  void slotDownloadKeysFinished(QStringList ids);
119 
120 private:
121  QString m_textencoding;
122 
123  KToggleAction *m_encodingaction;
124  KAction *m_editundo;
125  KAction *m_editredo;
126  KAction *m_editcopy;
127  KAction *m_editcut;
128  KFind *m_find;
129  KUrl m_docname;
130 
131  bool m_textchanged; //< text was changed since last save
132  bool m_emptytext; //< this was not saved to a file ever
133 
134  KGpgItemModel *m_model;
135  KeysManager *m_parent;
136 };
137 
138 #endif // KGPGEDITOR_H
KgpgEditor::m_editor
KgpgTextEdit *const m_editor
Definition: kgpgeditor.h:45
KGpgItemModel
Definition: kgpgitemmodel.h:44
KgpgEditor::openChangeFont
void openChangeFont()
KgpgEditor::saveOptions
void saveOptions()
Definition: kgpgeditor.cpp:152
KgpgEditor::openConfigDialog
void openConfigDialog()
QFont
KgpgEditor::KgpgView
friend class KgpgView
Definition: kgpgeditor.h:36
KgpgEditor::m_recentfiles
KRecentFilesAction * m_recentfiles
Definition: kgpgeditor.h:46
KXmlGuiWindow
KgpgEditor::openEncryptedDocumentFile
void openEncryptedDocumentFile(const KUrl &url)
Definition: kgpgeditor.cpp:136
KgpgEditor
Definition: kgpgeditor.h:33
KgpgEditor::~KgpgEditor
~KgpgEditor()
Definition: kgpgeditor.cpp:109
KeysManager
Definition: keysmanager.h:66
KgpgTextEdit
Definition: kgpgtextedit.h:29
QString
Qt::WFlags
typedef WFlags
QTextCodec
KgpgEditor::closeWindow
void closeWindow()
Definition: kgpgeditor.cpp:146
KgpgEditor::queryClose
bool queryClose()
Definition: kgpgeditor.cpp:225
QStringList
KgpgEditor::initActions
void initActions()
Definition: kgpgeditor.cpp:158
KgpgEditor::openDocumentFile
void openDocumentFile(const KUrl &url, const QString &encoding=QString())
Definition: kgpgeditor.cpp:114
KgpgEditor::saveBeforeClear
bool saveBeforeClear()
Definition: kgpgeditor.cpp:235
KgpgEditor::slotSetFont
void slotSetFont(QFont myFont)
Definition: kgpgeditor.cpp:141
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:42:08 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

kgpg

Skip menu "kgpg"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdeutils API Reference

Skip menu "kdeutils API Reference"
  • ark
  • filelight
  • kcalc
  • kcharselect
  • kdf
  • kfloppy
  • kgpg
  • ktimer
  • kwallet
  • sweeper

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal