Defining Regions

Different parts of the screen can have specific requirements. For example, you might want to ignore the space where an ad banner is displayed on all screens that include the banner. You can apply annotation regions to control how the matching mechanism handles a particular region.

In the Test editor or Step editor, you can define a region using one of the following methods:

  • Element-based – (recommended) A dynamic region based on a web element, such as a frame, image, text box, or video. When you click on an object on the screen, Eyes automatically identifies the screen element. This method is recommended because Eyes can recognize the element even if its exact location on the screen changes. This method requires useDOM to be enabled.

  • Drawn – A region based on coordinates on the screen. This is useful if you want to define a fixed area that is not linked to a single element or create a region around multiple elements.

You can add padding around a region. For example, if an element includes a border or shadow, you may want to add several pixels on each side to apply the region settings to the border or shadow.

You can automatically convert drawn elements to linked element-based regions. For details, see Updating Drawn Regions to Element-Based Regions.

Match Types

You can set a region to use any of the following match types:

  • Ignore – Do not report any mismatches in the region.

    If you set an Ignore region that covers the entire width of the image, it splits the image horizontally. For example, if the center of the screen contains dynamic content, but you only need to compare the header and footer, draw an Ignore region around the center. This splits the screen into three parts: the header, the footer, and the ignored dynamic content in the middle, even if the height of the Ignore region changes.

  • Floating – Allow the region's position to move without reporting a mismatch.

  • Strict – Detect any mismatch visible to the human eye.

  • Dynamic – Allow text changes that conform to a defined pattern, such as date format or email address. For details, see Dynamic match level.

  • Ignore colors – Allow color changes. For example, this is useful if the screen sometimes appears in dark mode.

  • Layout – Check only the layout and ignore text and graphics.

    For more information on the available match levels, see Match levels.

Defining a Region

To define a region

  1. In the Test editor or Step editor, click and select one of the following:

    • Select element – Identifies a region based on the HTML element. This is recommended because Eyes can recognize the element even if its location on the screen moves. When selecting an element, the pointer highlights the element as you move it over the image. Click to select the highlighted element.

    • Draw Region – Identifies a region based on the location on the screen. Drag and drop a box to create a drawn region.

    The Region settings window opens.

  2. Select the match type for the region. If you select the Dynamic match type, you can select patterns dynamic patterns to apply. For details, see Dynamic match level.

  3. To convert the region from an element-based region to a drawn region or vice-versa, click or

  4. If required, add padding to the region. This applies the match level to the space around the region. For example, if an element has a shadow, you may want to add padding to include it.

  5. To apply the region to other similar screens, for example a logo or banner that appears on multiple screens, select Apply to other steps. For more information see Adding, modifying, or deleting regions of a step.

Updating Drawn Regions to Element-Based Regions

You can automatically update all drawn regions in a test to dynamic element-based regions. This improves results as the region's definition links to the element, allowing Eyes to recognize it even if the size or position changes. The option to update regions to element-based regions is available in several places in the system:

To update a single region:

  • In the Step editor or Test editor, click on a drawn region and in the Region settings window, click

To update all regions on a screen:

  • In the Step editor or Test editor, click > Convert drawn regions to element-based regions.

To update all regions in a test:

  • In the Test Results page, next to a test, click > Convert drawn regions to element-based regions.

To update all regions in a batch:

  • In the Test Results page, in the list of batches on the left, next to a batch , click > Convert drawn regions to element-based regions.

Copying Regions

You can copy a region with the same match level and padding settings.

  • In the Step editor or Test editor, click on a region and in the Region settings window, click .

  • Click to close the Region settings window.

  • Click on a different location on the image, and in the Set region dropdown list, select Paste region.

Deleting Regions

To delete a region:

  • In the Step editor or Test editor, click on a region and in the Region settings window, click .