commit 984ad9bd8cb359bc6342f447e982e7959935b163
Author: Juergen Spitzmueller <[email protected]>
Date:   Sun Jun 7 07:57:10 2026 +0200

    Use cached label for statistics and plaintext (#13322)
    
    (cherry picked from commit 7e69673c3b764bb28d2e24e46a25fce2f4253783)
---
 src/insets/InsetCitation.cpp | 4 ++--
 status.25x                   | 3 +++
 2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/src/insets/InsetCitation.cpp b/src/insets/InsetCitation.cpp
index 0ecf2c4ca1..71cf9e4839 100644
--- a/src/insets/InsetCitation.cpp
+++ b/src/insets/InsetCitation.cpp
@@ -601,7 +601,7 @@ int InsetCitation::plaintext(odocstringstream & os,
        if (cmd == "nocite")
                return 0;
 
-       docstring const label = generateLabel();
+       docstring const label = cache.generated_label;
        os << label;
        return label.size();
 }
@@ -790,7 +790,7 @@ void InsetCitation::latex(otexstream & os, OutputParams 
const & runparams) const
 
 void InsetCitation::updateStatistics(Statistics & stats) const
 {
-       stats.update(generateLabel(false));
+       stats.update(cache.generated_label);
 }
 
 
diff --git a/status.25x b/status.25x
index d68799bbb1..7713ee35db 100644
--- a/status.25x
+++ b/status.25x
@@ -25,6 +25,9 @@ What's new
 
 - Improve keyboard navigation in Cross-References dialog.
 
+- Use cached citation labels for statistics and plaintext to
+  improve performance (bug 13322).
+
 
 * DOCUMENTATION AND LOCALIZATION
 
-- 
lyx-cvs mailing list
[email protected]
https://lists.lyx.org/mailman/listinfo/lyx-cvs

Reply via email to