4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
7 * \author Martin Vermeer
9 * Full author contact details are available in file CREDITS.
16 #include "InsetCollapsable.h"
23 * InsetOptArg. Used to insert a short version of sectioning header etc.
24 * automatically, or other optional LaTeX arguments
26 class InsetOptArg : public InsetCollapsable {
28 InsetOptArg(BufferParams const &);
31 InsetCode lyxCode() const { return OPTARG_CODE; }
33 docstring name() const { return from_ascii("OptArg"); }
34 /// return an message upon editing
35 docstring editMessage() const;
37 /// Standard LaTeX output -- short-circuited
38 int latex(odocstream &, OutputParams const &) const;
39 /// Standard plain text output -- short-circuited
40 int plaintext(odocstream &, OutputParams const &) const;
41 /// Standard DocBook output -- short-circuited
42 int docbook(odocstream &, OutputParams const &) const;
44 /// Outputting the optional parameter of a LaTeX command
45 int latexOptional(odocstream &, OutputParams const &) const;
46 /// Write out to the .lyx file
47 void write(std::ostream & os) const;
49 /// should paragraph indendation be ommitted in any case?
50 bool neverIndent() const { return true; }
52 InsetOptArg(InsetOptArg const &);
54 Inset * clone() const;
60 #endif // INSETOPTARG_H