4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
7 * \author Asger Alstrup
9 * \author Angus Leeming
11 * Full author contact details are available in file CREDITS.
17 #include "GuiDialog.h"
18 #include "ui_ExternalUi.h"
20 #include "support/types.h"
22 #include "insets/InsetExternal.h"
33 class RotationDataType;
35 } // namespace external
39 class GuiExternal : public GuiDialog, public Ui::ExternalUi
44 GuiExternal(GuiView & lv);
49 void change_adaptor();
51 void extraChanged(const QString&);
52 void formatChanged(const QString&);
55 void templateChanged();
56 void widthUnitChanged();
60 typedef std::map<std::string, QString> MapType;
63 void closeEvent(QCloseEvent * e);
65 bool activateAspectratio() const;
69 void updateContents();
70 /// Helper function called when the template is changed.
71 void updateTemplate();
72 /// get bounding box from file
78 bool initialiseParams(std::string const & data);
82 void dispatchParams();
84 bool isBufferDependent() const { return true; }
89 std::vector<std::string> const getTemplates() const;
91 int getTemplateNumber(std::string const &) const;
93 external::Template getTemplate(int) const;
96 getTemplateFilters(std::string const & template_name) const;
98 docstring const browse(docstring const & input_file,
99 docstring const & template_name) const;
101 /// Read the Bounding Box from a eps or ps-file
102 std::string const readBB(std::string const & file);
106 InsetExternalParams params_;
110 } // namespace frontend
113 #endif // GUIEXTERNAL_H