2001-08-19 13:25:15 +00:00
|
|
|
/**
|
|
|
|
* \file QTabularCreate.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.
|
2001-08-19 13:25:15 +00:00
|
|
|
*
|
2002-10-20 01:48:28 +00:00
|
|
|
* \author John Levon
|
2002-09-24 13:57:09 +00:00
|
|
|
*
|
|
|
|
* Full author contact details are available in file CREDITS
|
2001-08-19 13:25:15 +00:00
|
|
|
*/
|
|
|
|
|
|
|
|
#include <config.h>
|
|
|
|
|
2001-08-28 04:17:49 +00:00
|
|
|
|
|
|
|
#include "ControlTabularCreate.h"
|
2001-08-19 13:25:15 +00:00
|
|
|
#include "QTabularCreateDialog.h"
|
|
|
|
#include "QTabularCreate.h"
|
2001-08-28 04:17:49 +00:00
|
|
|
#include "Qt2BC.h"
|
2002-12-17 20:37:13 +00:00
|
|
|
#include "qt_helpers.h"
|
2002-03-21 21:21:28 +00:00
|
|
|
#include "debug.h"
|
2001-08-19 13:25:15 +00:00
|
|
|
|
2001-08-28 04:17:49 +00:00
|
|
|
#include <qspinbox.h>
|
|
|
|
#include <qpushbutton.h>
|
2001-08-19 13:25:15 +00:00
|
|
|
|
2003-03-09 19:34:46 +00:00
|
|
|
typedef QController<ControlTabularCreate, QView<QTabularCreateDialog> > base_class;
|
2001-08-19 13:25:15 +00:00
|
|
|
|
2002-10-20 01:48:28 +00:00
|
|
|
|
2003-03-09 19:34:46 +00:00
|
|
|
QTabularCreate::QTabularCreate(Dialog & parent)
|
|
|
|
: base_class(parent, qt_("LyX: Insert Table"))
|
2001-08-19 13:25:15 +00:00
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2001-08-28 04:17:49 +00:00
|
|
|
void QTabularCreate::build_dialog()
|
2001-08-19 13:25:15 +00:00
|
|
|
{
|
2001-08-28 04:17:49 +00:00
|
|
|
dialog_.reset(new QTabularCreateDialog(this));
|
2001-08-19 13:25:15 +00:00
|
|
|
|
2003-03-10 03:13:28 +00:00
|
|
|
bcview().setOK(dialog_->okPB);
|
|
|
|
bcview().setCancel(dialog_->closePB);
|
2001-08-19 13:25:15 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
2001-08-28 04:17:49 +00:00
|
|
|
void QTabularCreate::apply()
|
2001-08-19 13:25:15 +00:00
|
|
|
{
|
2001-08-28 04:17:49 +00:00
|
|
|
controller().params().first = dialog_->rowsSB->value();
|
|
|
|
controller().params().second = dialog_->columnsSB->value();
|
2001-08-19 13:25:15 +00:00
|
|
|
}
|