/*
- * Copyright (c) 2015 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
const PointSize26Dot6 FontClient::DEFAULT_POINT_SIZE = 768u; // 12*64
+FontClient::GlyphBufferData::GlyphBufferData()
+: buffer( NULL ),
+ width( 0u ),
+ height( 0u ),
+ format( Pixel::A8 )
+{
+}
+
+FontClient::GlyphBufferData::~GlyphBufferData()
+{
+}
+
FontClient FontClient::Get()
{
return Internal::FontClient::Get();
GetImplementation(*this).GetDpi( horizontalDpi, verticalDpi );
}
+int FontClient::GetDefaultFontSize()
+{
+ return GetImplementation(*this).GetDefaultFontSize();
+}
+
void FontClient::ResetSystemDefaults()
{
GetImplementation(*this).ResetSystemDefaults();
return GetImplementation(*this).GetPointSize( id );
}
-FontId FontClient::FindDefaultFont( Character charcode, PointSize26Dot6 requestedPointSize, bool preferColor )
+bool FontClient::IsCharacterSupportedByFont( FontId fontId, Character character )
{
- return GetImplementation(*this).FindDefaultFont( charcode, requestedPointSize, preferColor );
+ return GetImplementation(*this).IsCharacterSupportedByFont( fontId, character );
}
-FontId FontClient::FindFallbackFont( FontId preferredFont, Character charcode, PointSize26Dot6 requestedPointSize, bool preferColor )
+FontId FontClient::FindDefaultFont( Character charcode,
+ PointSize26Dot6 requestedPointSize,
+ bool preferColor )
{
- return GetImplementation(*this).FindFallbackFont( preferredFont, charcode, requestedPointSize, preferColor );
+ return GetImplementation(*this).FindDefaultFont( charcode,
+ requestedPointSize,
+ preferColor );
+}
+
+FontId FontClient::FindFallbackFont( Character charcode,
+ const FontDescription& preferredFontDescription,
+ PointSize26Dot6 requestedPointSize,
+ bool preferColor )
+{
+ return GetImplementation(*this).FindFallbackFont( charcode, preferredFontDescription, requestedPointSize, preferColor );
}
FontId FontClient::GetFontId( const FontPath& path, PointSize26Dot6 requestedPointSize, FaceIndex faceIndex )
return GetImplementation(*this).GetGlyphMetrics( array, size, type, horizontal );
}
-PixelData FontClient::CreateBitmap( FontId fontId, GlyphIndex glyphIndex )
+void FontClient::CreateBitmap( FontId fontId, GlyphIndex glyphIndex, GlyphBufferData& data, int outlineWidth )
{
- return GetImplementation(*this).CreateBitmap( fontId, glyphIndex );
+ GetImplementation(*this).CreateBitmap( fontId, glyphIndex, data, outlineWidth );
+}
+
+PixelData FontClient::CreateBitmap( FontId fontId, GlyphIndex glyphIndex, int outlineWidth )
+{
+ return GetImplementation(*this).CreateBitmap( fontId, glyphIndex, outlineWidth );
}
void FontClient::CreateVectorBlob( FontId fontId, GlyphIndex glyphIndex, VectorBlob*& blob, unsigned int& blobLength, unsigned int& nominalWidth, unsigned int& nominalHeight )
return GetImplementation(*this).GetEllipsisGlyph( requestedPointSize );
}
+bool FontClient::IsColorGlyph( FontId fontId, GlyphIndex glyphIndex )
+{
+ return GetImplementation(*this).IsColorGlyph( fontId, glyphIndex );
+}
+
+bool FontClient::AddCustomFontDirectory( const char* path )
+{
+ return GetImplementation(*this).AddCustomFontDirectory( path );
+}
+
FontClient::FontClient( Internal::FontClient* internal )
: BaseHandle( internal )
{