#include <QComboBox>
#include <kdialog.h>
#include <klocale.h>
+#include <kicon.h>
#include <kiconloader.h>
#include <ktoolbar.h>
#include <kdebug.h>
int year = 0;
QString week = i18n("Week %1", d->calendar->weekNumber(day, &year));
if ( year != date.year() ) week += "*"; // show that this is a week from a different year
- d->selectWeek->insertItem(week);
+ d->selectWeek->addItem(week);
}
}
QBoxLayout * topLayout = new QVBoxLayout(this);
- d->navigationLayout = new QHBoxLayout(topLayout);
+ d->navigationLayout = new QHBoxLayout();
+ topLayout->addLayout(d->navigationLayout);
d->navigationLayout->addStretch();
yearBackward = new QToolButton(this);
yearBackward->setAutoRaise(true);
topLayout->addWidget(table);
- QBoxLayout * bottomLayout = new QHBoxLayout(topLayout);
+ QBoxLayout * bottomLayout = new QHBoxLayout();
+ topLayout->addLayout(bottomLayout);
bottomLayout->addWidget(d->todayButton);
bottomLayout->addWidget(line);
bottomLayout->addWidget(d->selectWeek);
d->navigationLayout->addSpacing(KDialog::spacingHint());
d->navigationLayout->addWidget(d->closeButton);
d->closeButton->setToolTip(i18n("Close"));
- d->closeButton->setPixmap( SmallIcon("remove") );
+ d->closeButton->setIcon( SmallIconSet("remove") );
connect( d->closeButton, SIGNAL( clicked() ),
topLevelWidget(), SLOT( close() ) );
}
m_doc = doc;
m_outputStream.setDevice(m_outputFile);
- m_outputStream.setEncoding(QTextStream::Latin1);
+ m_outputStream.setCodec("ISO-8851-1");
+ m_outputStream.setAutoDetectUnicode(false);
m_outputStream << "WordQuiz" << winendl;
m_outputStream << "5.9.0" << winendl << winendl;