korganizer

calprintmonthconfig_base.cpp

00001 #include <kdialog.h>
00002 #include <klocale.h>
00003 /****************************************************************************
00004 ** Form implementation generated from reading ui file './calprintmonthconfig_base.ui'
00005 **
00006 ** Created: Wed Feb 5 12:13:57 2014
00007 **
00008 ** WARNING! All changes made in this file will be lost!
00009 ****************************************************************************/
00010 
00011 #include "calprintmonthconfig_base.h"
00012 
00013 #include <qvariant.h>
00014 #include <qgroupbox.h>
00015 #include <qlabel.h>
00016 #include <kcombobox.h>
00017 #include <knuminput.h>
00018 #include <qcheckbox.h>
00019 #include <qlayout.h>
00020 #include <qtooltip.h>
00021 #include <qwhatsthis.h>
00022 
00023 /*
00024  *  Constructs a CalPrintMonthConfig_Base as a child of 'parent', with the
00025  *  name 'name' and widget flags set to 'f'.
00026  */
00027 CalPrintMonthConfig_Base::CalPrintMonthConfig_Base( QWidget* parent, const char* name, WFlags fl )
00028     : QWidget( parent, name, fl )
00029 {
00030     if ( !name )
00031     setName( "CalPrintMonth_Base" );
00032     CalPrintMonth_BaseLayout = new QVBoxLayout( this, 0, 6, "CalPrintMonth_BaseLayout"); 
00033 
00034     mDateRangeGroup = new QGroupBox( this, "mDateRangeGroup" );
00035     mDateRangeGroup->setColumnLayout(0, Qt::Vertical );
00036     mDateRangeGroup->layout()->setSpacing( 6 );
00037     mDateRangeGroup->layout()->setMargin( 11 );
00038     mDateRangeGroupLayout = new QHBoxLayout( mDateRangeGroup->layout() );
00039     mDateRangeGroupLayout->setAlignment( Qt::AlignTop );
00040 
00041     mFromDateLabel = new QLabel( mDateRangeGroup, "mFromDateLabel" );
00042     mDateRangeGroupLayout->addWidget( mFromDateLabel );
00043 
00044     mFromMonth = new KComboBox( FALSE, mDateRangeGroup, "mFromMonth" );
00045     mDateRangeGroupLayout->addWidget( mFromMonth );
00046 
00047     mFromYear = new KIntSpinBox( mDateRangeGroup, "mFromYear" );
00048     mFromYear->setMaxValue( 3000 );
00049     mFromYear->setValue( 2007 );
00050     mDateRangeGroupLayout->addWidget( mFromYear );
00051 
00052     mToDateLabel = new QLabel( mDateRangeGroup, "mToDateLabel" );
00053     mDateRangeGroupLayout->addWidget( mToDateLabel );
00054 
00055     mToMonth = new KComboBox( FALSE, mDateRangeGroup, "mToMonth" );
00056     mDateRangeGroupLayout->addWidget( mToMonth );
00057 
00058     mToYear = new KIntSpinBox( mDateRangeGroup, "mToYear" );
00059     mToYear->setMaxValue( 3000 );
00060     mToYear->setValue( 2007 );
00061     mDateRangeGroupLayout->addWidget( mToYear );
00062     spacer1 = new QSpacerItem( 17, 21, QSizePolicy::Expanding, QSizePolicy::Minimum );
00063     mDateRangeGroupLayout->addItem( spacer1 );
00064     CalPrintMonth_BaseLayout->addWidget( mDateRangeGroup );
00065 
00066     mWeekNumbers = new QCheckBox( this, "mWeekNumbers" );
00067     CalPrintMonth_BaseLayout->addWidget( mWeekNumbers );
00068 
00069     mRecurDaily = new QCheckBox( this, "mRecurDaily" );
00070     CalPrintMonth_BaseLayout->addWidget( mRecurDaily );
00071 
00072     mRecurWeekly = new QCheckBox( this, "mRecurWeekly" );
00073     CalPrintMonth_BaseLayout->addWidget( mRecurWeekly );
00074 
00075     mIncludeTodos = new QCheckBox( this, "mIncludeTodos" );
00076     mIncludeTodos->setEnabled( FALSE );
00077     CalPrintMonth_BaseLayout->addWidget( mIncludeTodos );
00078 
00079     mSingleLineLimit = new QCheckBox( this, "mSingleLineLimit" );
00080     CalPrintMonth_BaseLayout->addWidget( mSingleLineLimit );
00081 
00082     mColors = new QCheckBox( this, "mColors" );
00083     CalPrintMonth_BaseLayout->addWidget( mColors );
00084     spacer2 = new QSpacerItem( 21, 30, QSizePolicy::Minimum, QSizePolicy::Expanding );
00085     CalPrintMonth_BaseLayout->addItem( spacer2 );
00086     languageChange();
00087     resize( QSize(557, 245).expandedTo(minimumSizeHint()) );
00088     clearWState( WState_Polished );
00089 
00090     // tab order
00091     setTabOrder( mWeekNumbers, mRecurDaily );
00092     setTabOrder( mRecurDaily, mRecurWeekly );
00093     setTabOrder( mRecurWeekly, mIncludeTodos );
00094 
00095     // buddies
00096     mFromDateLabel->setBuddy( mFromMonth );
00097     mToDateLabel->setBuddy( mToMonth );
00098 }
00099 
00100 /*
00101  *  Destroys the object and frees any allocated resources
00102  */
00103 CalPrintMonthConfig_Base::~CalPrintMonthConfig_Base()
00104 {
00105     // no need to delete child widgets, Qt does it all for us
00106 }
00107 
00108 /*
00109  *  Sets the strings of the subwidgets using the current
00110  *  language.
00111  */
00112 void CalPrintMonthConfig_Base::languageChange()
00113 {
00114     setCaption( tr2i18n( "CalPrintMonth_Base" ) );
00115     mDateRangeGroup->setTitle( tr2i18n( "Date && Time Range" ) );
00116     mFromDateLabel->setText( tr2i18n( "&Start month:" ) );
00117     QWhatsThis::add( mFromDateLabel, tr2i18n( "When you want to print more months at once, you can define a month range. This option defines the first month to be printed. Use the option <i>End month</i> to define the last month in this range." ) );
00118     QWhatsThis::add( mFromMonth, tr2i18n( "When you want to print more months at once, you can define a month range. This option defines the first month to be printed. Use the on <i>End month</i> to define the last month in this range." ) );
00119     QWhatsThis::add( mFromYear, tr2i18n( "When you want to print more months at once, you can define a month range. This option defines the first month to be printed. Use the on <i>End month</i> to define the last month in this range." ) );
00120     mToDateLabel->setText( tr2i18n( "&End month:" ) );
00121     QWhatsThis::add( mToDateLabel, tr2i18n( "When you want to print more months at once, you can define a month range. This option defines the last month to be printed. Use the option <i>Start month</i> to define the first month in this range." ) );
00122     QWhatsThis::add( mToMonth, tr2i18n( "When you want to print more months at once, you can define a month range. This option defines the last month to be printed. Use the option <i>Start month</i> to define the first month in this range." ) );
00123     QWhatsThis::add( mToYear, tr2i18n( "When you want to print more months at once, you can define a month range. This option defines the last month to be printed. Use the option <i>Start month</i> to define the first month in this range." ) );
00124     mWeekNumbers->setText( tr2i18n( "Print week &numbers" ) );
00125     mWeekNumbers->setAccel( QKeySequence( tr2i18n( "Alt+N" ) ) );
00126     QWhatsThis::add( mWeekNumbers, tr2i18n( "Enable this to print week numbers at the left of each row." ) );
00127     mRecurDaily->setText( tr2i18n( "Print daily re&curring to-dos and events" ) );
00128     mRecurDaily->setAccel( QKeySequence( tr2i18n( "Alt+C" ) ) );
00129     QWhatsThis::add( mRecurDaily, tr2i18n( "With this option it is possible to leave out the daily recurring to-dos and events in the print. They take a lot of space and make the month view needlessly complicated." ) );
00130     mRecurWeekly->setText( tr2i18n( "Print weekl&y recurring to-dos and events" ) );
00131     mRecurWeekly->setAccel( QKeySequence( tr2i18n( "Alt+Y" ) ) );
00132     QWhatsThis::add( mRecurWeekly, tr2i18n( "Similar to \"Print daily recurring to-dos and events\". Weekly to-dos and events will be omitted when making a print of the selected month." ) );
00133     mIncludeTodos->setText( tr2i18n( "Include to-&dos that are due on the printed day(s)" ) );
00134     mIncludeTodos->setAccel( QKeySequence( tr2i18n( "Alt+D" ) ) );
00135     QWhatsThis::add( mIncludeTodos, tr2i18n( "Check this option if you want to have to-dos on the print, placed by their due date." ) );
00136     mSingleLineLimit->setText( tr2i18n( "Limit events in each day to a &single line" ) );
00137     mSingleLineLimit->setAccel( QKeySequence( tr2i18n( "Alt+S" ) ) );
00138     QWhatsThis::add( mSingleLineLimit, tr2i18n( "Check this option to limit events to a single line." ) );
00139     mColors->setText( tr2i18n( "&Use Colors" ) );
00140     mColors->setAccel( QKeySequence( tr2i18n( "Alt+U" ) ) );
00141     QWhatsThis::add( mColors, tr2i18n( "Enable this option if you want to print in color. The items will be printed using their category color." ) );
00142 }
00143 
00144 #include "calprintmonthconfig_base.moc"
KDE Home | KDE Accessibility Home | Description of Access Keys