summaryrefslogtreecommitdiffabout
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--bin/kdepim/korganizer/germantranslation.txt2
-rw-r--r--korganizer/komonthview.cpp18
-rw-r--r--korganizer/komonthview.h2
-rw-r--r--korganizer/koprefs.cpp3
-rw-r--r--korganizer/koprefs.h1
-rw-r--r--korganizer/koprefsdialog.cpp5
6 files changed, 25 insertions, 6 deletions
diff --git a/bin/kdepim/korganizer/germantranslation.txt b/bin/kdepim/korganizer/germantranslation.txt
index 8c3b1e4..5a5b73e 100644
--- a/bin/kdepim/korganizer/germantranslation.txt
+++ b/bin/kdepim/korganizer/germantranslation.txt
@@ -1212,13 +1212,13 @@
{ "Set Alarm!","Setze Alarm!" },
{ "Canged alarm for %1 items","Alarm für %1 Items geändert" },
{ " and "," und " },
{ "<IMG src="%1"> only )","nur <IMG src="%1"> )" },
{ "Mail to selected","Mail an Ausgewählte" },
{ "Mail to all","Mail an Alle" },
-{ "","" },
+{ "Week view mode uses bigger font","Wochenansicht Modus nutzt größeren Font" },
{ "","" },
{ "","" },
{ "","" },
{ "","" },
{ "","" },
{ "","" },
diff --git a/korganizer/komonthview.cpp b/korganizer/komonthview.cpp
index daa37fd..dfa89e2 100644
--- a/korganizer/komonthview.cpp
+++ b/korganizer/komonthview.cpp
@@ -611,15 +611,24 @@ void MonthViewCell::updateCell()
}
finishUpdateCell();
// if ( isVisible())
//qApp->processEvents();
}
-void MonthViewCell::updateConfig()
+void MonthViewCell::updateConfig( bool bigFont ) // = false
{
- setFont( KOPrefs::instance()->mMonthViewFont );
+
+ if ( bigFont ) {
+ QFont fo = KOPrefs::instance()->mMonthViewFont;
+ int ps = fo.pointSize() + 2;
+ if ( ps < 18 )
+ ps += 2;
+ fo.setPointSize( ps );
+ setFont( fo );
+ } else
+ setFont( KOPrefs::instance()->mMonthViewFont );
QFontMetrics fm( font() );
mLabelSize = fm.size( 0, "30" ) + QSize( 4, 2 );
mLabelBigSize = fm.size( 0, "Mag 30" ) + QSize( 2, 2 );
mHolidayPalette = mStandardPalette;
mPrimaryPalette = mStandardPalette;
@@ -866,12 +875,13 @@ KOMonthView::KOMonthView(Calendar *calendar, QWidget *parent, const char *name)
connect( cell, SIGNAL( defaultAction( Incidence * ) ),
SLOT( defaultAction( Incidence * ) ) );
connect( cell, SIGNAL( newEventSignal( QDateTime ) ),
SIGNAL( newEventSignal( QDateTime ) ) );
connect( cell, SIGNAL( showDaySignal( QDate ) ),
SIGNAL( showDaySignal( QDate ) ) );
+ cell->updateConfig(KOPrefs::instance()->mMonthViewUsesBigFont );
}
//connect( mWeekLabels[mNumWeeks], SIGNAL( clicked() ), SLOT( switchView() ) );
mContextMenu = eventPopup();
// updateConfig(); //useless here
@@ -989,12 +999,16 @@ void KOMonthView::updateConfig()
//qDebug("KOMonthView::updateConfig() %d %d %d ",height(), mDayLabels[0]->sizeHint().height() ,mNumWeeks);
//int cellHeight = (height() - mDayLabels[0]->sizeHint().height()) /mNumWeeks;
//resizeEvent( 0 );
for (uint i = 0; i < mCells.count(); ++i) {
mCells[i]->updateConfig();
}
+
+ for (uint i = 0; i < mCellsW.count(); ++i) {
+ mCellsW[i]->updateConfig(KOPrefs::instance()->mMonthViewUsesBigFont);
+ }
#ifdef DESKTOP_VERSION
MonthViewCell::toolTipGroup()->setEnabled(KOPrefs::instance()->mEnableToolTips);
#endif
updateView();
}
diff --git a/korganizer/komonthview.h b/korganizer/komonthview.h
index b89b2bc..700f098 100644
--- a/korganizer/komonthview.h
+++ b/korganizer/komonthview.h
@@ -140,13 +140,13 @@ class MonthViewCell : public QWidget
void updateCell();
void startUpdateCell();
void finishUpdateCell();
void insertEvent(Event *);
void insertTodo(Todo *);
- void updateConfig();
+ void updateConfig( bool bigFont = false );
void enableScrollBars( bool );
Incidence *selectedIncidence();
QDate selectedIncidenceDate();
diff --git a/korganizer/koprefs.cpp b/korganizer/koprefs.cpp
index 2fb7c36..ea5aaa1 100644
--- a/korganizer/koprefs.cpp
+++ b/korganizer/koprefs.cpp
@@ -242,13 +242,14 @@ KOPrefs::KOPrefs() :
addItemBool("WNViewShowsPast",&mWNViewShowsPast,true);
addItemBool("WNViewShowLocation",&mWNViewShowLocation,false);
addItemBool("UseHighlightLightColor",&mUseHighlightLightColor,false);
addItemBool("ListViewMonthTimespan",&mListViewMonthTimespan,true);
addItemBool("TodoViewUsesCatColors",&mTodoViewUsesCatColors,false);
addItemBool("TodoViewShowsPercentage",&mTodoViewShowsPercentage,false);
- addItemBool("TodoViewUsesSmallFont",&mTodoViewUsesSmallFont,false);
+ addItemBool("TodoViewUsesSmallFont",&mTodoViewUsesSmallFont,true);
+ addItemBool("MonthViewUsesBigFont",&mMonthViewUsesBigFont,true);
addItemBool("TodoViewUsesForegroundColor",&mTodoViewUsesForegroundColor,false);
addItemBool("MonthViewUsesForegroundColor",&mMonthViewUsesForegroundColor,false);
#ifdef DESKTOP_VERSION
addItemBool("UseInternalAlarmNotification",&mUseInternalAlarmNotification,true);
#else
addItemBool("UseInternalAlarmNotification",&mUseInternalAlarmNotification,false);
diff --git a/korganizer/koprefs.h b/korganizer/koprefs.h
index 6541af2..dddcdca 100644
--- a/korganizer/koprefs.h
+++ b/korganizer/koprefs.h
@@ -237,12 +237,13 @@ class KOPrefs : public KPimPrefs
bool mListViewMonthTimespan;
bool mWNViewShowsParents;
bool mWNViewShowsPast;
bool mWNViewShowLocation;
bool mTodoViewShowsPercentage;
bool mTodoViewUsesCatColors;
+ bool mMonthViewUsesBigFont;
bool mTodoViewUsesSmallFont;
bool mTodoViewUsesForegroundColor;
bool mMonthViewUsesForegroundColor;
bool mHightlightDateTimeEdit;
bool mShortDateInViewer;
diff --git a/korganizer/koprefsdialog.cpp b/korganizer/koprefsdialog.cpp
index 580dff2..452d019 100644
--- a/korganizer/koprefsdialog.cpp
+++ b/korganizer/koprefsdialog.cpp
@@ -756,13 +756,16 @@ void KOPrefsDialog::setupViewsTab()
#ifdef DESKTOP_VERSION
KPrefsDialogWidBool *enableMonthScroll =
addWidBool(i18n("Enable scrollbars in month view cells"),
&(KOPrefs::instance()->mEnableMonthScroll),topFrame);
topLayout->addWidget(enableMonthScroll->checkBox(),ii++,0);
#endif
-
+ dummy =
+ addWidBool(i18n("Week view mode uses bigger font"),
+ &(KOPrefs::instance()->mMonthViewUsesBigFont),topFrame);
+ topLayout->addWidget(dummy->checkBox(),ii++,0);
dummy =
addWidBool(i18n("Show Sat/Sun together"),
&(KOPrefs::instance()->mMonthViewSatSunTog),topFrame);
topLayout->addWidget(dummy->checkBox(),ii++,0);
KPrefsDialogWidBool *coloredCategoriesInMonthView =