summaryrefslogtreecommitdiffabout
path: root/korganizer/koeditorgeneral.cpp
Unidiff
Diffstat (limited to 'korganizer/koeditorgeneral.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/koeditorgeneral.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/korganizer/koeditorgeneral.cpp b/korganizer/koeditorgeneral.cpp
index 407a5d5..fd50b05 100644
--- a/korganizer/koeditorgeneral.cpp
+++ b/korganizer/koeditorgeneral.cpp
@@ -62,71 +62,71 @@
62KOEditorGeneral::KOEditorGeneral(QObject* parent, const char* name) : 62KOEditorGeneral::KOEditorGeneral(QObject* parent, const char* name) :
63 QObject( parent, name) 63 QObject( parent, name)
64{ 64{
65 mNextFocus = 0; 65 mNextFocus = 0;
66} 66}
67 67
68KOEditorGeneral::~KOEditorGeneral() 68KOEditorGeneral::~KOEditorGeneral()
69{ 69{
70} 70}
71 71
72void KOEditorGeneral::initHeader(QWidget *parent,QBoxLayout *topLayout) 72void KOEditorGeneral::initHeader(QWidget *parent,QBoxLayout *topLayout)
73{ 73{
74 QGridLayout *headerLayout = new QGridLayout(topLayout); 74 QGridLayout *headerLayout = new QGridLayout(topLayout);
75 75
76#if 0 76#if 0
77 mOwnerLabel = new QLabel(i18n("Owner:"),parent); 77 mOwnerLabel = new QLabel(i18n("Owner:"),parent);
78 headerLayout->addMultiCellWidget(mOwnerLabel,0,0,0,1); 78 headerLayout->addMultiCellWidget(mOwnerLabel,0,0,0,1);
79#endif 79#endif
80 // 1 on pda 80 // 1 on pda
81 // 11 on desktop 81 // 11 on desktop
82 headerLayout->setSpacing( (KDialog::spacingHint()-3)*2+1 ); 82 headerLayout->setSpacing( (KDialog::spacingHint()-3)*2+1 );
83 QLabel *summaryLabel = new QLabel(i18n("Summary:"),parent); 83 QLabel *summaryLabel = new QLabel(i18n("Summary:"),parent);
84 headerLayout->addWidget(summaryLabel,0,0); 84 headerLayout->addWidget(summaryLabel,0,0);
85 85
86 mSummaryEdit = new KOLocationBox(TRUE,parent, 10); 86 mSummaryEdit = new KOLocationBox(TRUE,parent, 50);
87 mSummaryEdit->setSizePolicy( QSizePolicy( QSizePolicy::Preferred ,QSizePolicy::MinimumExpanding ,FALSE) ); 87 mSummaryEdit->setSizePolicy( QSizePolicy( QSizePolicy::Preferred ,QSizePolicy::MinimumExpanding ,FALSE) );
88 //mSummaryEdit->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)5 ,(QSizePolicy::SizeType)3 ,FALSE) ); 88 //mSummaryEdit->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)5 ,(QSizePolicy::SizeType)3 ,FALSE) );
89 //qDebug("h %d %d ", summaryLabel->sizeHint().height(),mSummaryEdit->sizeHint().height() ); 89 //qDebug("h %d %d ", summaryLabel->sizeHint().height(),mSummaryEdit->sizeHint().height() );
90 int hei = (summaryLabel->sizeHint().height() + mSummaryEdit->sizeHint().height())/2; 90 int hei = (summaryLabel->sizeHint().height() + mSummaryEdit->sizeHint().height())/2;
91 if ( QApplication::desktop()->width() > 320 ) 91 if ( QApplication::desktop()->width() > 320 )
92 mSummaryEdit->setMaximumHeight( hei +6 ); 92 mSummaryEdit->setMaximumHeight( hei +6 );
93 //qDebug("%d %d %d %d %d %d ", QSizePolicy::Fixed , QSizePolicy::Minimum , QSizePolicy:: Maximum , QSizePolicy:: Preferred , QSizePolicy:: MinimumExpanding , QSizePolicy::Expanding ); 93 //qDebug("%d %d %d %d %d %d ", QSizePolicy::Fixed , QSizePolicy::Minimum , QSizePolicy:: Maximum , QSizePolicy:: Preferred , QSizePolicy:: MinimumExpanding , QSizePolicy::Expanding );
94 // SizeType { Fixed = 0, Minimum = MayGrow, Maximum = MayShrink, Preferred = MayGrow|MayShrink, MinimumExpanding = Minimum|ExpMask, Expanding = MinimumExpanding|MayShrink } 94 // SizeType { Fixed = 0, Minimum = MayGrow, Maximum = MayShrink, Preferred = MayGrow|MayShrink, MinimumExpanding = Minimum|ExpMask, Expanding = MinimumExpanding|MayShrink }
95 // mSummaryEdit = new QLineEdit(parent); 95 // mSummaryEdit = new QLineEdit(parent);
96 if ( QApplication::desktop()->height() < 320 ) 96 if ( QApplication::desktop()->height() < 320 )
97 headerLayout->addWidget(mSummaryEdit,0,1); 97 headerLayout->addWidget(mSummaryEdit,0,1);
98 else 98 else
99 headerLayout->addMultiCellWidget(mSummaryEdit,0,0,1,2); 99 headerLayout->addMultiCellWidget(mSummaryEdit,0,0,1,2);
100 connect ( mSummaryEdit->lineEdit(), SIGNAL ( returnPressed() ), this, SIGNAL (allAccepted () ) ); 100 connect ( mSummaryEdit->lineEdit(), SIGNAL ( returnPressed() ), this, SIGNAL (allAccepted () ) );
101 101
102 QLabel *locationLabel = new QLabel(i18n("Location:"),parent); 102 QLabel *locationLabel = new QLabel(i18n("Location:"),parent);
103 if ( QApplication::desktop()->height() < 320 ) 103 if ( QApplication::desktop()->height() < 320 )
104 headerLayout->addWidget(locationLabel,0,2); 104 headerLayout->addWidget(locationLabel,0,2);
105 else 105 else
106 headerLayout->addWidget(locationLabel,1,0); 106 headerLayout->addWidget(locationLabel,1,0);
107 107
108 mLocationEdit = new KOLocationBox(TRUE,parent,10); 108 mLocationEdit = new KOLocationBox(TRUE,parent,30);
109 mLocationEdit->setSizePolicy( QSizePolicy( QSizePolicy::Preferred ,QSizePolicy::MinimumExpanding ,FALSE) ); 109 mLocationEdit->setSizePolicy( QSizePolicy( QSizePolicy::Preferred ,QSizePolicy::MinimumExpanding ,FALSE) );
110 if ( QApplication::desktop()->width() > 320 && QApplication::desktop()->height() > 240 ) 110 if ( QApplication::desktop()->width() > 320 && QApplication::desktop()->height() > 240 )
111 mLocationEdit->setMaximumHeight( hei + 6); 111 mLocationEdit->setMaximumHeight( hei + 6);
112 112
113 // mLocationEdit = new QLineEdit(parent); 113 // mLocationEdit = new QLineEdit(parent);
114 connect ( mLocationEdit->lineEdit(), SIGNAL ( returnPressed() ), this, SIGNAL (allAccepted () ) ); 114 connect ( mLocationEdit->lineEdit(), SIGNAL ( returnPressed() ), this, SIGNAL (allAccepted () ) );
115 115
116 mCalendarBox = new QComboBox ( parent ); 116 mCalendarBox = new QComboBox ( parent );
117 mCalendarBox->setSizePolicy( QSizePolicy( QSizePolicy::Preferred ,QSizePolicy::MinimumExpanding ,FALSE) ); 117 mCalendarBox->setSizePolicy( QSizePolicy( QSizePolicy::Preferred ,QSizePolicy::MinimumExpanding ,FALSE) );
118 if ( QApplication::desktop()->height() < 320 ) { 118 if ( QApplication::desktop()->height() < 320 ) {
119 headerLayout->addWidget(mLocationEdit,0,3); 119 headerLayout->addWidget(mLocationEdit,0,3);
120 headerLayout->addWidget(mCalendarBox,0,4); 120 headerLayout->addWidget(mCalendarBox,0,4);
121 headerLayout->setColStretch( 1, 10); 121 headerLayout->setColStretch( 1, 10);
122 headerLayout->setColStretch( 3, 10); 122 headerLayout->setColStretch( 3, 10);
123 mCalendarBox->setMaximumWidth( 64 ); 123 mCalendarBox->setMaximumWidth( 64 );
124 } 124 }
125 else { 125 else {
126 headerLayout->addWidget(mLocationEdit,1,1); 126 headerLayout->addWidget(mLocationEdit,1,1);
127 headerLayout->addWidget(mCalendarBox,1,2); 127 headerLayout->addWidget(mCalendarBox,1,2);
128 headerLayout->setColStretch( 1, 3); 128 headerLayout->setColStretch( 1, 3);
129 headerLayout->setColStretch( 2, 1); 129 headerLayout->setColStretch( 2, 1);
130 } 130 }
131 131
132} 132}