4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
10 * \author Angus Leeming
12 * Full author contact details are available in file CREDITS.
18 #include "GuiDialog.h"
19 #include "ui_GraphicsUi.h"
21 #include "support/docstring.h"
22 #include "insets/InsetGraphics.h"
31 class InsetGraphicsParams;
35 class GuiGraphics : public GuiDialog, public Ui::GraphicsUi
40 GuiGraphics(GuiView & lv);
44 void change_adaptor();
46 void on_browsePB_clicked();
47 void on_getPB_clicked();
48 void on_filename_textChanged(const QString &);
49 void on_scaleCB_toggled(bool);
50 void on_WidthCB_toggled(bool);
51 void on_HeightCB_toggled(bool);
52 void on_angle_textChanged(const QString &);
60 void updateContents();
61 /// get bounding box from file
64 /// Store the LaTeX names for the rotation origins.
65 std::vector<std::string> origin_ltx;
67 bool initialiseParams(std::string const & data);
71 void dispatchParams();
73 bool isBufferDependent() const { return true; }
76 QString browse(QString const &) const;
77 /// Read the Bounding Box from a eps or ps-file
78 std::string const readBB(std::string const & file);
81 /// test if file exist
82 bool isFilenameValid(std::string const & fname) const;
86 InsetGraphicsParams params_;
90 /// get the units for the bounding box
91 std::vector<std::string> const getBBUnits();
93 } // namespace frontend
96 #endif // GUIGRAPHICS_H