Process Plan: Color picker to derive a specific color

This Process Plan can be used to derive a color at the specified area and place a color swatch:

Erliest version with full support for “Determine color and place patch.kfpx” is pdfToolbox 15

1. Determine color at picker

To determine the average color of a custom area, the "Effective ink coverage for separated plate" Check property is used in combination with the "Effective ink coverage – limit to custom area" Check property to limit the color detection to a custom area. The Check uses variables, so that the position and size of the color swatch can be defined in the Ask-at-runtime dialog that appears when the Process Plan is executed.

In the trigger value the Check returns the color values for all color separations (process and spot colors) in percent (example: "Black: 31.7922, 0.28; Cyan: 30.5014, 0.28; Magenta: 94.5429, 0.28; Yellow: 79.59, 0.28").

2. Variable step

To use the color values for further processing, they have to be extracted from the string. This is done in a variable step using JavaScript: The string is split into segments, each representing a separation name with its corresponding ink coverage percentage. As a result, the extracted color data is stored in a JavaScript object, where each separation name is associated with its respective ink coverage percentage. The area highlighted in yellow in the screenshot below shows the evaluation result.

3. Place swatch

This Fixup step places a square color patch with the determined color values of the JavaScript object on top of the PDF page. This step is optional and is only used for demonstration purposes to visualize where the color was determined and what the color looks like.


The color swatch does not take spot colors into account. However, the spot color values in the respective area are available in the JavaScript object.

This Process Plan can only determine a color on one page. It is not designed to determine colors on multiple pages.