2 * \file GuiTabularCreate.cpp
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 "GuiTabularCreate.h"
15 #include "ControlTabularCreate.h"
16 #include "EmptyTable.h"
18 #include <QCloseEvent>
20 #include <QPushButton>
26 GuiTabularCreateDialog::GuiTabularCreateDialog(LyXView & lv)
27 : GuiDialog(lv, "tabularcreate")
30 setViewTitle(_("Insert Table"));
31 setController(new ControlTabularCreate(*this));
34 columnsSB->setValue(5);
36 connect(okPB, SIGNAL(clicked()), this, SLOT(slotOK()));
37 connect(closePB, SIGNAL(clicked()), this, SLOT(slotClose()));
39 connect(rowsSB, SIGNAL(valueChanged(int)),
40 this, SLOT(rowsChanged(int)));
41 connect(columnsSB, SIGNAL(valueChanged(int)),
42 this, SLOT(columnsChanged(int)));
44 bc().setPolicy(ButtonPolicy::IgnorantPolicy);
46 bc().setCancel(closePB);
50 ControlTabularCreate & GuiTabularCreateDialog::controller() const
52 return static_cast<ControlTabularCreate &>(Dialog::controller());
56 void GuiTabularCreateDialog::columnsChanged(int)
62 void GuiTabularCreateDialog::rowsChanged(int)
68 void GuiTabularCreateDialog::applyView()
70 controller().params().first = rowsSB->value();
71 controller().params().second = columnsSB->value();
74 } // namespace frontend
77 #include "GuiTabularCreate_moc.cpp"