2 /* This file is part of*
3 * ======================================================
5 * LyX, The Document Processor
7 * Copyright 1995 Matthias Ettrich
8 * Copyright 1995-2000 The LyX Team.
10 * ====================================================== */
19 #include FORMS_H_LOCATION
24 /** Used for error messages from LaTeX runs.
26 The edit-operation opens a
27 dialog with the text of the error-message. The inset is displayed as
28 "Error" in a box, and automatically deleted. */
29 class InsetError: public Inset {
32 InsetError(string const & string);
39 int ascent(Painter &, LyXFont const & font) const;
41 int descent(Painter &, LyXFont const & font) const;
43 int width(Painter &, LyXFont const & font) const;
45 void draw(Painter &, LyXFont const & font,
46 int baseline, float & x) const;
49 int Ascent(LyXFont const & font) const;
51 int Descent(LyXFont const & font) const;
53 int Width(LyXFont const & font) const;
55 void Draw(LyXFont font, LyXScreen & scr, int baseline, float & x);
58 void Write(ostream &);
60 void Read(LyXLex & lex);
62 int Latex(ostream &, signed char fragile);
64 int Latex(string & file, signed char fragile);
66 int Linuxdoc(string & file);
68 int DocBook(string & file);
70 bool AutoDelete() const;
71 /// what appears in the minibuffer when opening
72 char const * EditMessage() const {return _("Opened error");}
76 unsigned char Editable() const;
78 Inset * Clone() const;
80 Inset::Code LyxCode() const { return Inset::NO_CODE; }
81 /// We don't want "begin" and "end inset" in lyx-file
82 bool DirectWrite() const { return true; };
84 static void CloseErrorCB(FL_OBJECT *, long data);