Module: wine Branch: refs/heads/master Commit: 9be30c83cae96a9e85e168948d13b00b6277baea URL: http://source.winehq.org/git/?p=wine.git;a=commit;h=9be30c83cae96a9e85e16894...
Author: Jeff Latimer lats@yless4u.com.au Date: Thu Apr 20 21:57:06 2006 +1000
usp10: Set defaults for ScriptGetFontProperties.
Set defaults similar to Win XP for Kashida and set the default char in ScriptGetFontProperties.
---
dlls/usp10/usp10.c | 8 ++++++-- 1 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/dlls/usp10/usp10.c b/dlls/usp10/usp10.c index cc8b922..d1be349 100644 --- a/dlls/usp10/usp10.c +++ b/dlls/usp10/usp10.c @@ -123,6 +123,7 @@ HRESULT WINAPI ScriptGetFontProperties(H { HDC phdc; Scriptcache *pScriptcache; + TEXTMETRICW ptm;
TRACE("%p,%p,%p\n", hdc, psc, sfp); if (!hdc && !*psc) { @@ -146,9 +147,12 @@ HRESULT WINAPI ScriptGetFontProperties(H /* return something sensible? */ if (NULL != sfp) { sfp->wgBlank = 0; - sfp->wgDefault = 0; + if (GetTextMetricsW(phdc, &ptm)) + sfp->wgDefault = ptm.tmDefaultChar; + else + sfp->wgDefault = 0; sfp->wgInvalid = 0; - sfp->wgKashida = 1; + sfp->wgKashida = 0xffff; sfp->iKashidaWidth = 0; } return 0;