-rw-r--r-- | korganizer/koprefsdialog.cpp | 179 |
1 files changed, 100 insertions, 79 deletions
diff --git a/korganizer/koprefsdialog.cpp b/korganizer/koprefsdialog.cpp index 443508d..40e8a99 100644 --- a/korganizer/koprefsdialog.cpp +++ b/korganizer/koprefsdialog.cpp | |||
@@ -333,13 +333,13 @@ void KOPrefsDialog::setupSyncTab() | |||
333 | 333 | ||
334 | void KOPrefsDialog::setupMainTab() | 334 | void KOPrefsDialog::setupMainTab() |
335 | { | 335 | { |
336 | QFrame *topFrame = addPage(i18n("General"),0,0); | 336 | QFrame *topFrame = addPage(i18n("General"),0,0); |
337 | // DesktopIcon("identity",KIcon::SizeMedium)); | 337 | // DesktopIcon("identity",KIcon::SizeMedium)); |
338 | 338 | ||
339 | QGridLayout *topLayout = new QGridLayout(topFrame,6,2); | 339 | QGridLayout *topLayout = new QGridLayout(topFrame,5,2); |
340 | topLayout->setSpacing(spacingHint()); | 340 | topLayout->setSpacing(spacingHint()); |
341 | topLayout->setMargin(marginHint()); | 341 | topLayout->setMargin(marginHint()); |
342 | 342 | ||
343 | // KPrefsDialogWidBool *emailControlCenter = | 343 | // KPrefsDialogWidBool *emailControlCenter = |
344 | // addWidBool(i18n("&Use email settings from Control Center"), | 344 | // addWidBool(i18n("&Use email settings from Control Center"), |
345 | // &(KOPrefs::instance()->mEmailControlCenter),topFrame); | 345 | // &(KOPrefs::instance()->mEmailControlCenter),topFrame); |
@@ -354,53 +354,39 @@ void KOPrefsDialog::setupMainTab() | |||
354 | 354 | ||
355 | mEmailEdit = new QLineEdit(topFrame); | 355 | mEmailEdit = new QLineEdit(topFrame); |
356 | mEmailLabel = new QLabel(mEmailEdit, i18n("E&mail address:"),topFrame); | 356 | mEmailLabel = new QLabel(mEmailEdit, i18n("E&mail address:"),topFrame); |
357 | topLayout->addWidget(mEmailLabel,1,0); | 357 | topLayout->addWidget(mEmailLabel,1,0); |
358 | topLayout->addWidget(mEmailEdit,1,1); | 358 | topLayout->addWidget(mEmailEdit,1,1); |
359 | KPrefsDialogWidBool *wb; | 359 | KPrefsDialogWidBool *wb; |
360 | QHBox *dummy; | 360 | |
361 | if ( QApplication::desktop()->width() > 480 ) { | ||
362 | dummy = new QHBox(topFrame); | ||
363 | } else { | ||
364 | dummy = new QVBox(topFrame); | ||
365 | } | ||
366 | 361 | ||
367 | topLayout->addMultiCellWidget(dummy, 2,2,0,1); | ||
368 | addWidBool(i18n("Full menu bar(nr)"), | ||
369 | &(KOPrefs::instance()->mShowFullMenu),dummy); | ||
370 | 362 | ||
363 | KPrefsDialogWidBool *widbool = addWidBool(i18n("Full menu bar(nr)"), | ||
364 | &(KOPrefs::instance()->mShowFullMenu),topFrame); | ||
365 | topLayout->addMultiCellWidget( widbool->checkBox(), 2,2,0,1); | ||
371 | 366 | ||
372 | addWidBool(i18n("Mini icons in toolbar(nr)"), | 367 | |
373 | &(KOPrefs::instance()->mToolBarMiniIcons),dummy); | 368 | widbool = addWidBool(i18n("Mini icons in toolbar(nr)"), |
374 | 369 | &(KOPrefs::instance()->mToolBarMiniIcons),topFrame); | |
370 | topLayout->addMultiCellWidget( widbool->checkBox(), 3,3,0,1); | ||
375 | 371 | ||
376 | dummy = new QHBox(topFrame); | ||
377 | new QLabel(i18n("Days in What's Next:"),dummy); | ||
378 | mWhatsNextSpin = new QSpinBox(1,14,1,dummy); | ||
379 | |||
380 | topLayout->addMultiCellWidget(dummy,3,3,0,1); | ||
381 | 372 | ||
373 | KPrefsDialogWidBool *verticalScreen = | ||
374 | addWidBool(i18n("Show vertical screen (Needs restart)"), | ||
375 | &(KOPrefs::instance()->mVerticalScreen),topFrame); | ||
376 | //topLayout->addWidget(verticalScreen->checkBox(),ii++,0); | ||
377 | topLayout->addMultiCellWidget(verticalScreen->checkBox(),4,4,0,1); | ||
382 | 378 | ||
383 | 379 | ||
384 | dummy = new QHBox(topFrame); | 380 | QHBox *dummy = new QHBox(topFrame); |
385 | new QLabel(i18n("Days in Next-X-Days:"),dummy); | 381 | new QLabel(i18n("Days in Next-X-Days:"),dummy); |
386 | mNextXDaysSpin = new QSpinBox(2,14,1,dummy); | 382 | mNextXDaysSpin = new QSpinBox(2,14,1,dummy); |
387 | 383 | ||
388 | topLayout->addMultiCellWidget(dummy,4,4,0,1); | 384 | topLayout->addMultiCellWidget(dummy,5,5,0,1); |
389 | 385 | ||
390 | QHBox *prioBox = new QHBox(topFrame); | 386 | |
391 | // intervalBox->setSpacing(spacingHint()); | ||
392 | topLayout->addMultiCellWidget(prioBox,5,5,0,1); | ||
393 | QString messa = i18n("Show topmost todo prios in What's Next:"); | ||
394 | |||
395 | if ( QApplication::desktop()->width() < 300 ) | ||
396 | messa = i18n("Show topmost todo prios in What's N.:"); | ||
397 | QLabel *prioLabel = new QLabel(messa, prioBox); | ||
398 | mPrioSpin = new QSpinBox(0,5,1,prioBox); | ||
399 | if ( QApplication::desktop()->width() < 300 ) | ||
400 | mPrioSpin->setFixedWidth( 40 ); | ||
401 | 387 | ||
402 | // KPrefsDialogWidBool *bcc = | 388 | // KPrefsDialogWidBool *bcc = |
403 | // addWidBool(i18n("Send copy to owner when mailing events"), | 389 | // addWidBool(i18n("Send copy to owner when mailing events"), |
404 | // &(KOPrefs::instance()->mBcc),topFrame); | 390 | // &(KOPrefs::instance()->mBcc),topFrame); |
405 | // topLayout->addMultiCellWidget(bcc->checkBox(),4,4,0,1); | 391 | // topLayout->addMultiCellWidget(bcc->checkBox(),4,4,0,1); |
406 | 392 | ||
@@ -423,22 +409,18 @@ void KOPrefsDialog::setupMainTab() | |||
423 | new QLabel (i18n("AllDayAgenda Height:"), agendasize ); | 409 | new QLabel (i18n("AllDayAgenda Height:"), agendasize ); |
424 | 410 | ||
425 | 411 | ||
426 | mHourSizeSlider = new QSlider(24,47,1,24,Horizontal,agendasize); | 412 | mHourSizeSlider = new QSlider(24,47,1,24,Horizontal,agendasize); |
427 | topLayout->addMultiCellWidget(agendasize,7,7,0,1); | 413 | topLayout->addMultiCellWidget(agendasize,7,7,0,1); |
428 | */ | 414 | */ |
429 | KPrefsDialogWidBool *verticalScreen = | 415 | |
430 | addWidBool(i18n("Show vertical screen (Needs restart)"), | ||
431 | &(KOPrefs::instance()->mVerticalScreen),topFrame); | ||
432 | //topLayout->addWidget(verticalScreen->checkBox(),ii++,0); | ||
433 | topLayout->addMultiCellWidget(verticalScreen->checkBox(),7,7,0,1); | ||
434 | 416 | ||
435 | KPrefsDialogWidBool *ask = | 417 | KPrefsDialogWidBool *ask = |
436 | addWidBool(i18n("Ask for quit when closing KO/Pi"), | 418 | addWidBool(i18n("Ask for quit when closing KO/Pi"), |
437 | &(KOPrefs::instance()->mAskForQuit),topFrame); | 419 | &(KOPrefs::instance()->mAskForQuit),topFrame); |
438 | topLayout->addMultiCellWidget(ask->checkBox(),8,8,0,1); | 420 | topLayout->addMultiCellWidget(ask->checkBox(),7,7,0,1); |
439 | 421 | ||
440 | 422 | ||
441 | /* | 423 | /* |
442 | KPrefsDialogWidBool *confirmCheck = | 424 | KPrefsDialogWidBool *confirmCheck = |
443 | addWidBool(i18n("Confirm &deletes"),&(KOPrefs::instance()->mConfirm), | 425 | addWidBool(i18n("Confirm &deletes"),&(KOPrefs::instance()->mConfirm), |
444 | topFrame); | 426 | topFrame); |
@@ -603,108 +585,127 @@ void KOPrefsDialog::setupViewsTab() | |||
603 | int ii = 0; | 585 | int ii = 0; |
604 | KPrefsDialogWidBool *dummy = | 586 | KPrefsDialogWidBool *dummy = |
605 | addWidBool(i18n("Edit item on doubleclick (if not, show)"), | 587 | addWidBool(i18n("Edit item on doubleclick (if not, show)"), |
606 | &(KOPrefs::instance()->mEditOnDoubleClick),topFrame); | 588 | &(KOPrefs::instance()->mEditOnDoubleClick),topFrame); |
607 | topLayout->addWidget(dummy->checkBox(),ii++,0); | 589 | topLayout->addWidget(dummy->checkBox(),ii++,0); |
608 | 590 | ||
609 | dummy = | 591 | |
610 | addWidBool(i18n("Show time in agenda items"), | ||
611 | &(KOPrefs::instance()->mShowTimeInAgenda),topFrame); | ||
612 | topLayout->addWidget(dummy->checkBox(),ii++,0); | ||
613 | |||
614 | dummy = | ||
615 | addWidBool(i18n("Highlight current day in agenda"), | ||
616 | &(KOPrefs::instance()->mHighlightCurrentDay),topFrame); | ||
617 | topLayout->addWidget(dummy->checkBox(),ii++,0); | ||
618 | |||
619 | dummy = | ||
620 | addWidBool(i18n("Use light color for highlight current day"), | ||
621 | &(KOPrefs::instance()->mUseHighlightLightColor),topFrame); | ||
622 | topLayout->addWidget(dummy->checkBox(),ii++,0); | ||
623 | |||
624 | KPrefsDialogWidBool *dailyRecur = | ||
625 | addWidBool(i18n("Show events that recur daily in date nav."), | ||
626 | &(KOPrefs::instance()->mDailyRecur),topFrame); | ||
627 | topLayout->addWidget(dailyRecur->checkBox(),ii++,0); | ||
628 | 592 | ||
629 | KPrefsDialogWidBool *weeklyRecur = | ||
630 | addWidBool(i18n("Show ev. that recur weekly in date nav."), | ||
631 | &(KOPrefs::instance()->mWeeklyRecur),topFrame); | ||
632 | topLayout->addWidget(weeklyRecur->checkBox(),ii++,0); | ||
633 | if ( QApplication::desktop()->width() > 640 ) { | 593 | if ( QApplication::desktop()->width() > 640 ) { |
634 | 594 | ||
635 | KPrefsDialogWidBool *enableToolTips = | 595 | KPrefsDialogWidBool *enableToolTips = |
636 | addWidBool(i18n("Enable tooltips displaying summary of ev."), | 596 | addWidBool(i18n("Enable tooltips displaying summary of ev."), |
637 | &(KOPrefs::instance()->mEnableToolTips),topFrame); | 597 | &(KOPrefs::instance()->mEnableToolTips),topFrame); |
638 | topLayout->addWidget(enableToolTips->checkBox(),ii++,0); | 598 | topLayout->addWidget(enableToolTips->checkBox(),ii++,0); |
639 | 599 | ||
640 | } | 600 | } |
641 | 601 | ||
642 | KPrefsDialogWidBool *marcusBainsEnabled = | 602 | |
643 | addWidBool(i18n("Show Marcus Bains line"), | ||
644 | &(KOPrefs::instance()->mMarcusBainsEnabled),topFrame); | ||
645 | topLayout->addWidget(marcusBainsEnabled->checkBox(),ii++,0); | ||
646 | |||
647 | 603 | ||
648 | // topLayout->addWidget(hourSizeGroup,ii++,0); | 604 | // topLayout->addWidget(hourSizeGroup,ii++,0); |
649 | // topLayout->addMultiCellWidget(hourSizeGroup,ii,ii,0,0); | 605 | // topLayout->addMultiCellWidget(hourSizeGroup,ii,ii,0,0); |
650 | //topLayout->setRowStretch(11,1); | 606 | //topLayout->setRowStretch(11,1); |
651 | 607 | ||
652 | 608 | ||
653 | 609 | ||
654 | 610 | ||
655 | 611 | #if 0 | |
656 | 612 | ||
657 | topFrame = addPage(i18n("ViewChange"),0,0); | 613 | topFrame = addPage(i18n("ViewChange"),0,0); |
658 | // DesktopIcon("viewmag",KIcon::SizeMedium)); | 614 | // DesktopIcon("viewmag",KIcon::SizeMedium)); |
659 | 615 | ||
660 | topLayout = new QGridLayout(topFrame,6,1); | 616 | topLayout = new QGridLayout(topFrame,6,1); |
661 | topLayout->setSpacing(spacingHint()); | 617 | topLayout->setSpacing(spacingHint()); |
662 | topLayout->setMargin(marginHint()); | 618 | topLayout->setMargin(marginHint()); |
663 | ii = 0; | 619 | ii = 0; |
664 | 620 | ||
621 | #endif | ||
665 | 622 | ||
666 | dummy = | 623 | dummy = |
667 | addWidBool(i18n("Hold fullscreen on view change"), | 624 | addWidBool(i18n("Hold fullscreen on view change"), |
668 | &(KOPrefs::instance()->mViewChangeHoldFullscreen),topFrame); | 625 | &(KOPrefs::instance()->mViewChangeHoldFullscreen),topFrame); |
669 | topLayout->addWidget(dummy->checkBox(),ii++,0); | 626 | topLayout->addWidget(dummy->checkBox(),ii++,0); |
670 | 627 | ||
671 | dummy = | 628 | dummy = |
672 | addWidBool(i18n("Hold non-fullscreen on view change"), | 629 | addWidBool(i18n("Hold non-fullscreen on view change"), |
673 | &(KOPrefs::instance()->mViewChangeHoldNonFullscreen),topFrame); | 630 | &(KOPrefs::instance()->mViewChangeHoldNonFullscreen),topFrame); |
674 | topLayout->addWidget(dummy->checkBox(),ii++,0); | 631 | topLayout->addWidget(dummy->checkBox(),ii++,0); |
675 | 632 | ||
676 | 633 | ||
677 | KPrefsDialogWidBool *fullViewTodo = | ||
678 | addWidBool(i18n("Event list view uses full window"), | ||
679 | &(KOPrefs::instance()->mFullViewTodo),topFrame); | ||
680 | topLayout->addWidget(fullViewTodo->checkBox(),ii++,0); | ||
681 | 634 | ||
682 | KPrefsDialogWidBool *fullViewMonth = | 635 | KPrefsDialogWidBool *fullViewMonth = |
683 | addWidBool(i18n("Next days view uses full window"), | 636 | addWidBool(i18n("Next days view uses full window"), |
684 | &(KOPrefs::instance()->mFullViewMonth),topFrame); | 637 | &(KOPrefs::instance()->mFullViewMonth),topFrame); |
685 | topLayout->addWidget(fullViewMonth->checkBox(),ii++,0); | 638 | topLayout->addWidget(fullViewMonth->checkBox(),ii++,0); |
686 | 639 | ||
640 | |||
641 | KPrefsDialogWidBool *fullViewTodo = | ||
642 | addWidBool(i18n("Event list view uses full window"), | ||
643 | &(KOPrefs::instance()->mFullViewTodo),topFrame); | ||
644 | topLayout->addWidget(fullViewTodo->checkBox(),ii++,0); | ||
645 | dummy = | ||
646 | addWidBool(i18n("Listview uses monthly timespan"), | ||
647 | &(KOPrefs::instance()->mListViewMonthTimespan),topFrame); | ||
648 | topLayout->addWidget(dummy->checkBox(),ii++,0); | ||
649 | dummy = | ||
650 | addWidBool(i18n("Highlight selection in Time Edit"), | ||
651 | &(KOPrefs::instance()->mHightlightDateTimeEdit),topFrame); | ||
652 | topLayout->addWidget( dummy->checkBox(), ii++,0); | ||
653 | |||
654 | KPrefsDialogWidBool *dailyRecur = | ||
655 | addWidBool(i18n("Show events that recur daily in date nav."), | ||
656 | &(KOPrefs::instance()->mDailyRecur),topFrame); | ||
657 | topLayout->addWidget(dailyRecur->checkBox(),ii++,0); | ||
658 | |||
659 | KPrefsDialogWidBool *weeklyRecur = | ||
660 | addWidBool(i18n("Show ev. that recur weekly in date nav."), | ||
661 | &(KOPrefs::instance()->mWeeklyRecur),topFrame); | ||
662 | topLayout->addWidget(weeklyRecur->checkBox(),ii++,0); | ||
663 | |||
664 | topFrame = addPage(i18n("Agenda View"),0,0); | ||
665 | // DesktopIcon("viewmag",KIcon::SizeMedium)); | ||
666 | |||
667 | topLayout = new QGridLayout(topFrame,5,1); | ||
668 | topLayout->setSpacing(spacingHint()); | ||
669 | topLayout->setMargin(marginHint()); | ||
670 | ii = 0; | ||
671 | |||
672 | |||
673 | dummy = | ||
674 | addWidBool(i18n("Show time in agenda items"), | ||
675 | &(KOPrefs::instance()->mShowTimeInAgenda),topFrame); | ||
676 | topLayout->addWidget(dummy->checkBox(),ii++,0); | ||
677 | |||
678 | dummy = | ||
679 | addWidBool(i18n("Highlight current day in agenda"), | ||
680 | &(KOPrefs::instance()->mHighlightCurrentDay),topFrame); | ||
681 | topLayout->addWidget(dummy->checkBox(),ii++,0); | ||
682 | |||
683 | dummy = | ||
684 | addWidBool(i18n("Use light color for highlight current day"), | ||
685 | &(KOPrefs::instance()->mUseHighlightLightColor),topFrame); | ||
686 | topLayout->addWidget(dummy->checkBox(),ii++,0); | ||
687 | |||
688 | |||
689 | KPrefsDialogWidBool *marcusBainsEnabled = | ||
690 | addWidBool(i18n("Show current time"), | ||
691 | &(KOPrefs::instance()->mMarcusBainsEnabled),topFrame); | ||
692 | topLayout->addWidget(marcusBainsEnabled->checkBox(),ii++,0); | ||
693 | |||
694 | |||
687 | dummy = | 695 | dummy = |
688 | addWidBool(i18n("Set agenda to DayBeginsAt on change"), | 696 | addWidBool(i18n("Set agenda to DayBeginsAt on change"), |
689 | &(KOPrefs::instance()->mSetTimeToDayStartAt),topFrame); | 697 | &(KOPrefs::instance()->mSetTimeToDayStartAt),topFrame); |
690 | topLayout->addWidget(dummy->checkBox(),ii++,0); | 698 | topLayout->addWidget(dummy->checkBox(),ii++,0); |
691 | 699 | ||
692 | dummy = | 700 | dummy = |
693 | addWidBool(i18n("Set agenda to current time on change"), | 701 | addWidBool(i18n("Set agenda to current time on change"), |
694 | &(KOPrefs::instance()->mCenterOnCurrentTime),topFrame); | 702 | &(KOPrefs::instance()->mCenterOnCurrentTime),topFrame); |
695 | topLayout->addWidget(dummy->checkBox(),ii++,0); | 703 | topLayout->addWidget(dummy->checkBox(),ii++,0); |
696 | 704 | ||
697 | dummy = | 705 | |
698 | addWidBool(i18n("Listview uses monthly timespan"), | ||
699 | &(KOPrefs::instance()->mListViewMonthTimespan),topFrame); | ||
700 | topLayout->addWidget(dummy->checkBox(),ii++,0); | ||
701 | dummy = | ||
702 | addWidBool(i18n("Highlight selection in Time Edit"), | ||
703 | &(KOPrefs::instance()->mHightlightDateTimeEdit),topFrame); | ||
704 | topLayout->addWidget( dummy->checkBox(), ii++,0); | ||
705 | 706 | ||
706 | 707 | ||
707 | 708 | ||
708 | 709 | ||
709 | 710 | ||
710 | topFrame = addPage(i18n("Month View"),0,0); | 711 | topFrame = addPage(i18n("Month View"),0,0); |
@@ -805,12 +806,32 @@ void KOPrefsDialog::setupViewsTab() | |||
805 | // DesktopIcon("viewmag",KIcon::SizeMedium)); | 806 | // DesktopIcon("viewmag",KIcon::SizeMedium)); |
806 | 807 | ||
807 | topLayout = new QGridLayout(topFrame,4,1); | 808 | topLayout = new QGridLayout(topFrame,4,1); |
808 | topLayout->setSpacing(spacingHint()); | 809 | topLayout->setSpacing(spacingHint()); |
809 | topLayout->setMargin(marginHint()); | 810 | topLayout->setMargin(marginHint()); |
810 | ii = 0; | 811 | ii = 0; |
812 | |||
813 | |||
814 | QHBox* hdummy = new QHBox(topFrame); | ||
815 | new QLabel(i18n("Days in What's Next:"),hdummy); | ||
816 | mWhatsNextSpin = new QSpinBox(1,14,1,hdummy); | ||
817 | |||
818 | topLayout->addWidget(hdummy,ii++,0); | ||
819 | |||
820 | QHBox *prioBox = new QHBox(topFrame); | ||
821 | // intervalBox->setSpacing(spacingHint()); | ||
822 | topLayout->addWidget(prioBox,ii++,0); | ||
823 | QString messa = i18n("Show topmost todo prios in What's Next:"); | ||
824 | |||
825 | if ( QApplication::desktop()->width() < 300 ) | ||
826 | messa = i18n("Show topmost todo prios in What's N.:"); | ||
827 | QLabel *prioLabel = new QLabel(messa, prioBox); | ||
828 | mPrioSpin = new QSpinBox(0,5,1,prioBox); | ||
829 | if ( QApplication::desktop()->width() < 300 ) | ||
830 | mPrioSpin->setFixedWidth( 40 ); | ||
831 | |||
811 | KPrefsDialogWidBool *passwdk = | 832 | KPrefsDialogWidBool *passwdk = |
812 | 833 | ||
813 | addWidBool(i18n("Show events, that are done in \nWhat's Next view"), | 834 | addWidBool(i18n("Show events, that are done in \nWhat's Next view"), |
814 | &(KOPrefs::instance()->mWNViewShowsPast),topFrame); | 835 | &(KOPrefs::instance()->mWNViewShowsPast),topFrame); |
815 | topLayout->addWidget(passwdk->checkBox(), ii++,0); | 836 | topLayout->addWidget(passwdk->checkBox(), ii++,0); |
816 | passwdk = | 837 | passwdk = |