kleopatra
formatting.cpp
Go to the documentation of this file.
64 QString Formatting::prettyName( int proto, const char * id, const char * name_, const char * comment_ ) {
87 QString Formatting::prettyNameAndEMail( int proto, const char * id, const char * name_, const char * email_, const char * comment_ ) {
88 return prettyNameAndEMail( proto, QString::fromUtf8( id ), QString::fromUtf8( name_ ), prettyEMail( email_, id ), QString::fromUtf8( comment_ ) );
91 QString Formatting::prettyNameAndEMail( int proto, const QString & id, const QString & name, const QString & email, const QString & comment ) {
144 return prettyNameAndEMail( uid.parent().protocol(), uid.id(), uid.name(), uid.email(), uid.comment() );
208 return i18n( "<tr><th>%1:</th><td>%2</td></tr>", protect_whitespace( field ), Qt::escape( arg ) );
217 return i18n( "%1-bit %2 (secret key available)", subkey.length(), QLatin1String(subkey.publicKeyAlgorithmAsString()) );
219 return i18n( "%1-bit %2", subkey.length(), QLatin1String(subkey.publicKeyAlgorithmAsString()) );
246 return QLatin1String( "<font color=\"red\">" ) + Qt::escape( txt ) + QLatin1String( "</font>" );
287 for ( std::vector<UserID>::const_iterator it = uids.begin() + 1, end = uids.end() ; it != end ; ++it )
295 : i18n( "from %1 through %2", time_t2string( subkey.creationTime() ), time_t2string( subkey.expirationTime() ) ) );
313 result += format_row( i18n("Stored"), i18nc("stored...","on SmartCard with serial no. %1", QString::fromUtf8( card ) ) );
494 return QString::fromLatin1( "<a href=\"key:%1\">%2</a>" ).arg( QLatin1String(key.primaryFingerprint()), Formatting::prettyName( key ) );
502 return i18nc( "name, email, key id", "%1 %2 (%3)", name, mail, QLatin1String(key.shortKeyID()) ).simplified();
544 return i18n("Bad signature by unknown certificate %1: %2", QString::fromLatin1( fpr ), QString::fromLocal8Bit( sig.status().asString() ) );
546 return i18n("Bad signature by an unknown certificate: %1", QString::fromLocal8Bit( sig.status().asString() ) );
548 return i18n("Bad signature by %1: %2", keyToString( key ), QString::fromLocal8Bit( sig.status().asString() ) );
562 return i18n("Invalid signature by unknown certificate %1: %2", QString::fromLatin1( fpr ), QString::fromLocal8Bit( sig.status().asString() ) );
564 return i18n("Invalid signature by an unknown certificate: %1", QString::fromLocal8Bit( sig.status().asString() ) );
566 return i18n("Invalid signature by %1: %2", keyToString( key ), QString::fromLocal8Bit( sig.status().asString() ) );
Definition: formatting.h:75
QString ownerTrustShort(const GpgME::Key &key)
Definition: setinitialpindialog.cpp:57
QString toUpper() const
QString type(const GpgME::Key &key)
void push_back(const T &value)
QString formatOverview(const GpgME::Key &key)
QString creationDateString(const GpgME::Key &key)
QString displayName(GpgME::Protocol prot)
QString toolTip(const GpgME::Key &key, int opts)
QString join(const QString &separator) const
QString expirationDateString(const GpgME::Key &key)
Definition: formatting.h:78
QString prettyUserID(const GpgME::UserID &uid)
QString formatForComboBox(const GpgME::Key &key)
Definition: formatting.cpp:497
QString fromLocal8Bit(const char *str, int size)
QString fromUtf8(const char *str, int size)
bool empty() const
Definition: classify.h:49
Definition: formatting.h:74
bool isEmpty() const
QString trimmed() const
QString validityShort(const GpgME::Subkey &subkey)
Definition: formatting.h:72
QDate expirationDate(const GpgME::Key &key)
Definition: classify.h:48
const char * summaryToString(const GpgME::Signature::Summary summary)
QString prettyNameAndEMail(int proto, const char *id, const char *name, const char *email, const char *comment)
Definition: formatting.cpp:87
QString prettyEMail(const char *email, const char *id)
Definition: formatting.cpp:184
QString & replace(int position, int n, QChar after)
QString signatureToString(const GpgME::Signature &sig, const GpgME::Key &key)
QDate creationDate(const GpgME::Key &key)
QDate date() const
QString importMetaData(const GpgME::Import &import)
Definition: formatting.h:81
QString escape(const QString &plain)
QString prettyName(int proto, const char *id, const char *name, const char *comment)
Definition: formatting.cpp:64
Definition: formatting.h:70
Definition: formatting.h:69
QString fromLatin1(const char *str, int size)
Definition: formatting.h:71
Definition: formatting.h:79
QString formatKeyLink(const GpgME::Key &key)
QString arg(qlonglong a, int fieldWidth, int base, const QChar &fillChar) const
Definition: formatting.h:68
void setTime_t(uint seconds)
Definition: formatting.h:77
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:33:11 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:33:11 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.