summaryrefslogtreecommitdiffabout
Unidiff
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--bin/kdepim/kaddressbook/germantranslation.txt2
-rw-r--r--bin/kdepim/kopiemail/germantranslation.txt2
-rw-r--r--bin/kdepim/korganizer/germantranslation.txt2
-rw-r--r--bin/kdepim/pwmanager/germantranslation.txt2
-rw-r--r--korganizer/kodaymatrix.cpp14
-rw-r--r--korganizer/koprefsdialog.cpp4
-rw-r--r--libkcal/icalformatimpl.cpp3
-rw-r--r--libkdepim/kcmconfigs/kdepimconfigwidget.cpp41
-rw-r--r--libkdepim/kcmconfigs/kdepimconfigwidget.h4
-rw-r--r--libkdepim/kpimglobalprefs.cpp7
-rw-r--r--libkdepim/kpimglobalprefs.h6
-rw-r--r--libkdepim/kprefsdialog.cpp2
-rw-r--r--libkdepim/kprefsdialog.h7
-rw-r--r--microkde/kglobalsettings.cpp9
-rw-r--r--microkde/kglobalsettings.h1
15 files changed, 86 insertions, 20 deletions
diff --git a/bin/kdepim/kaddressbook/germantranslation.txt b/bin/kdepim/kaddressbook/germantranslation.txt
index 0884a83..85aed43 100644
--- a/bin/kdepim/kaddressbook/germantranslation.txt
+++ b/bin/kdepim/kaddressbook/germantranslation.txt
@@ -435,49 +435,49 @@
435{ "Full Name","Voller Name" }, 435{ "Full Name","Voller Name" },
436{ "Reverse Name","Namen umdrehen" }, 436{ "Reverse Name","Namen umdrehen" },
437{ "Contact","Kontakt" }, 437{ "Contact","Kontakt" },
438{ "Global","Allgemein" }, 438{ "Global","Allgemein" },
439{ "Phone","Telefon" }, 439{ "Phone","Telefon" },
440{ "SMS","SMS" }, 440{ "SMS","SMS" },
441{ "Language:(needs restart)","Sprache:(Neustart)" }, 441{ "Language:(needs restart)","Sprache:(Neustart)" },
442{ "English","English" }, 442{ "English","English" },
443{ "German","Deutsch" }, 443{ "German","Deutsch" },
444{ "French","Französisch" }, 444{ "French","Französisch" },
445{ "Italian","Italienisch" }, 445{ "Italian","Italienisch" },
446{ "User defined (usertranslation.txt)","Benutzerdef. (usertranslation.txt)" }, 446{ "User defined (usertranslation.txt)","Benutzerdef. (usertranslation.txt)" },
447{ "Time Format(nr):","Zeit Format(nr):" }, 447{ "Time Format(nr):","Zeit Format(nr):" },
448{ "24:00","24:00" }, 448{ "24:00","24:00" },
449{ "12:00am","12:00am" }, 449{ "12:00am","12:00am" },
450{ "Week starts on Sunday","Woche beginnt Sonntags" }, 450{ "Week starts on Sunday","Woche beginnt Sonntags" },
451{ "Locale","Locale" }, 451{ "Locale","Locale" },
452{ "Date Format:","Datums Format:" }, 452{ "Date Format:","Datums Format:" },
453{ "24.03.2004 (%d.%m.%Y|%A %d %B %Y)","24.03.2004 (%d.%m.%Y|%A %d %B %Y)" }, 453{ "24.03.2004 (%d.%m.%Y|%A %d %B %Y)","24.03.2004 (%d.%m.%Y|%A %d %B %Y)" },
454{ "03.24.2004 (%m.%d.%Y|%A %B %d %Y)","03.24.2004 (%m.%d.%Y|%A %B %d %Y)" }, 454{ "03.24.2004 (%m.%d.%Y|%A %B %d %Y)","03.24.2004 (%m.%d.%Y|%A %B %d %Y)" },
455{ "2004-03-24 (%Y-%m-%d|%A %Y %B %d)","2004-03-24 (%Y-%m-%d|%A %Y %B %d)" }, 455{ "2004-03-24 (%Y-%m-%d|%A %Y %B %d)","2004-03-24 (%Y-%m-%d|%A %Y %B %d)" },
456{ "User defined","Benutzerdefiniert" }, 456{ "User defined","Benutzerdefiniert" },
457{ "User long date:","Format langes Datum:" }, 457{ "User long date:","Format langes Datum:" },
458{ "User short date:","Format kurzes Datum:" }, 458{ "User short date:","Format kurzes Datum:" },
459{ "Daylight start:","Sommerzeit Beginn:" }, 459{ "Daylight start:","Sommerzeit Start:" },
460{ "Daylight end:","Sommerzeit Ende:" }, 460{ "Daylight end:","Sommerzeit Ende:" },
461{ "Actual start and end is the\nsunday before this date.","Tatsächlicher Beginn/Ende ist der\nSonntag vor diesem Datum!" }, 461{ "Actual start and end is the\nsunday before this date.","Tatsächlicher Beginn/Ende ist der\nSonntag vor diesem Datum!" },
462{ "Monday 19 April 2004: %A %d %B %Y","Monday 19 April 2004: %A %d %B %Y" }, 462{ "Monday 19 April 2004: %A %d %B %Y","Monday 19 April 2004: %A %d %B %Y" },
463{ "Mon 19.04.04: %a %d.%m.%y","Mon 19.04.04: %a %d.%m.%y" }, 463{ "Mon 19.04.04: %a %d.%m.%y","Mon 19.04.04: %a %d.%m.%y" },
464{ "Mon, 19.Apr.04: %a, %d.%b.%y","Mon, 19.Apr.04: %a, %d.%b.%y" }, 464{ "Mon, 19.Apr.04: %a, %d.%b.%y","Mon, 19.Apr.04: %a, %d.%b.%y" },
465{ "Date Format","Datums Format" }, 465{ "Date Format","Datums Format" },
466{ "Timezone:","Zeitzone:" }, 466{ "Timezone:","Zeitzone:" },
467{ "The year in the date is ignored.","Das Jahr vom Datum wird ignoriert." }, 467{ "The year in the date is ignored.","Das Jahr vom Datum wird ignoriert." },
468{ "Timezone has daylight saving","Zeitzone hat Sommerzeit" }, 468{ "Timezone has daylight saving","Zeitzone hat Sommerzeit" },
469{ "Add 30 min to selected Timezone","Addiere 30 min zur Zeitzone" }, 469{ "Add 30 min to selected Timezone","Addiere 30 min zur Zeitzone" },
470{ "Used Mail Client","Benutzter Mail Client" }, 470{ "Used Mail Client","Benutzter Mail Client" },
471{ "Channel:","Channel:" }, 471{ "Channel:","Channel:" },
472{ "Message:","Message:" }, 472{ "Message:","Message:" },
473{ "Parameters:","Parameter:" }, 473{ "Parameters:","Parameter:" },
474{ "HINT: Delimiter=; Name=%1,Email=%2","Hinweis: Begrenzer=; Name=%1,Email=%2" }, 474{ "HINT: Delimiter=; Name=%1,Email=%2","Hinweis: Begrenzer=; Name=%1,Email=%2" },
475{ "extra Message:","extra Message:" }, 475{ "extra Message:","extra Message:" },
476{ "extra Parameters:","extra Parameter:" }, 476{ "extra Parameters:","extra Parameter:" },
477{ "HINT: Emails=%1,Attachments=%2","Hinweis: Emails=%1,Attachments=%2" }, 477{ "HINT: Emails=%1,Attachments=%2","Hinweis: Emails=%1,Attachments=%2" },
478{ "External Apps.","Externe Appl." }, 478{ "External Apps.","Externe Appl." },
479{ "Used %1 Client","Benutzer %1 Client" }, 479{ "Used %1 Client","Benutzer %1 Client" },
480{ "No email client installed","Keine Email Client installiert" }, 480{ "No email client installed","Keine Email Client installiert" },
481{ "Userdefined email client","Benutzerdef. Email Client" }, 481{ "Userdefined email client","Benutzerdef. Email Client" },
482{ "OM/Pi email client","OM/Pi Email Client" }, 482{ "OM/Pi email client","OM/Pi Email Client" },
483{ "Close KA/Pi?","Schließe KA/Pi?" }, 483{ "Close KA/Pi?","Schließe KA/Pi?" },
diff --git a/bin/kdepim/kopiemail/germantranslation.txt b/bin/kdepim/kopiemail/germantranslation.txt
index 903abdf..75fdd11 100644
--- a/bin/kdepim/kopiemail/germantranslation.txt
+++ b/bin/kdepim/kopiemail/germantranslation.txt
@@ -16,49 +16,49 @@
16{ "French","Französich" }, 16{ "French","Französich" },
17{ "Italian","Italienisch" }, 17{ "Italian","Italienisch" },
18{ "User defined (usertranslation.txt)","Benutzerdef.(usertranslation.txt)" }, 18{ "User defined (usertranslation.txt)","Benutzerdef.(usertranslation.txt)" },
19{ "Time Format(nr):","Zeit Format(Neustart!)" }, 19{ "Time Format(nr):","Zeit Format(Neustart!)" },
20{ "24:00","24:00" }, 20{ "24:00","24:00" },
21{ "12:00am","12:00am" }, 21{ "12:00am","12:00am" },
22{ "Week starts on Sunday","Woche beginnt Sonntags" }, 22{ "Week starts on Sunday","Woche beginnt Sonntags" },
23{ "Locale","Localisation" }, 23{ "Locale","Localisation" },
24{ "Date Format:","Datums Format:" }, 24{ "Date Format:","Datums Format:" },
25{ "24.03.2004 (%d.%m.%Y|%A %d %B %Y)","24.03.2004 (%d.%m.%Y|%A %d %B %Y)" }, 25{ "24.03.2004 (%d.%m.%Y|%A %d %B %Y)","24.03.2004 (%d.%m.%Y|%A %d %B %Y)" },
26{ "03.24.2004 (%m.%d.%Y|%A %B %d %Y)","03.24.2004 (%m.%d.%Y|%A %B %d %Y)" }, 26{ "03.24.2004 (%m.%d.%Y|%A %B %d %Y)","03.24.2004 (%m.%d.%Y|%A %B %d %Y)" },
27{ "2004-03-24 (%Y-%m-%d|%A %Y %B %d)","2004-03-24 (%Y-%m-%d|%A %Y %B %d)" }, 27{ "2004-03-24 (%Y-%m-%d|%A %Y %B %d)","2004-03-24 (%Y-%m-%d|%A %Y %B %d)" },
28{ "User defined","Benutzerdefiniert" }, 28{ "User defined","Benutzerdefiniert" },
29{ "User long date:","Format langes Datum:" }, 29{ "User long date:","Format langes Datum:" },
30{ "User short date:","Format kurzes Datum:" }, 30{ "User short date:","Format kurzes Datum:" },
31{ "Monday 19 April 2004: %A %d %B %Y","Montag 19 April 2004: %A %d %B %Y" }, 31{ "Monday 19 April 2004: %A %d %B %Y","Montag 19 April 2004: %A %d %B %Y" },
32{ "Mon 19.04.04: %a %d.%m.%y","Mon 19.04.04: %a %d.%m.%y" }, 32{ "Mon 19.04.04: %a %d.%m.%y","Mon 19.04.04: %a %d.%m.%y" },
33{ "Mon, 19.Apr.04: %a, %d.%b.%y","Mon, 19.Apr.04: %a, %d.%b.%y" }, 33{ "Mon, 19.Apr.04: %a, %d.%b.%y","Mon, 19.Apr.04: %a, %d.%b.%y" },
34{ "Date Format","Datums Format" }, 34{ "Date Format","Datums Format" },
35{ "Timezone:","Zeitzone:" }, 35{ "Timezone:","Zeitzone:" },
36{ "Add 30 min to selected Timezone","Addiere 30 min zur Zeitzone" }, 36{ "Add 30 min to selected Timezone","Addiere 30 min zur Zeitzone" },
37{ "Timezone has daylight saving","Zeitzone hat Sommerzeit" }, 37{ "Timezone has daylight saving","Zeitzone hat Sommerzeit" },
38{ "Actual start and end is the\nsunday before this date.","Tatsächlicher Beginn/Ende ist der\nSonntag vor diesem Datum!" }, 38{ "Actual start and end is the\nsunday before this date.","Tatsächlicher Beginn/Ende ist der\nSonntag vor diesem Datum!" },
39{ "The year in the date is ignored.","Das Jahr vom Datum wird ignoriert." }, 39{ "The year in the date is ignored.","Das Jahr vom Datum wird ignoriert." },
40{ "Daylight start:","Sommerzeit Beginn:" }, 40{ "Daylight start:","Sommerzeit Start:" },
41{ "Mon","Mo" }, 41{ "Mon","Mo" },
42{ "Tue","Di" }, 42{ "Tue","Di" },
43{ "Wed","Mi" }, 43{ "Wed","Mi" },
44{ "Thu","Do" }, 44{ "Thu","Do" },
45{ "Fri","Fr" }, 45{ "Fri","Fr" },
46{ "Sat","Sa" }, 46{ "Sat","Sa" },
47{ "Sun","So" }, 47{ "Sun","So" },
48{ "January","Januar" }, 48{ "January","Januar" },
49{ "February","Februar" }, 49{ "February","Februar" },
50{ "March","März" }, 50{ "March","März" },
51{ "April","April" }, 51{ "April","April" },
52{ "May","Mai" }, 52{ "May","Mai" },
53{ "June","Juni" }, 53{ "June","Juni" },
54{ "July","Juli" }, 54{ "July","Juli" },
55{ "August","August" }, 55{ "August","August" },
56{ "September","September" }, 56{ "September","September" },
57{ "October","Oktober" }, 57{ "October","Oktober" },
58{ "November","November" }, 58{ "November","November" },
59{ "December","Dezember" }, 59{ "December","Dezember" },
60{ "tomorrow","morgen" }, 60{ "tomorrow","morgen" },
61{ "today","heute" }, 61{ "today","heute" },
62{ "yesterday","gestern" }, 62{ "yesterday","gestern" },
63{ "Monday","Montag" }, 63{ "Monday","Montag" },
64{ "Tuesday","Dienstag" }, 64{ "Tuesday","Dienstag" },
diff --git a/bin/kdepim/korganizer/germantranslation.txt b/bin/kdepim/korganizer/germantranslation.txt
index 5693112..fa18304 100644
--- a/bin/kdepim/korganizer/germantranslation.txt
+++ b/bin/kdepim/korganizer/germantranslation.txt
@@ -424,49 +424,49 @@
424{ "View","Ansicht" }, 424{ "View","Ansicht" },
425{ "View Fonts","Schriftarten Ansichten" }, 425{ "View Fonts","Schriftarten Ansichten" },
426{ "Views","Ansichten" }, 426{ "Views","Ansichten" },
427{ "Wed","Mi" }, 427{ "Wed","Mi" },
428{ "Wednesday","Mittwoch" }, 428{ "Wednesday","Mittwoch" },
429{ "Week %1","Woche %1" }, 429{ "Week %1","Woche %1" },
430{ "Weekly","Wöchentlich" }, 430{ "Weekly","Wöchentlich" },
431{ "Week starts on Sunday","Woche beginnt Sonntags" }, 431{ "Week starts on Sunday","Woche beginnt Sonntags" },
432{ "What's Next View:","What's Next Anz." }, 432{ "What's Next View:","What's Next Anz." },
433{ "What's next ?","Was kommt als nächstes?(What's Next)" }, 433{ "What's next ?","Was kommt als nächstes?(What's Next)" },
434{ "Working Hours","Tägliche Arbeitszeit" }, 434{ "Working Hours","Tägliche Arbeitszeit" },
435{ "Working hours color:","Arbeitszeit in der Agenda Ansicht:" }, 435{ "Working hours color:","Arbeitszeit in der Agenda Ansicht:" },
436{ "Write back existing entries only","Nur exisitierende Einträge zurückschreiben" }, 436{ "Write back existing entries only","Nur exisitierende Einträge zurückschreiben" },
437{ "Write back synced file","Syncronisierte Datei zurückschreiben" }, 437{ "Write back synced file","Syncronisierte Datei zurückschreiben" },
438{ "Yearly","Jährlich" }, 438{ "Yearly","Jährlich" },
439{ "year(s)","Jahr(e)" }, 439{ "year(s)","Jahr(e)" },
440{ "Yes","Ja" }, 440{ "Yes","Ja" },
441{ "You have %d item(s) selected.\n","Sie haben %d Einträge ausgewählt.\n" }, 441{ "You have %d item(s) selected.\n","Sie haben %d Einträge ausgewählt.\n" },
442{ "You have to restart KOrganizer for this setting to take effect.","Sie müssem Korganizer neu starten, damit diese Einstellung aktiviert wird." }, 442{ "You have to restart KOrganizer for this setting to take effect.","Sie müssem Korganizer neu starten, damit diese Einstellung aktiviert wird." },
443{ "week(s) on:","Woche(n) am: " }, 443{ "week(s) on:","Woche(n) am: " },
444{ "Full menu bar(nr)","Volle Menuleiste(bn)" }, 444{ "Full menu bar(nr)","Volle Menuleiste(bn)" },
445{ "Timezone has daylight saving","Zeitzone hat Sommerzeit" }, 445{ "Timezone has daylight saving","Zeitzone hat Sommerzeit" },
446{ "Actual start and end is the\nsunday before this date.","Tatsächlicher Beginn/Ende ist der\nSonntag vor diesem Datum!" }, 446{ "Actual start and end is the\nsunday before this date.","Tatsächlicher Beginn/Ende ist der\nSonntag vor diesem Datum!" },
447{ "The year in the date is ignored.","Das Jahr vom Datum wird ignoriert." }, 447{ "The year in the date is ignored.","Das Jahr vom Datum wird ignoriert." },
448{ "Daylight start:","Sommerzeit Beginn:" }, 448{ "Daylight start:","Sommerzeit Start:" },
449{ "Daylight end:","Sommerzeit Ende:" }, 449{ "Daylight end:","Sommerzeit Ende:" },
450{ "Time Zone","Zeitzone" }, 450{ "Time Zone","Zeitzone" },
451{ "Monday 19 April 2004: %A %d %B %Y","Montag 19 April 2004: %A %d %B %Y" }, 451{ "Monday 19 April 2004: %A %d %B %Y","Montag 19 April 2004: %A %d %B %Y" },
452{ "%A: Monday --- %a: Mon","%A: Montag --- %a: Mon" }, 452{ "%A: Monday --- %a: Mon","%A: Montag --- %a: Mon" },
453{ "minutely","minütlich" }, 453{ "minutely","minütlich" },
454{ "hourly","stündlich" }, 454{ "hourly","stündlich" },
455{ "daily","täglich" }, 455{ "daily","täglich" },
456{ "weekly","wöchentlich" }, 456{ "weekly","wöchentlich" },
457{ "monthly","monatlich" }, 457{ "monthly","monatlich" },
458{ "day-monthly","tag-monatlich" }, 458{ "day-monthly","tag-monatlich" },
459{ "month-yearly","monat-jährlich" }, 459{ "month-yearly","monat-jährlich" },
460{ "day-yearly","tag-jährlich" }, 460{ "day-yearly","tag-jährlich" },
461{ "position-yearly","pos-jährlich" }, 461{ "position-yearly","pos-jährlich" },
462{ "Edit item on doubleclick (if not, show)","Editiere mit Doppelklick(wenn nicht, zeige)" }, 462{ "Edit item on doubleclick (if not, show)","Editiere mit Doppelklick(wenn nicht, zeige)" },
463{ "Highlight current day in agenda","Hebe >>heute<< in Agenda hervor" }, 463{ "Highlight current day in agenda","Hebe >>heute<< in Agenda hervor" },
464{ "Use light color for highlight current day","Helle Farbe für >>heute<< Hervorhebung" }, 464{ "Use light color for highlight current day","Helle Farbe für >>heute<< Hervorhebung" },
465{ "Highlight selection in Time Edit","Hebe Auswahl in Zeit Edit hervor" }, 465{ "Highlight selection in Time Edit","Hebe Auswahl in Zeit Edit hervor" },
466{ "Hold fullscreen on view change","Behalte Vollbild bei Ansichswechsel" }, 466{ "Hold fullscreen on view change","Behalte Vollbild bei Ansichswechsel" },
467{ "Hold non-fullscreen on view change","Behalte Nicht-Vollbild bei Ansichtsw." }, 467{ "Hold non-fullscreen on view change","Behalte Nicht-Vollbild bei Ansichtsw." },
468{ "Event list view uses full window","Listenansicht nutzt Vollbild" }, 468{ "Event list view uses full window","Listenansicht nutzt Vollbild" },
469{ "Set agenda to DayBeginsAt on change","Setze Agenda auf TagBeginntUm bei Wechsel" }, 469{ "Set agenda to DayBeginsAt on change","Setze Agenda auf TagBeginntUm bei Wechsel" },
470{ "Set agenda to current time on change","Setze Agenda auf gegenw.Zeit bei Wechsel" }, 470{ "Set agenda to current time on change","Setze Agenda auf gegenw.Zeit bei Wechsel" },
471{ "Listview uses monthly timespan","Listenansicht zeigt monatliche Zeitspanne" }, 471{ "Listview uses monthly timespan","Listenansicht zeigt monatliche Zeitspanne" },
472{ "ViewChange","Ansichtswechsel" }, 472{ "ViewChange","Ansichtswechsel" },
diff --git a/bin/kdepim/pwmanager/germantranslation.txt b/bin/kdepim/pwmanager/germantranslation.txt
index beb066e..a50dd04 100644
--- a/bin/kdepim/pwmanager/germantranslation.txt
+++ b/bin/kdepim/pwmanager/germantranslation.txt
@@ -112,49 +112,49 @@
112{ "Italian","Italienisch" }, 112{ "Italian","Italienisch" },
113{ "User defined (usertranslation.txt)","Benutzerdef. (usertranslation.txt)" }, 113{ "User defined (usertranslation.txt)","Benutzerdef. (usertranslation.txt)" },
114{ "Language","Sprache" }, 114{ "Language","Sprache" },
115{ "Time Format(nr):","Zeit Format(nr):" }, 115{ "Time Format(nr):","Zeit Format(nr):" },
116{ "24:00","24:00" }, 116{ "24:00","24:00" },
117{ "12:00am","12:00am" }, 117{ "12:00am","12:00am" },
118{ "Week starts on Sunday","Woche beginnt Sonntags" }, 118{ "Week starts on Sunday","Woche beginnt Sonntags" },
119{ "Time Format","Zeit Format" }, 119{ "Time Format","Zeit Format" },
120{ "Date Format:","Datums Format:" }, 120{ "Date Format:","Datums Format:" },
121{ "24.03.2004 (%d.%m.%Y|%A %d %B %Y)","24.03.2004 (%d.%m.%Y|%A %d %B %Y)" }, 121{ "24.03.2004 (%d.%m.%Y|%A %d %B %Y)","24.03.2004 (%d.%m.%Y|%A %d %B %Y)" },
122{ "03.24.2004 (%m.%d.%Y|%A %B %d %Y)","03.24.2004 (%m.%d.%Y|%A %B %d %Y)" }, 122{ "03.24.2004 (%m.%d.%Y|%A %B %d %Y)","03.24.2004 (%m.%d.%Y|%A %B %d %Y)" },
123{ "2004-03-24 (%Y-%m-%d|%A %Y %B %d)","2004-03-24 (%Y-%m-%d|%A %Y %B %d)" }, 123{ "2004-03-24 (%Y-%m-%d|%A %Y %B %d)","2004-03-24 (%Y-%m-%d|%A %Y %B %d)" },
124{ "User defined","Benutzerdefiniert" }, 124{ "User defined","Benutzerdefiniert" },
125{ "User long date:","Format langes Datum:" }, 125{ "User long date:","Format langes Datum:" },
126{ "User short date:","Format kurzes Datum:" }, 126{ "User short date:","Format kurzes Datum:" },
127{ "Monday 19 April 2004: %A %d %B %Y","Monday 19 April 2004: %A %d %B %Y" }, 127{ "Monday 19 April 2004: %A %d %B %Y","Monday 19 April 2004: %A %d %B %Y" },
128{ "Mon 19.04.04: %a %d.%m.%y","Mon 19.04.04: %a %d.%m.%y" }, 128{ "Mon 19.04.04: %a %d.%m.%y","Mon 19.04.04: %a %d.%m.%y" },
129{ "Mon, 19.Apr.04: %a, %d.%b.%y","Mon, 19.Apr.04: %a, %d.%b.%y" }, 129{ "Mon, 19.Apr.04: %a, %d.%b.%y","Mon, 19.Apr.04: %a, %d.%b.%y" },
130{ "Date Format","Datums Format" }, 130{ "Date Format","Datums Format" },
131{ "Timezone:","Zeitzone:" }, 131{ "Timezone:","Zeitzone:" },
132{ "Add 30 min to selected Timezone","Addiere 30 min zur Zeitzone" }, 132{ "Add 30 min to selected Timezone","Addiere 30 min zur Zeitzone" },
133{ "Timezone has daylight saving","Zeitzone hat Sommerzeit" }, 133{ "Timezone has daylight saving","Zeitzone hat Sommerzeit" },
134{ "Actual start and end is the\nsunday before this date.","Tatsächlicher Beginn/Ende ist der\nSonntag vor diesem Datum!" }, 134{ "Actual start and end is the\nsunday before this date.","Tatsächlicher Beginn/Ende ist der\nSonntag vor diesem Datum!" },
135{ "The year in the date is ignored.","Das Jahr vom Datum wird ignoriert." }, 135{ "The year in the date is ignored.","Das Jahr vom Datum wird ignoriert." },
136{ "Daylight start:","Sommerzeit Beginn:" }, 136{ "Daylight start:","Sommerzeit Start:" },
137{ "Mon","Mo" }, 137{ "Mon","Mo" },
138{ "Tue","Di" }, 138{ "Tue","Di" },
139{ "Wed","Mi" }, 139{ "Wed","Mi" },
140{ "Thu","Do" }, 140{ "Thu","Do" },
141{ "Fri","Fr" }, 141{ "Fri","Fr" },
142{ "Sat","Sa" }, 142{ "Sat","Sa" },
143{ "Sun","So" }, 143{ "Sun","So" },
144{ "January","Januar" }, 144{ "January","Januar" },
145{ "February","Februar" }, 145{ "February","Februar" },
146{ "March","März" }, 146{ "March","März" },
147{ "April","April" }, 147{ "April","April" },
148{ "May","Mai" }, 148{ "May","Mai" },
149{ "June","Juni" }, 149{ "June","Juni" },
150{ "July","July" }, 150{ "July","July" },
151{ "August","August" }, 151{ "August","August" },
152{ "September","September" }, 152{ "September","September" },
153{ "October","October" }, 153{ "October","October" },
154{ "November","November" }, 154{ "November","November" },
155{ "December","Dezember" }, 155{ "December","Dezember" },
156{ "tomorrow","Morgen" }, 156{ "tomorrow","Morgen" },
157{ "today","Heute" }, 157{ "today","Heute" },
158{ "yesterday","Gestern" }, 158{ "yesterday","Gestern" },
159{ "Monday","Montag" }, 159{ "Monday","Montag" },
160{ "Tuesday","Dienstag" }, 160{ "Tuesday","Dienstag" },
diff --git a/korganizer/kodaymatrix.cpp b/korganizer/kodaymatrix.cpp
index df606d0..c32a2a4 100644
--- a/korganizer/kodaymatrix.cpp
+++ b/korganizer/kodaymatrix.cpp
@@ -42,95 +42,93 @@
42#include <kcalendarsystem.h> 42#include <kcalendarsystem.h>
43 43
44#ifndef KORG_NOPLUGINS 44#ifndef KORG_NOPLUGINS
45#include "kocore.h" 45#include "kocore.h"
46#endif 46#endif
47#include "koprefs.h" 47#include "koprefs.h"
48#include "koglobals.h" 48#include "koglobals.h"
49 49
50#include "kodaymatrix.h" 50#include "kodaymatrix.h"
51 51
52// ============================================================================ 52// ============================================================================
53// D Y N A M I C T I P 53// D Y N A M I C T I P
54// ============================================================================ 54// ============================================================================
55 55
56DynamicTip::DynamicTip( QWidget * parent ) 56DynamicTip::DynamicTip( QWidget * parent )
57 : QToolTip( parent ) 57 : QToolTip( parent )
58{ 58{
59 matrix = (KODayMatrix*)parent; 59 matrix = (KODayMatrix*)parent;
60} 60}
61 61
62class KODaymatrixWhatsThis :public QWhatsThis 62class KODaymatrixWhatsThis :public QWhatsThis
63{ 63{
64public: 64public:
65 KODaymatrixWhatsThis( KODayMatrix* view ) : QWhatsThis( view ),_view (view) { ;}; 65 KODaymatrixWhatsThis( KODayMatrix* view ) : QWhatsThis( view ),_view (view) { ;};
66 ~KODaymatrixWhatsThis() { ; }; 66 ~KODaymatrixWhatsThis() { qDebug("DELETE KODaymatrixWhatsThis "); };
67 67
68protected: 68protected:
69 virtual QString text( const QPoint& p ) 69 virtual QString text( const QPoint& p )
70 { 70 {
71 return _view->getWhatsThisText( p ) ; 71 return _view->getWhatsThisText( p ) ;
72 } 72 }
73private: 73private:
74 KODayMatrix * _view; 74 KODayMatrix * _view;
75}; 75};
76 76
77void DynamicTip::maybeTip( const QPoint &pos ) 77void DynamicTip::maybeTip( const QPoint &pos )
78{ 78{
79 //calculate which cell of the matrix the mouse is in 79 //calculate which cell of the matrix the mouse is in
80 QRect sz = matrix->frameRect(); 80 QRect sz = matrix->frameRect();
81 int dheight = sz.height()*7 / 42; 81 int dheight = sz.height()*7 / 42;
82 int dwidth = sz.width() / 7; 82 int dwidth = sz.width() / 7;
83 int row = pos.y()/dheight; 83 int row = pos.y()/dheight;
84 int col = pos.x()/dwidth; 84 int col = pos.x()/dwidth;
85 85
86 QRect rct(col*dwidth, row*dheight, dwidth, dheight); 86 QRect rct(col*dwidth, row*dheight, dwidth, dheight);
87 87
88// kdDebug() << "DynamicTip::maybeTip matrix cell index [" << 88// kdDebug() << "DynamicTip::maybeTip matrix cell index [" <<
89// col << "][" << row << "] => " <<(col+row*7) << endl; 89// col << "][" << row << "] => " <<(col+row*7) << endl;
90 90
91 //show holiday names only 91 //show holiday names only
92 QString str = matrix->getHolidayLabel(col+row*7); 92 QString str = matrix->getHolidayLabel(col+row*7);
93 if (str.isEmpty()) return; 93 if (str.isEmpty()) return;
94 tip(rct, str); 94 tip(rct, str);
95} 95}
96 96
97 97
98// ============================================================================ 98// ============================================================================
99// K O D A Y M A T R I X 99// K O D A Y M A T R I X
100// ============================================================================ 100// ============================================================================
101 101
102const int KODayMatrix::NOSELECTION = -1000; 102const int KODayMatrix::NOSELECTION = -1000;
103const int KODayMatrix::NUMDAYS = 42; 103const int KODayMatrix::NUMDAYS = 42;
104 104
105KODayMatrix::KODayMatrix( QWidget *parent, const char *name ) 105KODayMatrix::KODayMatrix( QWidget *parent, const char *name )
106 : QFrame( parent, name , Qt::WRepaintNoErase ), mCalendar( 0 ) 106 : QFrame( parent, name , Qt::WRepaintNoErase ), mCalendar( 0 )
107 107
108#if 0 108
109KODayMatrix::KODayMatrix(QWidget *parent, Calendar* calendar, QDate date, const char *name) :
110 QFrame(parent, name)
111#endif
112{ 109{
110 mLastView = -1;
113 oldW = 0; 111 oldW = 0;
114 oldH = 0; 112 oldH = 0;
115 myPix.resize( 150, 120 ); 113 myPix.resize( 150, 120 );
116 mRedrawNeeded = true; 114 mRedrawNeeded = true;
117 mKODaymatrixWhatsThis = new KODaymatrixWhatsThis(this); 115 mKODaymatrixWhatsThis = new KODaymatrixWhatsThis(this);
118 mPendingUpdateBeforeRepaint = false; 116 mPendingUpdateBeforeRepaint = false;
119 mouseDown = false; 117 mouseDown = false;
120 // initialize dynamic arrays 118 // initialize dynamic arrays
121 bDays.resize ( NUMDAYS ); 119 bDays.resize ( NUMDAYS );
122 pDays.resize ( NUMDAYS ); 120 pDays.resize ( NUMDAYS );
123 hDays.resize ( NUMDAYS ); 121 hDays.resize ( NUMDAYS );
124 eDays.resize ( NUMDAYS ); 122 eDays.resize ( NUMDAYS );
125 days = new QDate[NUMDAYS]; 123 days = new QDate[NUMDAYS];
126 daylbls = new QString[NUMDAYS]; 124 daylbls = new QString[NUMDAYS];
127 //events = new int[NUMDAYS]; 125 //events = new int[NUMDAYS];
128 mToolTip = new DynamicTip(this); 126 mToolTip = new DynamicTip(this);
129 127
130 // set default values used for drawing the matrix 128 // set default values used for drawing the matrix
131 mDefaultBackColor = palette().active().base(); 129 mDefaultBackColor = palette().active().base();
132 mDefaultTextColor = palette().active().foreground(); 130 mDefaultTextColor = palette().active().foreground();
133 mDefaultTextColorShaded = getShadedColor(mDefaultTextColor); 131 mDefaultTextColorShaded = getShadedColor(mDefaultTextColor);
134 mHolidayColorShaded = getShadedColor(KOPrefs::instance()->mHolidayColor); 132 mHolidayColorShaded = getShadedColor(KOPrefs::instance()->mHolidayColor);
135 mSelectedDaysColor = QColor("white"); 133 mSelectedDaysColor = QColor("white");
136 mTodayMarginWidth = 2; 134 mTodayMarginWidth = 2;
@@ -223,48 +221,54 @@ void KODayMatrix::setCalendar( Calendar *cal )
223{ 221{
224 mCalendar = cal; 222 mCalendar = cal;
225 223
226 setAcceptDrops( mCalendar ); 224 setAcceptDrops( mCalendar );
227 225
228 updateEvents(); 226 updateEvents();
229} 227}
230 228
231QColor KODayMatrix::getShadedColor(QColor color) 229QColor KODayMatrix::getShadedColor(QColor color)
232{ 230{
233 QColor shaded; 231 QColor shaded;
234 int h=0; 232 int h=0;
235 int s=0; 233 int s=0;
236 int v=0; 234 int v=0;
237 color.hsv(&h,&s,&v); 235 color.hsv(&h,&s,&v);
238 s = s/4; 236 s = s/4;
239 v = 192+v/4; 237 v = 192+v/4;
240 shaded.setHsv(h,s,v); 238 shaded.setHsv(h,s,v);
241 239
242 return shaded; 240 return shaded;
243} 241}
244 242
245KODayMatrix::~KODayMatrix() 243KODayMatrix::~KODayMatrix()
246{ 244{
245#if QT_VERSION >= 0x030000
246
247#else
248 delete mKODaymatrixWhatsThis;
249#endif
250
247 // delete mKODaymatrixWhatsThis; 251 // delete mKODaymatrixWhatsThis;
248 delete [] days; 252 delete [] days;
249 delete [] daylbls; 253 delete [] daylbls;
250 //delete [] events; 254 //delete [] events;
251 delete mToolTip; 255 delete mToolTip;
252} 256}
253 257
254/* 258/*
255void KODayMatrix::setStartDate(QDate start) 259void KODayMatrix::setStartDate(QDate start)
256{ 260{
257 updateView(start); 261 updateView(start);
258} 262}
259*/ 263*/
260 264
261void KODayMatrix::addSelectedDaysTo(DateList& selDays) 265void KODayMatrix::addSelectedDaysTo(DateList& selDays)
262{ 266{
263 267
264 if (mSelStart == NOSELECTION) { 268 if (mSelStart == NOSELECTION) {
265 return; 269 return;
266 } 270 }
267 271
268 //cope with selection being out of matrix limits at top (< 0) 272 //cope with selection being out of matrix limits at top (< 0)
269 int i0 = mSelStart; 273 int i0 = mSelStart;
270 if (i0 < 0) { 274 if (i0 < 0) {
diff --git a/korganizer/koprefsdialog.cpp b/korganizer/koprefsdialog.cpp
index d9d7924..e4bee63 100644
--- a/korganizer/koprefsdialog.cpp
+++ b/korganizer/koprefsdialog.cpp
@@ -1007,52 +1007,48 @@ dummy =
1007#endif 1007#endif
1008 1008
1009 QHBox* dummyBox = new QHBox(topFrame); 1009 QHBox* dummyBox = new QHBox(topFrame);
1010 new QLabel(i18n("Play beeps count:"),dummyBox); 1010 new QLabel(i18n("Play beeps count:"),dummyBox);
1011 mAlarmPlayBeeps = new QSpinBox(0,500,1,dummyBox); 1011 mAlarmPlayBeeps = new QSpinBox(0,500,1,dummyBox);
1012 topLayout->addWidget(dummyBox,iii++,0); 1012 topLayout->addWidget(dummyBox,iii++,0);
1013 1013
1014 dummyBox = new QHBox(topFrame); 1014 dummyBox = new QHBox(topFrame);
1015 new QLabel(i18n("Beeps interval in sec:"),dummyBox); 1015 new QLabel(i18n("Beeps interval in sec:"),dummyBox);
1016 mAlarmBeepInterval = new QSpinBox(1,600,1,dummyBox); 1016 mAlarmBeepInterval = new QSpinBox(1,600,1,dummyBox);
1017 topLayout->addWidget(dummyBox,iii++,0); 1017 topLayout->addWidget(dummyBox,iii++,0);
1018 1018
1019 dummyBox = new QHBox(topFrame); 1019 dummyBox = new QHBox(topFrame);
1020 new QLabel(i18n("Default suspend time in min:"),dummyBox); 1020 new QLabel(i18n("Default suspend time in min:"),dummyBox);
1021 mAlarmSuspendTime = new QSpinBox(1,600,1,dummyBox); 1021 mAlarmSuspendTime = new QSpinBox(1,600,1,dummyBox);
1022 topLayout->addWidget(dummyBox,iii++,0); 1022 topLayout->addWidget(dummyBox,iii++,0);
1023 1023
1024 dummyBox = new QHBox(topFrame); 1024 dummyBox = new QHBox(topFrame);
1025 new QLabel(i18n("Auto suspend count:"),dummyBox); 1025 new QLabel(i18n("Auto suspend count:"),dummyBox);
1026 mAlarmSuspendCount = new QSpinBox(0,60,1,dummyBox); 1026 mAlarmSuspendCount = new QSpinBox(0,60,1,dummyBox);
1027 topLayout->addWidget(dummyBox,iii++,0); 1027 topLayout->addWidget(dummyBox,iii++,0);
1028 1028
1029 1029
1030 1030
1031
1032
1033
1034
1035 QHBox* hbo = new QHBox ( topFrame ); 1031 QHBox* hbo = new QHBox ( topFrame );
1036 mDefaultAlarmFile = new QLineEdit(hbo); 1032 mDefaultAlarmFile = new QLineEdit(hbo);
1037 QPushButton * loadTemplate = new QPushButton(hbo); 1033 QPushButton * loadTemplate = new QPushButton(hbo);
1038 QPixmap icon; 1034 QPixmap icon;
1039 if ( QApplication::desktop()->width() < 321 ) 1035 if ( QApplication::desktop()->width() < 321 )
1040 icon = SmallIcon("fileimport16"); 1036 icon = SmallIcon("fileimport16");
1041 else 1037 else
1042 icon = SmallIcon("fileimport"); 1038 icon = SmallIcon("fileimport");
1043 loadTemplate->setIconSet (icon ) ; 1039 loadTemplate->setIconSet (icon ) ;
1044 connect( loadTemplate, SIGNAL( clicked() ), this , SLOT( selectSoundFile() ) ); 1040 connect( loadTemplate, SIGNAL( clicked() ), this , SLOT( selectSoundFile() ) );
1045 int size = loadTemplate->sizeHint().height(); 1041 int size = loadTemplate->sizeHint().height();
1046 loadTemplate->setFixedSize( size, size ); 1042 loadTemplate->setFixedSize( size, size );
1047 //lab = new QLabel( i18n("This setting is useless for 5500 user!"), topFrame); 1043 //lab = new QLabel( i18n("This setting is useless for 5500 user!"), topFrame);
1048 // topLayout->addWidget(lab ,iii++,0); 1044 // topLayout->addWidget(lab ,iii++,0);
1049 lab = new QLabel( i18n("Alarm *.wav file for newly created alarm:"), topFrame); 1045 lab = new QLabel( i18n("Alarm *.wav file for newly created alarm:"), topFrame);
1050 topLayout->addWidget(lab ,iii++,0); 1046 topLayout->addWidget(lab ,iii++,0);
1051 topLayout->addWidget(hbo,iii++,0); 1047 topLayout->addWidget(hbo,iii++,0);
1052 // lab = new QLabel( i18n("Note: This does not mean, that for every alarm this file is replayed. This file here is associated with a newly created alarm."), topFrame); 1048 // lab = new QLabel( i18n("Note: This does not mean, that for every alarm this file is replayed. This file here is associated with a newly created alarm."), topFrame);
1053 1049
1054// topLayout->addWidget(lab ,iii++,0); 1050// topLayout->addWidget(lab ,iii++,0);
1055// #ifndef DESKTOP_VERSION 1051// #ifndef DESKTOP_VERSION
1056// lab->setAlignment( AlignLeft|WordBreak|AlignTop); 1052// lab->setAlignment( AlignLeft|WordBreak|AlignTop);
1057// #else 1053// #else
1058// lab->setAlignment( AlignLeft|BreakAnywhere|WordBreak|AlignTop); 1054// lab->setAlignment( AlignLeft|BreakAnywhere|WordBreak|AlignTop);
diff --git a/libkcal/icalformatimpl.cpp b/libkcal/icalformatimpl.cpp
index fe7413f..2405682 100644
--- a/libkcal/icalformatimpl.cpp
+++ b/libkcal/icalformatimpl.cpp
@@ -674,73 +674,76 @@ icalproperty *ICalFormatImpl::writeRecurrenceRule(Recurrence *recur)
674 kdDebug(5800) << " String: " << str << endl; 674 kdDebug(5800) << " String: " << str << endl;
675 } else { 675 } else {
676 kdDebug(5800) << " No String" << endl; 676 kdDebug(5800) << " No String" << endl;
677 } 677 }
678#endif 678#endif
679 679
680 return icalproperty_new_rrule(r); 680 return icalproperty_new_rrule(r);
681} 681}
682 682
683icalcomponent *ICalFormatImpl::writeAlarm(Alarm *alarm) 683icalcomponent *ICalFormatImpl::writeAlarm(Alarm *alarm)
684{ 684{
685 icalcomponent *a = icalcomponent_new(ICAL_VALARM_COMPONENT); 685 icalcomponent *a = icalcomponent_new(ICAL_VALARM_COMPONENT);
686 686
687 icalproperty_action action; 687 icalproperty_action action;
688 icalattach *attach = 0; 688 icalattach *attach = 0;
689 689
690 switch (alarm->type()) { 690 switch (alarm->type()) {
691 case Alarm::Procedure: 691 case Alarm::Procedure:
692 action = ICAL_ACTION_PROCEDURE; 692 action = ICAL_ACTION_PROCEDURE;
693 attach = icalattach_new_from_url( QFile::encodeName(alarm->programFile()).data() ); 693 attach = icalattach_new_from_url( QFile::encodeName(alarm->programFile()).data() );
694 icalcomponent_add_property(a,icalproperty_new_attach(attach)); 694 icalcomponent_add_property(a,icalproperty_new_attach(attach));
695 if (!alarm->programArguments().isEmpty()) { 695 if (!alarm->programArguments().isEmpty()) {
696 icalcomponent_add_property(a,icalproperty_new_description(alarm->programArguments().utf8())); 696 icalcomponent_add_property(a,icalproperty_new_description(alarm->programArguments().utf8()));
697 } 697 }
698 icalattach_unref( attach );
698 break; 699 break;
699 case Alarm::Audio: 700 case Alarm::Audio:
700 action = ICAL_ACTION_AUDIO; 701 action = ICAL_ACTION_AUDIO;
701 if (!alarm->audioFile().isEmpty()) { 702 if (!alarm->audioFile().isEmpty()) {
702 attach = icalattach_new_from_url(QFile::encodeName( alarm->audioFile() ).data()); 703 attach = icalattach_new_from_url(QFile::encodeName( alarm->audioFile() ).data());
703 icalcomponent_add_property(a,icalproperty_new_attach(attach)); 704 icalcomponent_add_property(a,icalproperty_new_attach(attach));
705 icalattach_unref( attach );
704 } 706 }
705 break; 707 break;
706 case Alarm::Email: { 708 case Alarm::Email: {
707 action = ICAL_ACTION_EMAIL; 709 action = ICAL_ACTION_EMAIL;
708 QValueList<Person> addresses = alarm->mailAddresses(); 710 QValueList<Person> addresses = alarm->mailAddresses();
709 for (QValueList<Person>::Iterator ad = addresses.begin(); ad != addresses.end(); ++ad) { 711 for (QValueList<Person>::Iterator ad = addresses.begin(); ad != addresses.end(); ++ad) {
710 icalproperty *p = icalproperty_new_attendee("MAILTO:" + (*ad).email().utf8()); 712 icalproperty *p = icalproperty_new_attendee("MAILTO:" + (*ad).email().utf8());
711 if (!(*ad).name().isEmpty()) { 713 if (!(*ad).name().isEmpty()) {
712 icalproperty_add_parameter(p,icalparameter_new_cn((*ad).name().utf8())); 714 icalproperty_add_parameter(p,icalparameter_new_cn((*ad).name().utf8()));
713 } 715 }
714 icalcomponent_add_property(a,p); 716 icalcomponent_add_property(a,p);
715 } 717 }
716 icalcomponent_add_property(a,icalproperty_new_summary(alarm->mailSubject().utf8())); 718 icalcomponent_add_property(a,icalproperty_new_summary(alarm->mailSubject().utf8()));
717 icalcomponent_add_property(a,icalproperty_new_description(alarm->text().utf8())); 719 icalcomponent_add_property(a,icalproperty_new_description(alarm->text().utf8()));
718 QStringList attachments = alarm->mailAttachments(); 720 QStringList attachments = alarm->mailAttachments();
719 if (attachments.count() > 0) { 721 if (attachments.count() > 0) {
720 for (QStringList::Iterator at = attachments.begin(); at != attachments.end(); ++at) { 722 for (QStringList::Iterator at = attachments.begin(); at != attachments.end(); ++at) {
721 attach = icalattach_new_from_url(QFile::encodeName( *at ).data()); 723 attach = icalattach_new_from_url(QFile::encodeName( *at ).data());
722 icalcomponent_add_property(a,icalproperty_new_attach(attach)); 724 icalcomponent_add_property(a,icalproperty_new_attach(attach));
725 icalattach_unref( attach );
723 } 726 }
724 } 727 }
725 break; 728 break;
726 } 729 }
727 case Alarm::Display: 730 case Alarm::Display:
728 action = ICAL_ACTION_DISPLAY; 731 action = ICAL_ACTION_DISPLAY;
729 icalcomponent_add_property(a,icalproperty_new_description(alarm->text().utf8())); 732 icalcomponent_add_property(a,icalproperty_new_description(alarm->text().utf8()));
730 break; 733 break;
731 case Alarm::Invalid: 734 case Alarm::Invalid:
732 default: 735 default:
733 kdDebug(5800) << "Unknown type of alarm" << endl; 736 kdDebug(5800) << "Unknown type of alarm" << endl;
734 action = ICAL_ACTION_NONE; 737 action = ICAL_ACTION_NONE;
735 break; 738 break;
736 } 739 }
737 icalcomponent_add_property(a,icalproperty_new_action(action)); 740 icalcomponent_add_property(a,icalproperty_new_action(action));
738 741
739 // Trigger time 742 // Trigger time
740 icaltriggertype trigger; 743 icaltriggertype trigger;
741 if ( alarm->hasTime() ) { 744 if ( alarm->hasTime() ) {
742 trigger.time = writeICalDateTime(alarm->time()); 745 trigger.time = writeICalDateTime(alarm->time());
743 trigger.duration = icaldurationtype_null_duration(); 746 trigger.duration = icaldurationtype_null_duration();
744 } else { 747 } else {
745 trigger.time = icaltime_null_time(); 748 trigger.time = icaltime_null_time();
746 Duration offset; 749 Duration offset;
diff --git a/libkdepim/kcmconfigs/kdepimconfigwidget.cpp b/libkdepim/kcmconfigs/kdepimconfigwidget.cpp
index 753d90a..fbfbc45 100644
--- a/libkdepim/kcmconfigs/kdepimconfigwidget.cpp
+++ b/libkdepim/kcmconfigs/kdepimconfigwidget.cpp
@@ -14,56 +14,59 @@
14 14
15 You should have received a copy of the GNU General Public License 15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software 16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 17 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
18 18
19 As a special exception, permission is given to link this program 19 As a special exception, permission is given to link this program
20 with any edition of Qt, and distribute the resulting executable, 20 with any edition of Qt, and distribute the resulting executable,
21 without including the source code for Qt in the source distribution. 21 without including the source code for Qt in the source distribution.
22*/ 22*/
23 23
24/* 24/*
25Enhanced Version of the file for platform independent KDE tools. 25Enhanced Version of the file for platform independent KDE tools.
26Copyright (c) 2004 Ulf Schenk 26Copyright (c) 2004 Ulf Schenk
27 27
28$Id$ 28$Id$
29*/ 29*/
30 30
31#include <qlayout.h> 31#include <qlayout.h>
32#include <qtabwidget.h> 32#include <qtabwidget.h>
33#include <qcombobox.h> 33#include <qcombobox.h>
34#include <qgroupbox.h> 34#include <qgroupbox.h>
35#include <qlabel.h> 35#include <qlabel.h>
36#include <qlineedit.h> 36#include <qlineedit.h>
37#include <qbuttongroup.h> 37#include <qbuttongroup.h>
38#include <qcheckbox.h>
38#include <qfile.h> 39#include <qfile.h>
39#include <qvbox.h> 40#include <qvbox.h>
40#include <qdir.h> 41#include <qdir.h>
41#include <qregexp.h> 42#include <qregexp.h>
43#include <qspinbox.h>
42 44
43#include <kdialog.h> 45#include <kdialog.h>
44#include <kprefsdialog.h> 46#include <kprefsdialog.h>
45#include <klocale.h> 47#include <klocale.h>
48#include <kglobalsettings.h>
46#include <kdateedit.h> 49#include <kdateedit.h>
47#include <kglobal.h> 50#include <kglobal.h>
48#include <stdlib.h> 51#include <stdlib.h>
49 52
50/*US 53/*US
51#include <qcheckbox.h> 54#include <qcheckbox.h>
52#include <qframe.h> 55#include <qframe.h>
53#include <qpushbutton.h> 56#include <qpushbutton.h>
54#include <qcombobox.h> 57#include <qcombobox.h>
55#include <qlineedit.h> 58#include <qlineedit.h>
56#include <qlabel.h> 59#include <qlabel.h>
57#include <qfile.h> 60#include <qfile.h>
58 61
59#include <kconfig.h> 62#include <kconfig.h>
60#include <kdebug.h> 63#include <kdebug.h>
61#include <kdialog.h> 64#include <kdialog.h>
62#include <klistview.h> 65#include <klistview.h>
63#include <klocale.h> 66#include <klocale.h>
64#include <kglobal.h> 67#include <kglobal.h>
65#include <kmessagebox.h> 68#include <kmessagebox.h>
66#include <kstandarddirs.h> 69#include <kstandarddirs.h>
67 70
68#ifndef KAB_EMBEDDED 71#ifndef KAB_EMBEDDED
69#include <ktrader.h> 72#include <ktrader.h>
@@ -88,54 +91,90 @@ $Id$
88 91
89KDEPIMConfigWidget::KDEPIMConfigWidget(KPimGlobalPrefs *prefs, QWidget *parent, const char *name ) 92KDEPIMConfigWidget::KDEPIMConfigWidget(KPimGlobalPrefs *prefs, QWidget *parent, const char *name )
90 : KPrefsWidget(prefs, parent, name ) 93 : KPrefsWidget(prefs, parent, name )
91{ 94{
92 mExternalAppsMap.insert(ExternalAppHandler::EMAIL, i18n("Email")); 95 mExternalAppsMap.insert(ExternalAppHandler::EMAIL, i18n("Email"));
93 mExternalAppsMap.insert(ExternalAppHandler::PHONE, i18n("Phone")); 96 mExternalAppsMap.insert(ExternalAppHandler::PHONE, i18n("Phone"));
94 mExternalAppsMap.insert(ExternalAppHandler::SMS, i18n("SMS")); 97 mExternalAppsMap.insert(ExternalAppHandler::SMS, i18n("SMS"));
95 mExternalAppsMap.insert(ExternalAppHandler::FAX, i18n("Fax")); 98 mExternalAppsMap.insert(ExternalAppHandler::FAX, i18n("Fax"));
96 mExternalAppsMap.insert(ExternalAppHandler::PAGER, i18n("Pager")); 99 mExternalAppsMap.insert(ExternalAppHandler::PAGER, i18n("Pager"));
97 mExternalAppsMap.insert(ExternalAppHandler::SIP, i18n("SIP")); 100 mExternalAppsMap.insert(ExternalAppHandler::SIP, i18n("SIP"));
98 101
99 102
100 QVBoxLayout *topLayout = new QVBoxLayout( this, 0, 103 QVBoxLayout *topLayout = new QVBoxLayout( this, 0,
101 KDialog::spacingHint() ); 104 KDialog::spacingHint() );
102 105
103 tabWidget = new QTabWidget( this ); 106 tabWidget = new QTabWidget( this );
104 topLayout->addWidget( tabWidget ); 107 topLayout->addWidget( tabWidget );
105 108
106 109
107 setupLocaleTab(); 110 setupLocaleTab();
108 setupLocaleDateTab(); 111 setupLocaleDateTab();
109 setupTimeZoneTab(); 112 setupTimeZoneTab();
110 setupExternalAppTab(); 113 setupExternalAppTab();
111 setupStoreTab(); 114 setupStoreTab();
112 115 setupBackupTab();
113} 116}
114void KDEPIMConfigWidget::showTimeZoneTab() 117void KDEPIMConfigWidget::showTimeZoneTab()
115{ 118{
116 tabWidget->setCurrentPage ( 3 ) ; 119 tabWidget->setCurrentPage ( 3 ) ;
117} 120}
121void KDEPIMConfigWidget::setupBackupTab()
122{
123 QVBox *colorPage = new QVBox( this );
124 tabWidget->addTab( colorPage, i18n( "Backup" ) );
125 QWidget* topFrame = new QWidget( colorPage );
126 QVBoxLayout *topLayout = new QVBoxLayout(topFrame);
127 KPrefsWidBool *sb = addWidBool(i18n("Backup enabled"),
128 &(KPimGlobalPrefs::instance()->mBackupEnabled),topFrame);
129 topLayout->addWidget((QWidget*)sb->checkBox());
130 QWidget* bupFrame = new QWidget( topFrame );
131 topLayout->addWidget((bupFrame));
132 QObject::connect ( sb->checkBox(), SIGNAL (toggled ( bool ) ), bupFrame, SLOT ( setEnabled( bool ) ) );
133 QVBoxLayout *bupLayout = new QVBoxLayout(bupFrame);
134 sb = addWidBool(i18n("Use standard backup dir"),
135 &(KPimGlobalPrefs::instance()->mBackupEnabled),bupFrame);
136 bupLayout->addWidget((QWidget*)sb->checkBox());
137 mBackupUrl = new KURLRequester( bupFrame );
138 mBackupUrl->setURL( KGlobalSettings::backupDataDir() );
139 QObject::connect ( sb->checkBox(), SIGNAL (toggled ( bool ) ), mBackupUrl ,SLOT ( setDisabled( bool ) ) );
140 bupLayout->addWidget( mBackupUrl );
141
142
143 QHBox *dummy = new QHBox(bupFrame);
144 new QLabel(i18n("Number of Backups:"),dummy);
145 mBackupNumbersSpin = new QSpinBox(1,21,1,dummy);
146 new QLabel(i18n(" "),dummy);
147 bupLayout->addWidget( dummy );
148
149 dummy = new QHBox(bupFrame);
150 new QLabel(i18n("Make backup every "),dummy);
151 mBackupDayCountSpin = new QSpinBox(1,28,1,dummy);
152 new QLabel(i18n(" days"),dummy);
153 new QLabel(i18n(" "),dummy);
154 bupLayout->addWidget( dummy );
155
156}
118void KDEPIMConfigWidget::setupStoreTab() 157void KDEPIMConfigWidget::setupStoreTab()
119{ 158{
120 QVBox *colorPage = new QVBox( this ); 159 QVBox *colorPage = new QVBox( this );
121 tabWidget->addTab( colorPage, i18n( "Colors" ) ); 160 tabWidget->addTab( colorPage, i18n( "Colors" ) );
122 QWidget* cw = new QWidget( colorPage ); 161 QWidget* cw = new QWidget( colorPage );
123 KPrefsWidColor *holidayColor = 162 KPrefsWidColor *holidayColor =
124 addWidColor(i18n("Alternating background of list views"), 163 addWidColor(i18n("Alternating background of list views"),
125 &(KPimGlobalPrefs::instance()->mAlternateColor),cw); 164 &(KPimGlobalPrefs::instance()->mAlternateColor),cw);
126 QHBoxLayout *topLayout = new QHBoxLayout(cw); 165 QHBoxLayout *topLayout = new QHBoxLayout(cw);
127 topLayout->addWidget(holidayColor->label()); 166 topLayout->addWidget(holidayColor->label());
128 topLayout->addWidget( (QWidget* )holidayColor->button()); 167 topLayout->addWidget( (QWidget* )holidayColor->button());
129 168
130 169
131 QVBox *storePage = new QVBox( this ); 170 QVBox *storePage = new QVBox( this );
132 new QLabel( i18n("Your current storage dir is:\n%1\nYour mail is stored in:\n(storagedir)/apps/kopiemail/localmail").arg(KGlobal::dirs()->localkdedir()), storePage ); 171 new QLabel( i18n("Your current storage dir is:\n%1\nYour mail is stored in:\n(storagedir)/apps/kopiemail/localmail").arg(KGlobal::dirs()->localkdedir()), storePage );
133 new QLabel( i18n("<b>New data storage dir:</b>"), storePage ); 172 new QLabel( i18n("<b>New data storage dir:</b>"), storePage );
134 mStoreUrl = new KURLRequester( storePage ); 173 mStoreUrl = new KURLRequester( storePage );
135 mStoreUrl->setURL( KGlobal::dirs()->localkdedir() ); 174 mStoreUrl->setURL( KGlobal::dirs()->localkdedir() );
136#ifdef DESKTOP_VERSION 175#ifdef DESKTOP_VERSION
137 QString confFile = qApp->applicationDirPath ()+ "/.microkdehome" ; 176 QString confFile = qApp->applicationDirPath ()+ "/.microkdehome" ;
138 QFileInfo fi ( confFile ); 177 QFileInfo fi ( confFile );
139 if ( fi.exists() ) { 178 if ( fi.exists() ) {
140 KConfig cfg ( confFile ); 179 KConfig cfg ( confFile );
141 cfg.setGroup("Global"); 180 cfg.setGroup("Global");
diff --git a/libkdepim/kcmconfigs/kdepimconfigwidget.h b/libkdepim/kcmconfigs/kdepimconfigwidget.h
index 984e4e0..c0b92a9 100644
--- a/libkdepim/kcmconfigs/kdepimconfigwidget.h
+++ b/libkdepim/kcmconfigs/kdepimconfigwidget.h
@@ -58,48 +58,49 @@ class KDEPIMConfigWidget : public KPrefsWidget
58 58
59 protected: 59 protected:
60 /** Implement this to read custom configuration widgets. */ 60 /** Implement this to read custom configuration widgets. */
61 virtual void usrReadConfig(); 61 virtual void usrReadConfig();
62 /** Implement this to write custom configuration widgets. */ 62 /** Implement this to write custom configuration widgets. */
63 virtual void usrWriteConfig(); 63 virtual void usrWriteConfig();
64 64
65 65
66 private slots: 66 private slots:
67// void configureExtension(); 67// void configureExtension();
68// void selectionChanged( QListViewItem* ); 68// void selectionChanged( QListViewItem* );
69// void itemClicked( QListViewItem* ); 69// void itemClicked( QListViewItem* );
70 void client_changed( int newClient ); 70 void client_changed( int newClient );
71 void externalapp_changed( int newApp ); 71 void externalapp_changed( int newApp );
72 void saveStoreSettings(); 72 void saveStoreSettings();
73 void setStandardStore(); 73 void setStandardStore();
74 void setLocalStore(); 74 void setLocalStore();
75 75
76 private: 76 private:
77 void setupExternalAppTab(); 77 void setupExternalAppTab();
78 void setupLocaleDateTab(); 78 void setupLocaleDateTab();
79 void setupLocaleTab(); 79 void setupLocaleTab();
80 void setupTimeZoneTab(); 80 void setupTimeZoneTab();
81 void setupStoreTab(); 81 void setupStoreTab();
82 void setupBackupTab();
82 KURLRequester* mStoreUrl; 83 KURLRequester* mStoreUrl;
83 84
84 void setCombo(QComboBox *combo,const QString & text, const QStringList *tags = 0); 85 void setCombo(QComboBox *combo,const QString & text, const QStringList *tags = 0);
85 86
86 87
87 void saveEditFieldSettings(); 88 void saveEditFieldSettings();
88 void updateClientWidgets(); 89 void updateClientWidgets();
89 90
90 QTabWidget *tabWidget; 91 QTabWidget *tabWidget;
91 92
92 93
93 QLineEdit* mUserDateFormatShort; 94 QLineEdit* mUserDateFormatShort;
94 QLineEdit* mUserDateFormatLong; 95 QLineEdit* mUserDateFormatLong;
95 QComboBox* mTimeZoneCombo; 96 QComboBox* mTimeZoneCombo;
96 KDateEdit* mStartDateSavingEdit; 97 KDateEdit* mStartDateSavingEdit;
97 KDateEdit* mEndDateSavingEdit; 98 KDateEdit* mEndDateSavingEdit;
98 99
99// void restoreExtensionSettings(); 100// void restoreExtensionSettings();
100// void saveExtensionSettings(); 101// void saveExtensionSettings();
101 102
102// KListView *mExtensionView; 103// KListView *mExtensionView;
103 104
104// QCheckBox *mNameParsing; 105// QCheckBox *mNameParsing;
105// QCheckBox *mViewsSingleClickBox; 106// QCheckBox *mViewsSingleClickBox;
@@ -131,31 +132,32 @@ class KDEPIMConfigWidget : public KPrefsWidget
131 QString mPhoneOtherMessage; 132 QString mPhoneOtherMessage;
132 QString mPhoneOtherMessageParameters; 133 QString mPhoneOtherMessageParameters;
133 134
134 int mFaxClient; 135 int mFaxClient;
135 QString mFaxOtherChannel; 136 QString mFaxOtherChannel;
136 QString mFaxOtherMessage; 137 QString mFaxOtherMessage;
137 QString mFaxOtherMessageParameters; 138 QString mFaxOtherMessageParameters;
138 139
139 int mSMSClient; 140 int mSMSClient;
140 QString mSMSOtherChannel; 141 QString mSMSOtherChannel;
141 QString mSMSOtherMessage; 142 QString mSMSOtherMessage;
142 QString mSMSOtherMessageParameters; 143 QString mSMSOtherMessageParameters;
143 144
144 int mPagerClient; 145 int mPagerClient;
145 QString mPagerOtherChannel; 146 QString mPagerOtherChannel;
146 QString mPagerOtherMessage; 147 QString mPagerOtherMessage;
147 QString mPagerOtherMessageParameters; 148 QString mPagerOtherMessageParameters;
148 149
149 int mSipClient; 150 int mSipClient;
150 QString mSipOtherChannel; 151 QString mSipOtherChannel;
151 QString mSipOtherMessage; 152 QString mSipOtherMessage;
152 QString mSipOtherMessageParameters; 153 QString mSipOtherMessageParameters;
153 154
154 155
155 156 KURLRequester* mBackupUrl;
157 QSpinBox* mBackupDayCountSpin, *mBackupNumbersSpin ;
156 QMap<ExternalAppHandler::Types, QString> mExternalAppsMap; 158 QMap<ExternalAppHandler::Types, QString> mExternalAppsMap;
157 159
158// AddresseeWidget *mAddresseeWidget; 160// AddresseeWidget *mAddresseeWidget;
159}; 161};
160 162
161#endif 163#endif
diff --git a/libkdepim/kpimglobalprefs.cpp b/libkdepim/kpimglobalprefs.cpp
index 873f0eb..90321b2 100644
--- a/libkdepim/kpimglobalprefs.cpp
+++ b/libkdepim/kpimglobalprefs.cpp
@@ -90,48 +90,55 @@ KPimGlobalPrefs::KPimGlobalPrefs( const QString &name )
90 addItemString( "FaxChannel", &mFaxOtherChannel, "" ); 90 addItemString( "FaxChannel", &mFaxOtherChannel, "" );
91 addItemString( "FaxChannelMessage", &mFaxOtherMessage, "" ); 91 addItemString( "FaxChannelMessage", &mFaxOtherMessage, "" );
92 addItemString( "FaxChannelParameters", &mFaxOtherMessageParameters, "" ); 92 addItemString( "FaxChannelParameters", &mFaxOtherMessageParameters, "" );
93 93
94 addItemInt( "SMSChannelType", &mSMSClient, NONE_SMC ); 94 addItemInt( "SMSChannelType", &mSMSClient, NONE_SMC );
95 addItemString( "SMSChannel", &mSMSOtherChannel, "" ); 95 addItemString( "SMSChannel", &mSMSOtherChannel, "" );
96 addItemString( "SMSChannelMessage", &mSMSOtherMessage, "" ); 96 addItemString( "SMSChannelMessage", &mSMSOtherMessage, "" );
97 addItemString( "SMSChannelParameters", &mSMSOtherMessageParameters, "" ); 97 addItemString( "SMSChannelParameters", &mSMSOtherMessageParameters, "" );
98 98
99 addItemInt( "PagerChannelType", &mPagerClient, NONE_PAC ); 99 addItemInt( "PagerChannelType", &mPagerClient, NONE_PAC );
100 addItemString( "PagerChannel", &mPagerOtherChannel, "" ); 100 addItemString( "PagerChannel", &mPagerOtherChannel, "" );
101 addItemString( "PagerChannelMessage", &mPagerOtherMessage, "" ); 101 addItemString( "PagerChannelMessage", &mPagerOtherMessage, "" );
102 addItemString( "PagerChannelParameters", &mPagerOtherMessageParameters, "" ); 102 addItemString( "PagerChannelParameters", &mPagerOtherMessageParameters, "" );
103 103
104 addItemInt( "SIPChannelType", &mSipClient, KPPI_SIC ); 104 addItemInt( "SIPChannelType", &mSipClient, KPPI_SIC );
105 addItemString( "SIPChannel", &mSipOtherChannel, "" ); 105 addItemString( "SIPChannel", &mSipOtherChannel, "" );
106 addItemString( "SIPChannelMessage", &mSipOtherMessage, "" ); 106 addItemString( "SIPChannelMessage", &mSipOtherMessage, "" );
107 addItemString( "SIPChannelParameters", &mSipOtherMessageParameters, "" ); 107 addItemString( "SIPChannelParameters", &mSipOtherMessageParameters, "" );
108 108
109 KPrefs::setCurrentGroup( "PhoneAccess" ); 109 KPrefs::setCurrentGroup( "PhoneAccess" );
110 addItemString("Ex2PhoneDevice",&mEx2PhoneDevice,"/dev/ircomm"); 110 addItemString("Ex2PhoneDevice",&mEx2PhoneDevice,"/dev/ircomm");
111 addItemString("Ex2PhoneConnection",&mEx2PhoneConnection,"irda"); 111 addItemString("Ex2PhoneConnection",&mEx2PhoneConnection,"irda");
112 addItemString("Ex2PhoneModel",&mEx2PhoneModel,"6310i"); 112 addItemString("Ex2PhoneModel",&mEx2PhoneModel,"6310i");
113 113
114 KPrefs::setCurrentGroup( "BackupSettings" );
115 addItemString("BackupDatadir",&mBackupDatadir,KGlobalSettings::backupDataDir());
116 addItemInt( "BackupNumbers", &mBackupNumbers, 3 );
117 addItemInt( "BackupDayCount", &mBackupDayCount, 2 );
118 addItemBool( "BackupUseDefaultDir",&mBackupUseDefaultDir, true );
119 addItemBool( "BackupEnabled",&mBackupEnabled, false );
120
114} 121}
115 122
116void KPimGlobalPrefs::setGlobalConfig() 123void KPimGlobalPrefs::setGlobalConfig()
117{ 124{
118 if ( mLocaleDict == 0 ) { 125 if ( mLocaleDict == 0 ) {
119 QString fileName ; 126 QString fileName ;
120 QString name = KGlobal::getAppName() +"/"; 127 QString name = KGlobal::getAppName() +"/";
121#ifndef DESKTOP_VERSION 128#ifndef DESKTOP_VERSION
122 fileName= QString(getenv("QPEDIR"))+"/pics/kdepim/"+name; 129 fileName= QString(getenv("QPEDIR"))+"/pics/kdepim/"+name;
123#else 130#else
124 fileName = qApp->applicationDirPath () + "/kdepim/"+ name; 131 fileName = qApp->applicationDirPath () + "/kdepim/"+ name;
125#endif 132#endif
126 mLocaleDict = 0; 133 mLocaleDict = 0;
127 if ( mPreferredLanguage > 0 && mPreferredLanguage < 5 ) { 134 if ( mPreferredLanguage > 0 && mPreferredLanguage < 5 ) {
128 135
129 if ( mPreferredLanguage == 1 ) 136 if ( mPreferredLanguage == 1 )
130 fileName = fileName+"germantranslation.txt"; 137 fileName = fileName+"germantranslation.txt";
131 else if ( mPreferredLanguage == 4 ) 138 else if ( mPreferredLanguage == 4 )
132 fileName = fileName+"usertranslation.txt"; 139 fileName = fileName+"usertranslation.txt";
133 else if ( mPreferredLanguage == 2 ) 140 else if ( mPreferredLanguage == 2 )
134 fileName = fileName+"frenchtranslation.txt"; 141 fileName = fileName+"frenchtranslation.txt";
135 else if ( mPreferredLanguage == 3 ) 142 else if ( mPreferredLanguage == 3 )
136 fileName = fileName+"italiantranslation.txt"; 143 fileName = fileName+"italiantranslation.txt";
137 QFile file( fileName ); 144 QFile file( fileName );
diff --git a/libkdepim/kpimglobalprefs.h b/libkdepim/kpimglobalprefs.h
index 36cc25a..94ac8ae 100644
--- a/libkdepim/kpimglobalprefs.h
+++ b/libkdepim/kpimglobalprefs.h
@@ -119,27 +119,33 @@ class KPimGlobalPrefs : public KPrefs
119 int mFaxClient; 119 int mFaxClient;
120 QString mFaxOtherChannel; 120 QString mFaxOtherChannel;
121 QString mFaxOtherMessage; 121 QString mFaxOtherMessage;
122 QString mFaxOtherMessageParameters; 122 QString mFaxOtherMessageParameters;
123 123
124 int mSMSClient; 124 int mSMSClient;
125 QString mSMSOtherChannel; 125 QString mSMSOtherChannel;
126 QString mSMSOtherMessage; 126 QString mSMSOtherMessage;
127 QString mSMSOtherMessageParameters; 127 QString mSMSOtherMessageParameters;
128 128
129 int mPagerClient; 129 int mPagerClient;
130 QString mPagerOtherChannel; 130 QString mPagerOtherChannel;
131 QString mPagerOtherMessage; 131 QString mPagerOtherMessage;
132 QString mPagerOtherMessageParameters; 132 QString mPagerOtherMessageParameters;
133 133
134 int mSipClient; 134 int mSipClient;
135 QString mSipOtherChannel; 135 QString mSipOtherChannel;
136 QString mSipOtherMessage; 136 QString mSipOtherMessage;
137 QString mSipOtherMessageParameters; 137 QString mSipOtherMessageParameters;
138 138
139 QString mEx2PhoneDevice; 139 QString mEx2PhoneDevice;
140 QString mEx2PhoneConnection; 140 QString mEx2PhoneConnection;
141 QString mEx2PhoneModel; 141 QString mEx2PhoneModel;
142 142
143
144 bool mBackupEnabled;
145 QString mBackupDatadir;
146 bool mBackupUseDefaultDir;
147 int mBackupNumbers;
148 int mBackupDayCount;
143}; 149};
144 150
145#endif 151#endif
diff --git a/libkdepim/kprefsdialog.cpp b/libkdepim/kprefsdialog.cpp
index dd9a602..b6ae775 100644
--- a/libkdepim/kprefsdialog.cpp
+++ b/libkdepim/kprefsdialog.cpp
@@ -259,49 +259,49 @@ void KPrefsDialogWidString::readConfig()
259 259
260void KPrefsDialogWidString::writeConfig() 260void KPrefsDialogWidString::writeConfig()
261{ 261{
262 *mReference = mEdit->text(); 262 *mReference = mEdit->text();
263} 263}
264 264
265QLabel *KPrefsDialogWidString::label() 265QLabel *KPrefsDialogWidString::label()
266{ 266{
267 return mLabel; 267 return mLabel;
268} 268}
269 269
270QLineEdit *KPrefsDialogWidString::lineEdit() 270QLineEdit *KPrefsDialogWidString::lineEdit()
271{ 271{
272 return mEdit; 272 return mEdit;
273} 273}
274 274
275 275
276KPrefsDialog::KPrefsDialog(KPrefs *prefs,QWidget *parent,char *name,bool modal) : 276KPrefsDialog::KPrefsDialog(KPrefs *prefs,QWidget *parent,char *name,bool modal) :
277 KDialogBase(IconList,i18n("Preferences"),Ok|Cancel|Default,Ok,parent, 277 KDialogBase(IconList,i18n("Preferences"),Ok|Cancel|Default,Ok,parent,
278 name,modal,true) 278 name,modal,true)
279{ 279{
280 mPrefs = prefs; 280 mPrefs = prefs;
281 281
282// This seems to cause a crash on exit. Investigate later. 282// This seems to cause a crash on exit. Investigate later.
283// mPrefsWids.setAutoDelete(true); 283 mPrefsWids.setAutoDelete(true);
284 284
285 connect(this,SIGNAL(defaultClicked()),SLOT(slotDefault())); 285 connect(this,SIGNAL(defaultClicked()),SLOT(slotDefault()));
286 //connect(this,SIGNAL(cancelClicked()),SLOT(slotDefault())); 286 //connect(this,SIGNAL(cancelClicked()),SLOT(slotDefault()));
287 //connect(this,SIGNAL(cancelClicked()),SLOT(reject())); 287 //connect(this,SIGNAL(cancelClicked()),SLOT(reject()));
288} 288}
289 289
290KPrefsDialog::~KPrefsDialog() 290KPrefsDialog::~KPrefsDialog()
291{ 291{
292} 292}
293 293
294void KPrefsDialog::addWid(KPrefsDialogWid *wid) 294void KPrefsDialog::addWid(KPrefsDialogWid *wid)
295{ 295{
296 mPrefsWids.append(wid); 296 mPrefsWids.append(wid);
297} 297}
298 298
299KPrefsDialogWidBool *KPrefsDialog::addWidBool(const QString &text,bool *reference,QWidget *parent) 299KPrefsDialogWidBool *KPrefsDialog::addWidBool(const QString &text,bool *reference,QWidget *parent)
300{ 300{
301 KPrefsDialogWidBool *w = new KPrefsDialogWidBool(text,reference,parent); 301 KPrefsDialogWidBool *w = new KPrefsDialogWidBool(text,reference,parent);
302 addWid(w); 302 addWid(w);
303 return w; 303 return w;
304} 304}
305 305
306KPrefsDialogWidTime *KPrefsDialog::addWidTime(const QString &text,int *reference,QWidget *parent) 306KPrefsDialogWidTime *KPrefsDialog::addWidTime(const QString &text,int *reference,QWidget *parent)
307{ 307{
diff --git a/libkdepim/kprefsdialog.h b/libkdepim/kprefsdialog.h
index ad13b78..efcb86a 100644
--- a/libkdepim/kprefsdialog.h
+++ b/libkdepim/kprefsdialog.h
@@ -25,49 +25,49 @@
25// $Id$ 25// $Id$
26 26
27#include <qptrlist.h> 27#include <qptrlist.h>
28#include <qlineedit.h> 28#include <qlineedit.h>
29 29
30#include <kdialogbase.h> 30#include <kdialogbase.h>
31 31
32class KPrefs; 32class KPrefs;
33class KPrefsDialog; 33class KPrefsDialog;
34 34
35class KColorButton; 35class KColorButton;
36class QCheckBox; 36class QCheckBox;
37class QLabel; 37class QLabel;
38class QSpinBox; 38class QSpinBox;
39class QButtonGroup; 39class QButtonGroup;
40 40
41/** 41/**
42 @short Base class for widgets used by @ref KPrefsDialog. 42 @short Base class for widgets used by @ref KPrefsDialog.
43 @author Cornelius Schumacher 43 @author Cornelius Schumacher
44 @see KPrefsDialog 44 @see KPrefsDialog
45 45
46 This class provides the interface for the preferences widgets used by 46 This class provides the interface for the preferences widgets used by
47 KPrefsDialog. 47 KPrefsDialog.
48*/ 48*/
49class KPrefsDialogWid 49class KPrefsDialogWid : public QObject
50{ 50{
51 public: 51 public:
52 /** 52 /**
53 This function is called to read value of the setting from the 53 This function is called to read value of the setting from the
54 stored configuration and display it in the widget. 54 stored configuration and display it in the widget.
55 */ 55 */
56 virtual void readConfig() = 0; 56 virtual void readConfig() = 0;
57 /** 57 /**
58 This function is called to write the current setting of the widget to the 58 This function is called to write the current setting of the widget to the
59 stored configuration. 59 stored configuration.
60 */ 60 */
61 virtual void writeConfig() = 0; 61 virtual void writeConfig() = 0;
62}; 62};
63 63
64/** 64/**
65 @short Widget for bool settings in @ref KPrefsDialog. 65 @short Widget for bool settings in @ref KPrefsDialog.
66 66
67 This class provides a widget for configuring bool values. It is meant to be 67 This class provides a widget for configuring bool values. It is meant to be
68 used by KPrefsDialog. The user is responsible for the layout management. 68 used by KPrefsDialog. The user is responsible for the layout management.
69*/ 69*/
70class KPrefsDialogWidBool : public KPrefsDialogWid 70class KPrefsDialogWidBool : public KPrefsDialogWid
71{ 71{
72 public: 72 public:
73 /** 73 /**
@@ -115,92 +115,91 @@ class KPrefsDialogWidTime : public KPrefsDialogWid
115 Return QLabel used by this widget. 115 Return QLabel used by this widget.
116 */ 116 */
117 QLabel *label(); 117 QLabel *label();
118 /** 118 /**
119 Return QSpinBox used by this widget. 119 Return QSpinBox used by this widget.
120 */ 120 */
121 QSpinBox *spinBox(); 121 QSpinBox *spinBox();
122 122
123 void readConfig(); 123 void readConfig();
124 void writeConfig(); 124 void writeConfig();
125 125
126 private: 126 private:
127 int *mReference; 127 int *mReference;
128 128
129 QLabel *mLabel; 129 QLabel *mLabel;
130 QSpinBox *mSpin; 130 QSpinBox *mSpin;
131}; 131};
132 132
133/** 133/**
134 @short Widget for color settings in @ref KPrefsDialog. 134 @short Widget for color settings in @ref KPrefsDialog.
135 135
136 This class provides a widget for configuring color values. It is meant to be 136 This class provides a widget for configuring color values. It is meant to be
137 used by KPrefsDialog. The user is responsible for the layout management. 137 used by KPrefsDialog. The user is responsible for the layout management.
138*/ 138*/
139class KPrefsDialogWidColor : public QObject, public KPrefsDialogWid 139class KPrefsDialogWidColor : public KPrefsDialogWid
140{ 140{
141 Q_OBJECT
142 public: 141 public:
143 /** 142 /**
144 Create a color widget consisting of a test field and a button for opening 143 Create a color widget consisting of a test field and a button for opening
145 a color dialog. 144 a color dialog.
146 145
147 @param text Text of button. 146 @param text Text of button.
148 @param reference Pointer to variable read and written by this widget. 147 @param reference Pointer to variable read and written by this widget.
149 @param parent Parent widget. 148 @param parent Parent widget.
150 */ 149 */
151 KPrefsDialogWidColor(const QString &text,QColor *reference,QWidget *parent); 150 KPrefsDialogWidColor(const QString &text,QColor *reference,QWidget *parent);
152 /** 151 /**
153 Destruct color setting widget. 152 Destruct color setting widget.
154 */ 153 */
155 ~KPrefsDialogWidColor(); 154 ~KPrefsDialogWidColor();
156 155
157 /** 156 /**
158 Return QLabel for the button 157 Return QLabel for the button
159 */ 158 */
160 QLabel *label(); 159 QLabel *label();
161 /** 160 /**
162 Return button opening the color dialog. 161 Return button opening the color dialog.
163 */ 162 */
164 KColorButton *button(); 163 KColorButton *button();
165 164
166 void readConfig(); 165 void readConfig();
167 void writeConfig(); 166 void writeConfig();
168 167
169 private: 168 private:
170 QColor *mReference; 169 QColor *mReference;
171 170
172 QLabel *mLabel; 171 QLabel *mLabel;
173 KColorButton *mButton; 172 KColorButton *mButton;
174}; 173};
175 174
176/** 175/**
177 @short Widget for font settings in @ref KPrefsDialog. 176 @short Widget for font settings in @ref KPrefsDialog.
178 177
179 This class provides a widget for configuring font values. It is meant to be 178 This class provides a widget for configuring font values. It is meant to be
180 used by KPrefsDialog. The user is responsible for the layout management. 179 used by KPrefsDialog. The user is responsible for the layout management.
181*/ 180*/
182class KPrefsDialogWidFont : public QObject, public KPrefsDialogWid 181class KPrefsDialogWidFont : public KPrefsDialogWid
183{ 182{
184 Q_OBJECT 183 Q_OBJECT
185 public: 184 public:
186 /** 185 /**
187 Create a font widget consisting of a test field and a button for opening 186 Create a font widget consisting of a test field and a button for opening
188 a font dialog. 187 a font dialog.
189 188
190 @param label Text of label. 189 @param label Text of label.
191 @param reference Pointer to variable read and written by this widget. 190 @param reference Pointer to variable read and written by this widget.
192 @param parent Parent widget. 191 @param parent Parent widget.
193 */ 192 */
194 KPrefsDialogWidFont(const QString &sampleText,const QString &labelText, 193 KPrefsDialogWidFont(const QString &sampleText,const QString &labelText,
195 QFont *reference,QWidget *parent); 194 QFont *reference,QWidget *parent);
196 /** 195 /**
197 Destruct font setting widget. 196 Destruct font setting widget.
198 */ 197 */
199 ~KPrefsDialogWidFont(); 198 ~KPrefsDialogWidFont();
200 199
201 /** 200 /**
202 Return label. 201 Return label.
203 */ 202 */
204 QLabel *label(); 203 QLabel *label();
205 /** 204 /**
206 Return QFrame used as preview field. 205 Return QFrame used as preview field.
diff --git a/microkde/kglobalsettings.cpp b/microkde/kglobalsettings.cpp
index 5976aae..3f8a630 100644
--- a/microkde/kglobalsettings.cpp
+++ b/microkde/kglobalsettings.cpp
@@ -33,48 +33,57 @@ QFont KGlobalSettings::generalMaxFont()
33 int size = 12; 33 int size = 12;
34 if (QApplication::desktop()->width() < 480 ) { 34 if (QApplication::desktop()->width() < 480 ) {
35 size = 10; 35 size = 10;
36 } 36 }
37#ifndef DESKTOP_VERSION 37#ifndef DESKTOP_VERSION
38 else 38 else
39 if (QApplication::desktop()->width() >= 480 && QApplication::desktop()->width() <= 640 ) 39 if (QApplication::desktop()->width() >= 480 && QApplication::desktop()->width() <= 640 )
40 size = 18; 40 size = 18;
41#endif 41#endif
42 QFont f = QApplication::font(); 42 QFont f = QApplication::font();
43 if ( f.pointSize() > size ) 43 if ( f.pointSize() > size )
44 f.setPointSize( size ); 44 f.setPointSize( size );
45 return f; 45 return f;
46} 46}
47 47
48QString KGlobalSettings::timeTrackerDir() 48QString KGlobalSettings::timeTrackerDir()
49{ 49{
50 static QString dir; 50 static QString dir;
51 if ( dir.isEmpty() ) { 51 if ( dir.isEmpty() ) {
52 dir = locateLocal( "data", "timetrackerdir/d.ttl" ); 52 dir = locateLocal( "data", "timetrackerdir/d.ttl" );
53 dir = dir.left ( dir.length() - 5); 53 dir = dir.left ( dir.length() - 5);
54 } 54 }
55 return dir; 55 return dir;
56} 56}
57QString KGlobalSettings::backupDataDir()
58{
59 static QString dir;
60 if ( dir.isEmpty() ) {
61 dir = locateLocal( "data", "backupdir/d.ttl" );
62 dir = dir.left ( dir.length() - 5);
63 }
64 return dir;
65}
57 66
58QFont KGlobalSettings::toolBarFont() 67QFont KGlobalSettings::toolBarFont()
59{ 68{
60 return QApplication::font(); 69 return QApplication::font();
61} 70}
62 71
63QColor KGlobalSettings::toolBarHighlightColor() 72QColor KGlobalSettings::toolBarHighlightColor()
64{ 73{
65 return QColor( "black" ); 74 return QColor( "black" );
66} 75}
67 76
68QColor KGlobalSettings::alternateBackgroundColor() 77QColor KGlobalSettings::alternateBackgroundColor()
69{ 78{
70 return mAlternate; 79 return mAlternate;
71 80
72} 81}
73void KGlobalSettings::setAlternateBackgroundColor(QColor c) 82void KGlobalSettings::setAlternateBackgroundColor(QColor c)
74{ 83{
75 mAlternate = c; 84 mAlternate = c;
76 85
77} 86}
78 87
79QRect KGlobalSettings::desktopGeometry( QWidget * ) 88QRect KGlobalSettings::desktopGeometry( QWidget * )
80{ 89{
diff --git a/microkde/kglobalsettings.h b/microkde/kglobalsettings.h
index 05ef279..4e4d87c 100644
--- a/microkde/kglobalsettings.h
+++ b/microkde/kglobalsettings.h
@@ -1,35 +1,36 @@
1#ifndef MICROKDE_KGLOBALSETTINGS_H 1#ifndef MICROKDE_KGLOBALSETTINGS_H
2#define MICROKDE_KGLOBALSETTINGS_H 2#define MICROKDE_KGLOBALSETTINGS_H
3 3
4#include <qfont.h> 4#include <qfont.h>
5#include <qrect.h> 5#include <qrect.h>
6 6
7 7
8#define KDE_DEFAULT_SINGLECLICK true 8#define KDE_DEFAULT_SINGLECLICK true
9 9
10 10
11class KGlobalSettings 11class KGlobalSettings
12{ 12{
13 public: 13 public:
14 static QFont generalFont(); 14 static QFont generalFont();
15 static QFont generalMaxFont(); 15 static QFont generalMaxFont();
16 static QFont toolBarFont(); 16 static QFont toolBarFont();
17 17
18 static QColor mAlternate; 18 static QColor mAlternate;
19 static QColor toolBarHighlightColor(); 19 static QColor toolBarHighlightColor();
20 static QColor alternateBackgroundColor(); 20 static QColor alternateBackgroundColor();
21 static void setAlternateBackgroundColor(QColor); 21 static void setAlternateBackgroundColor(QColor);
22 static QRect desktopGeometry( QWidget * ); 22 static QRect desktopGeometry( QWidget * );
23 static QString timeTrackerDir(); 23 static QString timeTrackerDir();
24 static QString backupDataDir();
24 25
25 /** 26 /**
26 * Returns whether KDE runs in single (default) or double click 27 * Returns whether KDE runs in single (default) or double click
27 * mode. 28 * mode.
28 * see http://developer.kde.org/documentation/standards/kde/style/mouse/index.html 29 * see http://developer.kde.org/documentation/standards/kde/style/mouse/index.html
29 * @return true if single click mode, or false if double click mode. 30 * @return true if single click mode, or false if double click mode.
30 **/ 31 **/
31 static bool singleClick(); 32 static bool singleClick();
32 33
33}; 34};
34 35
35#endif 36#endif