[LyX/master] Revert "Fixup 572b06d6: reduce cache size for breakString"
Jean-Marc Lasgouttes
lasgouttes at lyx.org
Mon Nov 7 22:19:45 UTC 2022
commit a99f76477da0a61247f2c886ecd3598eb2dc09ac
Author: Jean-Marc Lasgouttes <lasgouttes at lyx.org>
Date: Tue Nov 8 00:10:18 2022 +0100
Revert "Fixup 572b06d6: reduce cache size for breakString"
10MB cache is not so large after all, and it can be helpful with
Scott's perverse examples.
This reverts commit 2abe7714078a0f772af2e3e2675d6f2b3c054e08.
Fixes part of bug #12598.
---
src/frontends/qt/GuiFontMetrics.cpp | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/src/frontends/qt/GuiFontMetrics.cpp b/src/frontends/qt/GuiFontMetrics.cpp
index 54d5fbd..c227c28 100644
--- a/src/frontends/qt/GuiFontMetrics.cpp
+++ b/src/frontends/qt/GuiFontMetrics.cpp
@@ -94,7 +94,7 @@ namespace {
int const strwidth_cache_max_cost = 1024 * 1024;
// Limit breakstr_cache_ total cost to 10MB of string data.
// This is useful for documents with very large insets.
-int const breakstr_cache_max_cost = 1024 * 1024;
+int const breakstr_cache_max_cost = 10 * 1024 * 1024;
// Qt 5.x already has its own caching of QTextLayout objects
// but it does not seem to work well on MacOS X.
#if (QT_VERSION < 0x050000) || defined(Q_OS_MAC)
More information about the lyx-cvs
mailing list