then do reset it only after footnotes or floats. \selectlanguage at
the end of environments might produce spurious vertical space
(see https://marc.info/?l=lyx-devel&m=
168872369617866)
*/
bool inInclude = false;
+ /** Whether we are inside a footnote.
+ */
+ bool inFootnote = false;
+
/** Whether a btUnit (for multiple biblographies) is open.
*/
mutable bool openbtUnit = false;
}
+void InsetFoot::latex(otexstream & os, OutputParams const & runparams_in) const
+{
+ OutputParams runparams(runparams_in);
+ runparams.inFootnote = true;
+ InsetText::latex(os, runparams);
+}
+
+
int InsetFoot::plaintext(odocstringstream & os,
OutputParams const & runparams, size_t max_length) const
{
///
docstring layoutName() const override;
///
+ void latex(otexstream &, OutputParams const &) const override;
+ ///
int plaintext(odocstringstream & ods, OutputParams const & op,
size_t max_length = INT_MAX) const override;
///
if (localswitch_needed
|| (intitle_command && using_begin_end)
|| closing_rtl_ltr_environment
- || (((runparams.isLastPar && !runparams.inbranch) || close_lang_switch)
- && (par_lang != outer_lang || (using_begin_end
- && style.isEnvironment()
- && par_lang != nextpar_lang)))) {
// Since \selectlanguage write the language to the aux file,
// we need to reset the language at the end of footnote or
// float.
+ || (((runparams.isLastPar
+ && (using_begin_end || runparams.inFloat != OutputParams::NONFLOAT || runparams.inFootnote))
+ || close_lang_switch)
+ && (par_lang != outer_lang || (using_begin_end
+ && style.isEnvironment()
+ && par_lang != nextpar_lang)))) {
if (!localswitch && (pending_newline || close_lang_switch))
os << '\n';