mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-26 19:25:39 +00:00
Amend bcad19e504
Allow searching in notes and comments if non-output-content is true
This commit is contained in:
parent
50374e38e1
commit
d96135a9dc
@ -206,9 +206,19 @@ bool InsetNote::isMacroScope() const
|
|||||||
|
|
||||||
void InsetNote::latex(otexstream & os, OutputParams const & runparams_in) const
|
void InsetNote::latex(otexstream & os, OutputParams const & runparams_in) const
|
||||||
{
|
{
|
||||||
if (params_.type == InsetNoteParams::Note)
|
if (params_.type != InsetNoteParams::Greyedout
|
||||||
|
&& (runparams_in.for_searchAdv & OutputParams::SearchNonOutput) == 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
if (params_.type == InsetNoteParams::Note) {
|
||||||
|
if ((runparams_in.for_searchAdv & OutputParams::SearchNonOutput) != 0) {
|
||||||
|
OutputParams runparams(runparams_in);
|
||||||
|
InsetCollapsible::latex(os, runparams);
|
||||||
|
runparams_in.encoding = runparams.encoding;
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
OutputParams runparams(runparams_in);
|
OutputParams runparams(runparams_in);
|
||||||
if (params_.type == InsetNoteParams::Comment) {
|
if (params_.type == InsetNoteParams::Comment) {
|
||||||
runparams.inComment = true;
|
runparams.inComment = true;
|
||||||
|
@ -485,12 +485,6 @@ void InsetText::latex(otexstream & os, OutputParams const & runparams) const
|
|||||||
// environment. Standard collapsible insets should not
|
// environment. Standard collapsible insets should not
|
||||||
// redefine this, non-standard ones may call this.
|
// redefine this, non-standard ones may call this.
|
||||||
InsetLayout const & il = getLayout();
|
InsetLayout const & il = getLayout();
|
||||||
if (runparams.for_searchAdv != OutputParams::NoSearch &&
|
|
||||||
(runparams.for_searchAdv & OutputParams::SearchNonOutput) == 0 &&
|
|
||||||
!il.latexname().empty() &&
|
|
||||||
il.latextype() == InsetLaTeXType::ENVIRONMENT &&
|
|
||||||
il.latexname() == "comment")
|
|
||||||
return;
|
|
||||||
|
|
||||||
if (il.forceOwnlines())
|
if (il.forceOwnlines())
|
||||||
os << breakln;
|
os << breakln;
|
||||||
|
Loading…
Reference in New Issue
Block a user