[Version] N/A
[Project] N/A
[Title] Fix the smallcaps-italic combination issue
[BinType] N/A
[Customer] N/A
[Issue#] N/A
[Solution] The combination of small-caps and italic is synthesized. If there is a combination of smallcaps and italic then the fon
cache will give the normal font and we will synthesize(skew) that font face.
[Developer] tanvir.rizvi
[Request] N/A
[Horizontal expansion] N/A
[SCM request] N/A
Change-Id: Ib857cbd00b54f4644321bcebe0bbcb6dd16570e5
Conflicts:
Source/WTF/wtf/Platform.h
#define ENABLE_TIZEN_FALLBACK_FONTDATA 1 /* Hyeonji Kim(hyeonji.kim@samsung.com) : Add the fallback fontData to FontFallbackList */
#define ENABLE_TIZEN_COLLECT_HARFBUZZRUN 1 /* Rashmi Shyamasundar(rashmi.s2@samsung.com) Create proper harfBuzzRun for a word which follows a space */
#define ENABLE_TIZEN_CANVAS_2D_LINE_JOIN 1 /* Rashmi Shyamasundar(rashmi.s2@samsung.com) Save the value of lineJoin in GraphicsContextState */
#define ENABLE_TIZEN_FALLBACK_FONTDATA 1 /* Hyeonji Kim(hyeonji.kim@samsung.com) : Add the fallback fontData to FontFallbackList */
#define ENABLE_TIZEN_COLLECT_HARFBUZZRUN 1 /* Rashmi Shyamasundar(rashmi.s2@samsung.com) Create proper harfBuzzRun for a word which follows a space */
#define ENABLE_TIZEN_CANVAS_2D_LINE_JOIN 1 /* Rashmi Shyamasundar(rashmi.s2@samsung.com) Save the value of lineJoin in GraphicsContextState */
+#define ENABLE_TIZEN_FAKE_ITALIC_SMALLCAPS_COMBINATION 1 /* Tanvir Rizvi(tanvir.rizvi@samsung.com) Synthesize the small-caps and Italic combination */
#define ENABLE_TIZEN_CONTEXTSHADOW_BLUR_NEON 0 /* use neon shadowblur function in ContextShadow.cpp <hyunki.baik@samsung.com> */
#define ENABLE_TIZEN_ON_AUTHENTICATION_REQUESTED 1 /* Sungman Kim(ssungmai.kim@samsung.com) : Implement to requested authentication signal handling method */
#define ENABLE_TIZEN_CONTEXTSHADOW_BLUR_NEON 0 /* use neon shadowblur function in ContextShadow.cpp <hyunki.baik@samsung.com> */
#define ENABLE_TIZEN_ON_AUTHENTICATION_REQUESTED 1 /* Sungman Kim(ssungmai.kim@samsung.com) : Implement to requested authentication signal handling method */
return 0;
bool italic = fontDescription.italic();
return 0;
bool italic = fontDescription.italic();
+#if ENABLE(TIZEN_FAKE_ITALIC_SMALLCAPS_COMBINATION)
+ bool smallCaps = fontDescription.smallCaps();
+ if (!FcPatternAddInteger(pattern.get(), FC_SLANT, (italic && !smallCaps) ? FC_SLANT_ITALIC : FC_SLANT_ROMAN))
+ return 0;
+#else
if (!FcPatternAddInteger(pattern.get(), FC_SLANT, italic ? FC_SLANT_ITALIC : FC_SLANT_ROMAN))
return 0;
if (!FcPatternAddInteger(pattern.get(), FC_SLANT, italic ? FC_SLANT_ITALIC : FC_SLANT_ROMAN))
return 0;
if (!FcPatternAddInteger(pattern.get(), FC_WEIGHT, fontWeightToFontconfigWeight(fontDescription.weight())))
return 0;
if (!FcPatternAddDouble(pattern.get(), FC_PIXEL_SIZE, fontDescription.computedPixelSize()))
if (!FcPatternAddInteger(pattern.get(), FC_WEIGHT, fontWeightToFontconfigWeight(fontDescription.weight())))
return 0;
if (!FcPatternAddDouble(pattern.get(), FC_PIXEL_SIZE, fontDescription.computedPixelSize()))