-rw-r--r-- | korganizer/calendarview.cpp | 33 | ||||
-rw-r--r-- | korganizer/calendarview.h | 3 | ||||
-rw-r--r-- | korganizer/komonthview.cpp | 5 | ||||
-rw-r--r-- | korganizer/koprefs.cpp | 28 | ||||
-rw-r--r-- | korganizer/ktimeedit.cpp | 8 | ||||
-rw-r--r-- | korganizer/mainwindow.cpp | 27 | ||||
-rw-r--r-- | korganizer/navigatorbar.cpp | 3 | ||||
-rw-r--r-- | libkdepim/kdatepicker.cpp | 10 | ||||
-rw-r--r-- | microkde/kdatetbl.cpp | 26 | ||||
-rw-r--r-- | microkde/kglobalsettings.cpp | 10 |
10 files changed, 98 insertions, 55 deletions
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp index 0fbaa9a..a9de65a 100644 --- a/korganizer/calendarview.cpp +++ b/korganizer/calendarview.cpp | |||
@@ -2459,19 +2459,9 @@ void CalendarView::beamDone( Ir *ir ) | |||
2459 | 2459 | ||
2460 | void CalendarView::moveIncidence(Incidence * inc ) | 2460 | void CalendarView::moveIncidence(Incidence * inc ) |
2461 | { | 2461 | { |
2462 | if ( !inc ) return; | 2462 | if ( !inc ) return; |
2463 | // qDebug("showDatePickerForIncidence( ) "); | 2463 | showDatePickerPopup(); |
2464 | if ( mDateFrame->isVisible() ) | ||
2465 | mDateFrame->hide(); | ||
2466 | else { | ||
2467 | int w =mDatePicker->sizeHint().width()+2*mDateFrame->lineWidth() ; | ||
2468 | int h = mDatePicker->sizeHint().height()+2*mDateFrame->lineWidth() ; | ||
2469 | int dw = QApplication::desktop()->width(); | ||
2470 | int dh = QApplication::desktop()->height(); | ||
2471 | mDateFrame->setGeometry( (dw-w)/2, (dh - h )/2 ,w,h ); | ||
2472 | mDateFrame->show(); | ||
2473 | } | ||
2474 | mDatePickerMode = 2; | 2464 | mDatePickerMode = 2; |
2475 | mMoveIncidence = inc ; | 2465 | mMoveIncidence = inc ; |
2476 | QDate da; | 2466 | QDate da; |
2477 | if ( mMoveIncidence->type() == "Todo" ) { | 2467 | if ( mMoveIncidence->type() == "Todo" ) { |
@@ -2486,21 +2476,34 @@ void CalendarView::moveIncidence(Incidence * inc ) | |||
2486 | //PENDING set date for recurring incidence to date of recurrence | 2476 | //PENDING set date for recurring incidence to date of recurrence |
2487 | //mMoveIncidenceOldDate; | 2477 | //mMoveIncidenceOldDate; |
2488 | mDatePicker->setDate( da ); | 2478 | mDatePicker->setDate( da ); |
2489 | } | 2479 | } |
2490 | void CalendarView::showDatePicker( ) | 2480 | void CalendarView::showDatePickerPopup() |
2491 | { | 2481 | { |
2492 | //qDebug("CalendarView::showDatePicker( ) "); | 2482 | if ( mDateFrame->isVisible() ) |
2493 | if ( mDateFrame->isVisible() ) | ||
2494 | mDateFrame->hide(); | 2483 | mDateFrame->hide(); |
2495 | else { | 2484 | else { |
2485 | int offX = 0, offY = 0; | ||
2486 | #ifdef DESKTOP_VERSION | ||
2487 | int w =mDatePicker->sizeHint().width() ; | ||
2488 | int h = mDatePicker->sizeHint().height() ; | ||
2489 | int dw = topLevelWidget()->width(); | ||
2490 | int dh = topLevelWidget()->height(); | ||
2491 | offX = topLevelWidget()->x(); | ||
2492 | offY = topLevelWidget()->y(); | ||
2493 | #else | ||
2496 | int w =mDatePicker->sizeHint().width() ; | 2494 | int w =mDatePicker->sizeHint().width() ; |
2497 | int h = mDatePicker->sizeHint().height() ; | 2495 | int h = mDatePicker->sizeHint().height() ; |
2498 | int dw = QApplication::desktop()->width(); | 2496 | int dw = QApplication::desktop()->width(); |
2499 | int dh = QApplication::desktop()->height(); | 2497 | int dh = QApplication::desktop()->height(); |
2500 | mDateFrame->setGeometry( (dw-w)/2, (dh - h )/2 ,w,h ); | 2498 | #endif |
2499 | mDateFrame->setGeometry( (dw-w)/2+offX, (dh - h )/2+offY ,w,h ); | ||
2501 | mDateFrame->show(); | 2500 | mDateFrame->show(); |
2502 | } | 2501 | } |
2502 | } | ||
2503 | void CalendarView::showDatePicker( ) | ||
2504 | { | ||
2505 | showDatePickerPopup(); | ||
2503 | mDatePickerMode = 1; | 2506 | mDatePickerMode = 1; |
2504 | mDatePicker->setDate( mNavigator->selectedDates().first() ); | 2507 | mDatePicker->setDate( mNavigator->selectedDates().first() ); |
2505 | } | 2508 | } |
2506 | 2509 | ||
diff --git a/korganizer/calendarview.h b/korganizer/calendarview.h index 731298d..e626ea3 100644 --- a/korganizer/calendarview.h +++ b/korganizer/calendarview.h | |||
@@ -440,9 +440,10 @@ class CalendarView : public KOrg::CalendarViewBase, public KCal::Calendar::Obser | |||
440 | const QString &datebookFile, | 440 | const QString &datebookFile, |
441 | const QString &tasklistFile ); | 441 | const QString &tasklistFile ); |
442 | void syncExternal( int mode ); | 442 | void syncExternal( int mode ); |
443 | void slotSelectPickerDate( QDate ) ; | 443 | void slotSelectPickerDate( QDate ) ; |
444 | void showDatePicker( ) ; | 444 | void showDatePicker() ; |
445 | void showDatePickerPopup() ; | ||
445 | void moveIncidence(Incidence *) ; | 446 | void moveIncidence(Incidence *) ; |
446 | void beamIncidence(Incidence *) ; | 447 | void beamIncidence(Incidence *) ; |
447 | void beamCalendar() ; | 448 | void beamCalendar() ; |
448 | void beamFilteredCalendar() ; | 449 | void beamFilteredCalendar() ; |
diff --git a/korganizer/komonthview.cpp b/korganizer/komonthview.cpp index 6ae4c6f..02d2585 100644 --- a/korganizer/komonthview.cpp +++ b/korganizer/komonthview.cpp | |||
@@ -924,10 +924,13 @@ KOMonthView::KOMonthView(Calendar *calendar, QWidget *parent, const char *name) | |||
924 | 924 | ||
925 | emit incidenceSelected( 0 ); | 925 | emit incidenceSelected( 0 ); |
926 | #ifndef DESKTOP_VERSION | 926 | #ifndef DESKTOP_VERSION |
927 | resize( QApplication::desktop()->size() ); | 927 | resize( QApplication::desktop()->size() ); |
928 | computeLayout(); | 928 | #else |
929 | resize(640, 480 ); | ||
929 | #endif | 930 | #endif |
931 | computeLayout(); | ||
932 | |||
930 | } | 933 | } |
931 | 934 | ||
932 | KOMonthView::~KOMonthView() | 935 | KOMonthView::~KOMonthView() |
933 | { | 936 | { |
diff --git a/korganizer/koprefs.cpp b/korganizer/koprefs.cpp index 576c265..5bfe2a1 100644 --- a/korganizer/koprefs.cpp +++ b/korganizer/koprefs.cpp | |||
@@ -35,8 +35,9 @@ | |||
35 | #include <qstringlist.h> | 35 | #include <qstringlist.h> |
36 | #include <stdlib.h> | 36 | #include <stdlib.h> |
37 | 37 | ||
38 | #include <kglobal.h> | 38 | #include <kglobal.h> |
39 | #include <kglobalsettings.h> | ||
39 | #include <kconfig.h> | 40 | #include <kconfig.h> |
40 | #include <klocale.h> | 41 | #include <klocale.h> |
41 | #include <kdebug.h> | 42 | #include <kdebug.h> |
42 | #include <kemailsettings.h> | 43 | #include <kemailsettings.h> |
@@ -61,15 +62,18 @@ KOPrefs::KOPrefs() : | |||
61 | QColor defaultWorkingHoursColor = QColor(170,223,150);//160,160,160); | 62 | QColor defaultWorkingHoursColor = QColor(170,223,150);//160,160,160); |
62 | QColor defaultTodoDueTodayColor = QColor(255,220,100); | 63 | QColor defaultTodoDueTodayColor = QColor(255,220,100); |
63 | QColor defaultTodoOverdueColor = QColor(255,153,125); | 64 | QColor defaultTodoOverdueColor = QColor(255,153,125); |
64 | 65 | ||
66 | /* | ||
65 | mTimeBarFont = QFont("helvetica",10);//,QFont::Bold); | 67 | mTimeBarFont = QFont("helvetica",10);//,QFont::Bold); |
66 | mDefaultViewFont = QFont("helvetica",10); | 68 | mDefaultViewFont = QFont("helvetica",10); |
67 | mDefaultMonthViewFont = QFont("helvetica",8); | 69 | mDefaultMonthViewFont = QFont("helvetica",8); |
68 | mMarcusBainsFont= QFont("helvetica",10); | 70 | mMarcusBainsFont= QFont("helvetica",10); |
69 | mDateNavigatorFont= QFont("helvetica",10, QFont::Bold); | 71 | mDateNavigatorFont= QFont("helvetica",10, QFont::Bold); |
70 | mEditBoxFont = QFont("helvetica",12); | 72 | mEditBoxFont = QFont("helvetica",12); |
71 | mJornalViewFont = QFont("helvetica",12); | 73 | mJornalViewFont = QFont("helvetica",12); |
74 | */ | ||
75 | |||
72 | 76 | ||
73 | KPrefs::setCurrentGroup("General"); | 77 | KPrefs::setCurrentGroup("General"); |
74 | 78 | ||
75 | 79 | ||
@@ -155,20 +159,20 @@ KOPrefs::KOPrefs() : | |||
155 | addItemInt("Default Calendar Format",&mDefaultFormat,FormatICalendar); | 159 | addItemInt("Default Calendar Format",&mDefaultFormat,FormatICalendar); |
156 | 160 | ||
157 | KPrefs::setCurrentGroup("Fonts"); | 161 | KPrefs::setCurrentGroup("Fonts"); |
158 | // qDebug(" KPrefs::setCurrentGroup(Fonts); "); | 162 | // qDebug(" KPrefs::setCurrentGroup(Fonts); "); |
159 | addItemFont("TimeBar Font",&mTimeBarFont); | 163 | addItemFont("TimeBar Font",&mTimeBarFont,KGlobalSettings::generalFont() ); |
160 | addItemFont("MonthView Font",&mMonthViewFont); | 164 | addItemFont("MonthView Font",&mMonthViewFont,KGlobalSettings::generalFont()); |
161 | addItemFont("AgendaView Font",&mAgendaViewFont); | 165 | addItemFont("AgendaView Font",&mAgendaViewFont,KGlobalSettings::generalFont()); |
162 | addItemFont("MarcusBains Font",&mMarcusBainsFont); | 166 | addItemFont("MarcusBains Font",&mMarcusBainsFont,KGlobalSettings::generalFont()); |
163 | addItemFont("TimeLabels Font",&mTimeLabelsFont); | 167 | addItemFont("TimeLabels Font",&mTimeLabelsFont,KGlobalSettings::generalFont()); |
164 | addItemFont("TodoView Font",&mTodoViewFont); | 168 | addItemFont("TodoView Font",&mTodoViewFont,KGlobalSettings::generalFont()); |
165 | addItemFont("ListView Font",&mListViewFont); | 169 | addItemFont("ListView Font",&mListViewFont,KGlobalSettings::generalFont()); |
166 | addItemFont("DateNavigator Font",&mDateNavigatorFont); | 170 | addItemFont("DateNavigator Font",&mDateNavigatorFont,KGlobalSettings::generalFont()); |
167 | addItemFont("EditBox Font",&mEditBoxFont); | 171 | addItemFont("EditBox Font",&mEditBoxFont,KGlobalSettings::generalFont()); |
168 | addItemFont("JournalView Font",&mJornalViewFont); | 172 | addItemFont("JournalView Font",&mJornalViewFont,KGlobalSettings::generalFont()); |
169 | addItemFont("WhatsNextView Font",&mWhatsNextFont); | 173 | addItemFont("WhatsNextView Font",&mWhatsNextFont,KGlobalSettings::generalFont()); |
170 | addItemFont("EventView Font",&mEventViewFont); | 174 | addItemFont("EventView Font",&mEventViewFont,KGlobalSettings::generalFont()); |
171 | 175 | ||
172 | KPrefs::setCurrentGroup("RemoteSyncing"); | 176 | KPrefs::setCurrentGroup("RemoteSyncing"); |
173 | addItemString("ActiveSyncPort",&mActiveSyncPort,"9197" ); | 177 | addItemString("ActiveSyncPort",&mActiveSyncPort,"9197" ); |
174 | addItemString("ActiveSyncIP",&mActiveSyncIP,"192.168.0.40" ); | 178 | addItemString("ActiveSyncIP",&mActiveSyncIP,"192.168.0.40" ); |
diff --git a/korganizer/ktimeedit.cpp b/korganizer/ktimeedit.cpp index 5222ac9..61a0931 100644 --- a/korganizer/ktimeedit.cpp +++ b/korganizer/ktimeedit.cpp | |||
@@ -48,12 +48,14 @@ KOTimeEdit::KOTimeEdit(QWidget *parent, QTime qt, const char *name) | |||
48 | : QComboBox(TRUE, parent, name) | 48 | : QComboBox(TRUE, parent, name) |
49 | { | 49 | { |
50 | setInsertionPolicy(NoInsertion); | 50 | setInsertionPolicy(NoInsertion); |
51 | mFlagKeyPressed = false; | 51 | mFlagKeyPressed = false; |
52 | 52 | if ( QApplication::desktop()->height() <= 480 ) { | |
53 | if ( QApplication::desktop()->width() < 650 ) | ||
54 | setSizeLimit ( 6 ); | 53 | setSizeLimit ( 6 ); |
55 | mTime = qt; | 54 | } else { |
55 | setSizeLimit ( 12 ); | ||
56 | } | ||
57 | mTime = qt; | ||
56 | 58 | ||
57 | // mNoTimeString = i18n("No Time"); | 59 | // mNoTimeString = i18n("No Time"); |
58 | // insertItem( mNoTimeString ); | 60 | // insertItem( mNoTimeString ); |
59 | 61 | ||
diff --git a/korganizer/mainwindow.cpp b/korganizer/mainwindow.cpp index 7810bf9..61c39f5 100644 --- a/korganizer/mainwindow.cpp +++ b/korganizer/mainwindow.cpp | |||
@@ -2029,18 +2029,35 @@ void MainWindow::printCal() | |||
2029 | void MainWindow::weekAction() | 2029 | void MainWindow::weekAction() |
2030 | { | 2030 | { |
2031 | int month; | 2031 | int month; |
2032 | KPopupFrame* popup = new KPopupFrame(this); | 2032 | KPopupFrame* popup = new KPopupFrame(this); |
2033 | int size = 12; | 2033 | KDateInternalWeekPicker* picker = new KDateInternalWeekPicker(10, popup); |
2034 | if ( QApplication::desktop()->width() >= 480 ) | ||
2035 | size = 18; | ||
2036 | KDateInternalWeekPicker* picker = new KDateInternalWeekPicker(size, popup); | ||
2037 | // ----- | 2034 | // ----- |
2038 | picker->resize(picker->sizeHint()); | 2035 | picker->resize(picker->sizeHint()); |
2039 | popup->setMainWidget(picker); | 2036 | popup->setMainWidget(picker); |
2040 | picker->setFocus(); | 2037 | picker->setFocus(); |
2041 | connect(picker, SIGNAL(closeMe(int)), popup, SLOT(close(int))); | 2038 | connect(picker, SIGNAL(closeMe(int)), popup, SLOT(close(int))); |
2042 | if(popup->exec(iconToolBar->mapToGlobal(QPoint(0, iconToolBar->height())))) | 2039 | int x = 0; |
2040 | int y = iconToolBar->height(); | ||
2041 | int dX = 0; | ||
2042 | int dY = 0; | ||
2043 | if ( iconToolBar->orientation () == Qt:: Horizontal ) { | ||
2044 | if ( iconToolBar->y() > height()/2 ) { | ||
2045 | dY = iconToolBar->height()+picker->sizeHint().height(); | ||
2046 | y = 0; | ||
2047 | } | ||
2048 | } else { | ||
2049 | if ( iconToolBar->x() > width()/2 ) { // right side | ||
2050 | x=0; | ||
2051 | dX= iconToolBar->width()+picker->sizeHint().width(); | ||
2052 | y = 0; | ||
2053 | } else { | ||
2054 | x= iconToolBar->width(); | ||
2055 | y = 0; | ||
2056 | } | ||
2057 | } | ||
2058 | qDebug("dax %d dy %d %d %d ", dX, dY, iconToolBar->x(), iconToolBar->y() ); | ||
2059 | if(popup->exec(iconToolBar->mapToGlobal(QPoint(x,y)-QPoint( dX,dY)))) | ||
2043 | { | 2060 | { |
2044 | month = picker->getResult(); | 2061 | month = picker->getResult(); |
2045 | emit selectWeek ( month ); | 2062 | emit selectWeek ( month ); |
2046 | //qDebug("weekSelected %d ", month); | 2063 | //qDebug("weekSelected %d ", month); |
diff --git a/korganizer/navigatorbar.cpp b/korganizer/navigatorbar.cpp index f05e6f6..4a31c77 100644 --- a/korganizer/navigatorbar.cpp +++ b/korganizer/navigatorbar.cpp | |||
@@ -39,8 +39,9 @@ | |||
39 | #include <knotifyclient.h> | 39 | #include <knotifyclient.h> |
40 | #include "kdatetbl.h" | 40 | #include "kdatetbl.h" |
41 | 41 | ||
42 | #include "koglobals.h" | 42 | #include "koglobals.h" |
43 | #include <kglobalsettings.h> | ||
43 | #include "koprefs.h" | 44 | #include "koprefs.h" |
44 | #ifndef KORG_NOPLUGINS | 45 | #ifndef KORG_NOPLUGINS |
45 | #include "kocore.h" | 46 | #include "kocore.h" |
46 | #endif | 47 | #endif |
@@ -60,9 +61,9 @@ NavigatorBar::NavigatorBar( const QDate & date, QWidget *parent, const char *nam | |||
60 | mCtrlFrame->setLineWidth(1); | 61 | mCtrlFrame->setLineWidth(1); |
61 | 62 | ||
62 | topLayout->addWidget( mCtrlFrame ); | 63 | topLayout->addWidget( mCtrlFrame ); |
63 | 64 | ||
64 | QFont tfont = font(); | 65 | QFont tfont = KGlobalSettings::generalFont();//font(); |
65 | if ( QApplication::desktop()->width() >= 480 ) | 66 | if ( QApplication::desktop()->width() >= 480 ) |
66 | tfont.setPointSize(tfont.pointSize()+2); | 67 | tfont.setPointSize(tfont.pointSize()+2); |
67 | tfont.setBold(true); | 68 | tfont.setBold(true); |
68 | 69 | ||
diff --git a/libkdepim/kdatepicker.cpp b/libkdepim/kdatepicker.cpp index d8bc9f5..2be9c9e 100644 --- a/libkdepim/kdatepicker.cpp +++ b/libkdepim/kdatepicker.cpp | |||
@@ -32,8 +32,9 @@ | |||
32 | #include <qlineedit.h> | 32 | #include <qlineedit.h> |
33 | #include <qvalidator.h> | 33 | #include <qvalidator.h> |
34 | #include <kdebug.h> | 34 | #include <kdebug.h> |
35 | #include <knotifyclient.h> | 35 | #include <knotifyclient.h> |
36 | #include <kglobalsettings.h> | ||
36 | #include "kdatetbl.h" | 37 | #include "kdatetbl.h" |
37 | #include "kdateedit.h" | 38 | #include "kdateedit.h" |
38 | //#include "kdatepicker.moc" | 39 | //#include "kdatepicker.moc" |
39 | 40 | ||
@@ -50,16 +51,11 @@ KDatePicker::KDatePicker(QWidget *parent, QDate dt, const char *name) | |||
50 | val(new KDateValidator(this)) | 51 | val(new KDateValidator(this)) |
51 | //table(new KDateTable(this)), | 52 | //table(new KDateTable(this)), |
52 | //fontsize(1) | 53 | //fontsize(1) |
53 | { | 54 | { |
54 | // ----- | 55 | setFont ( KGlobalSettings::generalFont() ); |
55 | int size = 12; | ||
56 | if ( QApplication::desktop()->width() >= 480 ) | ||
57 | size = 18; | ||
58 | fontsize = size; | ||
59 | setFont ( QFont("helvetica",size) ); | ||
60 | table = new KDateTable(this); | 56 | table = new KDateTable(this); |
61 | setFontSize(size); | 57 | setFontSize(font().pointSize()+2); |
62 | //line->setValidator(val); | 58 | //line->setValidator(val); |
63 | lineDate = new KDateEdit( this, "dateediipicker", true ); | 59 | lineDate = new KDateEdit( this, "dateediipicker", true ); |
64 | yearForward->setPixmap(SmallIcon("2rightarrowB")); | 60 | yearForward->setPixmap(SmallIcon("2rightarrowB")); |
65 | yearBackward->setPixmap(SmallIcon("2leftarrowB")); | 61 | yearBackward->setPixmap(SmallIcon("2leftarrowB")); |
diff --git a/microkde/kdatetbl.cpp b/microkde/kdatetbl.cpp index fce0e5a..e827412 100644 --- a/microkde/kdatetbl.cpp +++ b/microkde/kdatetbl.cpp | |||
@@ -197,10 +197,14 @@ KDateTable::paintCell(QPainter *painter, int row, int col) | |||
197 | painter->drawRect(0, 0, w, h); | 197 | painter->drawRect(0, 0, w, h); |
198 | painter->setPen(pen); | 198 | painter->setPen(pen); |
199 | painter->drawText(0, 0, w, h, AlignCenter, text, -1, &rect); | 199 | painter->drawText(0, 0, w, h, AlignCenter, text, -1, &rect); |
200 | } | 200 | } |
201 | if(rect.width()>maxCell.width()) maxCell.setWidth(rect.width()); | 201 | /* |
202 | if(rect.height()>maxCell.height()) maxCell.setHeight(rect.height()); | 202 | if(rect.width()>maxCell.width()) maxCell.setWidth(rect.width()); |
203 | if(rect.height()>maxCell.height()) { | ||
204 | maxCell.setHeight(rect.height()); | ||
205 | } | ||
206 | */ | ||
203 | } | 207 | } |
204 | 208 | ||
205 | void | 209 | void |
206 | KDateTable::keyPressEvent( QKeyEvent *e ) | 210 | KDateTable::keyPressEvent( QKeyEvent *e ) |
@@ -312,11 +316,17 @@ KDateTable::setFontSize(int size) | |||
312 | } | 316 | } |
313 | // ----- compare with a real wide number and add some space: | 317 | // ----- compare with a real wide number and add some space: |
314 | rect=metrics.boundingRect(QString::fromLatin1("88")); | 318 | rect=metrics.boundingRect(QString::fromLatin1("88")); |
315 | maxCell.setWidth(QMAX(maxCell.width()+2, rect.width())); | 319 | maxCell.setWidth(QMAX(maxCell.width()+2, rect.width())); |
320 | #ifdef DESKTOP_VERSION | ||
321 | maxCell.setHeight(QMAX(maxCell.height()+8, rect.height())); | ||
322 | #else | ||
316 | maxCell.setHeight(QMAX(maxCell.height()+4, rect.height())); | 323 | maxCell.setHeight(QMAX(maxCell.height()+4, rect.height())); |
317 | if ( maxCell.width() * 1000 / maxCell.height() > 1900 ) | 324 | #endif |
325 | if ( maxCell.width() * 1000 / maxCell.height() > 1900 ) { | ||
318 | maxCell.setHeight(maxCell.width() * 1000 / 1900 ); | 326 | maxCell.setHeight(maxCell.width() * 1000 / 1900 ); |
327 | qDebug("setmax "); | ||
328 | } | ||
319 | } | 329 | } |
320 | 330 | ||
321 | void | 331 | void |
322 | KDateTable::contentsMousePressEvent(QMouseEvent *e) | 332 | KDateTable::contentsMousePressEvent(QMouseEvent *e) |
@@ -442,9 +452,9 @@ KDateInternalMonthPicker::KDateInternalMonthPicker | |||
442 | // ----- | 452 | // ----- |
443 | activeCol = -1; | 453 | activeCol = -1; |
444 | activeRow = -1; | 454 | activeRow = -1; |
445 | font=KGlobalSettings::generalFont(); | 455 | font=KGlobalSettings::generalFont(); |
446 | font.setPointSize(fontsize); | 456 | //font.setPointSize(fontsize); |
447 | setFont(font); | 457 | setFont(font); |
448 | setHScrollBarMode(AlwaysOff); | 458 | setHScrollBarMode(AlwaysOff); |
449 | setVScrollBarMode(AlwaysOff); | 459 | setVScrollBarMode(AlwaysOff); |
450 | setFrameStyle(QFrame::NoFrame); | 460 | setFrameStyle(QFrame::NoFrame); |
@@ -760,9 +770,9 @@ KDateInternalWeekPicker::KDateInternalWeekPicker | |||
760 | // ----- | 770 | // ----- |
761 | activeCol = -1; | 771 | activeCol = -1; |
762 | activeRow = -1; | 772 | activeRow = -1; |
763 | font=KGlobalSettings::generalFont(); | 773 | font=KGlobalSettings::generalFont(); |
764 | font.setPointSize(fontsize); | 774 | //font.setPointSize(fontsize); |
765 | setFont(font); | 775 | setFont(font); |
766 | setHScrollBarMode(AlwaysOff); | 776 | setHScrollBarMode(AlwaysOff); |
767 | setVScrollBarMode(AlwaysOff); | 777 | setVScrollBarMode(AlwaysOff); |
768 | setFrameStyle(QFrame::NoFrame); | 778 | setFrameStyle(QFrame::NoFrame); |
@@ -781,9 +791,13 @@ KDateInternalWeekPicker::KDateInternalWeekPicker | |||
781 | rect=metrics.boundingRect(QString::number( i )); | 791 | rect=metrics.boundingRect(QString::number( i )); |
782 | if(max.width()<rect.width()) max.setWidth(rect.width()); | 792 | if(max.width()<rect.width()) max.setWidth(rect.width()); |
783 | if(max.height()<rect.height()) max.setHeight(rect.height()); | 793 | if(max.height()<rect.height()) max.setHeight(rect.height()); |
784 | } | 794 | } |
785 | 795 | if ( QApplication::desktop()->width() > 640 ) { | |
796 | |||
797 | max.setWidth(max.width()+6); | ||
798 | max.setHeight(max.height()+8); | ||
799 | } | ||
786 | } | 800 | } |
787 | 801 | ||
788 | QSize | 802 | QSize |
789 | KDateInternalWeekPicker::sizeHint() const | 803 | KDateInternalWeekPicker::sizeHint() const |
diff --git a/microkde/kglobalsettings.cpp b/microkde/kglobalsettings.cpp index 2fff8fc..30e793f 100644 --- a/microkde/kglobalsettings.cpp +++ b/microkde/kglobalsettings.cpp | |||
@@ -9,18 +9,20 @@ QFont KGlobalSettings::generalFont() | |||
9 | { | 9 | { |
10 | int size = 12; | 10 | int size = 12; |
11 | if (QApplication::desktop()->width() < 480 ) | 11 | if (QApplication::desktop()->width() < 480 ) |
12 | size = 10; | 12 | size = 10; |
13 | return QFont("helvetica",size); | 13 | QFont f = QApplication::font(); |
14 | f.setPointSize( size ); | ||
15 | return f; | ||
14 | } | 16 | } |
15 | QFont KGlobalSettings::toolBarFont() | 17 | QFont KGlobalSettings::toolBarFont() |
16 | { | 18 | { |
17 | return QFont("helevetica",12); | 19 | return QApplication::font(); |
18 | } | 20 | } |
19 | 21 | ||
20 | QColor KGlobalSettings::toolBarHighlightColor() | 22 | QColor KGlobalSettings::toolBarHighlightColor() |
21 | { | 23 | { |
22 | return QColor("black"); | 24 | return QColor( "black" ); |
23 | } | 25 | } |
24 | 26 | ||
25 | QRect KGlobalSettings::desktopGeometry( QWidget * ) | 27 | QRect KGlobalSettings::desktopGeometry( QWidget * ) |
26 | { | 28 | { |
@@ -33,9 +35,9 @@ QRect KGlobalSettings::desktopGeometry( QWidget * ) | |||
33 | * see http://developer.kde.org/documentation/standards/kde/style/mouse/index.html | 35 | * see http://developer.kde.org/documentation/standards/kde/style/mouse/index.html |
34 | * @return true if single click mode, or false if double click mode. | 36 | * @return true if single click mode, or false if double click mode. |
35 | **/ | 37 | **/ |
36 | bool KGlobalSettings::singleClick() | 38 | bool KGlobalSettings::singleClick() |
37 | { | 39 | { |
38 | KConfig *c = KGlobal::config(); | 40 | KConfig *c = KGlobal::config(); |
39 | KConfigGroupSaver cgs( c, "KDE" ); | 41 | KConfigGroupSaver cgs( c, "KDE" ); |
40 | return c->readBoolEntry("SingleClick", KDE_DEFAULT_SINGLECLICK); | 42 | return c->readBoolEntry("SingleClick", KDE_DEFAULT_SINGLECLICK); |
41 | } | 43 | } |