GpgFrontend Project A Free, Powerful, Easy-to-Use, Compact, Cross-Platform, and Installation-Free OpenPGP(pgp) Crypto Tool.

Signals | Public Member Functions | Private Slots | Private Member Functions | Private Attributes | List of all members
GpgFrontend::UI::SubkeyGenerateDialog Class Reference
Inheritance diagram for GpgFrontend::UI::SubkeyGenerateDialog:
Collaboration diagram for GpgFrontend::UI::SubkeyGenerateDialog:

## Signals
void | SignalSubKeyGenerated ()

## Public Member Functions
| SubkeyGenerateDialog (const KeyId &key_id, QWidget *parent)
| Construct a new Subkey Generate Dialog object. More...
Public Member Functions inherited from GpgFrontend::UI::GeneralDialog
| GeneralDialog (std::string name, QWidget *parent=nullptr)

## Private Slots
void | slot_expire_box_changed ()
void | slot_key_gen_accept ()
void | slot_encryption_box_changed (int state)
void | slot_signing_box_changed (int state)
void | slot_certification_box_changed (int state)
void | slot_authentication_box_changed (int state)
void | slot_activated_key_type (int index)

## Private Member Functions
QGroupBox * | create_key_usage_group_box ()
| Create a key usage group box object. More...
QGroupBox * | create_basic_info_group_box ()
| Create a basic info group box object. More...
void | set_signal_slot ()
| Set the signal slot object.
void | refresh_widgets_state ()

## Private Attributes
GpgKey | key_
std::unique_ptr< GenKeyInfo > | gen_key_info_
QGroupBox * | key_usage_group_box_ {}
QDialogButtonBox * | button_box_
| Box for standard buttons.
QLabel * | error_label_ {}
| Label containing error message.
QSpinBox * | key_size_spin_box_ {}
| Spinbox for the keys size (in bit)
QComboBox * | key_type_combo_box_ {}
| Combobox for Key tpe.
QDateTimeEdit * | date_edit_ {}
| Date edit for expiration date.
QCheckBox * | expire_check_box_ {}
| Checkbox, if key should expire.
QCheckBox * | no_pass_phrase_check_box_ {}
| Checkbox, if key should expire.
QLineEdit * | passphrase_edit_ {}
std::vector< QCheckBox * > | key_usage_check_boxes_
| ENCR, SIGN, CERT, AUTH.
QDateTime | max_date_time_
bool | use_pinentry_ = false

## Additional Inherited Members
Protected Member Functions inherited from GpgFrontend::UI::GeneralDialog
void | setPosCenterOfScreen ()
void | movePosition2CenterOfParent ()

## Constructor & Destructor Documentation

## ◆ SubkeyGenerateDialog()

GpgFrontend::UI::SubkeyGenerateDialog::SubkeyGenerateDialog | ( | const KeyId & | key_id,
|  | QWidget * | parent
| ) |  |
| explicit

Construct a new Subkey Generate Dialog object.

Parameters

  key_id |
  parent |

References button_box_, create_basic_info_group_box(), create_key_usage_group_box(), error_label_, GpgFrontend::UI::SignalStation::GetInstance(), GpgFrontend::SingletonFunctionObject< GlobalSettingStation >::GetInstance(), GpgFrontend::GlobalSettingStation::LookupSettings(), refresh_widgets_state(), and set_signal_slot().

## Member Function Documentation

## ◆ create_basic_info_group_box()

QGroupBox * GpgFrontend::UI::SubkeyGenerateDialog::create_basic_info_group_box | ( |  | ) |
| private

Create a basic info group box object.

Returns
  QGroupBox*

References date_edit_, error_label_, expire_check_box_, GpgFrontend::GenKeyInfo::GetSupportedSubkeyAlgo(), key_size_spin_box_, key_type_combo_box_, and no_pass_phrase_check_box_.

Referenced by SubkeyGenerateDialog().

## ◆ create_key_usage_group_box()

QGroupBox * GpgFrontend::UI::SubkeyGenerateDialog::create_key_usage_group_box | ( |  | ) |
| private

Create a key usage group box object.

Returns
  QGroupBox*

References key_usage_check_boxes_.

Referenced by SubkeyGenerateDialog().

## ◆ refresh_widgets_state()

void GpgFrontend::UI::SubkeyGenerateDialog::refresh_widgets_state | ( |  | ) |
| private

Refresh widgets state by GenKeyInfo

References key_size_spin_box_, and key_usage_check_boxes_.

Referenced by slot_activated_key_type(), and SubkeyGenerateDialog().

## ◆ slot_activated_key_type

void GpgFrontend::UI::SubkeyGenerateDialog::slot_activated_key_type | ( | int | index | ) |
| private slot

Parameters

  index |

References refresh_widgets_state().

Referenced by set_signal_slot().

## ◆ slot_authentication_box_changed

void GpgFrontend::UI::SubkeyGenerateDialog::slot_authentication_box_changed | ( | int | state | ) |
| private slot

Parameters

  state |

Referenced by set_signal_slot().

## ◆ slot_certification_box_changed

void GpgFrontend::UI::SubkeyGenerateDialog::slot_certification_box_changed | ( | int | state | ) |
| private slot

Parameters

  state |

Referenced by set_signal_slot().

## ◆ slot_encryption_box_changed

void GpgFrontend::UI::SubkeyGenerateDialog::slot_encryption_box_changed | ( | int | state | ) |
| private slot

Parameters

  state |

Referenced by set_signal_slot().

## ◆ slot_expire_box_changed

void GpgFrontend::UI::SubkeyGenerateDialog::slot_expire_box_changed | ( |  | ) |
| private slot

when expire box was checked/unchecked, enable/disable the expiration date box

References date_edit_, and expire_check_box_.

Referenced by set_signal_slot().

## ◆ slot_key_gen_accept

void GpgFrontend::UI::SubkeyGenerateDialog::slot_key_gen_accept | ( |  | ) |
| private slot

check all line edits for false entries. Show error, when there is one, otherwise generate the key

primary keys should have a reasonable expiration date (no more than 2 years in the future)

create error message

References GpgFrontend::check_gpg_error_2_err_code(), date_edit_, error_label_, expire_check_box_, GpgFrontend::GpgKeyOpera::GenerateSubkey(), GpgFrontend::CoreCommonUtil::GetInstance(), GpgFrontend::SingletonFunctionObject< GpgKeyOpera >::GetInstance(), key_size_spin_box_, GpgFrontend::CoreCommonUtil::ResetTempCacheValue(), and GpgFrontend::CoreCommonUtil::SetTempCacheValue().

Referenced by set_signal_slot().

## ◆ slot_signing_box_changed

void GpgFrontend::UI::SubkeyGenerateDialog::slot_signing_box_changed | ( | int | state | ) |
| private slot

Parameters

  state |

Referenced by set_signal_slot().

## Member Data Documentation

## ◆ gen_key_info_

std::unique_ptr<GenKeyInfo> GpgFrontend::UI::SubkeyGenerateDialog::gen_key_info_
| private

Initial value:
=
std::make_unique<GenKeyInfo>(true)

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

- src/ui/dialog/key_generate/SubkeyGenerateDialog.h
- src/ui/dialog/key_generate/SubkeyGenerateDialog.cpp