summaryrefslogtreecommitdiffabout
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--bin/kdepim/korganizer/germantranslation.txt2
-rw-r--r--korganizer/koagendaitem.cpp10
-rw-r--r--korganizer/koprefs.cpp1
-rw-r--r--korganizer/koprefs.h1
-rw-r--r--korganizer/koprefsdialog.cpp6
5 files changed, 18 insertions, 2 deletions
diff --git a/bin/kdepim/korganizer/germantranslation.txt b/bin/kdepim/korganizer/germantranslation.txt
index eec0b38..00f5c28 100644
--- a/bin/kdepim/korganizer/germantranslation.txt
+++ b/bin/kdepim/korganizer/germantranslation.txt
@@ -1201,12 +1201,12 @@
1201{ "Next month","Nächster Monat" }, 1201{ "Next month","Nächster Monat" },
1202{ "Journal view","Journal" }, 1202{ "Journal view","Journal" },
1203{ "Display all opened","Zeige alle geöffnet" }, 1203{ "Display all opened","Zeige alle geöffnet" },
1204{ "Display all closed","Zeige alle geschlossen" }, 1204{ "Display all closed","Zeige alle geschlossen" },
1205{ "Display all flat","Zeige alle flach" }, 1205{ "Display all flat","Zeige alle flach" },
1206{ "<p><i>Completed on %1</i></p>","<p><i>Erledigt am %1</i></p>" }, 1206{ "<p><i>Completed on %1</i></p>","<p><i>Erledigt am %1</i></p>" },
1207{ "","" }, 1207{ "Default todo done color:","Standard Todo erledigt Farbe" },
1208{ "","" }, 1208{ "","" },
1209{ "","" }, 1209{ "","" },
1210{ "","" }, 1210{ "","" },
1211{ "","" }, 1211{ "","" },
1212{ "","" }, 1212{ "","" },
diff --git a/korganizer/koagendaitem.cpp b/korganizer/koagendaitem.cpp
index ee9f39a..a05c60e 100644
--- a/korganizer/koagendaitem.cpp
+++ b/korganizer/koagendaitem.cpp
@@ -91,16 +91,24 @@ void KOAgendaItem::init ( Incidence *incidence, QDate qd )
91 mBackgroundColor = KOPrefs::instance()->mTodoDueTodayColor; 91 mBackgroundColor = KOPrefs::instance()->mTodoDueTodayColor;
92 } 92 }
93 else { 93 else {
94 QStringList categories = mIncidence->categories(); 94 QStringList categories = mIncidence->categories();
95 QString cat = categories.first(); 95 QString cat = categories.first();
96 if (cat.isEmpty()) { 96 if (cat.isEmpty()) {
97 mBackgroundColor =KOPrefs::instance()->mEventColor; 97 if ( (incidence->type() == "Todo") &&((static_cast<Todo*>(incidence))->isCompleted()) )
98 mBackgroundColor =KOPrefs::instance()->mTodoDoneColor;
99 else
100 mBackgroundColor =KOPrefs::instance()->mEventColor;
98 } else { 101 } else {
99 mBackgroundColor = *KOPrefs::instance()->categoryColor(cat); 102 mBackgroundColor = *KOPrefs::instance()->categoryColor(cat);
103 if ( (incidence->type() == "Todo") &&((static_cast<Todo*>(incidence))->isCompleted()) ) {
104 if ( mBackgroundColor == KOPrefs::instance()->mEventColor )
105 mBackgroundColor =KOPrefs::instance()->mTodoDoneColor;
106 }
100 } 107 }
108
101 } 109 }
102 mColorGroup = QColorGroup( mBackgroundColor.light(), 110 mColorGroup = QColorGroup( mBackgroundColor.light(),
103 mBackgroundColor.dark(),mBackgroundColor.light(), 111 mBackgroundColor.dark(),mBackgroundColor.light(),
104 mBackgroundColor.dark(),mBackgroundColor, black, mBackgroundColor) ; 112 mBackgroundColor.dark(),mBackgroundColor, black, mBackgroundColor) ;
105 setBackgroundColor( mBackgroundColor ); 113 setBackgroundColor( mBackgroundColor );
106 114
diff --git a/korganizer/koprefs.cpp b/korganizer/koprefs.cpp
index 32cc291..0548f14 100644
--- a/korganizer/koprefs.cpp
+++ b/korganizer/koprefs.cpp
@@ -194,12 +194,13 @@ KOPrefs::KOPrefs() :
194 194
195 195
196 KPrefs::setCurrentGroup("Colors"); 196 KPrefs::setCurrentGroup("Colors");
197 addItemColor("Holiday Color",&mHolidayColor,defaultHolidayColor); 197 addItemColor("Holiday Color",&mHolidayColor,defaultHolidayColor);
198 addItemColor("Highlight Color",&mHighlightColor,defaultHighlightColor); 198 addItemColor("Highlight Color",&mHighlightColor,defaultHighlightColor);
199 addItemColor("Event Color",&mEventColor,mDefaultCategoryColor); 199 addItemColor("Event Color",&mEventColor,mDefaultCategoryColor);
200 addItemColor("Todo done Color",&mTodoDoneColor,QColor(111,255,115) );
200 addItemColor("Agenda Background Color",&mAgendaBgColor,defaultAgendaBgColor); 201 addItemColor("Agenda Background Color",&mAgendaBgColor,defaultAgendaBgColor);
201 addItemColor("WorkingHours Color",&mWorkingHoursColor,defaultWorkingHoursColor); 202 addItemColor("WorkingHours Color",&mWorkingHoursColor,defaultWorkingHoursColor);
202 addItemColor("Todo due today Color",&mTodoDueTodayColor,defaultTodoDueTodayColor); 203 addItemColor("Todo due today Color",&mTodoDueTodayColor,defaultTodoDueTodayColor);
203 addItemColor("Todo overdue Color",&mTodoOverdueColor,defaultTodoOverdueColor); 204 addItemColor("Todo overdue Color",&mTodoOverdueColor,defaultTodoOverdueColor);
204 addItemColor("MonthViewEvenColor",&mMonthViewEvenColor,QColor( 160,160,255 )); 205 addItemColor("MonthViewEvenColor",&mMonthViewEvenColor,QColor( 160,160,255 ));
205 addItemColor("MonthViewOddColor",&mMonthViewOddColor,QColor( 160,255,160 )); 206 addItemColor("MonthViewOddColor",&mMonthViewOddColor,QColor( 160,255,160 ));
diff --git a/korganizer/koprefs.h b/korganizer/koprefs.h
index b3acda7..8b849fa 100644
--- a/korganizer/koprefs.h
+++ b/korganizer/koprefs.h
@@ -120,12 +120,13 @@ class KOPrefs : public KPimPrefs
120 120
121 121
122 122
123 QColor mHolidayColor; 123 QColor mHolidayColor;
124 QColor mHighlightColor; 124 QColor mHighlightColor;
125 QColor mEventColor; 125 QColor mEventColor;
126 QColor mTodoDoneColor;
126 QColor mAgendaBgColor; 127 QColor mAgendaBgColor;
127 QColor mWorkingHoursColor; 128 QColor mWorkingHoursColor;
128 QColor mTodoDueTodayColor; 129 QColor mTodoDueTodayColor;
129 QColor mTodoOverdueColor; 130 QColor mTodoOverdueColor;
130 QColor mMonthViewEvenColor; 131 QColor mMonthViewEvenColor;
131 QColor mMonthViewOddColor; 132 QColor mMonthViewOddColor;
diff --git a/korganizer/koprefsdialog.cpp b/korganizer/koprefsdialog.cpp
index 1b24f56..580dff2 100644
--- a/korganizer/koprefsdialog.cpp
+++ b/korganizer/koprefsdialog.cpp
@@ -1173,12 +1173,18 @@ void KOPrefsDialog::setupColorsTab()
1173 // Event color 1173 // Event color
1174 KPrefsDialogWidColor *eventColor = 1174 KPrefsDialogWidColor *eventColor =
1175 addWidColor(i18n("Default event color:"), 1175 addWidColor(i18n("Default event color:"),
1176 &(KOPrefs::instance()->mEventColor),topFrame); 1176 &(KOPrefs::instance()->mEventColor),topFrame);
1177 topLayout->addWidget(eventColor->label(),ii,0); 1177 topLayout->addWidget(eventColor->label(),ii,0);
1178 topLayout->addWidget(eventColor->button(),ii++,1); 1178 topLayout->addWidget(eventColor->button(),ii++,1);
1179 eventColor =
1180 addWidColor(i18n("Default todo done color:"),
1181 &(KOPrefs::instance()->mTodoDoneColor),topFrame);
1182 topLayout->addWidget(eventColor->label(),ii,0);
1183 topLayout->addWidget(eventColor->button(),ii++,1);
1184
1179 1185
1180 // agenda view background color 1186 // agenda view background color
1181 KPrefsDialogWidColor *agendaBgColor = 1187 KPrefsDialogWidColor *agendaBgColor =
1182 addWidColor(i18n("Agenda view background color:"), 1188 addWidColor(i18n("Agenda view background color:"),
1183 &(KOPrefs::instance()->mAgendaBgColor),topFrame); 1189 &(KOPrefs::instance()->mAgendaBgColor),topFrame);
1184 topLayout->addWidget(agendaBgColor->label(),ii,0); 1190 topLayout->addWidget(agendaBgColor->label(),ii,0);