Trouble with non-square button appearances

Community Beginner ,
May 06, 2022 May 06, 2022

Copy link to clipboard

Copied

I have check boxes with unusual shapes, such as hexagons, that should fill when selected and clear when deselected. While building a PDF in InDesign, the Buttons and Forms panel appears to allow me to do this, and toggling the states works as expected.

Tintenseher_0-1651851928941.png

The hex shape appears to hold when viewing the EPUB Interactivity Preview, though it doesn't appear to be actually interactive; I assume I'm misunderstanding the preview feature.

Tintenseher_1-1651852018372.png

However, upon exporting an interactive PDF and viewing it with Acrobat, the hexagonal check box is overlaid with an ugly square check box with a literal check, which I specifically deleted when it was automatically created in InDesign. Interacting with the check box shows that the hexagon is still in use, it's just incorrectly encapsulated by the box. It only appears "correctly", as shown in the third image below, after clicking but before rolling off. As soon as the mouse leaves the bounding square, it returns to the normal square check box. The second image shows rollover without clicking.

Tintenseher_5-1651852221584.pngTintenseher_6-1651852234543.pngTintenseher_7-1651852263665.png

I thought maybe I could fix this with the Prepare Form tool by removing the check box's border in the Appearance tab, but doing so somehow removes the border of the check box and both the border and fills of the hexagon, leaving me only with an annoying check mark that I didn't ask for. (I'm aware I can change the style of the check box, but I want it to conform to the style I already created in InDesign.)

Tintenseher_10-1651852810441.pngTintenseher_11-1651852830767.png

However, when I open the PDF in a browser, it creates a more appealing but still not 100% intended translucent bounding box. Interacting with the hex here correctly fills it without creating the check mark, however, and the dotted outline that appears after doing so disappears after clicking off. This is not perfect but it is acceptable to me, as the hexagonal button at least displays and fills correctly, without visual interference. 

Tintenseher_8-1651852563995.pngTintenseher_9-1651852575838.png

All of the help and instructional articles I've seen instruct me on how to create custom buttons with InDesign and the Prepare Form tool in Acrobat, but do not cover this issue. Is there a way I can ensure that this browser-based behavior, or preferably an improved behavior (where the bounding box is limited to the shape of the hexagon itself), is replicated by the PDF when opened in Acrobat? I can't deliver the PDF in its current state with the unwanted checkboxes.

TOPICS
Create PDFs , General troubleshooting , How to , PDF forms

Views

303

Likes

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
Adobe Community Professional ,
May 06, 2022 May 06, 2022

Copy link to clipboard

Copied

All Acrobat form fields are square and have a set appearance.  Checkboxes and radio buttons offer a limited number of alternative appearances. It is futile to try to override any of these existing appearance parameters because they will just be overwritten the next time Acrobat decides to reset the appearance.  I'm surprised that InDesign doesn't a better conversion since they are offering alternatives that are way outside the functionality of Acrobat. 

 

That said, there are ways to create non-square appearance. The simplest is to remove the border and select a non-check option for the checked appearance. Then you can create whatever background you want. Another way is to use a button field instead of a checkbox. Buttons are capable of displaying any kind image you want. Doing this requires a script to change images to create the "checked' appearance and maintain the button state.  Unfortunately this method will not work when the PDF is opened in a PDF viewer that doesn't support scripting. 

 

 

 

Thom Parker - Software Developer at PDFScripting
Use the Acrobat JavaScript Reference early and often

Likes

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 Beginner ,
May 06, 2022 May 06, 2022

Copy link to clipboard

Copied

 

Thank you for the response!

 

That said, there are ways to create non-square appearance. The simplest is to remove the border and select a non-check option for the checked appearance. Then you can create whatever background you want.

 

I think I understand what you mean by this, and it would solve my problem, but just to be certain, what method are you thinking of when you say "create whatever background you want"?

 

I believe I understand that I could leave the hexagon as a non-interactive shape in the background, with a borderless button on top of it set to whatever fill I want, so that it would appear to fill the hexagon when it's really just centered on it. Is that correct, or is there a simpler way of creating the background you're referring to?

Likes

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
Adobe Community Professional ,
May 06, 2022 May 06, 2022

Copy link to clipboard

Copied

You got it!  

Thom Parker - Software Developer at PDFScripting
Use the Acrobat JavaScript Reference early and often

Likes

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 Beginner ,
May 06, 2022 May 06, 2022

Copy link to clipboard

Copied

Got it, thank you for the workaround!

Likes

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
Adobe Community Professional ,
May 09, 2022 May 09, 2022

Copy link to clipboard

Copied

Thom Parker:

Here are the examples of buttons and form fields proposed by InDesign. You can also modify them or make custom creations.

But in InDesign there is no warning that most them are not compatible with the PDF format, it is up to the users to guess or to find out.

 

Capture_393.png

 

Likes

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
Adobe Community Professional ,
May 09, 2022 May 09, 2022

Copy link to clipboard

Copied

They are just asking for unhappy customers.  You have to wonder why they do it. 

 

Thom Parker - Software Developer at PDFScripting
Use the Acrobat JavaScript Reference early and often

Likes

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
Adobe Community Professional ,
May 10, 2022 May 10, 2022

Copy link to clipboard

Copied

LATEST

They were designed for SWF and ePUB exports.

Likes

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