author | zautrix <zautrix> | 2005-07-09 11:21:22 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-07-09 11:21:22 (UTC) |
commit | e98b8d5a8e01d5dd7cf6b8967d1065d72f61c908 (patch) (unidiff) | |
tree | 0687ea02ba6cd6071cad137593b8d0e0e21e910f /korganizer | |
parent | b51db424f4b1e558ab8c7c723859bb564c99d83b (diff) | |
download | kdepimpi-e98b8d5a8e01d5dd7cf6b8967d1065d72f61c908.zip kdepimpi-e98b8d5a8e01d5dd7cf6b8967d1065d72f61c908.tar.gz kdepimpi-e98b8d5a8e01d5dd7cf6b8967d1065d72f61c908.tar.bz2 |
fixxx
-rw-r--r-- | korganizer/journalentry.cpp | 35 |
1 files changed, 26 insertions, 9 deletions
diff --git a/korganizer/journalentry.cpp b/korganizer/journalentry.cpp index f0e0f86..739949d 100644 --- a/korganizer/journalentry.cpp +++ b/korganizer/journalentry.cpp | |||
@@ -82,5 +82,5 @@ JournalEntry::JournalEntry(Calendar *calendar,QWidget *parent) : | |||
82 | mTitle = new KOLocationBox(TRUE, vb, 30); | 82 | mTitle = new KOLocationBox(TRUE, vb, 30); |
83 | mTitle->setSizePolicy( QSizePolicy( QSizePolicy::MinimumExpanding ,QSizePolicy::Fixed ,FALSE) ); | 83 | mTitle->setSizePolicy( QSizePolicy( QSizePolicy::Preferred ,QSizePolicy::Fixed ,FALSE) ); |
84 | mCalendarBox = new QComboBox(vb); | 84 | mCalendarBox = new QComboBox(vb); |
85 | mCalendarBox->setSizePolicy( QSizePolicy( QSizePolicy::MinimumExpanding ,QSizePolicy::Fixed ,FALSE) ); | 85 | mCalendarBox->setSizePolicy( QSizePolicy( QSizePolicy::Preferred ,QSizePolicy::Fixed ,FALSE) ); |
86 | #ifndef DESKTOP_VERSION | 86 | #ifndef DESKTOP_VERSION |
@@ -90,3 +90,6 @@ JournalEntry::JournalEntry(Calendar *calendar,QWidget *parent) : | |||
90 | vb->setStretchFactor ( mTitle, 8 ); | 90 | vb->setStretchFactor ( mTitle, 8 ); |
91 | vb->setStretchFactor ( mCalendarBox, 3 ); | 91 | int limit = 3; |
92 | if ( QApplication::desktop()->width() < 640 ) | ||
93 | limit = 6; | ||
94 | vb->setStretchFactor ( mCalendarBox, limit ); | ||
92 | //mTitleLabel->setMargin(0); | 95 | //mTitleLabel->setMargin(0); |
@@ -118,4 +121,10 @@ JournalEntry::JournalEntry(Calendar *calendar,QWidget *parent) : | |||
118 | int maxwid = mDeskWid - mMaxWidDiff; | 121 | int maxwid = mDeskWid - mMaxWidDiff; |
119 | mTitle->setMaximumWidth( maxwid/2 +20 ); | 122 | if ( QApplication::desktop()->width() < 640 ) { |
120 | mCalendarBox->setMaximumWidth( maxwid/2 -20 ); | 123 | mTitle->setMaximumWidth( maxwid/2 +20 ); |
124 | mCalendarBox->setMaximumWidth( maxwid/2 -20); | ||
125 | } else { | ||
126 | mTitle->setMaximumWidth( (maxwid/4)*3); | ||
127 | mCalendarBox->setMaximumWidth( maxwid/2 ); | ||
128 | } | ||
129 | //mCalendarBox->setMaximumWidth( maxwid/2 -20 ); | ||
121 | mEditor->setWordWrap( KTextEdit::WidgetWidth ); | 130 | mEditor->setWordWrap( KTextEdit::WidgetWidth ); |
@@ -139,2 +148,3 @@ void JournalEntry::resizeEvent(QResizeEvent* e ) | |||
139 | #ifndef DESKTOP_VERSION | 148 | #ifndef DESKTOP_VERSION |
149 | |||
140 | if ( mDeskWid != QApplication::desktop()->width() ) { | 150 | if ( mDeskWid != QApplication::desktop()->width() ) { |
@@ -142,7 +152,14 @@ void JournalEntry::resizeEvent(QResizeEvent* e ) | |||
142 | int maxwid = mDeskWid - mMaxWidDiff; | 152 | int maxwid = mDeskWid - mMaxWidDiff; |
143 | mTitle->setMaximumWidth( maxwid/2 +20 ); | 153 | if ( QApplication::desktop()->width() < 640 ) { |
144 | mCalendarBox->setMaximumWidth( maxwid/2 -20 ); | 154 | mTitle->setMaximumWidth( maxwid/2 +20 ); |
155 | mCalendarBox->setMaximumWidth( maxwid/2 -20); | ||
156 | } | ||
157 | else { | ||
158 | mTitle->setMaximumWidth( (maxwid/4)*3); | ||
159 | mCalendarBox->setMaximumWidth( maxwid/2 ); | ||
160 | } | ||
161 | //mCalendarBox->setMaximumWidth( maxwid/2 -20 ); | ||
145 | } | 162 | } |
146 | setMaximumWidth( QApplication::desktop()->width() ); | 163 | //setMaximumWidth( QApplication::desktop()->width() ); |
147 | qDebug("MAXXX %d ", QApplication::desktop()->width()); | 164 | //qDebug("MAXXX %d ", QApplication::desktop()->width()); |
148 | #endif | 165 | #endif |