GpgFrontend Project
A Free, Powerful, Easy-to-Use, Compact, Cross-Platform, and Installation-Free OpenPGP(pgp) Crypto Tool.
GpgFrontend::UI::MainWindow Class Reference
Inheritance diagram for GpgFrontend::UI::MainWindow:
Inheritance graph
Collaboration diagram for GpgFrontend::UI::MainWindow:
Collaboration graph

Classes

struct  CryptoMenu
 

Public Slots

void SlotSetStatusBarText (const QString &text)
 
void SlotOpenFile (QString &path)
 
void SlotFileEncrypt ()
 
void SlotFileDecrypt ()
 
void SlotFileSign ()
 
void SlotFileVerify ()
 
void SlotFileEncryptSign ()
 
void SlotFileDecryptVerify ()
 
void SlotSetRestartNeeded (int)
 

Signals

void SignalLoaded ()
 
void SignalRestartApplication (int)
 
void SignalUIRefresh ()
 
void SignalKeyDatabaseRefresh ()
 

Public Member Functions

void Init () noexcept
 
void SetCryptoMenuStatus (CryptoMenu::OperationType type)
 
- Public Member Functions inherited from GpgFrontend::UI::GeneralMainWindow
 GeneralMainWindow (std::string name, QWidget *parent=nullptr)
 

Protected Member Functions

void closeEvent (QCloseEvent *event) override
 
- Protected Member Functions inherited from GpgFrontend::UI::GeneralMainWindow
void closeEvent (QCloseEvent *event) override
 

Private Slots

void slot_encrypt ()
 
void slot_encrypt_sign ()
 
void slot_decrypt ()
 
void slot_sign ()
 
void slot_verify ()
 
void slot_decrypt_verify ()
 
void slot_show_key_details ()
 
void refresh_keys_from_key_server ()
 
void upload_key_to_server ()
 
void slot_find ()
 
void slot_start_wizard ()
 
void slot_import_key_from_edit ()
 
void slot_append_selected_keys ()
 
void slot_append_keys_create_datetime ()
 
void slot_append_keys_expire_datetime ()
 
void slot_append_keys_fingerprint ()
 
void slot_copy_mail_address_to_clipboard ()
 
void slot_copy_default_uid_to_clipboard ()
 
void slot_copy_key_id_to_clipboard ()
 
void slot_open_key_management ()
 
void slot_open_file_tab ()
 
void slot_open_settings_dialog ()
 
void slot_clean_double_line_breaks ()
 
void slot_cut_pgp_header ()
 
void slot_add_pgp_header ()
 
void slot_disable_tab_actions (int number)
 
void slot_version_upgrade (const SoftwareVersion &version)
 
void slot_add_key_2_favourite ()
 
void slot_remove_key_from_favourite ()
 
void slot_set_owner_trust_level_of_key ()
 

Private Member Functions

void create_actions ()
 
void create_menus ()
 
void create_tool_bars ()
 
void create_status_bar ()
 
void create_dock_windows ()
 
void create_attachment_dock ()
 
void close_attachment_dock ()
 
void restore_settings ()
 
void recover_editor_unsaved_pages_from_cache ()
 
void save_settings ()
 
int get_restart_needed () const
 return true, if restart is needed
 

Private Attributes

TextEditedit_ {}
 Tabwidget holding the edit-windows.
 
QMenu * file_menu_ {}
 Submenu for file-operations.
 
QMenu * edit_menu_ {}
 Submenu for text-operations.
 
QMenu * crypt_menu_ {}
 Submenu for crypt-operations.
 
QMenu * gpg_menu_ {}
 Submenu for help-operations.
 
QMenu * help_menu_ {}
 Submenu for help-operations.
 
QMenu * key_menu_ {}
 Submenu for key-operations.
 
QMenu * view_menu_ {}
 Submenu for view operations.
 
QMenu * import_key_menu_ {}
 Submenu for import operations.
 
QMenu * steganography_menu_ {}
 Submenu for steganography operations.
 
QToolBar * crypt_tool_bar_ {}
 Toolbar holding crypt actions.
 
QToolBar * file_tool_bar_ {}
 Toolbar holding file actions.
 
QToolBar * edit_tool_bar_ {}
 Toolbar holding edit actions.
 
QToolBar * special_edit_tool_bar_ {}
 Toolbar holding special edit actions.
 
QToolBar * key_tool_bar_ {}
 Toolbar holding key operations.
 
QToolButton * import_button_ {}
 Tool button for import dropdown menu in toolbar.
 
QDockWidget * key_list_dock_ {}
 Encrypt Dock.
 
QDockWidget * attachment_dock_ {}
 Attachment Dock.
 
QDockWidget * info_board_dock_ {}
 
QAction * new_tab_act_ {}
 Action to create new tab.
 
QAction * switch_tab_up_act_ {}
 Action to switch tab up.
 
QAction * switch_tab_down_act_ {}
 Action to switch tab down.
 
QAction * open_act_ {}
 Action to open file.
 
QAction * browser_act_ {}
 Action to open file browser.
 
QAction * save_act_ {}
 Action to save file.
 
QAction * save_as_act_ {}
 Action to save file as.
 
QAction * print_act_ {}
 Action to print.
 
QAction * close_tab_act_ {}
 Action to print.
 
QAction * quit_act_ {}
 Action to quit application.
 
QAction * encrypt_act_ {}
 Action to encrypt text.
 
QAction * encrypt_sign_act_ {}
 Action to encrypt and sign text.
 
QAction * decrypt_verify_act_ {}
 Action to encrypt and sign text.
 
QAction * decrypt_act_ {}
 Action to decrypt text.
 
QAction * sign_act_ {}
 Action to sign text.
 
QAction * verify_act_ {}
 Action to verify text.
 
QAction * import_key_from_edit_act_ {}
 Action to import key from edit.
 
QAction * clean_double_line_breaks_act_ {}
 
QAction * gnupg_controller_open_act_ {}
 
QAction * clean_gpg_password_cache_act_ {}
 
QAction * reload_components_act_ {}
 
QAction * restart_components_act_ {}
 
QAction * append_selected_keys_act_ {}
 Action to append selected keys to edit.
 
QAction * append_key_fingerprint_to_editor_act_ {}
 
QAction * append_key_create_date_to_editor_act_ {}
 
QAction * append_key_expire_date_to_editor_act_ {}
 
QAction * copy_mail_address_to_clipboard_act_ {}
 
QAction * copy_key_id_to_clipboard_act_ {}
 
QAction * copy_key_default_uid_to_clipboard_act_ {}
 
QAction * add_key_2_favourtie_act_ {}
 
QAction * remove_key_from_favourtie_act_ {}
 
QAction * set_owner_trust_of_key_act_ {}
 
QAction * open_key_management_act_ {}
 Action to open key management.
 
QAction * copy_act_ {}
 Action to copy text.
 
QAction * quote_act_ {}
 Action to quote text.
 
QAction * cut_act_ {}
 Action to cut text.
 
QAction * paste_act_ {}
 Action to paste text.
 
QAction * select_all_act_ {}
 Action to select whole text.
 
QAction * find_act_ {}
 Action to find text.
 
QAction * undo_act_ {}
 Action to undo last action.
 
QAction * redo_act_ {}
 Action to redo last action.
 
QAction * zoom_in_act_ {}
 Action to zoom in.
 
QAction * zoom_out_act_ {}
 Action to zoom out.
 
QAction * about_act_ {}
 Action to open about dialog.
 
QAction * check_update_act_ {}
 Action to open about dialog.
 
QAction * translate_act_ {}
 Action to open about dialog.
 
QAction * gnupg_act_ {}
 Action to open about dialog.
 
QAction * open_settings_act_ {}
 Action to open settings dialog.
 
QAction * show_key_details_act_ {}
 Action to open key-details dialog.
 
QAction * start_wizard_act_ {}
 Action to open the wizard.
 
QAction * cut_pgp_header_act_ {}
 Action for cutting the PGP header.
 
QAction * add_pgp_header_act_ {}
 Action for adding the PGP header.
 
QAction * import_key_from_file_act_ {}
 
QAction * import_key_from_clipboard_act_ {}
 
QAction * import_key_from_key_server_act_ {}
 
QLabel * status_bar_icon_ {}
 
KeyListm_key_list_ {}
 
InfoBoardWidgetinfo_board_ {}
 
bool attachment_dock_created_ {}
 
int restart_needed_ {0}
 
bool prohibit_update_checking_ = false
 

Additional Inherited Members

- Protected Attributes inherited from GpgFrontend::UI::GeneralMainWindow
QSize icon_size_ {}
 
int font_size_ {}
 
Qt::ToolButtonStyle icon_style_
 

Member Function Documentation

◆ close_attachment_dock()

void GpgFrontend::UI::MainWindow::close_attachment_dock ( )
private

close attachment-dockwindow.

◆ closeEvent()

void GpgFrontend::UI::MainWindow::closeEvent ( QCloseEvent *  event)
overrideprotected

Close event shows a save dialog, if there are unsaved documents on exit.

Parameters
event

◆ create_actions()

void GpgFrontend::UI::MainWindow::create_actions ( )
private

Create actions for the main-menu and the context-menu of the keylist.

References about_act_, add_pgp_header_act_, append_selected_keys_act_, browser_act_, check_update_act_, clean_double_line_breaks_act_, close_tab_act_, copy_act_, copy_mail_address_to_clipboard_act_, cut_act_, cut_pgp_header_act_, decrypt_act_, decrypt_verify_act_, edit_, encrypt_act_, encrypt_sign_act_, find_act_, GpgFrontend::UI::CommonUtils::GetInstance(), GpgFrontend::SingletonFunctionObject< GlobalSettingStation >::GetInstance(), GpgFrontend::SingletonFunctionObject< GpgAdvancedOperator >::GetInstance(), gnupg_act_, import_key_from_edit_act_, GpgFrontend::GlobalSettingStation::LookupSettings(), new_tab_act_, open_act_, open_key_management_act_, open_settings_act_, paste_act_, print_act_, quit_act_, quote_act_, redo_act_, save_act_, save_as_act_, select_all_act_, show_key_details_act_, sign_act_, slot_add_pgp_header(), slot_append_selected_keys(), slot_clean_double_line_breaks(), slot_copy_default_uid_to_clipboard(), slot_copy_key_id_to_clipboard(), slot_copy_mail_address_to_clipboard(), slot_cut_pgp_header(), slot_decrypt(), slot_decrypt_verify(), slot_encrypt(), slot_encrypt_sign(), slot_find(), slot_import_key_from_edit(), slot_open_file_tab(), slot_open_key_management(), slot_open_settings_dialog(), slot_show_key_details(), slot_sign(), slot_start_wizard(), slot_verify(), GpgFrontend::UI::TextEdit::SlotCloseTab(), GpgFrontend::UI::TextEdit::SlotCopy(), GpgFrontend::UI::TextEdit::SlotCut(), GpgFrontend::UI::CommonUtils::SlotImportKeyFromClipboard(), GpgFrontend::UI::CommonUtils::SlotImportKeyFromFile(), GpgFrontend::UI::CommonUtils::SlotImportKeyFromKeyServer(), GpgFrontend::UI::TextEdit::SlotNewTab(), GpgFrontend::UI::TextEdit::SlotOpen(), GpgFrontend::UI::TextEdit::SlotPaste(), GpgFrontend::UI::TextEdit::SlotPrint(), GpgFrontend::UI::TextEdit::SlotQuote(), GpgFrontend::UI::TextEdit::SlotRedo(), GpgFrontend::UI::TextEdit::SlotSave(), GpgFrontend::UI::TextEdit::SlotSaveAs(), GpgFrontend::UI::TextEdit::SlotSelectAll(), GpgFrontend::UI::TextEdit::SlotSwitchTabDown(), GpgFrontend::UI::TextEdit::SlotSwitchTabUp(), GpgFrontend::UI::TextEdit::SlotUndo(), start_wizard_act_, switch_tab_down_act_, switch_tab_up_act_, translate_act_, undo_act_, verify_act_, zoom_in_act_, and zoom_out_act_.

◆ create_attachment_dock()

void GpgFrontend::UI::MainWindow::create_attachment_dock ( )
private

Create attachment dock window.

◆ create_dock_windows()

◆ create_menus()

◆ create_status_bar()

void GpgFrontend::UI::MainWindow::create_status_bar ( )
private

Create statusbar of mainwindow.

◆ create_tool_bars()

◆ Init()

void GpgFrontend::UI::MainWindow::Init ( )
noexcept

◆ refresh_keys_from_key_server

void GpgFrontend::UI::MainWindow::refresh_keys_from_key_server ( )
privateslot

Refresh key information of selected keys from default keyserver

References GpgFrontend::UI::KeyList::GetSelected().

◆ restore_settings()

void GpgFrontend::UI::MainWindow::restore_settings ( )
private

Load settings from ini-file.

◆ save_settings()

void GpgFrontend::UI::MainWindow::save_settings ( )
private

Save settings to ini-file.

Referenced by slot_open_settings_dialog().

◆ SetCryptoMenuStatus()

void GpgFrontend::UI::MainWindow::SetCryptoMenuStatus ( CryptoMenu::OperationType  type)

refresh and enable specify crypto-menu actions.

References decrypt_act_, decrypt_verify_act_, encrypt_act_, encrypt_sign_act_, sign_act_, and verify_act_.

◆ slot_add_pgp_header

◆ slot_append_selected_keys

◆ slot_clean_double_line_breaks

void GpgFrontend::UI::MainWindow::slot_clean_double_line_breaks ( )
privateslot

◆ slot_copy_default_uid_to_clipboard

void GpgFrontend::UI::MainWindow::slot_copy_default_uid_to_clipboard ( )
privateslot

Copy the mailaddress of selected key to clipboard. Method for keylists contextmenu.

References GpgFrontend::SingletonFunctionObject< GpgKeyGetter >::GetInstance(), GpgFrontend::GpgKeyGetter::GetKey(), and GpgFrontend::UI::KeyList::GetSelected().

Referenced by create_actions().

◆ slot_copy_key_id_to_clipboard

void GpgFrontend::UI::MainWindow::slot_copy_key_id_to_clipboard ( )
privateslot

Copy the mailaddress of selected key to clipboard. Method for keylists contextmenu.

References GpgFrontend::SingletonFunctionObject< GpgKeyGetter >::GetInstance(), GpgFrontend::GpgKeyGetter::GetKey(), and GpgFrontend::UI::KeyList::GetSelected().

Referenced by create_actions().

◆ slot_copy_mail_address_to_clipboard

void GpgFrontend::UI::MainWindow::slot_copy_mail_address_to_clipboard ( )
privateslot

Copy the mailaddress of selected key to clipboard. Method for keylists contextmenu.

References GpgFrontend::SingletonFunctionObject< GpgKeyGetter >::GetInstance(), GpgFrontend::GpgKeyGetter::GetKey(), and GpgFrontend::UI::KeyList::GetSelected().

Referenced by create_actions().

◆ slot_cut_pgp_header

◆ slot_decrypt

◆ slot_decrypt_verify

◆ slot_disable_tab_actions

void GpgFrontend::UI::MainWindow::slot_disable_tab_actions ( int  number)
privateslot

◆ slot_encrypt

◆ slot_encrypt_sign

◆ slot_find

◆ slot_import_key_from_edit

◆ slot_open_file_tab

void GpgFrontend::UI::MainWindow::slot_open_file_tab ( )
privateslot

Open File Opera Tab

References edit_, and GpgFrontend::UI::TextEdit::SlotNewFileTab().

Referenced by create_actions().

◆ slot_open_key_management

void GpgFrontend::UI::MainWindow::slot_open_key_management ( )
privateslot

Open key management dialog.

Referenced by create_actions().

◆ slot_open_settings_dialog

void GpgFrontend::UI::MainWindow::slot_open_settings_dialog ( )
privateslot

◆ slot_show_key_details

void GpgFrontend::UI::MainWindow::slot_show_key_details ( )
privateslot

◆ slot_sign

◆ slot_start_wizard

void GpgFrontend::UI::MainWindow::slot_start_wizard ( )
privateslot

start the wizard

Referenced by create_actions().

◆ slot_verify

◆ slot_version_upgrade

◆ SlotFileDecrypt

◆ SlotFileDecryptVerify

◆ SlotFileEncrypt

◆ SlotFileEncryptSign

◆ SlotFileSign

◆ SlotFileVerify

◆ SlotOpenFile

void GpgFrontend::UI::MainWindow::SlotOpenFile ( QString &  path)
slot

Open a new tab for path

References edit_, and GpgFrontend::UI::TextEdit::SlotOpenFile().

◆ SlotSetRestartNeeded

void GpgFrontend::UI::MainWindow::SlotSetRestartNeeded ( int  mode)
slot

get value of member restartNeeded to needed.

Parameters
neededtrue, if application has to be restarted

Referenced by GpgFrontend::UI::SettingsDialog::SettingsDialog().

◆ upload_key_to_server

void GpgFrontend::UI::MainWindow::upload_key_to_server ( )
privateslot

upload the selected key to the keyserver

References GpgFrontend::UI::KeyList::GetSelected().

Member Data Documentation

◆ clean_double_line_breaks_act_

QAction* GpgFrontend::UI::MainWindow::clean_double_line_breaks_act_ {}
private

Action to remove double line breaks

Referenced by create_actions(), create_menus(), create_tool_bars(), and slot_disable_tab_actions().

◆ copy_mail_address_to_clipboard_act_

QAction* GpgFrontend::UI::MainWindow::copy_mail_address_to_clipboard_act_ {}
private

Action to copy mail to clipboard

Referenced by create_actions().


The documentation for this class was generated from the following files: