]> git.lyx.org Git - lyx.git/blob - src/frontends/controllers/ControlGraphics.h
ws cleanup
[lyx.git] / src / frontends / controllers / ControlGraphics.h
1 // -*- C++ -*-
2 /* This file is part of
3  * ======================================================
4  *
5  *           LyX, The Document Processor
6  *
7  *           Copyright 2001 The LyX Team.
8  *
9  * ======================================================
10  *
11  * \file ControlGraphics.h
12  * \author Angus Leeming <a.leeming@ic.ac.uk>
13  * \author Herbert Voss <voss@perce.de>
14 */
15
16 #ifndef CONTROLGRAPHICS_H
17 #define CONTROLGRAPHICS_H
18
19 #ifdef __GNUG__
20 #pragma interface
21 #endif
22
23 #include "ControlInset.h"
24
25 class InsetGraphics;
26 class InsetGraphicsParams;
27 class LyXView;
28
29 /** A controller for Graphics dialogs.
30  */
31 class ControlGraphics
32         : public ControlInset<InsetGraphics, InsetGraphicsParams> {
33 public:
34         ///
35         ControlGraphics(LyXView &, Dialogs &);
36
37         /// Browse for a file
38         string const Browse(string const &);
39         /// Read the Bounding Box from a eps or ps-file
40         string const readBB(string const & file);
41         /// Control the bb
42         bool bbChanged;
43         /// test if file exist
44         void checkFilename(string const & fname);
45 private:
46         /// Dispatch the changed parameters to the kernel.
47         virtual void applyParamsToInset();
48         ///
49         virtual void applyParamsNoInset();
50         /// get the parameters from the string passed to createInset.
51         virtual InsetGraphicsParams const getParams(string const &);
52         /// get the parameters from the inset passed to showInset.
53         virtual InsetGraphicsParams const getParams(InsetGraphics const &);
54 };
55
56 #endif // CONTROLGRAPHICS_H