2 * \file QCharacterDialog.C
3 * This file is part of LyX, the document processor.
4 * Licence details can be found in the file COPYING.
8 * Full author contact details are available in file CREDITS.
13 #include "QCharacterDialog.h"
15 #include <qcheckbox.h>
16 #include <qpushbutton.h>
18 #include <QCloseEvent>
23 QCharacterDialog::QCharacterDialog(QCharacter * form)
27 connect(okPB, SIGNAL(clicked()),
28 form_, SLOT(slotOK()));
29 connect(applyPB, SIGNAL(clicked()),
30 form_, SLOT(slotApply()));
31 connect(closePB, SIGNAL(clicked()),
32 form_, SLOT(slotClose()));
34 connect( miscCO, SIGNAL( activated(int) ), this, SLOT( change_adaptor() ) );
35 connect( sizeCO, SIGNAL( activated(int) ), this, SLOT( change_adaptor() ) );
36 connect( familyCO, SIGNAL( activated(int) ), this, SLOT( change_adaptor() ) );
37 connect( seriesCO, SIGNAL( activated(int) ), this, SLOT( change_adaptor() ) );
38 connect( shapeCO, SIGNAL( activated(int) ), this, SLOT( change_adaptor() ) );
39 connect( colorCO, SIGNAL( activated(int) ), this, SLOT( change_adaptor() ) );
40 connect( langCO, SIGNAL( activated(int) ), this, SLOT( change_adaptor() ) );
41 connect( toggleallCB, SIGNAL( toggled(bool) ), this, SLOT( change_adaptor() ) );
45 void QCharacterDialog::change_adaptor()
49 if (!autoapplyCB->isChecked())
52 // to be really good here, we should set the combos to the values of
53 // the current text, and make it appear as "no change" if the values
54 // stay the same between applys. Might be difficult though wrt to a
57 familyCO->setCurrentIndex(0);
58 seriesCO->setCurrentIndex(0);
59 sizeCO->setCurrentIndex(0);
60 shapeCO->setCurrentIndex(0);
61 miscCO->setCurrentIndex(0);
62 langCO->setCurrentIndex(0);
63 colorCO->setCurrentIndex(0);
67 void QCharacterDialog::closeEvent(QCloseEvent * e)
73 } // namespace frontend
76 #include "QCharacterDialog_moc.cpp"