Forum Discussion

jazeckel's avatar
jazeckel
Occasional Contributor
15 years ago

screenshots between OS's

This question is not specific to TestComplete, but I thought someone on here might know.  Our application has a WPF user interface.  We have been running TestComplete on Windows XP and Windows Vista, and we have a large number of reference screenshots that are used as region checkpoints.  In order to make XP and Vista match across all our hardware, I had to disable all forms of antialiasing, including adding registry keys to disable WPF antialiasing and turning off hardware antialiasing through the display driver.



Today I got a Windows 7 machine to set up as another test machine.  Despite turning off ClearType, grayscale antialiasing, all the display driver options, and WPF antialiasing in the registry, my screenshots do not match under Windows 7.  By looking at the image diffs I am 100% sure the difference is antialising, as it is only rendered text that is mismatched.  Does anyone have any ideas?

3 Replies

  • jazeckel's avatar
    jazeckel
    Occasional Contributor
    A related question is, what method does TestComplete use to capture screenshots?  I had some other issues recently with TC capturing PNG's when I was expecting BMP's, or capturing in different color depths, and I couldn't find the settings to configure the capture settings anywhere.

  • Hi Jessica,





    As far as I know, WPF has its own mechanism of drawing text. Probably, this depends on the version of the .NET Framework installed on a machine. What do you use image comparison for? Probably, using other ways to validate data (e.g. Object or Property checkpoints) will work better for you.





    A related question is, what method does TestComplete use to capture screenshots?


    You can use the SaveToFile method of the Picture object. Please find more information in the Picture.SaveToFile help topic.
  • jazeckel's avatar
    jazeckel
    Occasional Contributor
    I worked through the antialiasing issues and got them to match.  In case anyone else is having the same problem, you can see the solution on my MSDN thread about it here.



    I will ask my question about the stores images in a different thread since I don't think it's really related to this one.  Thanks!