4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
9 * Full author contact details are available in file CREDITS
19 #include "insetcommand.h"
23 /** The reference inset
25 class InsetRef : public InsetCommand {
33 string short_gui_name;
35 static type_info types[];
37 static int getType(string const & name);
39 static string const & getName(int type);
42 InsetRef(InsetCommandParams const &, Buffer const &, bool same_id = false);
44 virtual Inset * clone(Buffer const & buffer, bool same_id = false) const {
45 return new InsetRef(params(), buffer, same_id);
48 string const getScreenLabel(Buffer const *) const;
50 EDITABLE editable() const { return IS_EDITABLE; }
52 Inset::Code lyxCode() const { return Inset::REF_CODE; }
54 void edit(BufferView *, int, int, mouse_button::state);
56 void edit(BufferView * bv, bool front = true);
58 bool display() const { return false; }
60 int latex(Buffer const *, std::ostream &,
61 bool fragile, bool free_spc) const;
63 int ascii(Buffer const *, std::ostream &, int linelen) const;
65 int linuxdoc(Buffer const *, std::ostream &) const;
67 int docbook(Buffer const *, std::ostream &, bool mixcont) const;
69 void validate(LaTeXFeatures & features) const;