1 /* This file is part of
2 * ======================================================
4 * LyX, The Document Processor
6 * Copyright 1998 The LyX Team.
8 *======================================================*/
13 #pragma implementation
21 //#include "lyx_gui_misc.h"
25 InsetERT::InsetERT(Buffer * bf)
26 : InsetCollapsable(bf)
29 LyXFont font(LyXFont::ALL_SANE);
30 font.setLatex (LyXFont::ON);
31 real_current_font = current_font = font;
32 LyXFont labelfont(LyXFont::ALL_SANE);
35 labelfont.setColor(LColor::ert);
36 setLabelFont(labelfont);
37 setAutoCollapse(false);
41 Inset * InsetERT::Clone() const
43 InsetERT * result = new InsetERT(buffer);
48 void InsetERT::Write(ostream & os) const
51 WriteParagraphData(os);
55 char const * InsetERT::EditMessage() const
57 return _("Opened ERT Inset");
61 bool InsetERT::InsertInset(BufferView *, Inset *)
67 void InsetERT::SetFont(BufferView *, LyXFont const &, bool)
69 WriteAlert(_("Impossible Operation!"),
70 _("Not permitted to change font-types inside ERT-insets!"),
74 void InsetERT::Edit(BufferView * bv, int x, int y, unsigned int button)
76 InsetCollapsable::Edit(bv, x, y, button);
77 LyXFont font(LyXFont::ALL_SANE);
78 font.setLatex (LyXFont::ON);
79 current_font = real_current_font = font;