- // Iterators of the font and script runs.
- Vector<FontRun>::ConstIterator fontRunIt = definedFonts.Begin();
- Vector<FontRun>::ConstIterator fontRunEndIt = definedFonts.End();
+ // Get the default font description and default size.
+ TextAbstraction::FontDescription defaultFontDescription;
+ TextAbstraction::PointSize26Dot6 defaultPointSize = TextAbstraction::FontClient::DEFAULT_POINT_SIZE;
+ if( defaultFontId > 0u )
+ {
+ fontClient.GetDescription( defaultFontId, defaultFontDescription );
+ defaultPointSize = fontClient.GetPointSize( defaultFontId );
+ }
+
+ // Merge font descriptions
+ Vector<FontId> fontIds;
+ fontIds.Resize( numberOfCharacters, defaultFontId );
+ MergeFontDescriptions( fontDescriptions,
+ fontIds,
+ defaultFontDescription,
+ defaultPointSize );
+
+ const Character* const textBuffer = text.Begin();
+ const FontId* const fontIdsBuffer = fontIds.Begin();