Browse Source

remove unused function getMinCharWidth

Aakansha Doshi 2 năm trước cách đây
mục cha
commit
fd18896293
1 tập tin đã thay đổi với 0 bổ sung10 xóa
  1. 0 10
      src/element/textMeasurements.ts

+ 0 - 10
src/element/textMeasurements.ts

@@ -112,16 +112,6 @@ export const charWidth = (() => {
   };
 })();
 
-export const getMinCharWidth = (font: FontString) => {
-  const cache = charWidth.getCache(font);
-  if (!cache) {
-    return 0;
-  }
-  const cacheWithOutEmpty = cache.filter((val) => val !== undefined);
-
-  return Math.min(...cacheWithOutEmpty);
-};
-
 export const getMaxCharWidth = (font: FontString) => {
   const cache = charWidth.getCache(font);
   if (!cache) {