kaddressbook Library API Documentation

rbs_appearance.cpp

00001 #include <kdialog.h>
00002 #include <klocale.h>
00003 /****************************************************************************
00004 ** Form implementation generated from reading ui file './rbs_appearance.ui'
00005 **
00006 ** Created: Wed Mar 23 22:15:21 2005
00007 **      by: The User Interface Compiler ($Id: qt/main.cpp   3.3.4   edited Nov 24 2003 $)
00008 **
00009 ** WARNING! All changes made in this file will be lost!
00010 ****************************************************************************/
00011 
00012 #include "rbs_appearance.h"
00013 
00014 #include <qvariant.h>
00015 #include <qpushbutton.h>
00016 #include <qgroupbox.h>
00017 #include <qlabel.h>
00018 #include <klistbox.h>
00019 #include <qcheckbox.h>
00020 #include <qspinbox.h>
00021 #include <qlayout.h>
00022 #include <qtooltip.h>
00023 #include <qwhatsthis.h>
00024 #include "./rbs_appearance.ui.h"
00025 
00026 /*
00027  *  Constructs a RingBinderStyleAppearanceForm as a child of 'parent', with the
00028  *  name 'name' and widget flags set to 'f'.
00029  */
00030 RingBinderStyleAppearanceForm::RingBinderStyleAppearanceForm( QWidget* parent, const char* name, WFlags fl )
00031     : QWidget( parent, name, fl )
00032 {
00033     if ( !name )
00034     setName( "RingBinderStyleAppearanceForm" );
00035     RingBinderStyleAppearanceFormLayout = new QGridLayout( this, 1, 1, 11, 6, "RingBinderStyleAppearanceFormLayout"); 
00036 
00037     GroupBox1 = new QGroupBox( this, "GroupBox1" );
00038     QFont GroupBox1_font(  GroupBox1->font() );
00039     GroupBox1->setFont( GroupBox1_font ); 
00040     GroupBox1->setColumnLayout(0, Qt::Vertical );
00041     GroupBox1->layout()->setSpacing( 6 );
00042     GroupBox1->layout()->setMargin( 11 );
00043     GroupBox1Layout = new QGridLayout( GroupBox1->layout() );
00044     GroupBox1Layout->setAlignment( Qt::AlignTop );
00045 
00046     TextLabel1 = new QLabel( GroupBox1, "TextLabel1" );
00047     TextLabel1->setTextFormat( QLabel::RichText );
00048     TextLabel1->setAlignment( int( QLabel::WordBreak | QLabel::AlignVCenter ) );
00049 
00050     GroupBox1Layout->addMultiCellWidget( TextLabel1, 0, 0, 0, 1 );
00051 
00052     letterListBox = new KListBox( GroupBox1, "letterListBox" );
00053 
00054     GroupBox1Layout->addMultiCellWidget( letterListBox, 1, 3, 0, 0 );
00055 
00056     groupButton = new QPushButton( GroupBox1, "groupButton" );
00057 
00058     GroupBox1Layout->addWidget( groupButton, 1, 1 );
00059 
00060     ungroupButton = new QPushButton( GroupBox1, "ungroupButton" );
00061 
00062     GroupBox1Layout->addWidget( ungroupButton, 2, 1 );
00063     Spacer1 = new QSpacerItem( 16, 119, QSizePolicy::Minimum, QSizePolicy::Expanding );
00064     GroupBox1Layout->addItem( Spacer1, 3, 1 );
00065 
00066     RingBinderStyleAppearanceFormLayout->addMultiCellWidget( GroupBox1, 0, 1, 0, 0 );
00067 
00068     GroupBox3 = new QGroupBox( this, "GroupBox3" );
00069     GroupBox3->setColumnLayout(0, Qt::Vertical );
00070     GroupBox3->layout()->setSpacing( 6 );
00071     GroupBox3->layout()->setMargin( 11 );
00072     GroupBox3Layout = new QGridLayout( GroupBox3->layout() );
00073     GroupBox3Layout->setAlignment( Qt::AlignTop );
00074 
00075     cbFillEmpty = new QCheckBox( GroupBox3, "cbFillEmpty" );
00076     cbFillEmpty->setChecked( TRUE );
00077 
00078     GroupBox3Layout->addMultiCellWidget( cbFillEmpty, 0, 0, 0, 1 );
00079 
00080     cbAlwaysAllPages = new QCheckBox( GroupBox3, "cbAlwaysAllPages" );
00081     cbAlwaysAllPages->setEnabled( FALSE );
00082     cbAlwaysAllPages->setChecked( TRUE );
00083 
00084     GroupBox3Layout->addMultiCellWidget( cbAlwaysAllPages, 2, 2, 0, 1 );
00085 
00086     sblabel = new QLabel( GroupBox3, "sblabel" );
00087 
00088     GroupBox3Layout->addWidget( sblabel, 1, 0 );
00089 
00090     sbMinNumFill = new QSpinBox( GroupBox3, "sbMinNumFill" );
00091 
00092     GroupBox3Layout->addWidget( sbMinNumFill, 1, 1 );
00093 
00094     RingBinderStyleAppearanceFormLayout->addWidget( GroupBox3, 1, 1 );
00095 
00096     GroupBox2 = new QGroupBox( this, "GroupBox2" );
00097     GroupBox2->setColumnLayout(0, Qt::Vertical );
00098     GroupBox2->layout()->setSpacing( 6 );
00099     GroupBox2->layout()->setMargin( 11 );
00100     GroupBox2Layout = new QVBoxLayout( GroupBox2->layout() );
00101     GroupBox2Layout->setAlignment( Qt::AlignTop );
00102 
00103     cbPhoneNumbers = new QCheckBox( GroupBox2, "cbPhoneNumbers" );
00104     cbPhoneNumbers->setChecked( TRUE );
00105     GroupBox2Layout->addWidget( cbPhoneNumbers );
00106 
00107     cbEmails = new QCheckBox( GroupBox2, "cbEmails" );
00108     cbEmails->setChecked( TRUE );
00109     GroupBox2Layout->addWidget( cbEmails );
00110 
00111     cbStreetAddresses = new QCheckBox( GroupBox2, "cbStreetAddresses" );
00112     cbStreetAddresses->setChecked( TRUE );
00113     GroupBox2Layout->addWidget( cbStreetAddresses );
00114 
00115     cbOrganization = new QCheckBox( GroupBox2, "cbOrganization" );
00116     GroupBox2Layout->addWidget( cbOrganization );
00117 
00118     cbBirthday = new QCheckBox( GroupBox2, "cbBirthday" );
00119     GroupBox2Layout->addWidget( cbBirthday );
00120 
00121     RingBinderStyleAppearanceFormLayout->addWidget( GroupBox2, 0, 1 );
00122     languageChange();
00123     resize( QSize(798, 407).expandedTo(minimumSizeHint()) );
00124     clearWState( WState_Polished );
00125 
00126     // signals and slots connections
00127     connect( groupButton, SIGNAL( clicked() ), this, SLOT( groupLetter() ) );
00128     connect( ungroupButton, SIGNAL( clicked() ), this, SLOT( ungroupLetter() ) );
00129 }
00130 
00131 /*
00132  *  Destroys the object and frees any allocated resources
00133  */
00134 RingBinderStyleAppearanceForm::~RingBinderStyleAppearanceForm()
00135 {
00136     // no need to delete child widgets, Qt does it all for us
00137 }
00138 
00139 /*
00140  *  Sets the strings of the subwidgets using the current
00141  *  language.
00142  */
00143 void RingBinderStyleAppearanceForm::languageChange()
00144 {
00145     setCaption( tr2i18n( "Appearance" ) );
00146     GroupBox1->setTitle( tr2i18n( "Letter Groups" ) );
00147     TextLabel1->setText( tr2i18n( "Here you can group letters together as they are grouped in your time planner. Press 'group letter' to combine the selected letter with the letter group above it, press 'ungroup letter' to remove the last letter from a selected group." ) );
00148     groupButton->setText( tr2i18n( "Group Letter" ) );
00149     ungroupButton->setText( tr2i18n( "Ungroup Letter" ) );
00150     GroupBox3->setTitle( tr2i18n( "Miscellaneous" ) );
00151     cbFillEmpty->setText( tr2i18n( "Fill pages with empty address fields" ) );
00152     QWhatsThis::add( cbFillEmpty, tr2i18n( "If this option is turned on, behind the contacts on a page the remaining space will be filled with empty fields so you can add contacts manually later" ) );
00153     cbAlwaysAllPages->setText( tr2i18n( "Always print pages for all tabs" ) );
00154     QWhatsThis::add( cbAlwaysAllPages, tr2i18n( "If this box is checked, at least one page will be printed for every letter group, regardless of whether entries exist for this letter group. This is normally only useful in conjunction with the option 'fill pages with empty address fields'." ) );
00155     sblabel->setText( tr2i18n( "Min. number of empty fields:" ) );
00156     QWhatsThis::add( sblabel, tr2i18n( "If you often add contacts to your printout manually before entering them into the KDE addressbook, you should set this option to a value greater than 0: it determines how many empty address fields must be printed; if this many do not fit onto the page, another page with empty fields only will be printed." ) );
00157     QWhatsThis::add( sbMinNumFill, tr2i18n( "This is the minimum number of empty fields that have to be printed in addition to real entries; if this number is not reached on the first page, more pages with empty fields only may be appended." ) );
00158     GroupBox2->setTitle( tr2i18n( "Print Contact's Information" ) );
00159     cbPhoneNumbers->setText( tr2i18n( "Phone numbers" ) );
00160     cbEmails->setText( tr2i18n( "Email addresses" ) );
00161     cbStreetAddresses->setText( tr2i18n( "Street addresses" ) );
00162     cbOrganization->setText( tr2i18n( "Organization" ) );
00163     cbBirthday->setText( tr2i18n( "Birthday" ) );
00164 }
00165 
00166 #include "rbs_appearance.moc"
KDE Logo
This file is part of the documentation for kaddressbook Library Version 3.3.2.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Wed Mar 23 22:42:48 2005 by doxygen 1.3.9.1 written by Dimitri van Heesch, © 1997-2003