summaryrefslogtreecommitdiffabout
path: root/korganizer
authorzautrix <zautrix>2007-06-08 10:31:01 (UTC)
committer zautrix <zautrix>2007-06-08 10:31:01 (UTC)
commit11edc920afe4f274c0964436633aa632c8288a40 (patch) (unidiff)
tree415d63843250f9901d8fdb5b6255e47d46651ac3 /korganizer
parent623b4d4abe87789dacd4c14de88a63b44ca352b7 (diff)
downloadkdepimpi-11edc920afe4f274c0964436633aa632c8288a40.zip
kdepimpi-11edc920afe4f274c0964436633aa632c8288a40.tar.gz
kdepimpi-11edc920afe4f274c0964436633aa632c8288a40.tar.bz2
translation fixes
Diffstat (limited to 'korganizer') (more/less context) (show whitespace changes)
-rw-r--r--korganizer/koeventviewer.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/korganizer/koeventviewer.cpp b/korganizer/koeventviewer.cpp
index 92d2a80..c0acf34 100644
--- a/korganizer/koeventviewer.cpp
+++ b/korganizer/koeventviewer.cpp
@@ -326,65 +326,65 @@ void KOEventViewer::appendEvent(Event *event, int mode )
326 addTag("i",i18n("This event has been cancelled!")); 326 addTag("i",i18n("This event has been cancelled!"));
327 mText.append("<br>"); 327 mText.append("<br>");
328 mText += "</font>"; 328 mText += "</font>";
329 mMailSubject += i18n("(cancelled)"); 329 mMailSubject += i18n("(cancelled)");
330 } 330 }
331 331
332 if (event->doesFloat()) { 332 if (event->doesFloat()) {
333 if (event->isMultiDay()) { 333 if (event->isMultiDay()) {
334 mText.append(i18n("<p><b>From:</b> %1 </p><p><b>To:</b> %2</p>") 334 mText.append(i18n("<p><b>From:</b> %1 </p><p><b>To:</b> %2</p>")
335 .arg(event->dtStartDateStr(shortDate)) 335 .arg(event->dtStartDateStr(shortDate))
336 .arg(event->dtEndDateStr(shortDate))); 336 .arg(event->dtEndDateStr(shortDate)));
337 mText.append(i18n("<p><b>Duration:</b> %1 days</p>") 337 mText.append(i18n("<p><b>Duration:</b> %1 days</p>")
338 .arg(event->dtStart().daysTo(event->dtEnd())+1)); 338 .arg(event->dtStart().daysTo(event->dtEnd())+1));
339 } else { 339 } else {
340 mText.append(i18n("<p><b>On:</b> %1</p>").arg(event->dtStartDateStr( shortDate ))); 340 mText.append(i18n("<p><b>On:</b> %1</p>").arg(event->dtStartDateStr( shortDate )));
341 } 341 }
342 } else { 342 } else {
343 if (event->isMultiDay()) { 343 if (event->isMultiDay()) {
344 mText.append(i18n("<p><b>From:</b> %1</p> ") 344 mText.append(i18n("<p><b>From:</b> %1</p> ")
345 .arg(event->dtStartStr( shortDate))); 345 .arg(event->dtStartStr( shortDate)));
346 mText.append(i18n("<p><b>To:</b> %1</p>") 346 mText.append(i18n("<p><b>To:</b> %1</p>")
347 .arg(event->dtEndStr(shortDate))); 347 .arg(event->dtEndStr(shortDate)));
348 } else { 348 } else {
349 mText.append(i18n("<p><b>From:</b> %1 <b>To:</b> %2</p>") 349 mText.append(i18n("<p><b>From:</b> %1 <b>To:</b> %2</p>")
350 .arg(event->dtStartTimeStr()) 350 .arg(event->dtStartTimeStr())
351 .arg(event->dtEndTimeStr())); 351 .arg(event->dtEndTimeStr()));
352 mText.append(i18n("<p><b>On:</b> %1</p> ") 352 mText.append(i18n("<p><b>On:</b> %1</p> ")
353 .arg(event->dtStartDateStr( shortDate ))); 353 .arg(event->dtStartDateStr( shortDate )));
354 } 354 }
355 } 355 }
356 if (!event->location().isEmpty()) { 356 if (!event->location().isEmpty()) {
357 addTag("p","<b>"+i18n("Location: ")+"</b>"+ deTag(event->location() ) ); 357 addTag("p","<b>"+i18n("Location: ")+"</b>"+ deTag(event->location() ) );
358 mMailSubject += i18n(" at ") + event->location(); 358 mMailSubject += " (" + i18n("Location: ") + event->location() + ")";
359 } 359 }
360 if (event->doesRecur()) { 360 if (event->doesRecur()) {
361 361
362 QString recurText = event->recurrenceText(); 362 QString recurText = event->recurrenceText();
363 addTag("p","<em>" + i18n("This is a %1 recurring event.").arg(recurText ) + "</em>"); 363 addTag("p","<em>" + i18n("This is a %1 recurring event.").arg(recurText ) + "</em>");
364 bool ok; 364 bool ok;
365 QDate start = QDate::currentDate(); 365 QDate start = QDate::currentDate();
366 QDateTime next; 366 QDateTime next;
367 next = event->getNextOccurence( QDateTime::currentDateTime() , &ok ); 367 next = event->getNextOccurence( QDateTime::currentDateTime() , &ok );
368 if ( ok ) { 368 if ( ok ) {
369 if ( wideScreen ){ 369 if ( wideScreen ){
370 addTag("p",i18n("<b>Next recurrence is on:</b>") +" " + KGlobal::locale()->formatDate( next.date(), shortDate ) ); 370 addTag("p",i18n("<b>Next recurrence is on:</b>") +" " + KGlobal::locale()->formatDate( next.date(), shortDate ) );
371 } else { 371 } else {
372 addTag("p",i18n("<b>Next recurrence is on:</b>") ); 372 addTag("p",i18n("<b>Next recurrence is on:</b>") );
373 addTag("p", KGlobal::locale()->formatDate( next.date(), shortDate )); 373 addTag("p", KGlobal::locale()->formatDate( next.date(), shortDate ));
374 } 374 }
375 mMailSubject += i18n(" - " )+ KGlobal::locale()->formatDateTime( next, true ); 375 mMailSubject += i18n(" - " )+ KGlobal::locale()->formatDateTime( next, true );
376 376
377 } else { 377 } else {
378 bool last; 378 bool last;
379 QDate nextd; 379 QDate nextd;
380 nextd = event->recurrence()->getPreviousDate( QDate::currentDate() , &last ); 380 nextd = event->recurrence()->getPreviousDate( QDate::currentDate() , &last );
381 if ( last ) { 381 if ( last ) {
382 if ( wideScreen ){ 382 if ( wideScreen ){
383 addTag("p",i18n("<b>Last recurrence was on:</b>") +" " + KGlobal::locale()->formatDate( nextd, shortDate )); 383 addTag("p",i18n("<b>Last recurrence was on:</b>") +" " + KGlobal::locale()->formatDate( nextd, shortDate ));
384 } else{ 384 } else{
385 addTag("p",i18n("<b>Last recurrence was on:</b>") ); 385 addTag("p",i18n("<b>Last recurrence was on:</b>") );
386 addTag("p", KGlobal::locale()->formatDate( nextd, shortDate )); 386 addTag("p", KGlobal::locale()->formatDate( nextd, shortDate ));
387 } 387 }
388 } 388 }
389 } 389 }
390 } else { 390 } else {
@@ -485,71 +485,72 @@ void KOEventViewer::appendTodo(Todo *event, int mode )
485 mText += "</font>"; 485 mText += "</font>";
486 } 486 }
487 mMailSubject += i18n( "Todo " )+ event->summary(); 487 mMailSubject += i18n( "Todo " )+ event->summary();
488 488
489 if ( event->percentComplete() == 100 && event->hasCompletedDate() ) { 489 if ( event->percentComplete() == 100 && event->hasCompletedDate() ) {
490 mText +="<font color=\"#B00000\">"; 490 mText +="<font color=\"#B00000\">";
491 addTag("i", i18n("<p><i>Completed on %1</i></p>").arg( event->completedStr(KOPrefs::instance()->mShortDateInViewer) ) ); 491 addTag("i", i18n("<p><i>Completed on %1</i></p>").arg( event->completedStr(KOPrefs::instance()->mShortDateInViewer) ) );
492 mText += "</font>"; 492 mText += "</font>";
493 } else { 493 } else {
494 mText.append(i18n("<p><i>%1 % completed</i></p>") 494 mText.append(i18n("<p><i>%1 % completed</i></p>")
495 .arg(event->percentComplete())); 495 .arg(event->percentComplete()));
496 } 496 }
497 497
498 if (event->cancelled ()) { 498 if (event->cancelled ()) {
499 mText +="<font color=\"#B00000\">"; 499 mText +="<font color=\"#B00000\">";
500 addTag("i",i18n("This todo has been cancelled!")); 500 addTag("i",i18n("This todo has been cancelled!"));
501 mText.append("<br>"); 501 mText.append("<br>");
502 mText += "</font>"; 502 mText += "</font>";
503 mMailSubject += i18n("(cancelled)"); 503 mMailSubject += i18n("(cancelled)");
504 } 504 }
505 505
506 506
507 507
508 if (event->doesRecur()) { 508 if (event->doesRecur()) {
509 509
510 QString recurText = event->recurrence()->recurrenceText(); 510 QString recurText = event->recurrence()->recurrenceText();
511 addTag("p","<em>" + i18n("This is a %1 recurring todo.").arg(recurText ) + "</em>"); 511 addTag("p","<em>" + i18n("This is a %1 recurring todo.").arg(recurText ) + "</em>");
512 512
513 } 513 }
514 if (event->hasStartDate()) { 514 if (event->hasStartDate()) {
515 mText.append(i18n("<p><b>Start on:</b> %1</p>").arg(event->dtStartStr(KOPrefs::instance()->mShortDateInViewer))); 515 mText.append(i18n("<p><b>Start on:</b> %1</p>").arg(event->dtStartStr(KOPrefs::instance()->mShortDateInViewer)));
516 } 516 }
517 if (!event->location().isEmpty()) {
518 mMailSubject += " (" + i18n("Location: ") + event->location() + ")";
519 }
517 if (event->hasDueDate()) { 520 if (event->hasDueDate()) {
518 mText.append(i18n("<p><b>Due on:</b> %1</p>").arg(event->dtDueStr(KOPrefs::instance()->mShortDateInViewer))); 521 mText.append(i18n("<p><b>Due on:</b> %1</p>").arg(event->dtDueStr(KOPrefs::instance()->mShortDateInViewer)));
519 mMailSubject += i18n(" - " )+event->dtDueStr( true );
520 } 522 }
521 if (!event->location().isEmpty()) { 523 if (!event->location().isEmpty()) {
522 addTag("p","<b>"+i18n("Location: ")+"</b>"+ deTag(event->location() ) ); 524 addTag("p","<b>"+i18n("Location: ")+"</b>"+ deTag(event->location() ) );
523 mMailSubject += i18n(" at ") + event->location();
524 } 525 }
525 mText.append(i18n("<p><b>Priority:</b> %2</p>") 526 mText.append(i18n("<p><b>Priority:</b> %2</p>")
526 .arg(QString::number(event->priority()))); 527 .arg(QString::number(event->priority())));
527 528
528 if (event->isAlarmEnabled()) { 529 if (event->isAlarmEnabled()) {
529 Alarm *alarm =event->alarms().first() ; 530 Alarm *alarm =event->alarms().first() ;
530 QDateTime t = alarm->time(); 531 QDateTime t = alarm->time();
531 if (event->doesRecur()) { 532 if (event->doesRecur()) {
532 bool ok = false; 533 bool ok = false;
533 int offset = 0; 534 int offset = 0;
534 QDateTime next = event->getNextAlarmDateTime(& ok, &offset, QDateTime::currentDateTime() ) ; 535 QDateTime next = event->getNextAlarmDateTime(& ok, &offset, QDateTime::currentDateTime() ) ;
535 if ( ok ) { 536 if ( ok ) {
536 t = next; 537 t = next;
537 } 538 }
538 } 539 }
539 QString s =i18n("( %1 before )").arg( alarm->offsetText() ); 540 QString s =i18n("( %1 before )").arg( alarm->offsetText() );
540 if ( wideScreen ) { 541 if ( wideScreen ) {
541 addTag("p",i18n("<b>Alarm on: ") + s +" </b>"+ KGlobal::locale()->formatDateTime( t, shortDate )); 542 addTag("p",i18n("<b>Alarm on: ") + s +" </b>"+ KGlobal::locale()->formatDateTime( t, shortDate ));
542 } else { 543 } else {
543 addTag("p",i18n("<b>Alarm on: ") + s +" </b>"); 544 addTag("p",i18n("<b>Alarm on: ") + s +" </b>");
544 addTag("p", KGlobal::locale()->formatDateTime( t, shortDate )); 545 addTag("p", KGlobal::locale()->formatDateTime( t, shortDate ));
545 } 546 }
546 if ( !(event->alarmEnabled() ) ) { 547 if ( !(event->alarmEnabled() ) ) {
547 addTag("p", "<em>("+i18n("Enable alarm in resource settings") + ")</em>"); 548 addTag("p", "<em>("+i18n("Enable alarm in resource settings") + ")</em>");
548 549
549 } 550 }
550 } 551 }
551 552
552 addTag("p","<b>"+i18n("Access: ") + "</b>" + event->secrecyStr()); 553 addTag("p","<b>"+i18n("Access: ") + "</b>" + event->secrecyStr());
553 554
554 formatCategories(event); 555 formatCategories(event);
555 556