Set maximum cache size used by font engine.


The fontCacheSize property defines the maximum amount of RAM (in bytes) that a font engine should use for its cache. It takes an int value and is set to 204800 by default. If set to 1 it disables the cache buffer.

Since Qt Quick Ultralite 1.9, the cache buffer is preallocated by default. See MCU.Config.fontCachePrealloc for more information about preallocating cache buffer.

The font engine cache size used by the application can be seen by looking at the performance logs.

Refer to the font engine cache part of the Resource cache documentation for tips on how to choose an appropriate cache size.

Note: This property is relevant only for the Monotype Spark font engine.

See Text Rendering and Fonts for font engine-specific details.


This property is accepted in the main application .qmlproject file, or BoardDefaults.qmlprojectconfig for the target platform. It takes an integer, and the default value is 104800.

Note: The property affects the Monotype Spark font engine only.

Code example:

MCU.Config {
    fontCacheSize: 12800


This property was introduced in QmlProject API 1.3 .

See also QUL_FONT_CACHE_SIZE and Text Rendering and Fonts.

Available under certain Qt licenses.
Find out more.