#ifndef INSETARGUMENT_H
#define INSETARGUMENT_H
-
+#include "FontInfo.h"
#include "InsetCollapsible.h"
InsetArgument(Buffer *, std::string const &);
///
- InsetArgument const * asInsetArgument() const { return this; }
+ InsetArgument const * asInsetArgument() const override { return this; }
/// Outputting the parameter of a LaTeX command
void latexArgument(otexstream & os, OutputParams const & runparams_in,
std::string name() const { return name_; }
+ bool docbookargumentbeforemaintag() const { return docbookargumentbeforemaintag_; }
+
+ bool docbookargumentaftermaintag() const { return docbookargumentaftermaintag_; }
+
/// \name Public functions inherited from Inset class
//@{
///
- bool hasSettings() const { return false; }
+ bool hasSettings() const override { return false; }
///
- InsetCode lyxCode() const { return ARG_CODE; }
+ InsetCode lyxCode() const override { return ARG_CODE; }
///
- docstring layoutName() const { return from_ascii("Argument"); }
+ docstring layoutName() const override { return from_ascii("Argument"); }
+
+ /// Initialize the members of this inset when inserted in \c par.
+ void init(Paragraph const & par);
/// Update the label string of this inset
- void updateBuffer(ParIterator const &, UpdateType, bool const deleted = false);
+ void updateBuffer(ParIterator const &, UpdateType, bool const deleted = false) override;
///
- void latex(otexstream &, OutputParams const &) const { }
+ void latex(otexstream &, OutputParams const &) const override { }
///
- int plaintext(odocstringstream &, OutputParams const &, size_t) const { return 0; }
+ int plaintext(odocstringstream &, OutputParams const &, size_t) const override { return 0; }
///
- int docbook(odocstream &, OutputParams const &) const { return 0; }
+ void docbook(XMLStream & xs, OutputParams const &) const override;
///
- docstring xhtml(XHTMLStream &, OutputParams const &) const
+ docstring xhtml(XMLStream &, OutputParams const &) const override
{ return docstring(); }
///
- void write(std::ostream & os) const;
+ void write(std::ostream & os) const override;
///
- void read(Lexer & lex);
+ void read(Lexer & lex) override;
///
- bool neverIndent() const { return true; }
+ bool neverIndent() const override { return true; }
///
- std::string contextMenuName() const;
+ std::string contextMenuName() const override;
///
- bool isPassThru() const { return pass_thru_; }
+ bool isPassThru() const override { return pass_thru_; }
///
- bool isFreeSpacing() const { return free_spacing_; }
+ bool isFreeSpacing() const override { return free_spacing_; }
///
bool isTocCaption() const { return is_toc_caption_; }
///
- bool resetFontEdit() const { return false; }
+ bool resetFontEdit() const override { return false; }
//@}
/// \name Public functions inherited from InsetCollapsible class
//@{
///
- InsetLayout::InsetDecoration decoration() const;
+ InsetDecoration decoration() const override;
///
- FontInfo getFont() const;
+ FontInfo getFont() const override;
///
- FontInfo getLabelfont() const;
+ FontInfo getLabelfont() const override;
///
- ColorCode labelColor() const;
+ ColorCode labelColor() const override;
///
- void setButtonLabel();
+ void setButtonLabel() override;
//@}
///
void addToToc(DocIterator const & dit, bool output_active,
- UpdateType utype, TocBackend & backend) const; //override
+ UpdateType utype, TocBackend & backend) const override;
private:
///
- docstring toolTip(BufferView const & bv, int, int) const;
+ docstring toolTip(BufferView const & bv, int, int) const override;
///
void fixParagraphLanguage(Language const *);
///
std::string caption_of_toc_;
/// Specific line break macro
std::string newline_cmd_;
+ /// DocBook tag for this argument, if any (otherwise, NONE).
+ docstring docbooktag_;
+ /// Type of DocBook tag (controls how new lines are inserted around this argument).
+ docstring docbooktagtype_;
+ /// DocBook attributes.
+ docstring docbookattr_;
+ ///
+ bool docbookargumentbeforemaintag_ = false;
+ ///
+ bool docbookargumentaftermaintag_ = false;
protected:
/// \name Protected functions inherited from Inset class
//@{
///
- bool getStatus(Cursor &, FuncRequest const &, FuncStatus &) const;
+ bool getStatus(Cursor &, FuncRequest const &, FuncStatus &) const override;
///
- void doDispatch(Cursor & cur, FuncRequest & cmd);
+ void doDispatch(Cursor & cur, FuncRequest & cmd) override;
///
- Inset * clone() const { return new InsetArgument(*this); }
+ Inset * clone() const override { return new InsetArgument(*this); }
/// Is the content of this inset part of the immediate (visible) text sequence?
- bool isPartOfTextSequence() const { return false; }
+ bool isPartOfTextSequence() const override { return false; }
//@}
};