33 #ifndef __KLEO_ENUM_H__
34 #define __KLEO_ENUM_H__
36 #include <tdemacros.h>
43 enum CryptoMessageFormat {
44 InlineOpenPGPFormat = 1,
45 OpenPGPMIMEFormat = 2,
47 SMIMEOpaqueFormat = 8,
48 AnyOpenPGP = InlineOpenPGPFormat|OpenPGPMIMEFormat,
49 AnySMIME = SMIMEOpaqueFormat|SMIMEFormat,
50 AutoFormat = AnyOpenPGP|AnySMIME
53 TDE_EXPORT TQString cryptoMessageFormatToLabel( CryptoMessageFormat f );
55 TDE_EXPORT const char * cryptoMessageFormatToString( CryptoMessageFormat f );
56 TDE_EXPORT TQStringList cryptoMessageFormatsToStringList( unsigned int f );
57 TDE_EXPORT CryptoMessageFormat stringToCryptoMessageFormat( const TQString & s );
58 TDE_EXPORT unsigned int stringListToCryptoMessageFormats( const TQStringList & sl );
61 Conflict, DoIt, DontDoIt, Ask, AskOpportunistic, Impossible
64 enum EncryptionPreference {
65 UnknownPreference = 0,
68 AlwaysEncryptIfPossible = 3,
69 AlwaysAskForEncryption = 4,
70 AskWheneverPossible = 5,
71 MaxEncryptionPreference = AskWheneverPossible
74 TDE_EXPORT TQString encryptionPreferenceToLabel( EncryptionPreference pref );
75 TDE_EXPORT const char* encryptionPreferenceToString( EncryptionPreference pref );
76 TDE_EXPORT EncryptionPreference stringToEncryptionPreference( const TQString& str );
78 enum SigningPreference {
79 UnknownSigningPreference = 0,
82 AlwaysSignIfPossible = 3,
83 AlwaysAskForSigning = 4,
84 AskSigningWheneverPossible = 5,
85 MaxSigningPreference = AskSigningWheneverPossible
88 TDE_EXPORT TQString signingPreferenceToLabel( SigningPreference pref );
89 TDE_EXPORT const char* signingPreferenceToString( SigningPreference pref );
90 TDE_EXPORT SigningPreference stringToSigningPreference( const TQString& str );
|