kmail Library API Documentation

warningconfiguration.cpp

00001 #include <kdialog.h> 00002 #include <klocale.h> 00003 /**************************************************************************** 00004 ** Form implementation generated from reading ui file './warningconfiguration.ui' 00005 ** 00006 ** Created: Fri Oct 1 15:06:19 2004 00007 ** by: The User Interface Compiler ($Id: qt/main.cpp 3.3.3 edited Nov 24 2003 $) 00008 ** 00009 ** WARNING! All changes made in this file will be lost! 00010 ****************************************************************************/ 00011 00012 #include "warningconfiguration.h" 00013 00014 #include <qvariant.h> 00015 #include <qcheckbox.h> 00016 #include <qgroupbox.h> 00017 #include <qlabel.h> 00018 #include <qspinbox.h> 00019 #include <qpushbutton.h> 00020 #include <qlayout.h> 00021 #include <qtooltip.h> 00022 #include <qwhatsthis.h> 00023 00024 /* 00025 * Constructs a WarningConfiguration as a child of 'parent', with the 00026 * name 'name' and widget flags set to 'f'. 00027 */ 00028 WarningConfiguration::WarningConfiguration( QWidget* parent, const char* name, WFlags fl ) 00029 : QWidget( parent, name, fl ) 00030 { 00031 if ( !name ) 00032 setName( "WarningConfiguration" ); 00033 WarningConfigurationLayout = new QVBoxLayout( this, 11, 6, "WarningConfigurationLayout"); 00034 00035 mWarnUnsigned = new QCheckBox( this, "mWarnUnsigned" ); 00036 mWarnUnsigned->setChecked( TRUE ); 00037 WarningConfigurationLayout->addWidget( mWarnUnsigned ); 00038 00039 warnUnencryptedCB = new QCheckBox( this, "warnUnencryptedCB" ); 00040 warnUnencryptedCB->setChecked( TRUE ); 00041 WarningConfigurationLayout->addWidget( warnUnencryptedCB ); 00042 00043 warnReceiverNotInCertificateCB = new QCheckBox( this, "warnReceiverNotInCertificateCB" ); 00044 warnReceiverNotInCertificateCB->setChecked( TRUE ); 00045 WarningConfigurationLayout->addWidget( warnReceiverNotInCertificateCB ); 00046 00047 warnGroupBox = new QGroupBox( this, "warnGroupBox" ); 00048 warnGroupBox->setCheckable( TRUE ); 00049 warnGroupBox->setColumnLayout(0, Qt::Vertical ); 00050 warnGroupBox->layout()->setSpacing( 6 ); 00051 warnGroupBox->layout()->setMargin( 11 ); 00052 warnGroupBoxLayout = new QGridLayout( warnGroupBox->layout() ); 00053 warnGroupBoxLayout->setAlignment( Qt::AlignTop ); 00054 00055 textLabel2 = new QLabel( warnGroupBox, "textLabel2" ); 00056 textLabel2->setAlignment( int( QLabel::AlignCenter ) ); 00057 00058 warnGroupBoxLayout->addWidget( textLabel2, 0, 1 ); 00059 00060 textLabel2_2 = new QLabel( warnGroupBox, "textLabel2_2" ); 00061 textLabel2_2->setAlignment( int( QLabel::AlignCenter ) ); 00062 00063 warnGroupBoxLayout->addWidget( textLabel2_2, 0, 2 ); 00064 00065 mWarnSignKeyExpiresSB = new QSpinBox( warnGroupBox, "mWarnSignKeyExpiresSB" ); 00066 mWarnSignKeyExpiresSB->setMaxValue( 999 ); 00067 mWarnSignKeyExpiresSB->setMinValue( 1 ); 00068 mWarnSignKeyExpiresSB->setValue( 14 ); 00069 00070 warnGroupBoxLayout->addWidget( mWarnSignKeyExpiresSB, 1, 1 ); 00071 00072 mWarnEncrKeyExpiresSB = new QSpinBox( warnGroupBox, "mWarnEncrKeyExpiresSB" ); 00073 mWarnEncrKeyExpiresSB->setMaxValue( 999 ); 00074 mWarnEncrKeyExpiresSB->setMinValue( 1 ); 00075 mWarnEncrKeyExpiresSB->setValue( 14 ); 00076 00077 warnGroupBoxLayout->addWidget( mWarnEncrKeyExpiresSB, 1, 2 ); 00078 00079 mWarnEncrChainCertExpiresSB = new QSpinBox( warnGroupBox, "mWarnEncrChainCertExpiresSB" ); 00080 mWarnEncrChainCertExpiresSB->setMaxValue( 999 ); 00081 mWarnEncrChainCertExpiresSB->setMinValue( 1 ); 00082 mWarnEncrChainCertExpiresSB->setValue( 14 ); 00083 00084 warnGroupBoxLayout->addWidget( mWarnEncrChainCertExpiresSB, 2, 2 ); 00085 00086 mWarnSignChainCertExpiresSB = new QSpinBox( warnGroupBox, "mWarnSignChainCertExpiresSB" ); 00087 mWarnSignChainCertExpiresSB->setMaxValue( 999 ); 00088 mWarnSignChainCertExpiresSB->setMinValue( 1 ); 00089 mWarnSignChainCertExpiresSB->setValue( 14 ); 00090 00091 warnGroupBoxLayout->addWidget( mWarnSignChainCertExpiresSB, 2, 1 ); 00092 00093 mWarnSignRootCertExpiresSB = new QSpinBox( warnGroupBox, "mWarnSignRootCertExpiresSB" ); 00094 mWarnSignRootCertExpiresSB->setMaxValue( 999 ); 00095 mWarnSignRootCertExpiresSB->setMinValue( 1 ); 00096 mWarnSignRootCertExpiresSB->setValue( 14 ); 00097 00098 warnGroupBoxLayout->addWidget( mWarnSignRootCertExpiresSB, 3, 1 ); 00099 00100 mWarnEncrRootCertExpiresSB = new QSpinBox( warnGroupBox, "mWarnEncrRootCertExpiresSB" ); 00101 mWarnEncrRootCertExpiresSB->setMaxValue( 999 ); 00102 mWarnEncrRootCertExpiresSB->setMinValue( 1 ); 00103 mWarnEncrRootCertExpiresSB->setValue( 14 ); 00104 00105 warnGroupBoxLayout->addWidget( mWarnEncrRootCertExpiresSB, 3, 2 ); 00106 00107 textLabel1_2_2 = new QLabel( warnGroupBox, "textLabel1_2_2" ); 00108 00109 warnGroupBoxLayout->addWidget( textLabel1_2_2, 3, 0 ); 00110 00111 textLabel1_2 = new QLabel( warnGroupBox, "textLabel1_2" ); 00112 00113 warnGroupBoxLayout->addWidget( textLabel1_2, 2, 0 ); 00114 00115 textLabel1 = new QLabel( warnGroupBox, "textLabel1" ); 00116 00117 warnGroupBoxLayout->addWidget( textLabel1, 1, 0 ); 00118 spacer5 = new QSpacerItem( 40, 20, QSizePolicy::Expanding, QSizePolicy::Minimum ); 00119 warnGroupBoxLayout->addItem( spacer5, 2, 3 ); 00120 WarningConfigurationLayout->addWidget( warnGroupBox ); 00121 spacer23 = new QSpacerItem( 20, 90, QSizePolicy::Minimum, QSizePolicy::Expanding ); 00122 WarningConfigurationLayout->addItem( spacer23 ); 00123 00124 layout1 = new QHBoxLayout( 0, 0, 6, "layout1"); 00125 spacer4 = new QSpacerItem( 40, 20, QSizePolicy::Expanding, QSizePolicy::Minimum ); 00126 layout1->addItem( spacer4 ); 00127 00128 enableAllWarningsPB = new QPushButton( this, "enableAllWarningsPB" ); 00129 layout1->addWidget( enableAllWarningsPB ); 00130 WarningConfigurationLayout->addLayout( layout1 ); 00131 languageChange(); 00132 resize( QSize(552, 325).expandedTo(minimumSizeHint()) ); 00133 clearWState( WState_Polished ); 00134 00135 // tab order 00136 setTabOrder( mWarnUnsigned, warnUnencryptedCB ); 00137 setTabOrder( warnUnencryptedCB, warnReceiverNotInCertificateCB ); 00138 setTabOrder( warnReceiverNotInCertificateCB, mWarnSignKeyExpiresSB ); 00139 setTabOrder( mWarnSignKeyExpiresSB, mWarnSignChainCertExpiresSB ); 00140 setTabOrder( mWarnSignChainCertExpiresSB, mWarnSignRootCertExpiresSB ); 00141 setTabOrder( mWarnSignRootCertExpiresSB, mWarnEncrKeyExpiresSB ); 00142 setTabOrder( mWarnEncrKeyExpiresSB, mWarnEncrChainCertExpiresSB ); 00143 setTabOrder( mWarnEncrChainCertExpiresSB, mWarnEncrRootCertExpiresSB ); 00144 setTabOrder( mWarnEncrRootCertExpiresSB, enableAllWarningsPB ); 00145 00146 // buddies 00147 textLabel1_2_2->setBuddy( mWarnSignRootCertExpiresSB ); 00148 textLabel1_2->setBuddy( mWarnSignChainCertExpiresSB ); 00149 textLabel1->setBuddy( mWarnSignKeyExpiresSB ); 00150 } 00151 00152 /* 00153 * Destroys the object and frees any allocated resources 00154 */ 00155 WarningConfiguration::~WarningConfiguration() 00156 { 00157 // no need to delete child widgets, Qt does it all for us 00158 } 00159 00160 /* 00161 * Sets the strings of the subwidgets using the current 00162 * language. 00163 */ 00164 void WarningConfiguration::languageChange() 00165 { 00166 mWarnUnsigned->setText( tr2i18n( "Warn when trying to send &unsigned messages" ) ); 00167 QToolTip::add( mWarnUnsigned, tr2i18n( "Check to be warned when sending unsigned messages." ) ); 00168 QWhatsThis::add( mWarnUnsigned, tr2i18n( "<qt>\n" 00169 "<h1>Warn When Trying To Send Unsigned Messages</h1>\n" 00170 "If this box is checked, you will be warned when you try to send parts of or the whole message unsigned.\n" 00171 "<p>\n" 00172 "It is recommended to leave this option turned on for maximum integrity.\n" 00173 "</qt>" ) ); 00174 warnUnencryptedCB->setText( tr2i18n( "&Warn when trying to send unencrypted messages" ) ); 00175 QToolTip::add( warnUnencryptedCB, tr2i18n( "Check to be warned when sending unencrypted messages." ) ); 00176 QWhatsThis::add( warnUnencryptedCB, tr2i18n( "<qt>\n" 00177 "<h1>Warn When Trying To Send Unencrypted Messages</h1>\n" 00178 "If this box is checked, you will be warned when you try to send parts of or the whole message unencrypted.\n" 00179 "<p>\n" 00180 "It is recommended to leave this option turned on for maximum integrity.\n" 00181 "</qt>" ) ); 00182 warnReceiverNotInCertificateCB->setText( tr2i18n( "Warn if &receiver's email address is not in certificate" ) ); 00183 QToolTip::add( warnReceiverNotInCertificateCB, tr2i18n( "Check to be warned if the address is not in the certificate" ) ); 00184 QWhatsThis::add( warnReceiverNotInCertificateCB, tr2i18n( "<qt>\n" 00185 "<h1>Warn If Receiver's Email Address Is Not In Certificate</h1>\n" 00186 "If this option is checked, a warning is issued if the email address of the receiver is not contained in the certificate used for encrypting.\n" 00187 "<p>\n" 00188 "It is recommended to leave this option turned on for maximum security.\n" 00189 "</qt>" ) ); 00190 warnGroupBox->setTitle( tr2i18n( "Warn if certificates/keys expire soon (configure thresholds below)" ) ); 00191 textLabel2->setText( tr2i18n( "For signing" ) ); 00192 textLabel2_2->setText( tr2i18n( "For encryption" ) ); 00193 mWarnSignKeyExpiresSB->setSuffix( tr2i18n( " days" ) ); 00194 QToolTip::add( mWarnSignKeyExpiresSB, tr2i18n( "Select the number of days here" ) ); 00195 QWhatsThis::add( mWarnSignKeyExpiresSB, tr2i18n( "<qt>\n" 00196 "<h1>Warn If Signature Certificate Expires</h1>\n" 00197 "Select the minimum number of days the signature certificate should be valid without issuing a warning.\n" 00198 "<p>\n" 00199 "The recommended SPHINX setting is 14 days.\n" 00200 "</qt>" ) ); 00201 mWarnEncrKeyExpiresSB->setSuffix( tr2i18n( " days" ) ); 00202 QToolTip::add( mWarnEncrKeyExpiresSB, tr2i18n( "Select the number of days here" ) ); 00203 QWhatsThis::add( mWarnEncrKeyExpiresSB, tr2i18n( "<qt>\n" 00204 "<h1>Warn If Encryption Certificate Expires</h1>\n" 00205 "Select the minimum number of days the encryption certificate should be valid without issuing a warning.\n" 00206 "<p>\n" 00207 "The recommended SPHINX setting is 14 days.\n" 00208 "</qt>" ) ); 00209 mWarnEncrChainCertExpiresSB->setSuffix( tr2i18n( " days" ) ); 00210 QToolTip::add( mWarnEncrChainCertExpiresSB, tr2i18n( "Select the number of days here" ) ); 00211 QWhatsThis::add( mWarnEncrChainCertExpiresSB, tr2i18n( "<qt>\n" 00212 "<h1>Warn If A Certificate In The Chain Expires</h1>\n" 00213 "Select the minimum number of days all certificates in the chain should be valid without issuing a warning.\n" 00214 "<p>\n" 00215 "The recommended SPHINX setting is 14 days.\n" 00216 "</qt>" ) ); 00217 mWarnSignChainCertExpiresSB->setSuffix( tr2i18n( " days" ) ); 00218 QToolTip::add( mWarnSignChainCertExpiresSB, tr2i18n( "Select the number of days here" ) ); 00219 QWhatsThis::add( mWarnSignChainCertExpiresSB, tr2i18n( "<qt>\n" 00220 "<h1>Warn If CA Certificate Expires</h1>\n" 00221 "Select the minimum number of days the CA certificate should be valid without issuing a warning.\n" 00222 "<p>\n" 00223 "The recommended SPHINX setting is 14 days.\n" 00224 "</qt>" ) ); 00225 mWarnSignRootCertExpiresSB->setSuffix( tr2i18n( " days" ) ); 00226 QToolTip::add( mWarnSignRootCertExpiresSB, tr2i18n( "Select the number of days here" ) ); 00227 QWhatsThis::add( mWarnSignRootCertExpiresSB, tr2i18n( "<qt>\n" 00228 "<h1>Warn If Root Certificate Expires</h1>\n" 00229 "Select the minimum number of days the root certificate should be valid without issuing a warning.\n" 00230 "<p>\n" 00231 "The recommended SPHINX setting is 14 days.\n" 00232 "</qt>" ) ); 00233 mWarnEncrRootCertExpiresSB->setSuffix( tr2i18n( " days" ) ); 00234 QToolTip::add( mWarnEncrRootCertExpiresSB, tr2i18n( "Select the number of days here" ) ); 00235 QWhatsThis::add( mWarnEncrRootCertExpiresSB, tr2i18n( "<qt>\n" 00236 "<h1>Warn If Root Certificate Expires</h1>\n" 00237 "Select the minimum number of days the root certificate should be valid without issuing a warning.\n" 00238 "<p>\n" 00239 "The recommended SPHINX setting is 14 days.\n" 00240 "</qt>" ) ); 00241 textLabel1_2_2->setText( tr2i18n( "For root certificates:" ) ); 00242 textLabel1_2->setText( tr2i18n( "For intermediate CA certificates:" ) ); 00243 textLabel1->setText( tr2i18n( "For end-user certificates/keys:" ) ); 00244 enableAllWarningsPB->setText( tr2i18n( "Re-Enable All \"Don't Ask Again\" Warnings" ) ); 00245 } 00246 00247 #include "warningconfiguration.moc"
KDE Logo
This file is part of the documentation for kmail Library Version 3.3.0.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Fri Oct 1 15:19:25 2004 by doxygen 1.3.7 written by Dimitri van Heesch, © 1997-2003