Improve 'stretch' in legacy create typeface for DirectWrite.

Previously the stretch (width) property was set to UNDEFINED, since the
legacy create typeface does not have this information. However, a better
default here is NORMAL.

Review URL: https://codereview.chromium.org/127813003

git-svn-id: http://skia.googlecode.com/svn/trunk@12966 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
bungeman@google.com 2014-01-08 20:32:07 +00:00
parent 677e815bf2
commit 97a5d5da16

View File

@ -1789,7 +1789,7 @@ SkTypeface* SkFontMgr_DirectWrite::onLegacyCreateTypeface(const char familyName[
DWRITE_FONT_WEIGHT weight = (styleBits & SkTypeface::kBold) DWRITE_FONT_WEIGHT weight = (styleBits & SkTypeface::kBold)
? DWRITE_FONT_WEIGHT_BOLD ? DWRITE_FONT_WEIGHT_BOLD
: DWRITE_FONT_WEIGHT_NORMAL; : DWRITE_FONT_WEIGHT_NORMAL;
DWRITE_FONT_STRETCH stretch = DWRITE_FONT_STRETCH_UNDEFINED; DWRITE_FONT_STRETCH stretch = DWRITE_FONT_STRETCH_NORMAL;
DWRITE_FONT_STYLE italic = (styleBits & SkTypeface::kItalic) DWRITE_FONT_STYLE italic = (styleBits & SkTypeface::kItalic)
? DWRITE_FONT_STYLE_ITALIC ? DWRITE_FONT_STYLE_ITALIC
: DWRITE_FONT_STYLE_NORMAL; : DWRITE_FONT_STYLE_NORMAL;