On this pageDrawingGetTextSize Gets the text size needed to fit inside a given width according to the current font. This function is memoized because <code>MainCanvas.measureText(Text)</code> is a major resource hog.CallableDrawingGetTextSize(Text, Width): [text: string, size: number]ParametersText: stringWidth: numberReturns [text: string, size: number]Text to drawWidth in which the text has to fitText to draw and its font sizeIndex MethodsclearCacheMethods clearCacheclearCache(): voidClears the cache of the memoized functionReturns void
Gets the text size needed to fit inside a given width according to the current font. This function is memoized because