2 /* This file is part of*
3 * ======================================================
5 * LyX, The Document Processor
7 * Copyright 1997-2000 LyX Team
9 * ====================================================== */
11 #ifndef INSET_PARENT_H
12 #define INSET_PARENT_H
18 #include "insetcommand.h"
22 /** Reference to the parent document.
24 Useful to load a parent document from a child document and to
25 share parent's properties between preambleless children.
27 class InsetParent : public InsetCommand {
30 InsetParent(InsetCommandParams const &, Buffer * owner = 0);
32 Inset * Clone() const { return new InsetParent(params()); }
34 string getScreenLabel() const;
36 EDITABLE Editable() const { return IS_EDITABLE; }
38 Inset::Code LyxCode() const { return Inset::PARENT_CODE; }
40 void Edit(BufferView *, int, int, unsigned int);
42 int Latex(Buffer const *, std::ostream &,
43 bool fragile, bool free_spc) const;
45 void setParent(string fn) { setContents(fn); }