Improve the description of Inset::inheritFont()

The existing descriptions were obsolete (see e.g. ticket #10263).
This commit is contained in:
Jean-Marc Lasgouttes 2021-04-13 10:33:42 +02:00
parent 441c6a9359
commit 0acf594df2
4 changed files with 6 additions and 16 deletions

View File

@ -586,13 +586,9 @@ public:
/// returns whether paragraph breaks can occur inside this inset
virtual bool allowMultiPar() const { return false; }
/**
* The font is inherited from the parent for LaTeX export if this
* method returns true. No open font changes are closed in front of
* the inset for LaTeX export, and the font is inherited for all other
* exports as well as on screen.
* If this method returns false all open font changes are closed in
* front of the inset for LaTeX export. The default font is used
* inside the inset for all exports and on screen.
* The font inside the inset is inherited from the parent for
* LaTeX export if this method returns true, as well as on screen.
* Otherwise the document default font is used.
*/
virtual bool inheritFont() const { return true; }
/**

View File

@ -104,9 +104,7 @@ private:
docstring xhtml(XMLStream &, OutputParams const &) const override;
///
bool insetAllowed(InsetCode) const override;
/** returns false if, when outputting LaTeX, font changes should
be closed before generating this inset. This is needed for
insets that may contain several paragraphs */
///
bool inheritFont() const override { return false; }
///
bool getStatus(Cursor &, FuncRequest const &, FuncStatus &) const override;

View File

@ -61,9 +61,7 @@ private:
InsetCode lyxCode() const override { return NOTE_CODE; }
///
docstring layoutName() const override;
/** returns false if, when outputting LaTeX, font changes should
be closed before generating this inset. This is needed for
insets that may contain several paragraphs */
///
bool inheritFont() const override { return params_.type == InsetNoteParams::Note; }
/// Is the content of this inset part of the output document?
bool producesOutput() const override

View File

@ -980,9 +980,7 @@ public:
bool canTrackChanges() const override { return true; }
///
bool canPaintChange(BufferView const &) const override { return true; }
/** returns false if, when outputting LaTeX, font changes should
be closed before generating this inset. This is needed for
insets that may contain several paragraphs */
///
bool inheritFont() const override { return false; }
///
bool allowMultiPar() const override;