i18n fixes.

Note: although sometimes a message with a number argument is never called for case n == 1, it still should be made plural, because plural forms accross languages are more complicated than just n == 1 and n > 1.

svn path=/trunk/KDE/kdepim/; revision=632290
wilder-work
Chusslove Illich 19 years ago
parent b14c969c80
commit f79f9609c9
  1. 2
      configuredialog.cpp
  2. 2
      customtemplates.cpp
  3. 6
      folderdiaquotatab.cpp
  4. 4
      folderdiaquotatab_p.cpp
  5. 4
      kmcomposewin.cpp
  6. 2
      popaccount.cpp
  7. 4
      quotajobs.h
  8. 38
      templateparser.cpp
  9. 14
      templatesconfiguration.cpp

@ -918,7 +918,7 @@ void AccountsPage::SendingTab::slotModifySelectedTransport()
if ( !changedIdents.isEmpty() ) {
QString information =
i18nc( "This identity has been changed to use the modified transport:",
i18np( "This identity has been changed to use the modified transport:",
"These %n identities have been changed to use the modified transport:",
changedIdents.count() );
KMessageBox::informationList( this, information, changedIdents );

@ -107,7 +107,7 @@ CustomTemplates::CustomTemplates( QWidget *parent, const char *name )
"You cannot bind a keyboard shortcut to <i>Universal</i> templates.</p>"
"</qt>" );
mHelp->setText( i18n( "<a href=\"whatsthis:%1\">How does this work?</a>" ).arg( help ) );
mHelp->setText( i18n( "<a href=\"whatsthis:%1\">How does this work?</a>", help ) );
mHelp->setOpenExternalLinks(true);
mHelp->setTextInteractionFlags(Qt::LinksAccessibleByMouse|Qt::LinksAccessibleByKeyboard);
}

@ -118,7 +118,7 @@ void KMail::FolderDiaQuotaTab::load()
KMFolder* folder = mDlg->folder() ? mDlg->folder() : mDlg->parentFolder();
if ( folder && folder->storage() == mImapAccount->rootFolder() )
return; // nothing to be done for the (virtual) account folder
mLabel->setText( i18n( "Connecting to server %1, please wait..." ).arg( mImapAccount->host() ) );
mLabel->setText( i18n( "Connecting to server %1, please wait...", mImapAccount->host() ) );
ImapAccountBase::ConnectionState state = mImapAccount->makeConnection();
if ( state == ImapAccountBase::Error ) { // Cancelled by user, or slave can't start
slotConnectionResult( -1, QString::null );
@ -137,7 +137,7 @@ void KMail::FolderDiaQuotaTab::slotConnectionResult( int errorCode, const QStrin
this, SLOT( slotConnectionResult(int, const QString&) ) );
if ( errorCode ) {
if ( errorCode == -1 ) // unspecified error
mLabel->setText( i18n( "Error connecting to server %1" ).arg( mImapAccount->host() ) );
mLabel->setText( i18n( "Error connecting to server %1", mImapAccount->host() ) );
else
// Connection error (error message box already shown by the account)
mLabel->setText( KIO::buildErrorString( errorCode, errorMsg ) );
@ -163,7 +163,7 @@ void KMail::FolderDiaQuotaTab::slotReceivedQuotaInfo( KMFolder* folder,
if ( job->error() == KIO::ERR_UNSUPPORTED_ACTION )
mLabel->setText( i18n( "This account does not have support for quota information." ) );
else
mLabel->setText( i18n( "Error retrieving quota information from server\n%1" ).arg( job->errorString() ) );
mLabel->setText( i18n( "Error retrieving quota information from server\n%1", job->errorString() ) );
} else {
mQuotaInfo = info;
}

@ -84,8 +84,8 @@ void QuotaWidget::setQuotaInfo( const QuotaInfo& info )
int factor = static_cast<int> ( pow( 1000, mFactor ) );
mProgressBar->setMaximum( max );
mProgressBar->setValue( current );
mInfoLabel->setText( i18n("%1 of %2 %3 used").arg( current/factor )
.arg( max/factor ).arg( mUnits ) );
mInfoLabel->setText( i18n("%1 of %2 %3 used", current/factor,
max/factor, mUnits ) );
mRootLabel->setText( info.root() );
}

@ -3892,8 +3892,8 @@ bool KMComposeWin::saveDraftOrTemplate( const QString &folderName,
i18n("The custom drafts or templates folder for "
"identify \"%1\" does not exist (anymore); "
"therefore, the default drafts or templates "
"folder will be used.")
.arg( id.identityName() ) );
"folder will be used.",
id.identityName() ) );
}
}
if ( imapTheFolder && imapTheFolder->noContent() )

@ -475,7 +475,7 @@ void PopAccount::slotJobFinished() {
"the UIDL command: this command is required to determine, in a reliable way, "
"which of the mails on the server KMail has already seen before;\n"
"the feature to leave the mails on the server will therefore not "
"work properly.").arg(NetworkAccount::name()) );
"work properly.", NetworkAccount::name()) );
// An attempt to work around buggy pop servers, these seem to be popular.
mUidsOfNextSeenMsgsDict = mUidsOfSeenMsgsDict;
}

@ -67,8 +67,8 @@ class QuotaInfo {
if ( isValid() && !isEmpty() ) {
readConfig();
int factor = static_cast<int> ( pow( 1000, mFactor ) );
return i18n("%1 of %2 %3 used").arg( mCurrent.toInt() / factor )
.arg( mMax.toInt() / factor ).arg( mUnits );
return i18n("%1 of %2 %3 used", mCurrent.toInt() / factor,
mMax.toInt() / factor, mUnits );
}
return QString();
}

@ -234,8 +234,8 @@ void TemplateParser::processWithTemplate( const QString &tmpl )
body.append( str );
} else if ( mDebug ) {
KMessageBox::error( 0,
i18n( "Cannot insert content from file %1: %2" ).
arg( path ).arg( file.errorString() ) );
i18n( "Cannot insert content from file %1: %2",
path, file.errorString() ) );
}
} else if ( cmd.startsWith( "SYSTEM=" ) ) {
@ -267,8 +267,8 @@ void TemplateParser::processWithTemplate( const QString &tmpl )
body.append( QString::fromLocal8Bit( content, content.size() ) );
} else if ( mDebug ) {
KMessageBox::error( 0,
i18n( "Cannot insert content from file %1: %2").
arg( path ).arg(file.errorString() ));
i18n( "Cannot insert content from file %1: %2",
path, file.errorString() ));
}
} else if ( cmd.startsWith( "QUOTEPIPE=" ) ) {
@ -1005,12 +1005,12 @@ QString TemplateParser::pipe( const QString &cmd, const QString &buf )
if ( mPipeRc != 0 && mDebug ) {
if ( mPipeErr.isEmpty() ) {
KMessageBox::error( 0,
i18n( "Pipe command exit with status %1: %2").
arg( mPipeRc ).arg( cmd ) );
i18n( "Pipe command exit with status %1: %2",
mPipeRc, cmd ) );
} else {
KMessageBox::detailedError( 0,
i18n( "Pipe command exit with status %1: %2" ).
arg( mPipeRc ).arg( cmd ), mPipeErr );
i18n( "Pipe command exit with status %1: %2",
mPipeRc, cmd ), mPipeErr );
}
}
@ -1020,12 +1020,12 @@ QString TemplateParser::pipe( const QString &cmd, const QString &buf )
if ( mPipeRc != 0 && mDebug ) {
if ( mPipeErr.isEmpty() ) {
KMessageBox::error( 0,
i18n( "Pipe command killed by signal %1: %2" ).
arg( -(mPipeRc) ).arg( cmd ) );
i18n( "Pipe command killed by signal %1: %2",
-(mPipeRc), cmd ) );
} else {
KMessageBox::detailedError( 0,
i18n( "Pipe command killed by signal %1: %2" ).
arg( -(mPipeRc) ).arg( cmd ), mPipeErr );
i18n( "Pipe command killed by signal %1: %2",
-(mPipeRc), cmd ), mPipeErr );
}
}
}
@ -1036,8 +1036,8 @@ QString TemplateParser::pipe( const QString &cmd, const QString &buf )
proc.detach();
if ( mDebug ) {
KMessageBox::error( 0,
i18n( "Pipe command did not finish within %1 seconds: %2" ).
arg( PipeTimeout ).arg( cmd ) );
i18n( "Pipe command did not finish within %1 seconds: %2",
PipeTimeout, cmd ) );
}
}
@ -1048,19 +1048,19 @@ QString TemplateParser::pipe( const QString &cmd, const QString &buf )
if ( mDebug ) {
if ( mPipeErr.isEmpty() ) {
KMessageBox::error( 0,
i18n( "Cannot write to process stdin: %1" ).arg( cmd ) );
i18n( "Cannot write to process stdin: %1", cmd ) );
} else {
KMessageBox::detailedError( 0,
i18n( "Cannot write to process stdin: %1" ).
arg( cmd ), mPipeErr );
i18n( "Cannot write to process stdin: %1",
cmd ), mPipeErr );
}
}
}
} else if ( mDebug ) {
KMessageBox::error( 0,
i18n( "Cannot start pipe command from template: %1" ).
arg( cmd ) );
i18n( "Cannot start pipe command from template: %1",
cmd ) );
}
return mPipeOut;

@ -104,7 +104,7 @@ TemplatesConfiguration::TemplatesConfiguration( QWidget *parent, const char *nam
"</qt>" );
}
mHelp->setText( i18n( "<a href=\"whatsthis:%1\">How does this work?</a>" ).arg( help ) );
mHelp->setText( i18n( "<a href=\"whatsthis:%1\">How does this work?</a>", help ) );
mHelp->setOpenExternalLinks(true);
mHelp->setTextInteractionFlags(Qt::LinksAccessibleByMouse|Qt::LinksAccessibleByKeyboard);
}
@ -343,12 +343,12 @@ void TemplatesConfiguration::loadFromPhrases()
str = replyPhrases.phraseForward();
if ( !str.isEmpty() ) {
textEdit_forward->setText( QString( i18n(
textEdit_forward->setText( i18n(
"%REM=\"Default forward template\"%-\n"
"---------- %1 ----------\n"
"%TEXT\n"
"-------------------------------------------------------\n"
) ).arg( convertPhrases( str ) ) );
"-------------------------------------------------------\n",
convertPhrases( str ) ) );
}
else {
textEdit_forward->setText( defaultForward() );
@ -392,7 +392,7 @@ void TemplatesConfiguration::importFromPhrases()
str = replyPhrases.phraseForward();
if ( !str.isEmpty() ) {
GlobalSettings::self()->setTemplateForward( QString( i18n(
GlobalSettings::self()->setTemplateForward( i18n(
"%REM=\"Default forward template\"%-\n"
"\n"
"---------- %1 ----------\n"
@ -403,8 +403,8 @@ void TemplatesConfiguration::importFromPhrases()
"To: %OTOADDR\n"
"\n"
"%TEXT\n"
"-------------------------------------------------------\n"
) ).arg( convertPhrases( str ) ) );
"-------------------------------------------------------\n",
convertPhrases( str ) ) );
}
else {
GlobalSettings::self()->setTemplateForward( defaultForward() );

Loading…
Cancel
Save