Having a curious problem with the TIG. Mac OSX 10.5.
Eggplant 401, most current Vine. This issue is happening on Mac.
If I Look for the Tools menu of my application, TIG will not find it. If I shorten it to “Too” it finds it.
The strange thing about it is that it works for other scripters that I’m working with.
Any ideas on how to make this work without shortening the string?
My apologies if you’ve already done this.
Make sure that your “Font Smoothing” (System Preferences-> Appearance) setting is the same on your Eggplant machine and your SUT, we recommend always using “Standard”.
Unfortunately, on 10.5 the menu bar has a transparent background, so it’s impacted by whatever your desktop background setting is.
If you want to turn that bar to plain white you can issue this command and restart your Mac
sudo defaults write /System/Library/LaunchDaemons/com.apple.WindowServer 'EnvironmentVariables' -dict 'CI_NO_BACKGROUND_IMAGE' 1
No apologies necessary!
I’ll check the font smoothing setting, but it may matter that my SUT is running 10.4 and my Script machine is running 10.5
It appears that, at least in OSX 10.5.5, in System Preferences->Desktop & Screen Saver->Desktop, there is a check box for “Translucent Menu Bar”. Unchecking this option appears to make the menu non-translucent.
However, I am still seeing problems similar to the original post here. For instance, if I have Safari open on my SUT (Mac 10.5.5 with non-translucent menu bar), I am able to find the text of all the menu bar headings except for “Bookmarks”. My script:
if ImageFound(5, (Text:"Bookmarks", TextStyle:"Menu"))
LogError "Text for Bookmarks menu not found."
does not find the Bookmarks text image.
I also have a related question. I would like to have a text style for menu items on Mac – the menu bar can be set to non-translucent, but the menus themselves are still translucent, so the background color of the menu item text is different depending on whether there are windows behind the menu or just the desktop background. Is there a good way to get around this translucent menus problem?
That setting was a godsend when I first noticed it.
As for the translucent menus, I’ve not been having too much trouble clicking on menu items. Background color is #F0F0F0, Text Color is #000000, Font: LucidaGrande, Size:14.
This has been working great.
The color tolerance of Eggplant’s Tolerant search type was originally designed specifically to deal with the translucence of menus (although it has proven to be useful in other situations as well, hence its use as the default search type). With the background color and tolerance set appropriately, you should be able to match items in translucent menus without any trouble.
Since we’re discussing TIG images here, I’ll mention that generated text images use the Text search type which automatically calculates the tolerance based on the contrast in the image. For a menu item with black text on a nearly-white background, this calculated tolerance is even greater than the normal default tolerance, so again the translucence of the menu shouldn’t be causing a problem.
If you’re having trouble matching a menu item it is more likely to be due to a text rendering issue. If you are running Eggplant on a different version of Mac OS X from what the SUT is running, or don’t have the font smoothing options set the same on both machines that is a more likely source of incompatibility.