]> git.lyx.org Git - lyx.git/blob - src/insets/insetparent.h
add warning make controllers compile and remove some alomost unused functions, commen...
[lyx.git] / src / insets / insetparent.h
1 // -*- C++ -*-
2 /**
3  * \file insetparent.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author Alejandro Aguilar Sierra
8  *
9  * Full author contact details are available in file CREDITS
10  */
11
12 #ifndef INSET_PARENT_H
13 #define INSET_PARENT_H
14
15
16 #include "insetcommand.h"
17
18 class Buffer;
19
20 /** Reference to the parent document.
21
22   Useful to load a parent document from a child document and to
23   share parent's properties between preambleless children.
24  */
25 class InsetParent : public InsetCommand {
26 public:
27         ///
28         InsetParent(InsetCommandParams const &, Buffer const &, bool same_id = false);
29         ///
30         virtual Inset * clone(Buffer const & buffer, bool same_id = false) const {
31                 return new InsetParent(params(), buffer, same_id);
32         }
33         ///
34         dispatch_result localDispatch(FuncRequest const & cmd);
35         ///
36         string const getScreenLabel(Buffer const *) const;
37         ///
38         EDITABLE editable() const { return IS_EDITABLE; }
39         ///
40         Inset::Code lyxCode() const { return Inset::PARENT_CODE; }
41         ///
42         int latex(Buffer const *, std::ostream &,
43                   bool fragile, bool free_spc) const;
44         ///
45         void setParent(string const & fn) { setContents(fn); }
46 };
47 #endif