• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

JavaScript for Acrobat API - Color conversion, Matching criteria, set Object Type to 'Image'

New Here ,
Jul 02, 2024 Jul 02, 2024

Copy link to clipboard

Copied

Hello community,

I want to embed a colour profile in a PDF file using Javascript.
This works well with the following script:

 

var toColorProfile = this.getColorConvertAction();
toColorProfile.matchAttributesAny = -1;
toColorProfile.matchAttributesAll = -1;
toColorProfile.matchSpaceTypeAny = -1
toColorProfile.matchIntent = toColorProfile.constants.renderingIntents.Any;
toColorProfile.convertProfile = 'PSO Coated v3';
toColorProfile.convertIntent = toColorProfile.constants.renderingIntents.Any;
toColorProfile.embed = true;
toColorProfile.action = toColorProfile.constants.actions.Convert;
toColorProfile.colorConvertAction = toColorProfile.constants.actions.Convert;
this.colorConvertPage(0, [toColorProfile], []);

 

 

But what i want to achieve is, that only the images are converted to the given colour profile and all other elements in the PDF are retained. In other words: i want to embed the colour profile with the settings shown in the screenshot, but with JavaScript.
So my question is: how do I have to adapt my script, that the colour profile only changes the images in the PDF and leaves all other elements as they are?

Views

56

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 02, 2024 Jul 02, 2024

Copy link to clipboard

Copied

LATEST

in the future, to find the best place to post your message, use the list here, https://community.adobe.com/

p.s. i don't think the adobe website, and forums in particular, are easy to navigate, so don't spend a lot of time searching that forum list. do your best and we'll move the post (like this one has already been moved) if it helps you get responses.



<"moved from using the community">

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources