+#ifdef DEBUG_ENABLED
+ {
+ Dali::TextAbstraction::FontDescription description;
+ fontClient.GetDescription( fontId, description );
+
+ DALI_LOG_INFO( gLogFilter,
+ Debug::Verbose,
+ " Initial font set\n Character : %x, Script : %s, Font : %s \n",
+ character,
+ Dali::TextAbstraction::ScriptName[script],
+ description.path.c_str() );
+ }
+#endif
+
+ // Validate whether the current character is supported by the given font.
+ bool isValidFont = false;
+
+ // Check first in the cache of default fonts per script and size.
+
+ FontId cachedDefaultFontId = 0u;
+ DefaultFonts* defaultFonts = *( defaultFontPerScriptCacheBuffer + script );
+ if( NULL != defaultFonts )
+ {
+ // This cache stores fall-back fonts.
+ cachedDefaultFontId = defaultFonts->FindFont( fontClient,
+ currentFontDescription,
+ currentFontPointSize );
+ }
+
+ // Whether the cached default font is valid.
+ const bool isValidCachedDefaultFont = 0u != cachedDefaultFontId;
+
+ // The font is valid if it matches with the default one for the current script and size and it's different than zero.
+ isValidFont = isValidCachedDefaultFont && ( fontId == cachedDefaultFontId );
+
+ if( isValidFont )