2006-03-05 17:24:44 +00:00
|
|
|
// -*- C++ -*-
|
|
|
|
/**
|
2007-08-31 05:53:55 +00:00
|
|
|
* \file GuiBox.h
|
2006-03-05 17:24:44 +00:00
|
|
|
* This file is part of LyX, the document processor.
|
|
|
|
* Licence details can be found in the file COPYING.
|
|
|
|
*
|
2008-11-14 15:58:50 +00:00
|
|
|
* \author Jürgen Spitzmüller
|
2007-10-06 10:23:51 +00:00
|
|
|
* \author Martin Vermeer (with useful hints from Angus Leeming)
|
2006-03-05 17:24:44 +00:00
|
|
|
*
|
|
|
|
* Full author contact details are available in file CREDITS.
|
|
|
|
*/
|
|
|
|
|
2007-08-31 22:16:11 +00:00
|
|
|
#ifndef GUIBOX_H
|
|
|
|
#define GUIBOX_H
|
2006-03-05 17:24:44 +00:00
|
|
|
|
2007-09-05 20:33:29 +00:00
|
|
|
#include "GuiDialog.h"
|
2007-08-11 15:48:15 +00:00
|
|
|
#include "ui_BoxUi.h"
|
2007-10-06 10:23:51 +00:00
|
|
|
#include "insets/InsetBox.h"
|
2007-04-24 10:56:22 +00:00
|
|
|
|
2007-10-06 10:23:51 +00:00
|
|
|
|
2006-03-05 17:24:44 +00:00
|
|
|
namespace lyx {
|
|
|
|
namespace frontend {
|
|
|
|
|
2007-10-09 19:34:27 +00:00
|
|
|
class GuiBox : public GuiDialog, public Ui::BoxUi
|
2007-09-05 20:33:29 +00:00
|
|
|
{
|
2007-04-24 10:56:22 +00:00
|
|
|
Q_OBJECT
|
2007-09-05 20:33:29 +00:00
|
|
|
|
2007-04-24 10:56:22 +00:00
|
|
|
public:
|
2007-11-23 09:44:02 +00:00
|
|
|
GuiBox(GuiView & lv);
|
2007-04-24 10:56:22 +00:00
|
|
|
|
2007-09-05 20:33:29 +00:00
|
|
|
private Q_SLOTS:
|
|
|
|
void change_adaptor();
|
2008-03-08 13:02:52 +00:00
|
|
|
void innerBoxChanged(QString const &);
|
2007-09-05 20:33:29 +00:00
|
|
|
void typeChanged(int);
|
|
|
|
void restoreClicked();
|
2007-12-04 09:25:50 +00:00
|
|
|
void pagebreakClicked();
|
2007-09-05 20:33:29 +00:00
|
|
|
|
|
|
|
private:
|
2006-03-05 17:24:44 +00:00
|
|
|
/// add and remove special lengths
|
|
|
|
void setSpecial(bool ibox);
|
|
|
|
/// only show valid inner box items
|
|
|
|
void setInnerType(bool frameless, int i);
|
2007-09-05 20:33:29 +00:00
|
|
|
|
2006-03-05 17:24:44 +00:00
|
|
|
/// Apply changes
|
2007-09-05 20:33:29 +00:00
|
|
|
void applyView();
|
2006-03-05 17:24:44 +00:00
|
|
|
/// update
|
2007-09-11 18:33:42 +00:00
|
|
|
void updateContents();
|
2007-09-05 20:33:29 +00:00
|
|
|
|
2007-10-06 10:23:51 +00:00
|
|
|
///
|
|
|
|
bool initialiseParams(std::string const & data);
|
|
|
|
///
|
|
|
|
void clearParams();
|
|
|
|
///
|
|
|
|
void dispatchParams();
|
|
|
|
///
|
|
|
|
bool isBufferDependent() const { return true; }
|
|
|
|
|
2006-03-05 17:24:44 +00:00
|
|
|
///
|
2008-03-08 13:02:52 +00:00
|
|
|
QStringList ids_;
|
2006-03-05 17:24:44 +00:00
|
|
|
///
|
2008-03-08 13:02:52 +00:00
|
|
|
QStringList gui_names_;
|
2006-03-05 17:24:44 +00:00
|
|
|
///
|
2008-03-08 13:02:52 +00:00
|
|
|
QStringList ids_spec_;
|
2006-03-05 17:24:44 +00:00
|
|
|
///
|
2008-03-08 13:02:52 +00:00
|
|
|
QStringList gui_names_spec_;
|
2007-10-06 10:23:51 +00:00
|
|
|
|
|
|
|
///
|
|
|
|
InsetBoxParams params_;
|
2006-03-05 17:24:44 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
} // namespace frontend
|
|
|
|
} // namespace lyx
|
|
|
|
|
2007-08-31 22:16:11 +00:00
|
|
|
#endif // GUIBOX_H
|