summaryrefslogtreecommitdiff
path: root/libs/minikin/MinikinInternal.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'libs/minikin/MinikinInternal.cpp')
-rw-r--r--libs/minikin/MinikinInternal.cpp13
1 files changed, 12 insertions, 1 deletions
diff --git a/libs/minikin/MinikinInternal.cpp b/libs/minikin/MinikinInternal.cpp
index d02f71f..5b81406 100644
--- a/libs/minikin/MinikinInternal.cpp
+++ b/libs/minikin/MinikinInternal.cpp
@@ -17,9 +17,12 @@
#define LOG_TAG "Minikin"
+#include "MinikinInternal.h"
+
#include <log/log.h>
-#include "MinikinInternal.h"
+#include "FeatureFlags.h"
+#include "minikin/MinikinPaint.h"
namespace minikin {
@@ -45,4 +48,12 @@ bool isVariationSelector(uint32_t codePoint) {
return isBMPVariationSelector(codePoint) || isVariationSelectorSupplement(codePoint);
}
+bool MinikinPaint::skipCache() const {
+ if (features::inter_character_justification()) {
+ return false; // if the flag is on, do not skip the cache.
+ } else {
+ return !fontFeatureSettings.empty();
+ }
+}
+
} // namespace minikin