Found_Image
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| Found_Image [2019/07/08 04:35] – [Search in Specified Area] peternlewis | Found_Image [2024/10/12 09:23] (current) – [Specifying Fields in Found Image Actions] peternlewis | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | {{: | ||
| ====== Found Image ====== | ====== Found Image ====== | ||
| - | Although it is generally better to use high level actions like Press Button or Resize Window, it is sometimes necessary to resort to looking at the screen for a specific image and responding appropriately (behaving differently if it exists, clicking on it, moving things to it, etc). | + | Although it is generally better to use high level actions like [[action: |
| There are various actions ([[action: | There are various actions ([[action: | ||
| - | **Example: Click on Found Image**\\ | + | ===== Example Click on Found Image ===== |
| - | This is how the Action appears when first inserted into your macro.{{: | + | |
| + | This is how the Action appears when first inserted into your macro. | ||
| + | {{ action: | ||
| ===== How To Use ===== | ===== How To Use ===== | ||
| + | |||
| ==== Specifying Fields in Found Image Actions ==== | ==== Specifying Fields in Found Image Actions ==== | ||
| Line 19: | Line 20: | ||
| * To view the image in the image well, click on it and press < | * To view the image in the image well, click on it and press < | ||
| * You can copy the image from the Image Well. | * You can copy the image from the Image Well. | ||
| + | * Alternatively, | ||
| - **Specify the amount of fuzziness allowed** | - **Specify the amount of fuzziness allowed** | ||
| * Because of transparency and anti-aliasing almost all screen matches are fuzzy to some degree. | * Because of transparency and anti-aliasing almost all screen matches are fuzzy to some degree. | ||
| * But usually about 20% is a good place to start. | * But usually about 20% is a good place to start. | ||
| - | - **//Must be Unique// | + | - **// |
| - | * If //checked//, then the image must be the only image in the specified area, or the // | + | * By default, the image must be unique on the screen so that Keyboard Maestro knows where to click, otherwise |
| - | * If //not checked//, then best one of the images | + | * Alternatively, you can have Keyboard Maestro click based on the best match, or (v9.0+) click on the topmost, leftmost, bottommost, or rightmost match. |
| - **// | - **// | ||
| * This can be helpful in debugging, like determining the right amount of fuzz to use. | * This can be helpful in debugging, like determining the right amount of fuzz to use. | ||
| * It will also show when an image is being found in more than one location. | * It will also show when an image is being found in more than one location. | ||
| - **Choose Where to Search for Image** | - **Choose Where to Search for Image** | ||
| - | * All screens. | + | * You can search in all screens, or on a specific |
| - | * Main screen. | + | * Alternatively, |
| - | * Specified screen (counting from the left). | + | * However, the window |
| - | * Front window. | + | * Or you can search within a specific |
| - | * Window with a specified title. | + | |
| - | * Window with a title containing a given string. | + | |
| - | * Window with a title matching a given regular expression. | + | |
| - | * Specified | + | |
| - | * Specified | + | |
| * For instructions on how to get data for area, see [Determine Location of Area to Search for Found Image](https:// | * For instructions on how to get data for area, see [Determine Location of Area to Search for Found Image](https:// | ||
| Line 48: | Line 45: | ||
| {{ action: | {{ action: | ||
| + | |||
| + | Note that in the above screen shot, the `WINDOW(0, | ||
| ===== Search Speed and Accuracy ===== | ===== Search Speed and Accuracy ===== | ||
| Line 53: | Line 52: | ||
| Keyboard Maestro uses a relatively fast search to make the action perform in a reasonable amount of time, but it can result in not finding some images. | Keyboard Maestro uses a relatively fast search to make the action perform in a reasonable amount of time, but it can result in not finding some images. | ||
| * Images Difficult to Match | * Images Difficult to Match | ||
| - | * The most difficult images to match are small grey images (like icons or text). | + | * The most difficult images to match are small grey images (like grey icons or text). |
| * Since the screen tends to be filled with small grey areas, it is hard for Keyboard Maestro to find the best locations to look. | * Since the screen tends to be filled with small grey areas, it is hard for Keyboard Maestro to find the best locations to look. | ||
| * Increasing Search Accuracy | * Increasing Search Accuracy | ||
| - | * Set Search Area to less than a quarter of the whole desktop | + | * Set Search Area to less than a quarter of the whole desktop. |
| - | * This will improve ability to find smaller images that have low contrast | + | * This will improve ability to find smaller images that have low contrast. |
| ===== Testing ===== | ===== Testing ===== | ||
| Line 63: | Line 62: | ||
| When testing found image macros: | When testing found image macros: | ||
| - | * ALWAYS hide the Keyboard Maestro editor | + | * Hide the action or the Keyboard Maestro editor as the image within |
| - | * ALWAYS turn ON the “Display” checkmark, so you get visual confirmation an image has been found. | + | * Turn on the “Display” checkmark, so you get visual confirmation an image has been found. |
| - | * If the image is NOT found ALWAYS | + | * If the image is not found, play with the fuzz slider. |
| - | * It's generally a good idea to initially test on the main monitor in the front window. | + | |
Found_Image.1562560532.txt.gz · Last modified: by peternlewis
