Eggplant Functional Text Preferences
These settings define the text platforms that are available for use in text property lists. Each platform includes a Text Engine, and any number of predefined text styles. Click Advanced Platform Options to select the languages you want made available to Eggplant Functional for use in OCR searches. {#text-preferences}
Text Properties Panel Overview
Text Style
A text style is a saved set of text properties as defined in the Eggplant Functional Text Preferences, OCR Tuner, or OCR Update panel. Each text style is typically tailored to a particular font or type of GUI element, such as a menu item or title bar that will be encountered repeatedly in an application under test. Text styles can be applied to both OCR searches and ReadText()
. For more on the difference between reading and searching, see How to Use OCR.
The panel opens with the Default style selected. Once you modify the OCR Properties in the sections below this one, you have altered the current style. To save this new style, select the word "Default" in the Text Style drop-down menu and change the name, or select the style you want to override (the Default style can be modified). Click Save Style.
To delete the current selected style, click Delete Style. This option is disabled when the Default style is selected.
To the right of this section is the copy icon. This can be used to copy the current text properties as you have them set in the following sections for use in your script. For more on this see Save or Copy Property Settings.
Contrast Section
The Contrast section allows you to set and work with the Contrast
property and related properties. The Contrast
setting converts the image OCR takes of the system under test (SUT) to black and white before sending it to the OCR engine for recognition. This interactive section has a live-update area to the right that shows the current search rectangle as it is drawn in your Viewer window, and how it will be sent to the OCR engine with the current Contrast
settings.
-
Contrast: Whether or not the SUT display is converted to a high contrast two-color image before it is sent to OCR for analysis. If
contrast
is on, a color referred to as the "contrast color" (which can be set using theContrastColor
property) is considered the primary color of the SUT display, and all other colors are treated as the secondary color. Text can be found in either color. TheContrast
property is available for use with both searching for (finding) text and reading text.- Contrast Color: If
Contrast
is on, the contrast color is considered the primary color of the SUT display, and all other colors are treated as the secondary color. For instructions on finding the background color, see Determining the Background Color. - Contrast Tolerance: When
Contrast
is on,contrastTolerance
sets the maximum per-channel color difference that is allowed for a pixel to be seen as the contrast color.
- Contrast Color: If