diff --git a/dlls/usp10/usp10.c b/dlls/usp10/usp10.c index 8511e6945f6..11e79051a6a 100644 --- a/dlls/usp10/usp10.c +++ b/dlls/usp10/usp10.c @@ -31,6 +31,11 @@ #include "wine/debug.h" +/** + * some documentation here: + * http://www.microsoft.com/typography/developers/uniscribe/uniscribe.htm + */ + WINE_DEFAULT_DEBUG_CHANNEL(uniscribe); BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpv) @@ -87,3 +92,40 @@ HRESULT WINAPI ScriptItemize(const WCHAR *pwcInChars, int cInChars, int cMaxItem psControl, psState, pItems, pcItems); return E_INVALIDARG; } + +HRESULT WINAPI ScriptStringAnalyse(HDC hdc, + const void *pString, + int cString, + int cGlyphs, + int iCharset, + DWORD dwFlags, + int iReqWidth, + SCRIPT_CONTROL *psControl, + SCRIPT_STATE *psState, + const int *piDx, + SCRIPT_TABDEF *pTabdef, + const BYTE *pbInClass, + SCRIPT_STRING_ANALYSIS *pssa) +{ + FIXME("(%p,%p,%d,%d,%d,0x%lx,%d,%p,%p,%p,%p,%p,%p): stub\n", + hdc, pString, cString, cGlyphs, iCharset, dwFlags, + iReqWidth, psControl, psState, piDx, pTabdef, pbInClass, pssa); + if (1 > cString || NULL == pString) { + return E_INVALIDARG; + } + if ((dwFlags & SSA_GLYPHS) && NULL == hdc) { + return E_INVALIDARG; + } + + return E_NOTIMPL; +} + +HRESULT WINAPI ScriptStringFree(SCRIPT_STRING_ANALYSIS *pssa) { + FIXME("(%p): stub\n",pssa); + return S_OK; +} + +HRESULT WINAPI ScriptIsComplex(const WCHAR* pwcInChars, int cInChars, DWORD dwFlags) { + FIXME("(%s,%d,0x%lx): stub\n", debugstr_w(pwcInChars), cInChars, dwFlags); + return E_NOTIMPL; +} diff --git a/dlls/usp10/usp10.spec b/dlls/usp10/usp10.spec index 95835f476e4..d8f77f08f62 100644 --- a/dlls/usp10/usp10.spec +++ b/dlls/usp10/usp10.spec @@ -10,16 +10,16 @@ @ stub ScriptGetGlyphABCWidth @ stub ScriptGetLogicalWidths @ stdcall ScriptGetProperties(ptr long) -@ stub ScriptIsComplex +@ stdcall ScriptIsComplex(wstr long long) @ stdcall ScriptItemize(wstr long long ptr ptr ptr ptr) @ stub ScriptJustify @ stub ScriptLayout @ stub ScriptPlace @ stdcall ScriptRecordDigitSubstitution(ptr ptr) @ stub ScriptShape -@ stub ScriptStringAnalyse +@ stdcall ScriptStringAnalyse(ptr ptr long long long long long ptr ptr ptr ptr ptr ptr) @ stub ScriptStringCPtoX -@ stub ScriptStringFree +@ stdcall ScriptStringFree(ptr) @ stub ScriptStringGetLogicalWidths @ stub ScriptStringGetOrder @ stub ScriptStringOut diff --git a/include/usp10.h b/include/usp10.h index 5d2676e53a4..886a7c1aef6 100644 --- a/include/usp10.h +++ b/include/usp10.h @@ -19,6 +19,34 @@ #ifndef __USP10_H #define __USP10_H +/** ScriptStringAnalyse */ +#define SSA_PASSWORD 0x00000001 +#define SSA_TAB 0x00000002 +#define SSA_CLIP 0x00000004 +#define SSA_FIT 0x00000008 +#define SSA_DZWG 0x00000010 +#define SSA_FALLBACK 0x00000020 +#define SSA_BREAK 0x00000040 +#define SSA_GLYPHS 0x00000080 +#define SSA_RTL 0x00000100 +#define SSA_GCP 0x00000200 +#define SSA_HOTKEY 0x00000400 +#define SSA_METAFILE 0x00000800 +#define SSA_LINK 0x00001000 +#define SSA_HIDEHOTKEY 0x00002000 +#define SSA_HOTKEYONLY 0x00002400 +#define SSA_FULLMEASURE 0x04000000 +#define SSA_LPKANSIFALLBACK 0x08000000 +#define SSA_PIDX 0x10000000 +#define SSA_LAYOUTRTL 0x20000000 +#define SSA_DONTGLYPH 0x40000000 +#define SSA_NOKASHIDA 0x80000000 + +/** StringIsComplex */ +#define SIC_COMPLEX 1 +#define SIC_ASCIIDIGIT 2 +#define SIC_NEUTRAL 4 + typedef struct tag_SCRIPT_CONTROL { DWORD uDefaultLanguage :16; DWORD fContextDigits :1; @@ -96,7 +124,15 @@ typedef struct tag_SCRIPT_FONTPROPERTIES { int iKashidaWidth; } SCRIPT_FONTPROPERTIES; +typedef struct tag_SCRIPT_TABDEF { + int cTabStops; + int iScale; + int *pTabStops; + int iTabOrigin; +} SCRIPT_TABDEF; + typedef void *SCRIPT_CACHE; +typedef void *SCRIPT_STRING_ANALYSIS; /* Function Declairations */ @@ -108,5 +144,20 @@ HRESULT WINAPI ScriptItemize(const WCHAR *pwcInChars, int cInChars, int cMaxItem const SCRIPT_CONTROL *psControl, const SCRIPT_STATE *psState, SCRIPT_ITEM *pItems, int *pcItems); HRESULT WINAPI ScriptGetFontProperties(HDC hdc, SCRIPT_CACHE *psc, SCRIPT_FONTPROPERTIES *sfp); +HRESULT WINAPI ScriptStringAnalyse(HDC hdc, + const void *pString, + int cString, + int cGlyphs, + int iCharset, + DWORD dwFlags, + int iReqWidth, + SCRIPT_CONTROL *psControl, + SCRIPT_STATE *psState, + const int *piDx, + SCRIPT_TABDEF *pTabdef, + const BYTE *pbInClass, + SCRIPT_STRING_ANALYSIS *pssa); +HRESULT WINAPI ScriptStringFree(SCRIPT_STRING_ANALYSIS *pssa); +HRESULT WINAPI ScriptIsComplex(const WCHAR* pwcInChars, int cInChars, DWORD dwFlags); #endif /* __USP10_H */