Author: akhaldi
Date: Sun Jun 4 01:50:46 2017
New Revision: 74881
URL:
http://svn.reactos.org/svn/reactos?rev=74881&view=rev
Log:
[GDI32_WINETEST] Sync with Wine Staging 2.9. CORE-13362
Modified:
trunk/rostests/winetests/gdi32/bitmap.c
trunk/rostests/winetests/gdi32/dib.c
trunk/rostests/winetests/gdi32/font.c
trunk/rostests/winetests/gdi32/wine_test.sfd
trunk/rostests/winetests/gdi32/wine_test.ttf
Modified: trunk/rostests/winetests/gdi32/bitmap.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/gdi32/bitmap.c?…
==============================================================================
--- trunk/rostests/winetests/gdi32/bitmap.c [iso-8859-1] (original)
+++ trunk/rostests/winetests/gdi32/bitmap.c [iso-8859-1] Sun Jun 4 01:50:46 2017
@@ -884,12 +884,13 @@
ok( ret == 1, "SetDIBColorTable returned unexpected result %u\n", ret );
ok( rgb[0].rgbReserved == 123, "Expected rgbReserved = 123, got %u\n",
rgb[0].rgbReserved );
+ rgb[0].rgbRed = rgb[0].rgbGreen = rgb[0].rgbBlue = rgb[0].rgbReserved = -1;
ret = GetDIBColorTable( hdcmem, 0, 1, rgb );
ok( ret == 1, "GetDIBColorTable returned unexpected result %u\n", ret );
ok( rgb[0].rgbRed == 1, "Expected rgbRed = 1, got %u\n", rgb[0].rgbRed );
ok( rgb[0].rgbGreen == 2, "Expected rgbGreen = 2, got %u\n",
rgb[0].rgbGreen );
ok( rgb[0].rgbBlue == 3, "Expected rgbBlue = 3, got %u\n", rgb[0].rgbBlue
);
- todo_wine ok( rgb[0].rgbReserved == 0, "Expected rgbReserved = 0, got
%u\n", rgb[0].rgbReserved );
+ ok( rgb[0].rgbReserved == 0, "Expected rgbReserved = 0, got %u\n",
rgb[0].rgbReserved );
SelectObject(hdcmem, oldbm);
DeleteObject(hdib);
@@ -4315,8 +4316,10 @@
memset( data, 0xaa, sizeof(data) );
info->bmiHeader.biHeight = 16;
+ info->bmiHeader.biSizeImage = 0;
ret = GetDIBits( hdc, dib, 1, 12, data, info, DIB_RGB_COLORS );
ok( ret == 5, "got %d\n", ret );
+ ok( info->bmiHeader.biSizeImage == 128 * 4, "got %d\n",
info->bmiHeader.biSizeImage );
for (i = 0; i < 56; i++) ok( data[i] == 0, "%d: got %08x\n", i, data[i]
);
ok( !memcmp( data + 56, dib_bits, 40 * 4 ), "bits differ\n");
for (i = 96; i < 128; i++) ok( data[i] == 0xaaaaaaaa, "%d: got %08x\n",
i, data[i] );
@@ -5674,8 +5677,10 @@
HGDIOBJ *bitmap;
DIBSECTION dib;
BOOL fail, ret;
- DWORD type;
+ DWORD type, pixel;
int size;
+ HDC bmp_dc;
+ HBITMAP bmp;
static const struct
{
@@ -5870,6 +5875,15 @@
ret = BitBlt( create_desc.hDc, 1, 1, 2, 2, NULL, 0, 0, WHITENESS );
ok(ret, "Failed to blit.\n");
+ /* Also test blitting to a regular bitmap */
+ bmp_dc = CreateCompatibleDC( create_desc.hDeviceDc );
+ ok(bmp_dc != NULL, "failed to create DC\n");
+ bmp = CreateCompatibleBitmap( bmp_dc, create_desc.Width, create_desc.Height );
+ ok(bmp != NULL, "failed to create bmp\n");
+ bmp = SelectObject( bmp_dc, bmp );
+ ret = BitBlt( bmp_dc, 0, 0, create_desc.Width, create_desc.Height,
create_desc.hDc, 0, 0, SRCCOPY );
+ ok(ret, "Failed to blit.\n");
+
destroy_desc.hDc = create_desc.hDc;
destroy_desc.hBitmap = create_desc.hBitmap;
@@ -5902,8 +5916,25 @@
test_data[i].name, colour, x, y, expected);
if (colour != expected)
fail = TRUE;
+
+ /* 'Xn' or 'An' formats don't successfully blit to
the regular bmp */
+ if (test_data[i].format == D3DDDIFMT_R8G8B8 || test_data[i].format ==
D3DDDIFMT_R5G6B5)
+ {
+ pixel = GetPixel( bmp_dc, x, y );
+ if ((x == 1 || x == 2) && (y == 1 || y == 2))
+ expected = 0x00ffffff;
+ else if (x < create_desc.Width && y <
create_desc.Height)
+ expected = 0x00000000;
+ else
+ expected = CLR_INVALID;
+ ok(pixel == expected, "%s: got 0x%08x at %u, %u, expect
0x%08x\n", test_data[i].name,
+ pixel, x, y, expected);
+ }
}
}
+
+ DeleteObject( SelectObject( bmp_dc, bmp ) );
+ DeleteDC( bmp_dc );
}
}
#endif /* __REACTOS__ */
Modified: trunk/rostests/winetests/gdi32/dib.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/gdi32/dib.c?rev…
==============================================================================
--- trunk/rostests/winetests/gdi32/dib.c [iso-8859-1] (original)
+++ trunk/rostests/winetests/gdi32/dib.c [iso-8859-1] Sun Jun 4 01:50:46 2017
@@ -36,9 +36,6 @@
#endif
static HCRYPTPROV crypt_prov;
-static BOOL (WINAPI
*pGdiAlphaBlend)(HDC,int,int,int,int,HDC,int,int,int,int,BLENDFUNCTION);
-static BOOL (WINAPI *pGdiGradientFill)(HDC,TRIVERTEX*,ULONG,void*,ULONG,ULONG);
-static DWORD (WINAPI *pSetLayout)(HDC hdc, DWORD layout);
static const DWORD rop3[256] =
{
@@ -110,7 +107,6 @@
"8b66f14d51ecdeea12bc993302bb9b7d3ec085a1",
"7da9dd3d40d44d92deb9883fb7110443c2d5769a",
"e358efb1c11172e40855de620bdb8a8e545cd790",
- "9e0c2596c6ecb4f1bc97b18ec3ca493d37626608",
"58806549380c964e7a53ad54821d2eb86fa5b9ce",
"7fc30d3058c235ce39088de0a598b8c7fe7ca61f",
"52a6c769c227f2bb1949097c4c87fed5ee0cbcb1",
@@ -134,6 +130,8 @@
"aaf62842bb98d8a2945c4f643baf50afaeea9307",
"d7e34fa02db7ad52327f80389bd1ba1b72b6c692",
"d7dd4700f49808541bba99244b7eb5840e0a2439",
+ "00b4e9b243a36a7210a48bcb7c2d410d9cd8c8c7",
+ "8eb1f99d21a84153e88e7958707049d517ab7641",
"af99228aa4cfbd1f61bd824db046144a3c6c2ed7",
"568f87f0194ca19b69a5b2bcdef795d89c5721ce",
"a37810f46dee8741fe5adbb3f1f2e87012ffc929",
@@ -145,11 +143,8 @@
"eca1998a4d79fb81b2a4103f79e3b846a864eaaf",
"e4acfcf2d001fbc431d9af59ab3d3ca7c2d965e5",
"2b3198bd5c0a87db5dab13df8bbe14363d02acec",
- "f115ef8392ba82d8cd6e7a039320edcd812c1d28",
"aebb1b3baa4fd5213bf80a5ad7a50d54de8fdba4",
- "f451a05f699ac3bbe155d059e7871a2636887b5f",
"5dca709c60e0cd50fa85274a2836aec9eb6168e3",
- "dccaef62738ff90da4554a85d8cb846d6436799e",
"cc4e1372ddf6e303a7fd159090c9d3a1f8ec2a89",
NULL
};
@@ -183,7 +178,6 @@
"8b66f14d51ecdeea12bc993302bb9b7d3ec085a1",
"7da9dd3d40d44d92deb9883fb7110443c2d5769a",
"e358efb1c11172e40855de620bdb8a8e545cd790",
- "9e0c2596c6ecb4f1bc97b18ec3ca493d37626608",
"58806549380c964e7a53ad54821d2eb86fa5b9ce",
"7fc30d3058c235ce39088de0a598b8c7fe7ca61f",
"52a6c769c227f2bb1949097c4c87fed5ee0cbcb1",
@@ -207,6 +201,8 @@
"aaf62842bb98d8a2945c4f643baf50afaeea9307",
"d7e34fa02db7ad52327f80389bd1ba1b72b6c692",
"d7dd4700f49808541bba99244b7eb5840e0a2439",
+ "00b4e9b243a36a7210a48bcb7c2d410d9cd8c8c7",
+ "8eb1f99d21a84153e88e7958707049d517ab7641",
"af99228aa4cfbd1f61bd824db046144a3c6c2ed7",
"568f87f0194ca19b69a5b2bcdef795d89c5721ce",
"a37810f46dee8741fe5adbb3f1f2e87012ffc929",
@@ -218,11 +214,8 @@
"eca1998a4d79fb81b2a4103f79e3b846a864eaaf",
"e4acfcf2d001fbc431d9af59ab3d3ca7c2d965e5",
"e4f110504dd3e4e34f960a39ba91a91c67bf26af",
- "f115ef8392ba82d8cd6e7a039320edcd812c1d28",
"aebb1b3baa4fd5213bf80a5ad7a50d54de8fdba4",
- "f451a05f699ac3bbe155d059e7871a2636887b5f",
"5dca709c60e0cd50fa85274a2836aec9eb6168e3",
- "dccaef62738ff90da4554a85d8cb846d6436799e",
"cc4e1372ddf6e303a7fd159090c9d3a1f8ec2a89",
NULL
};
@@ -256,7 +249,6 @@
"9aa506e3df33e0d5298755aa4144e10eb4b5adcf",
"abdf003699364fe45fab7dc61e67c606d0063b40",
"89abaadff4e68c738cf9251c51e3609564843381",
- "f6aa3f907f620b9f3493f03cb3b4b292df3a9545",
"77d0ad32938147aa4038c1eced232b7b5a5f88f3",
"43d36e57b702ce56eb250bf53f1ecc4680990cfe",
"fd6e0ebb52710ebcdd8dd69931165c83c4930b41",
@@ -280,6 +272,8 @@
"118bf4c5bddc206ba737f7aa8b239940cd1aadc2",
"eac5d164b83edf2cf85bac242686f9f617ec1fa4",
"86c84cc8306975edecc6d4a89a8aff29f59b55a7",
+ "698d6393e97539806351368f95be478c6fbc62b0",
+ "c272d1e0342e6089a0182dc42b37e47889116a9b",
"af99228aa4cfbd1f61bd824db046144a3c6c2ed7",
"25675c30adfe24d6cae60793b156dfdaa36ac3ba",
"849d4abf4b690128a5f70e9b8ac78f20c437de06",
@@ -291,11 +285,8 @@
"b76e0724496e471b01ef8b34f8beba69f5bde261",
"34201d3d3583f89ce3267d3d0c4e01c64463de4b",
"693f5c5fbaeaadb5928d34b035499626fecb8394",
- "8a9aa84c42dedc3e681191a1229846887ed262ec",
"66041875232f64dbfd2d18353aa28e43e8ccb6b5",
- "707bc44fc9fed68ff1f537f0473e0cd825dd660f",
"f19f5d8e2c96328f06f3985d02ff474fa37b1ea8",
- "175a7bcb73c74eceecc000657a0100bccf158ff4",
"d26eeb6b2d345b587d4305a1234ec0842a96d4b6",
NULL
};
@@ -329,7 +320,6 @@
"d578210815e27fe210eb678a71e6d22ba4b4c196",
"c7a027c7079dfcc831ca8bc134a509958273073c",
"19cf978596195b848df8709aaf637f83f92b8336",
- "798a835fe50156eeb478c0a6085b088f53409d52",
"86ddf268d854f37e5b478c48792b551b57635db6",
"8259d388e02542207b6a08d65d553871ce1c4a09",
"faea73ff9436223f8c4ee76ac9861a6609ac4ae4",
@@ -353,6 +343,8 @@
"43d67bc61ef54014b022891e5c024fc24b1fe797",
"5a713a91fd471fd331bd13b0868c994aa2ffe2b2",
"fc0c32afb719295f28bcfef22803bef94f798e20",
+ "bb2a421bab95f9b5420704ef44c0f3214a0b5a11",
+ "7735098af7535d8c57266190a13f92d8869e8529",
"36f6db4fbe2a1630a7597d3a446f2902755c96ef",
"d3f08946300e1700865042aed121870e292d1095",
"4782df8e24127e66a434b4e839adebf2dbb223fb",
@@ -364,11 +356,8 @@
"555b6f04ba8dec9e2a60693dcaac594227052727",
"c199b96a71c3aab2d49ccb5b6294bf14eb0dd1eb",
"4238fe9d296b5c72b0a8745cc761f308605b2094",
- "943dc6033ab335a6a63e666f70a6bb3a0677e157",
"88b6427cf71a6b9a26bfd6026103d50f721651a9",
- "88cfa7b7c1487f8eda05fce92b622942c9fb7ca4",
"64cf929548bc5324fb14b053077bf5bc4be3e15c",
- "ad91dde8566dceaadc3523cdc8149cd7415a1b70",
"1936661eee8073068506131c9e89265b2f8403e8",
NULL
};
@@ -402,7 +391,6 @@
"66b130f83381957cfc4763558c5f5cddf2e3b564",
"d548135ce2320499277ce12b80bc35004f8a9787",
"85a4f3f1b4b0a170198f1bb5d225fcf77887665e",
- "1906ddfd829e735af49245171f8eb7673295d399",
"971a0b786d5bccb1bfb9cbb054740e4eb36f9b7a",
"e2896035f178b3d20e4f4d1accb1b3d1b4028865",
"defd95a10d44cad6e736542920b74efd53e9e7eb",
@@ -426,6 +414,8 @@
"cd01f2c0a63b2229d4467d2f874d58edca32b3d4",
"8ad5cd520cd628b76d2e5a3f318ae1bbb6b4c994",
"49341c297a887186bd47d7465d827ab3147f05e3",
+ "514c07281ef6702c35e68b230e897303a8cdec81",
+ "4b41865829b50b2e29beda51b055bd1f908a649c",
"325279e76367200d3fd7194d81c09fd139988ece",
"c3def160a1e847605ff0fc7edd30397fa90635a0",
"2b3e87e0b705b03c7c08f403409ab82cce095ba1",
@@ -437,11 +427,8 @@
"3d0853f4f7580d7cd5148c21c34d878ecf39a5f3",
"1e5a4ef7f8634847a251d1fcce298c409fd13d87",
"481337fbedf181d4324bf7f8299b0327197ff468",
- "9ab957870fa4e17aec6a79bc1a4fdb42a5ffcc30",
"b4b9f0bf127ef11f510f25684ae21d692609c85e",
- "8e32ea3614c3b20899d748db48258761c7158d2b",
"5da35bad12e3e9b26a0444d30820099481281e45",
- "94f004e98ae8035af948611770a4a2dd6643f510",
"045ddaf752e7ffc7ded792f36af3c7c0cfeeae42",
NULL
};
@@ -475,7 +462,6 @@
"8bc3128ba47891366fd7b02fde7ca19100e64b9f",
"e649e00efe7fea1eb8b17f7867fe089e5270c44b",
"a0bffbbfb0adf6f188479c88da04e25d76ab4822",
- "92a1ab214dd8027c407814420449119466c92840",
"b58f19c1800344a2b8e017eb784705bdb2bd8450",
"5747a6d5c6ce79731c55e8cf33f7da3025cd35fd",
"955390669afed2369b15b32fa519f2f921cdf1a0",
@@ -499,6 +485,8 @@
"1015e0217ea13eaa62c7666b8b81aafd75f8f610",
"5578c80048520732557abf3a3a3fa22c85015d7d",
"b25ba91487ec945410deb2b51bc1156890c032a8",
+ "4c8c936372755f95051f1159b7ff65a484e1a555",
+ "bf55d4bdb26ae0f358bd67ef01932563519aab98",
"d347ca5c6c4b6a61389247c3b6f61564033e8c25",
"ee315634ed92da3a32c2675ecd1b369471c60936",
"099c688a920f606655b485e8f0a433dc811bc976",
@@ -510,11 +498,8 @@
"0bbdf0a0489428f96e3c1d3e5305f9a893820852",
"9d86b1b2bbce90efd3c0b9fe20d23ffa3eeecd20",
"8f7a0af421101952e674f37154c1e8c4646ea2d2",
- "e96b79bf88988b5694a04dfc3bd0029361b39801",
"d12284f58daabbd173dfae6c7e55fd5d822d89b4",
- "09cb4ab070083144bed4271c0a2a34ccb6ed13c0",
"cc5ed4c9e925f0a457a7437fbb8054528cdd9469",
- "c95afd0a020e68a76982fe8663b5d64113987233",
"48658ff76c137185c56a53f3ccf0e958d0296742",
NULL
};
@@ -548,7 +533,6 @@
"d7d97e28ed316f6596c737eb83baa5948d86b673",
"ecc2991277d7314f55b00e0f284ae3703aeef81e",
"656bf3b7121bcd620a0a3ad488f0d66604824577",
- "d7d8493b5fa7a3a8323d6ac84245093a79f052c1",
"df5dafe96e528c2cc7fd11e4934e298f53cec34b",
"a49530722328ae88fd765792ac0c657efbcce75d",
"aa46aa2226e3121eaefa9d0836418e0b69262d69",
@@ -559,23 +543,20 @@
"7df915bedcc5951a1b6f828490f7dbb93212e835",
"8720478d904a84c24071e97c731c1ba7882b131e",
"76215275593631f5900aad3616d725733dc39493",
- "81655a550703849a616d4a16504bb9c6f999285f",
"573d65665d20f00d36d9782ae2b89772140524ab",
- "619414c1b33ac60cb0c0de61df86245d472259b0",
"c3d4a1425e17de9e05e3f6dfc6a24c26bfd5ee12",
"2a66dae03890ff791eabb982949435adb19af02b",
"24ac219478ba406f30794550690486b14cbac5e8",
"2b28d20690dc92374ebecb5508f8fdc6c7581790",
- "db8c34882ddd46716d14bbf569d530f80db65ed4",
"6c652ecce55e71fee16bc1c9b2c5ae4161bdd2ea",
"9b02173f424c098ea0f4cc5db9eb65f69263d127",
"a92942269911a88793b3460b6f2a2cd56e48eec1",
"059db9f0426b371e464ef3d30f1a4f4aa599e101",
- "a52d6ceee5c2a04b4e059c0d49337a997cc17e40",
"aa4a0a4b7f2697aaf270c89874631974bd9d7183",
"a7506e2c001d271593297c9eda9b984d4d894774",
"8f447a3820c83662086dfa836da2205b0130fd5f",
- "3772003c7fb420003512d0c437b3659d96d89ce4",
+ "2ebf37d81da3f11434652d06bf65d55e96b090aa",
+ "ace2c60bd76b11a002bee852686e8783f102eba1",
"dab47c9dc149e570045d699598b14a613bf319b3",
"2daca4d26a086ed34894693be0b0374402232809",
"904f1d82159bcf5485f323bd12b859dc5e83f8eb",
@@ -587,11 +568,8 @@
"2230f36f12d4becb242e2962fa1b3694db2496ca",
"d81e41a765d7a2d68073f5fde3f74f09df84001d",
"0de013c2c6aba9f99cbcf5f8cfd3212ded7ae72a",
- "5950f7d00cd8692872377df0e869a7d5ea5e4420",
"fedc67d1b0797be5f40cd45280844f2b61d29b0a",
- "7de23c68ca224818fdf127c5e96729dcd0de2b8b",
"a848b1b0293b05b3f9358a3ffcb21a2e5fdecf05",
- "1a0fd0df17fa4c455a4a91cad30b5242f77fd233",
"af45bf81d119be5cf6845ad41191ba52637e65e9",
NULL
};
@@ -625,7 +603,6 @@
"0e183a4c30b3da345129cffe33fe0fc593d8666b",
"f14d9a4bd8a365b7c8f068a0dad481b6eb2b178b",
"8933450132bf949ba4bc28626968425b5ed2867d",
- "9928a8f28a66c00069a124f7171b248817005763",
"e4a9dcc3e565cd3a6b7087dd1433f3898bb9cdb2",
"eca4f9b16b3bddfd0735fdd792e0ccaadfb9ba49",
"233e588cf660e2c9b552cf02065cf63fa6655864",
@@ -648,6 +625,8 @@
"9af4907a8144458a73dbb7471784f8c3d9aeffcf",
"104e85bad287a62dfe25f0e78280179f18bac765",
"f0acb3cfcda62e95bee5f7bc8830ffeb3dd7e5a7",
+ "fde993dfce1551ef220f5a07ce4acd66e8524ac5",
+ "a80f3df0aea1e1b30d9833039157bca658218f48",
"07b10c3f191d0a93e5e5694aae37dcad407e10f5",
"f7900e60347029876ba55e8f0c4c02e89deb36b6",
"f373a5f37b82e7523c64c08eb509b6191e49b173",
@@ -659,11 +638,8 @@
"13d1634e03bc49cfe14a32278d9b1f5ddbb9be10",
"a79e4cc419b9e1735e275e2823da52875536943a",
"b0182002cb1f4fba9df3c21a4d046ab41ce7e9be",
- "3830cd728c1e72837310940bcdac4e294d6c9843",
"f571c7c4aac92491017963032194690c0fa06b42",
- "6fd751b7328c02954bce98bed94b3ce3c73db118",
"91d50b5a604d6c38aa0d08b9af995490f8ec246b",
- "8585783d0373e9696b508776b6e6b18a80b09888",
"b53cde47b0e28063770d3b1328c3cc2f774a6300",
NULL
};
@@ -697,7 +673,6 @@
"1df851515ecf46df5c2d3279535c1763f72353dd",
"b68922915ebc2797d58deecf983f7d0cf9a5efbd",
"359bd76088a965bb0cee7c44800bc46b2638807e",
- "e14e5734b33057b890368f3e9d482d9e5a0358c5",
"64205ccaa277e64eeea0c20e99900ac79858ca2c",
"2cdee35d43d62da09b4ddfddbd0948ddbb9fc48e",
"91f988f575338505ba8a40727865a8d3f2298624",
@@ -707,25 +682,21 @@
"4fd49cb49853ef950fd0b7e2e35718a71c8374c7",
"e15a355fc09bfd22267917898e2266168ff410e3",
"7a9c326a56a94621377a7258be70ba50042ca9a2",
- "5e38e03310f1c66f2052af2a745d8c60515707c5",
"f994fb5019bf4c1a96eccf89af599eae0aa6b412",
"3a71ad6fef147067641e49a5f69b2454e3a5010d",
"ea10eac72830dcae19bcb16a076c2b21d844b5b6",
- "6376234f542467e5887adfece62f753e998dc19d",
"add949d009217ef2b847e34772ba363e4be7b1b8",
- "28fcf9f7d098c05de632ae38b2fe33b9635ad445",
"0b58666deb3615e912896a764e5c6475989e95e4",
- "bf460cc44c0edee851d72587c8425c3f06a62c55",
"ea74c00c45569007383b632d7f1d2adc82645717",
"5ac22e1a33b0204fdc7a68d54ee94648e96079a0",
- "284abed096637c80bb50844e393da9dd4b3f19ac",
"9dc776c5ab8256b1301c7d1da60544a9410e6715",
- "a433c41c05b6db008a4cb2c52a321d027c6be1fe",
"46f772c2832b3aad584674db666bd63e48b4f338",
"a9f9ca0049235db51ab7359a5fc3d21be42d2aac",
"f3dc739da41fb299637c8660e8c46917ddcf87a8",
"abd2fff80f74b311072ecdb91ce9ceba268fa6e9",
"9ae38bb94c7b4c0c6dfebbee23d1de4db9b77488",
+ "8269b32b4a34440f1fa37927308debc7eb85f3fa",
+ "65b2c868790806be7ab4aaa6114d445c42a31f98",
"678979a45126a76eb629992cd64734862f53a555",
"2f7ba8803604c032cb1a1228bc021f0f1c03e245",
"52e7c2f8b01592898c13f1e7633881e350244209",
@@ -737,11 +708,8 @@
"5e9e3e71b06c5efe20f93b3838e745b40b878471",
"153ae5c9fc2a31b38c4878b25d9026b9f51f132d",
"488341e88810d737de0b26de4e4d4fa0e78eb482",
- "bd1e7f40e3971e2ff6c5561286901193a1557527",
"5a42b7eeff8198e7b005e4afa4282e6ffb939906",
- "d7ffa3893c6fa937569791cf49986518a4a4d96e",
"26bc25a011e2b60961ee9d6c6141d928ae24389b",
- "8771d5ff7b93b9dd9d077e672b342235dfb28472",
"6a1f6e1d494bf6b0ece7af5fa164ebaadb3a19bd",
NULL
};
@@ -764,13 +732,9 @@
"114bb377b4e78a1978e1ac09388c48861b5223a3",
"8d0a92e6333e1b99591962e2def9bc9121111cf5",
"9dc511d6947fe816185cdff93bf0cfe0349b72b4",
- "eb4c14ee66b012187f5fe6a2ec28b6be956567c8",
"216388ddf6b563dd2058a9df65b40b6f72df1715",
- "ad11e4b6979cf055e3bf1868112a7bef207385a4",
"47f72be971bd2d3399dabd018201f4f5075e96fe",
- "de09d41c9ae4338fbfcfe9f8ed71d343537a6f3d",
"f39ab890a2b99d0c31e6e047f2315244972f5ffd",
- "6e7baf7d328bc2c55366e32967a0db4d2f43ab82",
"15b991814d84d6aa252696dd0c6150ef88a8db3f",
"1cb52f2a4d17b9b0d8375d016aa8cf0677fcd29a",
"9a6cfd68523e40ea1d52847d7747da912cfe2ca9",
@@ -779,7 +743,6 @@
"15db343049e3a9b31addc5d2ffebc3fe91b39c51",
"a895daf1f20371d4d1c3f93c070124cc13e341c3",
"3ddc872384ed8f9eaef472aa14a1d79a2c3f3b04",
- "0000000000000000000000000000000000000000",
"bd7d8c1cb4b2adc31cf8c7d39a4fa1e3ac7f2545",
"33fc8618ce62f5cdd9e06ad61e296f718a99899e",
"dcaa7fe030ae4d3029e38ca584047eeb2d17fe10",
@@ -789,25 +752,21 @@
"650a51bedd1af92469d2950eb95220db35f95c6e",
"3f43aa11e6fccb747cc13224583fb2f951fee08c",
"b83f78ae85df87fc7af565db276c60c102274f20",
- "6b6f4b97f05e015eb37a5f6aff637235feacd030",
"1bd06e4e11929e5e91c3c9f20def639b20e731e8",
"d63a6086547e90d2ba84aaebfeae24f3ba0c04f1",
"85425940daf119125deb52421b2057acebe6d1cf",
- "a3db92382cf0a4c7cafe52c27b1f41520aaa677d",
"9869b6f088822fb423996f9968e5a931301fc2c3",
- "cdf63ab4ab32c2e8e27527a9588d0fb525f1c945",
"a7f81cf3326fa3608acc13cfce2f573912e9d745",
- "f2ea92f523f8918b1d514a2d9555dcb4750273b4",
"e9c16e43a8f589ae85289c5c3ffea6b22fba1806",
"84a4bc0c2c5d36d016da4df95a5d8d6c8ce3ba6f",
- "f543efc84e638afbaa456e629100f0274de1a35b",
"1bd2587399006eed0d46beff397d32081f6bc58e",
- "f8a571de89ed82ffb9cbc041ce1eacb064be2853",
"640a49455acabca6954a7fbb6af4e872af342d11",
"589e7911e09332ee090371deae17b0120ff990b5",
"a1a941fa270cda48c648553ed4b427e16e96f8e0",
"115c90df05b1ff754dbdfe2a712ef126034d952d",
"fb63bbb2f944fb63ed2d7399f07b168740c1034b",
+ "ae45f0d463ff916f3cb630103969fd49e8d09ef4",
+ "2becf041f83d22ac072fef5e0efd9bc1572796fd",
"3685c9ae95118a83db3569832c29753276fa1264",
"09640bad951c33e7d70a1fced83b1869f65b3fc5",
"5eb00252664ec39e61359adb1dade4906a87a248",
@@ -820,11 +779,8 @@
"55d302ece31a9b7fc4be4a07a53767ba210273e7",
"a6a29836291f9dbca85e25cee60f62ef5faca6d7",
"3494a23633405e46af96cb57715617fef1ac252e",
- "5a3ae1da30d83cc157e6a4a5617c85598309f4ac",
"edc1ad2704452354aa6f79fac244a55b6f509c2e",
- "87eab8f81fb2a036080e099760f628037f9306e7",
"a3eac75d30f681b3898ee469d368960529634d7d",
- "cd5caeabdb71241766d24f038cfc5f1e91e11256",
"e2b393dc3f5833f7868668ea31369e90348768cd",
NULL
};
@@ -858,7 +814,6 @@
"3caf512cfddfd463d0750cfe3cadb58548eb2ae8",
"4e5e7d5fd64818b2b3d3e793c88f603b699d2f0f",
"c4efce8f7ed2d380ea5dc6fe1ef8448a27827532",
- "bdc0a354635b879871077c5b712570e469863c99",
"d599bf210423fe3adbb4f1de87d9360de97827d0",
"bae7c8b789e4e9b336c03c4daee3bce63fe039d9",
"cc01f17928f7780cefd423ea653b072eea723a1b",
@@ -868,15 +823,11 @@
"9a603513cd81acf70cf8b27b0d544e7f672e9d40",
"f4a334e69535de74ee5ed54be93a75120a66e54a",
"f751a55fb738b63b6fd7c229c33ef92605d0c9c1",
- "995f77f2f53398399f09d1365cb4dfd105764e5c",
"61907a6685bba93077da40cfb28cf2ab74552fd2",
"122015e5e17c1c317c6e51c0e207826b606a4077",
"c21851589a5f8a45ea5f9bb3e72f4f88d0a6697d",
- "8c609921d4a3ed89a994a75482b27496bf103cf5",
"eb2ce16a6ae251f4965135ee776776b5fc02c42c",
- "66493ee117719e172f327a426af601996025f28c",
"acead2745fec0b6c817fa601353bdf2d197b64f7",
- "a6b858b2d125c159529d3f3ec45b31925a79acff",
"1f1379089d7c6e8d733aaa4eaffbe02db6255b61",
"d83adc669c0dea0dc4812b93f998514b6f02d805",
"9e8ceb7c3cd68e043b6d875c8c84a1e394962412",
@@ -885,6 +836,8 @@
"7d1bfff706b0713e53209407889f83a0da26a81d",
"5a1d8f9ea978b820edbc5c9e1c6f1cac022620ad",
"31e667c2dbb81dcf81d01cb88f794e88ddb90ff2",
+ "c404446958788fac00ee1eff571d682bc21dd7ac",
+ "95060f3dc9e6d01ada42f09a871b69f0699cb77c",
"465d9cd0a77ab4fcf035aa67544b2a26269e0b09",
"600d6b2713d5e4c0d90c02660245ed26c7ae3033",
"0025a440866a404523a8a20e79a8891e45a2ff56",
@@ -896,11 +849,8 @@
"293c41a7ed923a4617560481ae8815cebf83701a",
"ec06b56f3abe277be42650ebd49dabeaae9e756d",
"750c923785ba2afb9ce597516c072f90f014bf95",
- "80089132f8a11d86e8038f2f8e12dfba46624ee5",
"bde5a62a065c027561226fbec5155e938ba7f6b3",
- "a6311d74fc058079a327abb536e69353be719925",
"fbaa8848a1d3896469c37fd43ab44233f5b875a3",
- "0000000000000000000000000000000000000000",
"c2ac98ef716fd8a5ac8f08ce66293d9a96344337",
NULL
};
@@ -934,7 +884,6 @@
"26ad5116562e7b58c76a26eaf521e2e40899e944",
"1bcc54eaf8e3c2b7c59ecccb23c240181d7ba8b8",
"4f827ca6927f15191588456f985bf29d2a3b3c24",
- "e7de769c3d12ea9dd223bef4881c578823bec67e",
"6fb102d020e5554116feefc8482104f3ae2036d2",
"ae546ffd30b837afc7dfcb5c9ce4f01d15b35ddc",
"20c9eb3276c08fdce35755e349bec94b04929812",
@@ -957,6 +906,8 @@
"46760975993f9881b7bbe94123173e6a683d3f25",
"c644f460937107214a88d5eb9e846d27abd8c874",
"df5feb905a31c288008cf5e82d73ac818a160d82",
+ "4f9658dde0432a711a4d783c1b5aa3365fb7d54b",
+ "09438163dcbede3890a0e6d8e614c97a06759380",
"d8af3868c66c7d6dac35ec8ee0317b38a6910bb1",
"ec8e2aebfb4a1c28ebcd0e053b9e4d8638b50951",
"ccf8d11b1e81895e9781f17c227c821228d8714b",
@@ -968,11 +919,8 @@
"287ea7db721e641439888cb9f4bac3a5f16124eb",
"dd9eaa5325cdf250e89162ac84207978ebb6458e",
"42466aab11852741d937c1ff6f3bb711e58415a6",
- "0663cf6330591fcf744aba96664e05d90243d07a",
"3024fa38333f83a639b0f0e6ac6d4b9868231157",
- "6fe7d0d17b892032cfd171c3d7c365f030b5be38",
"7ae780dcc7cf04dda50648bfc07cc6a7a2f2189e",
- "0000000000000000000000000000000000000000",
"9ab46e0c42f82dc73df8a55cbf881abd72397cec",
NULL
};
@@ -1006,7 +954,6 @@
"afdf41fca7951c6dd6193320de1295f2c68fe52a",
"f2f1f331fe6b1b31d7c9ddd37793b375fc01d3d4",
"f0af0f1edcb837bdf1535c1f5e9988c21ae9bfd1",
- "0000000000000000000000000000000000000000",
"71c4577baaf35f12f6707b1e2f78a1e8c0d41d0b",
"9b7d6b12385bb9e1cd881758aff342bd5427432b",
"6fdd5aa022da2a8af6f1d02b6072ebc068b4b600",
@@ -1029,6 +976,8 @@
"5eeb56afea8040a8fb18c11f29931b836474126d",
"30c256a783c4874261667bb31307eb282ab9470e",
"f8681c09f1abfc38d31e47622cb8798cd896a00e",
+ "0ba7e5d68419702605739acb52fcc01c96cb63d4",
+ "f8d2f196ba8a16f54acb934e61a759ab7d3f2f05",
"b5ee51cfc73acb59a2f6124509ea236f8fc7f9f7",
"d374d4d92c940ae42a9b42c14d744341b68a8c14",
"06a6a224be0f5cdc51ac4704f9f57fc1f3813d6f",
@@ -1040,11 +989,8 @@
"aa89612798fbc4e11a73b6233c0ac4832e6af2f9",
"c96a998be5c1d588ef1243cfd2610d056d16947e",
"68bee638d59a373f33f308751471b3ef41849582",
- "be0501175cc3cbb61217fca76356f761117fb40f",
"8fa37e26cdae406c2d1c81b1175dcf0311cf60c9",
- "3efe128a5bf250f2c460664e8f543f5ec54d5dc2",
"2d5123e757cf00e423a89160d7dc4997c3688829",
- "0000000000000000000000000000000000000000",
"36dfdad9f3f5cfde6add3cef23368c343d30469a",
NULL
};
@@ -1067,34 +1013,17 @@
"b0cc1f5e244ae0c0835a9866a46abdfcd56d1cb1",
"7ddf19df5bbdf4475b6ec1bc042425e382502864",
"144c9a846e5e37ac6efd5ed3a97ec231479e8fca",
- "c5ffc59048bf786b5646ad6226cd8633965de9ef",
- "40fadc2d24c713b04ff96f7dc26e70e85f26c55e",
"400a21caa01e015096ee1afcf1b54e7f8ec515bd",
- "0ff4b49797e30e3555aab45219adf449a9a560ff",
- "280327328ca940c212ce24fe72e0b00014072767",
"144c9a846e5e37ac6efd5ed3a97ec231479e8fca",
- "b85463875f755b85f1464b1b6275912bcbad6c9f",
- "816f200969feecc788b61dfeecf05b1790984401",
"a4964d8bbf80fe785f906bc0f7c5b113242a58fc",
- "a5d204cc7342d40b765ca042f8668e22601c4ff9",
"adb2818f6d3845dd140bc0f9abdbaa89d2a8c3de",
- "0a76e0121facb103857130bc6e12185ad77fc3fa",
- "02aede714773d654d0fc2f640afaa133ec718ad5",
"13cc63972aee4f6ae27091a8af18de01f1d3a5da",
- "3bb745ccb08402ce6fac6ee26fb8d7aad2dba27e",
- "b26699f62661e16a1dc452d24c88ce363a1f2998",
"4d95c3d1e170f004c80aa8c52feafb8e0e90760e",
- "c14832e69ec3585c15987b3d69d5007236fa9814",
- "e44ea620b0c47125a34193537ab9d219a52ad028",
"ef2db9fb75a672f69bab88e5d08fe64f50ec2bc4",
- "df81db2a9b3942a82e0dc5e57247b642f9b42702",
- "8819bf7a43295161fe045a42936000b3a51fe200",
- "e08dbc26469c229f75ccbf1a38a133401f270b84",
"d1e6091caa4482d3142df3b958606c41ebf4698e",
"07c1116d8286fb665a1005de220eadc3d5999aaf",
"4afb0649488f6e6f7d3a2b8bf438d82f2c88f4d1",
"f2fe295317e795a88edd0b2c52618b8cb0e7f2ce",
- "ffc78c075d4be66806f6c59180772d5eed963dc0",
"c86eeaeed09871dee4b43722ba512d2d3af7f4d0",
"24b1a6241c81dbb950cfbe5da6798fd59eb36266",
"1007d3b531b4bc3553d4547bc88443fc1f497cf6",
@@ -1119,6 +1048,8 @@
"a2a928de9007d765da496abec8c21b23601f8c45",
"41a417c1f25f2619301afa44bfcde85198985792",
"23366004515f3bc46796ea505d748f8d0f97fbe1",
+ "ba682eb15c0ddffb942e6086e0ccad2353ed7241",
+ "58273e1fbf961ff2c772d57160d60170e258d3fe",
"88763f8e8fcf4f78fa864325791a9dd35a0bd279",
"013cee26bac8f815eadad4bfc012d9b5d01c3b7f",
"44a28536466dc895feb824b23dfd4a47c6948af8",
@@ -1130,14 +1061,8 @@
"53ab1fcccd09fa5cbff77497f36a70a3b3cb8b81",
"4842a30dd7fdf38ddc3ddec85c08efe13a0e2e0b",
"cc76db6da5ba1776f20240a5ad97a26a9cdf96b0",
- "014f477664a7f4ce4a948d6359a2707119afc8e2",
- "74d01690e344bc22e7a0478e7a09ccd92354c486",
"9ab50a663b74577b656e9849484a909d7ac52eeb",
- "128eefd2ee043d59dc37918065f687e378e5ca95",
- "d7e2daab98ce1f698c4bfedfc01c0d79fcb76b8e",
"8d34215487088b5d4ef63062270ce25c2862643d",
- "826562eb11a0d0bba77fa21245f7406a194e9225",
- "bbae6f0659e095a42b420082079663f937065813",
"bbabe686a6955402c90530e7c67f1428868369b3",
NULL
};
@@ -1193,6 +1118,8 @@
{ 100, 100, 356, 356 },
{ 10, 10, 356, 356 },
{ 100, 100, 356, 356 },
+ { 0, 0, 260, 39 },
+ { 0, 0, 16, 16 },
{ 10, 10, 416, 26 },
{ 10, 8, 60, 104 },
{ 0, 10, 511, 306 },
@@ -1281,12 +1208,6 @@
ok( EqualRect( current_bounds, &rect ), "%s: %s: expected bounds %s got
%s\n", dst_format, info,
wine_dbgstr_rect( current_bounds ), wine_dbgstr_rect( &rect ));
- current_bounds++;
-}
-
-static void skip_compare( int count )
-{
- current_sha1 += count;
current_bounds++;
}
@@ -1821,10 +1742,7 @@
y += 25;
}
}
- if (bmi->bmiHeader.biBitCount == 8 && bmi->bmiHeader.biClrUsed == 256)
/* 8-bpp grayscale broken on NT4 */
- compare_hash_broken_todo(hdc, bmi, bits, "top-down 8888 dib brush
patblt", 1, FALSE);
- else
- compare_hash_broken_todo(hdc, bmi, bits, "top-down 8888 dib brush
patblt", dib_is_1bpp ? 2 : 0, dib_is_1bpp);
+ compare_hash_broken_todo(hdc, bmi, bits, "top-down 8888 dib brush patblt",
0, dib_is_1bpp);
SelectObject(hdc, orig_brush);
DeleteObject(dib_brush);
@@ -1851,10 +1769,7 @@
y += 25;
}
}
- if (bmi->bmiHeader.biBitCount == 8 && bmi->bmiHeader.biClrUsed == 256)
/* 8-bpp grayscale broken on NT4 */
- compare_hash_broken_todo(hdc, bmi, bits, "bottom-up 8888 dib brush
patblt", 1, FALSE);
- else
- compare_hash_broken_todo(hdc, bmi, bits, "bottom-up 8888 dib brush
patblt", dib_is_1bpp ? 2 : 0, dib_is_1bpp);
+ compare_hash(hdc, bmi, bits, "bottom-up 8888 dib brush patblt");
SelectObject(hdc, orig_brush);
DeleteObject(dib_brush);
@@ -1881,10 +1796,7 @@
y += 25;
}
}
- if (bmi->bmiHeader.biBitCount == 8 && bmi->bmiHeader.biClrUsed == 256)
/* 8-bpp grayscale broken on NT4 */
- compare_hash_broken_todo(hdc, bmi, bits, "top-down 24 bpp brush
patblt", 1, FALSE);
- else
- compare_hash_broken_todo(hdc, bmi, bits, "top-down 24 bpp brush
patblt", dib_is_1bpp ? 2 : 0, dib_is_1bpp);
+ compare_hash(hdc, bmi, bits, "top-down 24 bpp brush patblt");
SelectObject(hdc, orig_brush);
DeleteObject(dib_brush);
@@ -1911,10 +1823,7 @@
y += 25;
}
}
- if (bmi->bmiHeader.biBitCount == 8 && bmi->bmiHeader.biClrUsed == 256)
/* 8-bpp grayscale broken on NT4 */
- compare_hash_broken_todo(hdc, bmi, bits, "top-down 555 dib brush
patblt", 1, FALSE);
- else
- compare_hash_broken_todo(hdc, bmi, bits, "top-down 555 dib brush
patblt", dib_is_1bpp ? 1 : 0, dib_is_1bpp);
+ compare_hash_broken_todo(hdc, bmi, bits, "top-down 555 dib brush patblt",
0, dib_is_1bpp);
SelectObject(hdc, orig_brush);
DeleteObject(dib_brush);
@@ -1951,7 +1860,7 @@
y += 25;
}
}
- compare_hash_broken_todo(hdc, bmi, bits, "top-down 8 bpp dib brush patblt",
dib_is_1bpp ? 2 : 0, dib_is_1bpp);
+ compare_hash_broken_todo(hdc, bmi, bits, "top-down 8 bpp dib brush patblt",
0, dib_is_1bpp);
SelectObject(hdc, orig_brush);
DeleteObject(dib_brush);
@@ -1973,7 +1882,7 @@
y += 25;
}
}
- compare_hash_broken_todo(hdc, bmi, bits, "top-down 4 bpp dib brush patblt",
dib_is_1bpp ? 2 : 0, dib_is_1bpp);
+ compare_hash_broken_todo(hdc, bmi, bits, "top-down 4 bpp dib brush patblt",
0, dib_is_1bpp);
SelectObject(hdc, orig_brush);
DeleteObject(dib_brush);
@@ -1999,7 +1908,7 @@
}
}
- compare_hash_broken_todo(hdc, bmi, bits, "top-down 1 bpp dib brush patblt",
dib_is_1bpp ? 2 : 0, dib_is_1bpp);
+ compare_hash_broken_todo(hdc, bmi, bits, "top-down 1 bpp dib brush patblt",
0, dib_is_1bpp);
SelectObject(hdc, orig_brush);
DeleteObject(dib_brush);
@@ -2023,7 +1932,7 @@
}
}
- compare_hash_broken_todo(hdc, bmi, bits, "1 bpp ddb brush patblt",
dib_is_1bpp ? 3 : 0, dib_is_1bpp);
+ compare_hash_broken_todo(hdc, bmi, bits, "1 bpp ddb brush patblt", 0,
dib_is_1bpp);
DeleteObject(bmp);
SelectObject(hdc, orig_brush);
@@ -2058,21 +1967,12 @@
/* RTL rectangles */
- if( !pSetLayout )
- {
- win_skip("Don't have SetLayout\n");
- skip_compare(1);
- }
- else
- {
- pSetLayout(hdc, LAYOUT_RTL);
- PaintRgn(hdc, hrgn);
- PatBlt(hdc, 10, 250, 10, 10, PATCOPY);
- Rectangle(hdc, 100, 250, 110, 260);
- compare_hash(hdc, bmi, bits, "rtl");
-
- pSetLayout(hdc, LAYOUT_LTR);
- }
+ SetLayout(hdc, LAYOUT_RTL);
+ PaintRgn(hdc, hrgn);
+ PatBlt(hdc, 10, 250, 10, 10, PATCOPY);
+ Rectangle(hdc, 100, 250, 110, 260);
+ compare_hash(hdc, bmi, bits, "rtl");
+ SetLayout(hdc, LAYOUT_LTR);
DeleteObject( hrgn );
for(i = 0, y = 10; i < 256; i++)
@@ -2092,7 +1992,7 @@
}
}
- compare_hash_broken_todo(hdc, bmi, bits, "hatch brushes", 1, FALSE); /* nt4
is different */
+ compare_hash(hdc, bmi, bits, "hatch brushes");
/* overlapping blits */
@@ -2196,39 +2096,17 @@
BitBlt( hdc, 7, 28, 2, 2, src_dc, 0, 0, SRCCOPY );
BitBlt( hdc, 7, 32, 9, 2, src_dc, 0, 0, SRCCOPY );
BitBlt( hdc, 7, 36, 10, 2, src_dc, 0, 0, SRCCOPY );
-
- if (bmi->bmiHeader.biBitCount == 8) /* broken on NT4 */
- compare_hash_broken_todo(hdc, bmi, bits, "BitBlt src 32-bpp SRCCOPY",
1, FALSE );
- else
- compare_hash(hdc, bmi, bits, "BitBlt src 32-bpp SRCCOPY" );
+ compare_hash(hdc, bmi, bits, "BitBlt src 32-bpp SRCCOPY" );
blend.SourceConstantAlpha = 0xd0;
blend.AlphaFormat = 0;
- if (pGdiAlphaBlend) pGdiAlphaBlend( hdc, 100, 100, 256, 256, src_dc, 0, 0, 256, 256,
blend );
- if (bmi->bmiHeader.biBitCount == 16 && bmi->bmiHeader.biCompression ==
BI_RGB) /* 555 broken on w2k */
- {
- if (!pGdiAlphaBlend) skip_compare(2);
- else compare_hash_broken_todo(hdc, bmi, bits, "AlphaBlend src 32-bpp no
alpha", 1, FALSE );
- }
- else
- {
- if (!pGdiAlphaBlend) skip_compare(1);
- else compare_hash_broken_todo(hdc, bmi, bits, "AlphaBlend src 32-bpp no
alpha", 0, dib_is_1bpp );
- }
+ GdiAlphaBlend( hdc, 100, 100, 256, 256, src_dc, 0, 0, 256, 256, blend );
+ compare_hash_broken_todo(hdc, bmi, bits, "AlphaBlend src 32-bpp no alpha",
0, dib_is_1bpp );
blend.SourceConstantAlpha = 0xb0;
blend.AlphaFormat = AC_SRC_ALPHA;
- if (pGdiAlphaBlend) pGdiAlphaBlend( hdc, 50, 50, 256, 256, src_dc, 0, 0, 256, 256,
blend );
- if (bmi->bmiHeader.biBitCount == 16 && bmi->bmiHeader.biCompression ==
BI_RGB) /* 555 broken on w2k */
- {
- if (!pGdiAlphaBlend) skip_compare(2);
- else compare_hash_broken_todo(hdc, bmi, bits, "AlphaBlend src 32-bpp
alpha", 1, FALSE );
- }
- else
- {
- if (!pGdiAlphaBlend) skip_compare(1);
- else compare_hash_broken_todo(hdc, bmi, bits, "AlphaBlend src 32-bpp
alpha", 0, dib_is_1bpp );
- }
+ GdiAlphaBlend( hdc, 50, 50, 256, 256, src_dc, 0, 0, 256, 256, blend );
+ compare_hash_broken_todo(hdc, bmi, bits, "AlphaBlend src 32-bpp alpha", 0,
dib_is_1bpp );
/* blitting with 32-bpp r10g10b10 source */
@@ -2249,10 +2127,7 @@
}
BitBlt( hdc, 100, 100, 256, 256, src_dc, 0, 0, SRCCOPY );
- if (bmi->bmiHeader.biBitCount == 8) /* broken on NT4 */
- compare_hash_broken_todo(hdc, bmi, bits, "BitBlt src 32-bpp r10g10b10
SRCCOPY", 1, FALSE );
- else
- compare_hash(hdc, bmi, bits, "BitBlt src 32-bpp r10g10b10 SRCCOPY" );
+ compare_hash(hdc, bmi, bits, "BitBlt src 32-bpp r10g10b10 SRCCOPY" );
/* blitting with 32-bpp b6g6r6 source */
@@ -2273,10 +2148,7 @@
}
BitBlt( hdc, 100, 100, 256, 256, src_dc, 0, 0, SRCCOPY );
- if (bmi->bmiHeader.biBitCount == 8) /* broken on NT4 */
- compare_hash_broken_todo(hdc, bmi, bits, "BitBlt src 32-bpp b6g6r6
SRCCOPY", 1, FALSE );
- else
- compare_hash(hdc, bmi, bits, "BitBlt src 32-bpp b6g6r6 SRCCOPY" );
+ compare_hash(hdc, bmi, bits, "BitBlt src 32-bpp b6g6r6 SRCCOPY" );
/* blitting with 24-bpp source */
@@ -2293,24 +2165,12 @@
}
BitBlt( hdc, 100, 100, 256, 256, src_dc, 0, 0, SRCCOPY );
- if (bmi->bmiHeader.biBitCount == 8) /* broken on NT4 */
- compare_hash_broken_todo(hdc, bmi, bits, "BitBlt src 24-bpp SRCCOPY",
1, FALSE );
- else
- compare_hash(hdc, bmi, bits, "BitBlt src 24-bpp SRCCOPY" );
+ compare_hash(hdc, bmi, bits, "BitBlt src 24-bpp SRCCOPY" );
blend.SourceConstantAlpha = 0xe0;
blend.AlphaFormat = 0;
- if (pGdiAlphaBlend) pGdiAlphaBlend( hdc, 100, 100, 256, 256, src_dc, 0, 0, 256, 256,
blend );
- if (bmi->bmiHeader.biBitCount == 16 && bmi->bmiHeader.biCompression ==
BI_RGB) /* 555 broken on w2k */
- {
- if (!pGdiAlphaBlend) skip_compare(2);
- else compare_hash_broken_todo(hdc, bmi, bits, "AlphaBlend src 24-bpp",
1, FALSE );
- }
- else
- {
- if (!pGdiAlphaBlend) skip_compare(1);
- else compare_hash_broken_todo(hdc, bmi, bits, "AlphaBlend src 24-bpp",
0, dib_is_1bpp );
- }
+ GdiAlphaBlend( hdc, 100, 100, 256, 256, src_dc, 0, 0, 256, 256, blend );
+ compare_hash_broken_todo(hdc, bmi, bits, "AlphaBlend src 24-bpp", 0,
dib_is_1bpp );
/* blitting with 16-bpp BI_RGB source */
@@ -2323,10 +2183,7 @@
((WORD *)src_bits)[y * 256 + x] = x | x << 4 | x << 8 | y
<< 3 | y << 7;
BitBlt( hdc, 100, 100, 256, 256, src_dc, 0, 0, SRCCOPY );
- if (bmi->bmiHeader.biBitCount == 8 && bmi->bmiHeader.biClrUsed > 5)
/* broken on NT4 */
- compare_hash_broken_todo(hdc, bmi, bits, "BitBlt src 16-bpp SRCCOPY",
1, FALSE );
- else
- compare_hash(hdc, bmi, bits, "BitBlt src 16-bpp SRCCOPY" );
+ compare_hash(hdc, bmi, bits, "BitBlt src 16-bpp SRCCOPY" );
/* blitting with 16-bpp b4g4r4 source */
@@ -2342,10 +2199,7 @@
((WORD *)src_bits)[y * 256 + x] = x | x << 4 | x << 8 | y
<< 3 | y << 7;
BitBlt( hdc, 100, 100, 256, 256, src_dc, 0, 0, SRCCOPY );
- if (bmi->bmiHeader.biBitCount == 8 && bmi->bmiHeader.biClrUsed > 5)
/* broken on NT4 */
- compare_hash_broken_todo(hdc, bmi, bits, "BitBlt src 16-bpp b4g4r4
SRCCOPY", 1, FALSE );
- else
- compare_hash(hdc, bmi, bits, "BitBlt src 16-bpp b4g4r4 SRCCOPY" );
+ compare_hash(hdc, bmi, bits, "BitBlt src 16-bpp b4g4r4 SRCCOPY" );
/* blitting with 8-bpp source */
@@ -2364,17 +2218,8 @@
blend.SourceConstantAlpha = 0xd0;
blend.AlphaFormat = 0;
- if (pGdiAlphaBlend) pGdiAlphaBlend( hdc, 100, 100, 256, 256, src_dc, 0, 0, 256, 256,
blend );
- if (bmi->bmiHeader.biBitCount == 16 && bmi->bmiHeader.biCompression ==
BI_RGB) /* 555 broken on w2k */
- {
- if (!pGdiAlphaBlend) skip_compare(2);
- else compare_hash_broken_todo(hdc, bmi, bits, "AlphaBlend src 8-bpp",
1, FALSE );
- }
- else
- {
- if (!pGdiAlphaBlend) skip_compare(1);
- else compare_hash_broken_todo(hdc, bmi, bits, "AlphaBlend src 8-bpp",
0, dib_is_1bpp );
- }
+ GdiAlphaBlend( hdc, 100, 100, 256, 256, src_dc, 0, 0, 256, 256, blend );
+ compare_hash_broken_todo(hdc, bmi, bits, "AlphaBlend src 8-bpp", 0,
dib_is_1bpp );
/* blitting with 4-bpp source */
@@ -2412,17 +2257,95 @@
blend.SourceConstantAlpha = 0x90;
blend.AlphaFormat = 0;
- if (pGdiAlphaBlend) pGdiAlphaBlend( hdc, 100, 100, 256, 256, src_dc, 0, 0, 256, 256,
blend );
- if (bmi->bmiHeader.biBitCount == 16 && bmi->bmiHeader.biCompression ==
BI_RGB) /* 555 broken on w2k */
- {
- if (!pGdiAlphaBlend) skip_compare(2);
- else compare_hash_broken_todo(hdc, bmi, bits, "AlphaBlend src 1-bpp",
1, FALSE );
- }
- else
- {
- if (!pGdiAlphaBlend) skip_compare(1);
- else compare_hash(hdc, bmi, bits, "AlphaBlend src 1-bpp" );
- }
+ GdiAlphaBlend( hdc, 100, 100, 256, 256, src_dc, 0, 0, 256, 256, blend );
+ compare_hash(hdc, bmi, bits, "AlphaBlend src 1-bpp" );
+
+ /* blitting with 1-bpp ddb source */
+
+ bmp = CreateBitmap( 16, 16, 1, 1, ddb_brush_bits );
+ DeleteObject( SelectObject( src_dc, bmp ) );
+
+ old_text = GetTextColor( hdc );
+ old_bkgnd = GetBkColor( hdc );
+ for (i = 0; i < 256; i += 13)
+ {
+ SetTextColor(hdc, RGB( i, 2*i, 255 - i ) );
+ SetBkColor(hdc, RGB( 255 - i, i / 3, i ) );
+ BitBlt( hdc, i, 0, 13, 13, src_dc, 0, 0, SRCCOPY );
+ }
+ for (i = 0; i < 256; i += 13)
+ {
+ SetTextColor(hdc, PALETTEINDEX( i ));
+ SetBkColor(hdc, PALETTEINDEX( i + 3 ));
+ BitBlt( hdc, i, 13, 13, 13, src_dc, 0, 0, SRCCOPY );
+ }
+ for (i = 0; i < 256; i += 13)
+ {
+ SetTextColor(hdc, DIBINDEX( i ));
+ SetBkColor(hdc, DIBINDEX( i + 3 ));
+ BitBlt( hdc, i, 26, 13, 13, src_dc, 0, 0, SRCCOPY );
+ }
+ SetTextColor( hdc, old_text );
+ SetBkColor( hdc, old_bkgnd );
+ compare_hash(hdc, bmi, bits, "BitBlt src 1-bpp ddb SRCCOPY" );
+
+ DeleteObject( bmp );
+
+ /* blitting to 1-bpp ddb dest */
+
+ bmp = CreateBitmap( 16, 16, 1, 1, ddb_brush_bits );
+ DeleteObject( SelectObject( src_dc, bmp ) );
+
+ for (y = 0; y < 16; y++)
+ for (x = 0; x < 16; x++)
+ SetPixel( hdc, x, y, RGB( 16 * x, 16 * y, 8 * (x + y)) );
+ PatBlt( hdc, 15, 15, 1, 1, WHITENESS );
+ /* source colors are ignored */
+ SetTextColor( src_dc, 0xbeef );
+ SetBkColor( src_dc, RGB( 16 * 2, 16 * 3, 8 * (2 + 3) ));
+ /* destination text color is also ignored */
+ SetTextColor( hdc, 0xbedead );
+
+ i = 16;
+ SetBkColor( hdc, 0xffffff );
+ BitBlt( src_dc, 0, 0, 16, 16, hdc, 0, 0, SRCCOPY );
+ GetBitmapBits( bmp, 32, bits + get_stride(bmi) * i++ );
+ StretchDIBits( src_dc, 0, 0, 16, 16, 0,
+ bmi->bmiHeader.biHeight - 16, 16, 16, bits, bmi, DIB_RGB_COLORS,
SRCCOPY );
+ GetBitmapBits( bmp, 32, bits + get_stride(bmi) * i++ );
+ SetBkColor( hdc, 0 );
+ BitBlt( src_dc, 0, 0, 16, 16, hdc, 0, 0, SRCCOPY );
+ GetBitmapBits( bmp, 32, bits + get_stride(bmi) * i++ );
+ StretchDIBits( src_dc, 0, 0, 16, 16, 0,
+ bmi->bmiHeader.biHeight - 16, 16, 16, bits, bmi, DIB_RGB_COLORS,
SRCCOPY );
+ GetBitmapBits( bmp, 32, bits + get_stride(bmi) * i++ );
+ SetBkColor( hdc, RGB( 16 * 2, 16 * 3, 8 * (2 + 3) ));
+ BitBlt( src_dc, 0, 0, 16, 16, hdc, 0, 0, SRCCOPY );
+ GetBitmapBits( bmp, 32, bits + get_stride(bmi) * i++ );
+ StretchDIBits( src_dc, 0, 0, 16, 16, 0,
+ bmi->bmiHeader.biHeight - 16, 16, 16, bits, bmi, DIB_RGB_COLORS,
SRCCOPY );
+ GetBitmapBits( bmp, 32, bits + get_stride(bmi) * i++ );
+ SetBkColor( hdc, RGB( 16 * 13, 16 * 14, 8 * (13 + 14) ));
+ BitBlt( src_dc, 0, 0, 16, 16, hdc, 0, 0, SRCCOPY );
+ GetBitmapBits( bmp, 32, bits + get_stride(bmi) * i++ );
+ StretchDIBits( src_dc, 0, 0, 16, 16, 0,
+ bmi->bmiHeader.biHeight - 16, 16, 16, bits, bmi, DIB_RGB_COLORS,
SRCCOPY );
+ GetBitmapBits( bmp, 32, bits + get_stride(bmi) * i++ );
+ SetBkColor( hdc, PALETTEINDEX( 1 ));
+ BitBlt( src_dc, 0, 0, 16, 16, hdc, 0, 0, SRCCOPY );
+ GetBitmapBits( bmp, 32, bits + get_stride(bmi) * i++ );
+ StretchDIBits( src_dc, 0, 0, 16, 16, 0,
+ bmi->bmiHeader.biHeight - 16, 16, 16, bits, bmi, DIB_RGB_COLORS,
SRCCOPY );
+ GetBitmapBits( bmp, 32, bits + get_stride(bmi) * i++ );
+ SetBkColor( hdc, DIBINDEX( 2 ));
+ BitBlt( src_dc, 0, 0, 16, 16, hdc, 0, 0, SRCCOPY );
+ GetBitmapBits( bmp, 32, bits + get_stride(bmi) * i++ );
+ StretchDIBits( src_dc, 0, 0, 16, 16, 0,
+ bmi->bmiHeader.biHeight - 16, 16, 16, bits, bmi, DIB_RGB_COLORS,
SRCCOPY );
+ GetBitmapBits( bmp, 32, bits + get_stride(bmi) * i++ );
+ SetTextColor( hdc, old_text );
+ SetBkColor( hdc, old_bkgnd );
+ compare_hash(hdc, bmi, bits, "BitBlt dst 1-bpp ddb");
DeleteDC( src_dc );
DeleteObject( bmp );
@@ -2553,7 +2476,6 @@
/* gradients */
- if (pGdiGradientFill)
{
TRIVERTEX vrect[] =
{
@@ -2600,28 +2522,17 @@
{ 2, 1, 0 }, { 3, 5, 4 }, { 7, 6, 8 }, { 10, 11, 9 }, { 14, 13, 12 }, { 17,
15, 16 }, { 19, 20, 18 }
};
- pGdiGradientFill( hdc, vrect, 4, rect, 2, GRADIENT_FILL_RECT_H );
+ GdiGradientFill( hdc, vrect, 4, rect, 2, GRADIENT_FILL_RECT_H );
for (i = 0; i < 4; i++) vrect[i].y += 250;
- pGdiGradientFill( hdc, vrect, 4, rect, 2, GRADIENT_FILL_RECT_V );
-
- if (bmi->bmiHeader.biBitCount <= 8) /* Wine's 8-bit dithering isn't
identical to Windows */
- compare_hash_broken_todo(hdc, bmi, bits, "GdiGradientFill", 0, 1
);
- else
- compare_hash(hdc, bmi, bits, "GdiGradientFill" );
-
- pGdiGradientFill( hdc, vtri, 7*3, tri, 7, GRADIENT_FILL_TRIANGLE );
+ GdiGradientFill( hdc, vrect, 4, rect, 2, GRADIENT_FILL_RECT_V );
+ /* Wine's 8-bit dithering isn't identical to Windows */
+ compare_hash_broken_todo(hdc, bmi, bits, "GdiGradientFill", 0,
(bmi->bmiHeader.biBitCount <= 8) );
+
+ GdiGradientFill( hdc, vtri, 7*3, tri, 7, GRADIENT_FILL_TRIANGLE );
for (i = 0; i < 7*3; i++) vtri[i].y += 100;
- pGdiGradientFill( hdc, vtri, 7*3, tri + 7, 7, GRADIENT_FILL_TRIANGLE );
- if (bmi->bmiHeader.biBitCount <= 8) /* Wine's 8-bit dithering isn't
identical to Windows */
- compare_hash_broken_todo(hdc, bmi, bits, "GdiGradientFill", 0, 1
);
- else
- compare_hash(hdc, bmi, bits, "GdiGradientFill" );
- }
- else
- {
- win_skip( "GdiGradientFill not supported\n" );
- skip_compare(1);
- skip_compare(1);
+ GdiGradientFill( hdc, vtri, 7*3, tri + 7, 7, GRADIENT_FILL_TRIANGLE );
+ /* Wine's 8-bit dithering isn't identical to Windows */
+ compare_hash_broken_todo(hdc, bmi, bits, "GdiGradientFill", 0,
(bmi->bmiHeader.biBitCount <= 8) );
}
/* wide pen */
@@ -2700,8 +2611,7 @@
LineTo( hdc, 10 * i, 200 + i );
LineTo( hdc, 20 * i, 200 + i );
}
- /* NT4 broken for all cases, W2K for 1 bpp only */
- compare_hash_broken_todo(hdc, bmi, bits, "wide brushed pen", 1 +
dib_is_1bpp, dib_is_1bpp );
+ compare_hash_broken_todo(hdc, bmi, bits, "wide brushed pen", 0,
dib_is_1bpp );
for (i = 1; i < 20; i++)
{
@@ -2714,8 +2624,7 @@
LineTo( hdc, 10 * i, 200 + i );
LineTo( hdc, 20 * i, 200 + i );
}
- /* NT4 broken for all cases, W2K for 1 bpp only */
- compare_hash_broken_todo(hdc, bmi, bits, "dashed wide brushed pen", 1 +
dib_is_1bpp, dib_is_1bpp );
+ compare_hash_broken_todo(hdc, bmi, bits, "dashed wide brushed pen", 0,
dib_is_1bpp );
DeleteObject(bmp);
SetTextColor(hdc, old_text);
@@ -2771,8 +2680,7 @@
SelectPalette( hdc, old_hpal, FALSE );
DeleteObject( hpal );
- /* NT4 broken for all cases, W2K for 1 bpp only */
- compare_hash_broken_todo(hdc, bmi, bits, "PALETTEINDEX", 1 + dib_is_1bpp,
dib_is_1bpp );
+ compare_hash_broken_todo(hdc, bmi, bits, "PALETTEINDEX", 0, dib_is_1bpp );
/* ExtFloodFill */
@@ -3019,9 +2927,7 @@
ok(ds.dsBitfields[0] == 0, "got %08x\n", ds.dsBitfields[0]);
ok(ds.dsBitfields[1] == 0, "got %08x\n", ds.dsBitfields[1]);
ok(ds.dsBitfields[2] == 0, "got %08x\n", ds.dsBitfields[2]);
- ok(ds.dsBmih.biCompression == BI_RGB ||
- broken(ds.dsBmih.biCompression == BI_BITFIELDS), /* nt4 sp1 and 2 */
- "got %x\n", ds.dsBmih.biCompression);
+ ok(ds.dsBmih.biCompression == BI_RGB, "got %x\n",
ds.dsBmih.biCompression);
orig_bm = SelectObject(mem_dc, dib);
@@ -3352,11 +3258,6 @@
START_TEST(dib)
{
- HMODULE mod = GetModuleHandleA("gdi32.dll");
- pSetLayout = (void *)GetProcAddress( mod, "SetLayout" );
- pGdiAlphaBlend = (void *)GetProcAddress( mod, "GdiAlphaBlend" );
- pGdiGradientFill = (void *)GetProcAddress( mod, "GdiGradientFill" );
-
CryptAcquireContextW(&crypt_prov, NULL, NULL, PROV_RSA_FULL,
CRYPT_VERIFYCONTEXT);
test_simple_graphics();
Modified: trunk/rostests/winetests/gdi32/font.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/gdi32/font.c?re…
==============================================================================
--- trunk/rostests/winetests/gdi32/font.c [iso-8859-1] (original)
+++ trunk/rostests/winetests/gdi32/font.c [iso-8859-1] Sun Jun 4 01:50:46 2017
@@ -30,10 +30,12 @@
#include "wine/test.h"
-/* Do not allow more than 1 deviation here */
-#define match_off_by_1(a, b, exact) (abs((a) - (b)) <= ((exact) ? 0 : 1))
-
-#define near_match(a, b) (abs((a) - (b)) <= 6)
+static inline BOOL match_off_by_n(int a, int b, unsigned int n)
+{
+ return abs(a - b) <= n;
+}
+#define match_off_by_1(a, b, exact) match_off_by_n((a), (b), (exact) ? 0 : 1)
+#define near_match(a, b) match_off_by_n((a), (b), 6)
#define expect(expected, got) ok(got == expected, "Expected %.8x, got %.8x\n",
expected, got)
static LONG (WINAPI *pGdiGetCharDimensions)(HDC hdc, LPTEXTMETRICW lptm, LONG *height);
@@ -107,20 +109,20 @@
system_lang_id = PRIMARYLANGID(GetSystemDefaultLangID());
}
-static void *heap_alloc( size_t len )
-{
- return HeapAlloc( GetProcessHeap(), 0, len );
-}
-
-static void *heap_realloc( void *p, size_t len )
-{
- if (!p) return heap_alloc( len );
- return HeapReAlloc( GetProcessHeap(), 0, p, len );
-}
-
-static void heap_free( void *p )
-{
- HeapFree( GetProcessHeap(), 0, p );
+static inline void* __WINE_ALLOC_SIZE(1) heap_alloc(size_t size)
+{
+ return HeapAlloc(GetProcessHeap(), 0, size);
+}
+
+static inline void* __WINE_ALLOC_SIZE(2) heap_realloc(void *mem, size_t size)
+{
+ if (!mem) return heap_alloc(size);
+ return HeapReAlloc(GetProcessHeap(), 0, mem, size);
+}
+
+static inline BOOL heap_free(void *mem)
+{
+ return HeapFree(GetProcessHeap(), 0, mem);
}
static INT CALLBACK is_truetype_font_installed_proc(const LOGFONTA *elf, const
TEXTMETRICA *ntm, DWORD type, LPARAM lParam)
@@ -4908,6 +4910,37 @@
ok(ratio >= 90 && ratio <= 110, "expected width/height ratio
90-110, got %d\n", ratio);
}
+static void test_GetCharacterPlacement(void)
+{
+ GCP_RESULTSA result;
+ DWORD size, size2;
+ WCHAR glyphs[20];
+ HDC hdc;
+
+ hdc = CreateCompatibleDC(0);
+ ok(!!hdc, "CreateCompatibleDC failed\n");
+
+ memset(&result, 0, sizeof(result));
+ result.lStructSize = sizeof(result);
+ result.lpGlyphs = glyphs;
+ result.nGlyphs = 20;
+
+ size = GetCharacterPlacementA(hdc, "Wine Test", 9, 0, &result, 0);
+ ok(size, "GetCharacterPlacementA failed!\n");
+
+ size2 = GetCharacterPlacementA(hdc, "Wine Test", 9, 0, NULL, 0);
+ ok(size2, "GetCharacterPlacementA failed!\n");
+ ok(size == size2, "GetCharacterPlacementA returned different result: %u vs
%u\n", size2, size);
+
+ size2 = GetCharacterPlacementA(hdc, "Wine Test", 9, 1024, NULL,
GCP_REORDER);
+ ok(size2, "GetCharacterPlacementA failed!\n");
+ ok(size == size2, "GetCharacterPlacementA returned different result: %u vs
%u\n", size2, size);
+
+ size = GetCharacterPlacementA(hdc, "Wine Test", 9, 1024, &result,
GCP_REORDER);
+ ok(size, "GetCharacterPlacementA failed!\n");
+ ok(size == size2, "GetCharacterPlacementA returned different result: %u vs
%u\n", size2, size);
+}
+
static void test_CreateFontIndirect(void)
{
LOGFONTA lf, getobj_lf;
@@ -5303,10 +5336,13 @@
ret = EnumFontFamiliesExA(hdc, &lf, enum_ms_shell_dlg_proc, (LPARAM)&efnd,
0);
ok(!ret, "MS Shell Dlg should be enumerated\n");
ok(efnd.total > 0, "MS Shell Dlg should be enumerated\n");
- ret = strcmp((const char *)efnd.elf[0].elfLogFont.lfFaceName, "MS Shell
Dlg");
- ok(!ret, "expected MS Shell Dlg, got %s\n",
efnd.elf[0].elfLogFont.lfFaceName);
- ret = strcmp((const char *)efnd.elf[0].elfFullName, "MS Shell Dlg");
- ok(ret, "did not expect MS Shell Dlg\n");
+ if (efnd.total)
+ {
+ ret = strcmp((const char *)efnd.elf[0].elfLogFont.lfFaceName, "MS Shell
Dlg");
+ ok(!ret, "expected MS Shell Dlg, got %s\n",
efnd.elf[0].elfLogFont.lfFaceName);
+ ret = strcmp((const char *)efnd.elf[0].elfFullName, "MS Shell Dlg");
+ ok(ret, "did not expect MS Shell Dlg\n");
+ }
efnd.total = 0;
ret = EnumFontFamiliesExA(hdc, NULL, enum_ms_shell_dlg2_proc, (LPARAM)&efnd, 0);
@@ -5318,10 +5354,13 @@
ret = EnumFontFamiliesExA(hdc, &lf, enum_ms_shell_dlg2_proc, (LPARAM)&efnd,
0);
ok(!ret, "MS Shell Dlg 2 should be enumerated\n");
ok(efnd.total > 0, "MS Shell Dlg 2 should be enumerated\n");
- ret = strcmp((const char *)efnd.elf[0].elfLogFont.lfFaceName, "MS Shell Dlg
2");
- ok(!ret, "expected MS Shell Dlg 2, got %s\n",
efnd.elf[0].elfLogFont.lfFaceName);
- ret = strcmp((const char *)efnd.elf[0].elfFullName, "MS Shell Dlg 2");
- ok(ret, "did not expect MS Shell Dlg 2\n");
+ if (efnd.total)
+ {
+ ret = strcmp((const char *)efnd.elf[0].elfLogFont.lfFaceName, "MS Shell Dlg
2");
+ ok(!ret, "expected MS Shell Dlg 2, got %s\n",
efnd.elf[0].elfLogFont.lfFaceName);
+ ret = strcmp((const char *)efnd.elf[0].elfFullName, "MS Shell Dlg 2");
+ ok(ret, "did not expect MS Shell Dlg 2\n");
+ }
heap_free(efnd.elf);
DeleteDC(hdc);
@@ -5646,6 +5685,45 @@
ReleaseDC(NULL, hdc);
}
+static void test_fstype_fixup(void)
+{
+ HDC hdc;
+ LOGFONTA lf;
+ HFONT hfont, hfont_prev;
+ DWORD ret;
+ OUTLINETEXTMETRICA *otm;
+ DWORD otm_size;
+
+ memset(&lf, 0, sizeof(lf));
+ lf.lfHeight = 72;
+ lstrcpyA(lf.lfFaceName, "wine_test");
+
+ SetLastError(0xdeadbeef);
+ hfont = CreateFontIndirectA(&lf);
+ ok(hfont != 0, "CreateFontIndirectA error %u\n", GetLastError());
+
+ hdc = GetDC(NULL);
+
+ hfont_prev = SelectObject(hdc, hfont);
+ ok(hfont_prev != NULL, "SelectObject failed\n");
+
+ otm_size = GetOutlineTextMetricsA(hdc, 0, NULL);
+ otm = HeapAlloc(GetProcessHeap(), 0, otm_size);
+ otm->otmSize = sizeof(*otm);
+ ret = GetOutlineTextMetricsA(hdc, otm->otmSize, otm);
+ ok(ret == otm->otmSize, "expected %u, got %u, error %d\n",
otm->otmSize, ret, GetLastError());
+
+ /* Test font has fsType set to 0x7fff, test that reserved bits are filtered out,
+ valid bits are 1, 2, 3, 8, 9. */
+ ok((otm->otmfsType & ~0x30e) == 0, "fsType %#x\n",
otm->otmfsType);
+
+ HeapFree(GetProcessHeap(), 0, otm);
+
+ SelectObject(hdc, hfont_prev);
+ DeleteObject(hfont);
+ ReleaseDC(NULL, hdc);
+}
+
static void test_CreateScalableFontResource(void)
{
char ttf_name[MAX_PATH];
@@ -5729,6 +5807,7 @@
test_GetGlyphOutline_empty_contour();
test_GetGlyphOutline_metric_clipping();
+ test_fstype_fixup();
ret = pRemoveFontResourceExA(fot_name, FR_PRIVATE, 0);
ok(!ret, "RemoveFontResourceEx() with not matching flags should fail\n");
@@ -6589,6 +6668,48 @@
DeleteDC(hdc);
}
+static void test_GetCharWidthI(void)
+{
+ static const char *teststr = "wine ";
+ HFONT hfont, prev_hfont;
+ WORD glyphs[5];
+ INT widths[5];
+ LOGFONTA lf;
+ ABC abc[5];
+ int len, i;
+ DWORD nb;
+ BOOL ret;
+ HDC hdc;
+
+ memset(&lf, 0, sizeof(lf));
+ strcpy(lf.lfFaceName, "Tahoma");
+ lf.lfHeight = -20;
+
+ hdc = GetDC(0);
+
+ hfont = CreateFontIndirectA(&lf);
+ prev_hfont = SelectObject(hdc, hfont);
+
+ len = strlen(teststr);
+ nb = GetGlyphIndicesA(hdc, teststr, len, glyphs, 0);
+ ok(nb == len, "\n");
+
+ memset(abc, 0xcc, sizeof(abc));
+ ret = GetCharABCWidthsI(hdc, 0, len, glyphs, abc);
+ ok(ret, "GetCharABCWidthsI failed\n");
+
+ memset(widths, 0xcc, sizeof(widths));
+ ret = GetCharWidthI(hdc, 0, len, glyphs, widths);
+ ok(ret, "GetCharWidthI failed\n");
+
+ for (i = 0; i < len; i++)
+ ok(widths[i] == abc[i].abcA + abc[i].abcB + abc[i].abcC, "%u, glyph %u, got
width %d\n",
+ i, glyphs[i], widths[i]);
+
+ DeleteObject(SelectObject(hdc, prev_hfont));
+ ReleaseDC(0, hdc);
+}
+
START_TEST(font)
{
init();
@@ -6640,6 +6761,7 @@
test_GetTextMetrics2("Arial", -11);
test_GetTextMetrics2("Arial", -55);
test_GetTextMetrics2("Arial", -110);
+ test_GetCharacterPlacement();
test_CreateFontIndirect();
test_CreateFontIndirectEx();
test_oemcharset();
@@ -6651,6 +6773,7 @@
test_GetCharWidth32();
test_fake_bold_font();
test_bitmap_font_glyph_index();
+ test_GetCharWidthI();
/* These tests should be last test until RemoveFontResource
* is properly implemented.
Modified: trunk/rostests/winetests/gdi32/wine_test.sfd
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/gdi32/wine_test…
==============================================================================
--- trunk/rostests/winetests/gdi32/wine_test.sfd [iso-8859-1] (original)
+++ trunk/rostests/winetests/gdi32/wine_test.sfd [iso-8859-1] Sun Jun 4 01:50:46 2017
@@ -15,7 +15,7 @@
Layer: 0 1 "Back" 1
Layer: 1 1 "Fore" 0
XUID: [1021 905 592216984 1247726]
-FSType: 0
+FSType: 32767
OS2Version: 2
OS2_WeightWidthSlopeOnly: 0
OS2_UseTypoMetrics: 1
Modified: trunk/rostests/winetests/gdi32/wine_test.ttf
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/gdi32/wine_test…
==============================================================================
Binary files - no diff available.