I started working with the new version of Eggplant vrsion 3.0. but facing problem with its new feature of text recognition.
While caputuring text image, we need to give the details like the text font, size, text color. Is there any way that the eggplant by itself can recognize the text type and its details??? Because itâs difficult to identify the text details like its exact size and style
We recognize that it can be difficult to determine the exact font and size being used by different elements in the interface. We have supplied the attributes for a few commonly-used styles in the predefined text styles for the Mac and Windows platforms to help you get started.
As you discover the correct attributes for other interface elements, we would encourage you to post that information here on the forum for other users to benefit from. We intend to add more predefined styles in future releases of Eggplant to make this easier.
One approach that may help you discover the correct attributes is to capture an ordinary image of the text you want to match (using âCapture Imageâ from the Remote Screen toolbar) and select that image in the Images tab of the Suite so you can see it on screen.
Next, open the Text Image Sheet (by clicking the Text Image button on the Remote Screen toolbar). Then, with the Text Image Preview section open in the sheet, enter the text in the Text String field, and then try various fonts and sizes while visually comparing the generated preview image to the one you previously captured. Itâs a bit of a hit-and-miss approach, but may be helpful if you already have a pretty good idea of which font it is.
A more systematic approach is to write a script that loops through all of the possible fonts, sizes, etc. for a given text string and looks for the generated image of each on the screen. We will post a sample script in the Examples forum soon to show how this can be done.
If your system under test is a Windows platform, you might want to consider ScreenOCR. ScreenOCR is a convenient way of getting the text font and size for Windows system fonts.
Hi,
ScreenOCR tool helped me to find out the exact font and size of the text in the Windows platform.
While capturing the text images from remote Windows, which of the 1 among 2 options - âMacOSX_10.4â and âWindowsClassicâ is to be selected in âPlatformâ combo :?:
I tried selecting âWindowsClassicâ option, but following error is generated :
"Error Generating Text Image â Unable to write Image Info to Text Image Generator :5899 "
Also, an error is generated for some fonts like Tahoma when iâm trying to use âMacOSX_10.4â option in platform, as these fonts are missing from the âFontâ field
The platform for text images is determined by what OS your system under test is running. For example, creating text images for the windows platform will require the selection of WindowsClassic.
As for your communication error with the Windows Text Image Generator, are you running the Text Image Generator on your Windows machine? If not, download the executable here:
Also, an error is generated for some fonts like Tahoma when iâm trying to use âMacOSX_10.4â option in platform, as these fonts are missing from the âFontâ field
What error message are you getting? The âTahomaâ font should be available for MacOSX_10.4.
I downloaded the Text Image Generator âWindows TIGâ on my Windows machine. But need to install one of the versions of the .Net Framework:v2.0.50727 to run this application on Windows.
On selecting âMacOSX_10.4â option in platform, iâm getting the following error:
âError generating Text Image â Unable to find font Tahoma of size 8.
Close Image Preview to save command anyhow.â
On closing the Image Preview, the âSaveâ button is enabled. After clicking Save button it displays following error:
âUnable to Generate Text Image.â
And gives the option to âDonât Insertâ and âInsert Command in Scriptâ. After inserting the command in the script, the script fails giving the same error:
âUnable to Generate Text Image.
Unable to find font Tahoma of size 8.â
Actually the âTahomaâ font is not present in the font combo itself. And many other fonts are missing in the combo. So gives error while we type the missing font names in the field. How can the font field be upgraded for other missing fonts :?:
Or is there any other way out to resolve this error :!:
If the Tahoma font is not listed as one of the available fonts for the MacOSX_10.4 platform then it means that you do not have that font installed on your Eggplant system. When generating fonts for any system you need to have that font installed.
The windows fonts are different however, in that any font available on your Windows system will not be displayed in the list of fonts on Eggplantâs side. Currently, as of Eggplant v3.01, the list of fonts only reflect the fonts that you have installed on your Eggplant system. You should be able to generate text using fonts installed on your Windows system by typing those fonts in.
Most of the time you shouldnât need to select a font directly from the font list. Instead, you can define a text style on the Text pane of the Preferences panel, and then simply use that style which will set all of the needed text attributes at once.
Having said that, to use generated text images effectively (no matter how you select the text attributes) you will need to have a live connection to a text image generator (TIG) for the platform you are scripting against. If the SUT is a Mac, you will use the MacOSX_10.4 TIG that is built into Eggplant. If the SUT is a Windows machine, your Text Platform should be set to WindowsClassic and you will need to have a Windows machine on your network that is running the Windows TIG.
is the connection to the WindowsTIG necessary at buildtime and runtime? Is it possible to generate Textimages without the TIG installed?
I ask this, because one of the main advantages of Eggplant is, that you do not need to install other components than a VNC-Server on the machine under test.
A necessary TIG on the machine under test would be a big disadvantage from my point of view. In this case I would prefer a text recognition feature, scanning the VNC-picture instead of text image creationâŚ
If you are driving a Windows based SUT then in order to use the Text Image Generation feature for Windows you do need access to a machine running the Windows TIG; however that machine does NOT need to be the same as the SUT machine, just a machine that will render text in the same way.
For Macintosh there is an embedded TIG within Eggplant so you wonât need anything (besides OSXvnc) installed on the SUT.
Regardless of SUT you can also continue to use the same image capture and compare techniques that are the basis of Eggplant scripts.
At this time we donât have a LINUX TIG so you would need to create a script based Text Image Generator to get Linux Images. Please See these for more information.
[list]Eggplant Reference->Eggplant Commands->CaptureTextImage
Using Eggplant->Images & Image Searching->Text Image Generators [/list:u]
However, we designed the TIG protocol to be simple enough that we can write additional ones or provide clear details on how exactly to produce a TIG for another operating system. If anyone would like to work with us to create a TIG for a new operating system (or other font rendering environment) please contact us at support@redstonesoftware.com.