2 /* This file is part of*
3 * ======================================================
5 * LyX, The Document Processor
7 * Copyright 1997 LyX Team (this file was created this year)
9 * ====================================================== */
18 #include "insetcommand.h"
22 /** The reference inset
24 class InsetRef : public InsetCommand {
32 string short_gui_name;
34 static type_info types[];
37 InsetRef(InsetCommandParams const &, Buffer const &);
39 Inset * Clone(Buffer const & buffer) const {
40 return new InsetRef(params(), buffer);
43 string const getScreenLabel() const;
45 EDITABLE Editable() const { return IS_EDITABLE; }
47 Inset::Code LyxCode() const { return Inset::REF_CODE; }
49 void Edit(BufferView *, int, int, unsigned int);
51 bool display() const { return false; }
53 int Latex(Buffer const *, std::ostream &,
54 bool fragile, bool free_spc) const;
56 int Ascii(Buffer const *, std::ostream &, int linelen) const;
58 int Linuxdoc(Buffer const *, std::ostream &) const;
60 int DocBook(Buffer const *, std::ostream &) const;
62 void Validate(LaTeXFeatures & features) const;
64 /// This function escapes 8-bit characters
65 string const escape(string const &) const;