2002-01-25 17:46:18 +00:00
|
|
|
/**
|
|
|
|
* \file QFloatDialog.C
|
2002-09-24 13:57:09 +00:00
|
|
|
* This file is part of LyX, the document processor.
|
|
|
|
* Licence details can be found in the file COPYING.
|
2002-01-25 17:46:18 +00:00
|
|
|
*
|
2002-10-20 01:48:28 +00:00
|
|
|
* \author Edwin Leuven
|
2002-09-24 13:57:09 +00:00
|
|
|
*
|
2003-08-23 00:17:00 +00:00
|
|
|
* Full author contact details are available in file CREDITS.
|
2002-01-25 17:46:18 +00:00
|
|
|
*/
|
|
|
|
|
|
|
|
#include <config.h>
|
|
|
|
|
2004-05-20 09:36:28 +00:00
|
|
|
#include "QFloatDialog.h"
|
|
|
|
#include "QFloat.h"
|
2003-03-28 17:19:49 +00:00
|
|
|
#include "floatplacement.h"
|
|
|
|
|
2002-06-19 03:38:44 +00:00
|
|
|
#include <qpushbutton.h>
|
|
|
|
|
2002-10-20 01:48:28 +00:00
|
|
|
|
2004-05-19 15:11:37 +00:00
|
|
|
namespace lyx {
|
|
|
|
namespace frontend {
|
2002-10-20 01:48:28 +00:00
|
|
|
|
2002-01-25 17:46:18 +00:00
|
|
|
QFloatDialog::QFloatDialog(QFloat * form)
|
2004-06-02 20:13:18 +00:00
|
|
|
: QFloatDialogBase(0, 0, false, 0),
|
2002-01-25 17:46:18 +00:00
|
|
|
form_(form)
|
|
|
|
{
|
|
|
|
connect(restorePB, SIGNAL(clicked()),
|
|
|
|
form, SLOT(slotRestore()));
|
|
|
|
connect(okPB, SIGNAL(clicked()),
|
|
|
|
form, SLOT(slotOK()));
|
|
|
|
connect(applyPB, SIGNAL(clicked()),
|
|
|
|
form, SLOT(slotApply()));
|
|
|
|
connect(closePB, SIGNAL(clicked()),
|
|
|
|
form, SLOT(slotClose()));
|
2003-03-28 17:19:49 +00:00
|
|
|
|
|
|
|
// enable span columns checkbox
|
|
|
|
floatFP->useWide();
|
2004-04-03 08:37:12 +00:00
|
|
|
|
2004-03-29 11:38:39 +00:00
|
|
|
// enable sideways checkbox
|
|
|
|
floatFP->useSideways();
|
2003-03-28 17:19:49 +00:00
|
|
|
|
|
|
|
connect(floatFP, SIGNAL(changed()),
|
|
|
|
this, SLOT(change_adaptor()));
|
2002-01-25 17:46:18 +00:00
|
|
|
}
|
|
|
|
|
2002-03-21 21:21:28 +00:00
|
|
|
|
2002-01-25 17:46:18 +00:00
|
|
|
void QFloatDialog::change_adaptor()
|
|
|
|
{
|
|
|
|
form_->changed();
|
|
|
|
}
|
|
|
|
|
2002-03-21 21:21:28 +00:00
|
|
|
|
2002-01-25 17:46:18 +00:00
|
|
|
void QFloatDialog::closeEvent(QCloseEvent * e)
|
|
|
|
{
|
|
|
|
form_->slotWMHide();
|
|
|
|
e->accept();
|
|
|
|
}
|
2004-05-19 15:11:37 +00:00
|
|
|
|
|
|
|
} // namespace frontend
|
|
|
|
} // namespace lyx
|