Skip to main content
Inspiring
August 24, 2020
Answered

Problem with role mapping paragraph styles to tags, from InDesign to PDF.

  • August 24, 2020
  • 6 replies
  • 7669 views

I am using InDesign 15.1.1 to create several accessible, tagged PDFs.

 

I have tagged every paragraph style correctly under the export tags for PDF (Edit all export tags > show: PDF), and I have left any list items and table of contents items with the default ‘Automatic’ tag.

 

I am exporting as an interactive PDF with ‘Create tagged PDF’ checked. 

 

Then when viewing the PDF in Acrobat Pro DC, in the Tags pane I have selected ‘Apply role mapping to tags’. This should ensure that in the tags pane in Acrobat, all my original paragraph style names are displaying as the tags that I have created. But this is not happening. I am finding that some of the tags are role mapping correctly, while several other tags are appearing incorrectly role-mapped with their original paragraph style names in place instead of the tags that I had assigned to them in InDesign.

 

There seems to be no logic to this. Why have some of my paragraph styles been role mapped correctly as per the tags I have created in InDesign and yet some styles have not? I am having to fix the role mapping, tag by tag in Acrobat which is a tortuous waste of time.

 

Is there a bug that can be causing this? I really need a solution as I have some very large documents to create as accessible PDFs.

    This topic has been closed for replies.
    Correct answer GreenRoof

    Yes, confirming that long InDesign style names often cause conflicts during Acrobat's role mapping.

    Although the style name becomes the "custom tag" in Acrobat (the long tag names that are similar to our InDesign style names), they are truncated by the PDF Export / Acrobat utilities. So long InDesign names can become wierdly named or overriden in Acrobat tags.

     

    Easy solution: as you mentioned, write shorter names for your InDesign paragraph styles. Why not use some shorthand:

    P = body text

    B = bold

     

    Your 'Body copy front section accounts - italic' can become 'P front sec accts - I'.

     

    Added benefit: by starting a style's name with the intended final tag, it's easy to check and correct the role mapping in Acrobat.

     


    Thanks for the affirmation Bevi.

     

    Yes, I have discovered that when InDesign paragraph style names are long, and begin with the same wording then they can get confused during PDF export. During PDF export only the initial few characters of the style name are used by the software to specify the role mapping, meaning anything that you have placed at the end of a long name to differentiate it from other similarly worded styles may get lost, thereby confusing one style with another. This can either result in incorrect role mapping (i.e the wrong tag being applied) or no role mapping (i.e. the paragraph style name appears in the tags panel instead of the tag specified in InDesign.

     

    If possible, can you vote this as the correct answer for the benefit of others? Then hopefully it won't take them ages to work it out for themselves as I had too! 🙂 Many thanks.

     

    Thanks for the shorthand tips.

     

     

    6 replies

    Iain McLeod
    Participant
    December 18, 2022

    I may have found a workaround. 

     

    I have a long document with quite prescriptive tagging, all mapped through the Paragraph Style's Export Tagging and verified through "Edit all Export Tags" – but several styles refuse to tag/role-map properly in an interactive PDF (they are completely missing in the PDF's role map). I've tried a long list of things to fix it, most of which are covered in this thread, but the only thing that works is to:

     

    – create a text frame on the first page that just overlaps the page bounds (so that it doesn't appear on the page but does get included in the tag structure)

    – add some sample text and style it with the paragraph styles that go missing (probably better practice to include every style)

    – export and check

    – delete the dummy text's "<Sect>" tag so that it isn't read by assistive technology

    – save.

     

    I only discovered this as I got tired of trying to manually find the styles in Acrobat, the first of which appears 46+ pages into this document, with no way to search in the Tags panel. 

     

    It looks very much like the export to interactive PDF function gives up on building the role map after a number of pages have been exported... this might also explain why some users can get results when exporting a subset of pages.

    Inspiring
    May 22, 2021

    I was having this issue as well!!!! I'm not sure what ended up fixing it but I did the following:

    - I made sure I didn't have any skipped Headings (ie: no H1 then H3 right after it)

    - I condensed my Paragraph Styles (used more character styles for bold or colour changes instead of having a paragraph style for it) and deleted the paragraph styles I wasn't using

    I think the following was what fixed it:

    - I went into the Tags panel and selected "Map Styles to Tags" and then I basically matched all the styles to tags (like you can in the "Edit all Export Tags" in the Paragraph Styles box.

     

    I'm not sure why this happened, it has never happened before and I have done many accessible documents in InDesign/exported to PDF. I may have clicked "Map Tags to Styles" by mistake? I have no idea - but it's fixed now thank goodness!

    Inspiring
    May 22, 2021

    Also... I made sure that the Paragraph Styles weren't "Based on" any other styles

    GreenRoofAuthor
    Inspiring
    May 24, 2021

    Hi Katie,

     

    Many thanks for your input. What you're saying is interesting.

     

    I don't think having a paragraph style based on another creates any issues. But I do agree that keeping the list of paragraph styles simple does make a difference. It seems that InDesign cannot cope with a long list of paragraph styles – it can only role map the first few styles in the list and then it seems to run out of memory or get confused for the rest.

     

    Last year I did an experiment with a complicated large document, which had a very long list of paragraph styles – I changed every para style name to a simple two- or three-word name such as Cat, Pop, XY, AB, Dog. And when I exported the interactive PDF all the styles were role-mapped correctly! Clearly it's not practical to have such ridiculous style names, so since then I have made sure I keep list of the paragraph styles shorter, simple and with names which are not similar to each other, and then use character styles more to define nuances. 

     

    I'm interested in what you're saying about 'Map styles to tags'. I've looked at this and don't understand how to set it up. Can you advise?

     

     

     

    tobiasw63582802
    Participant
    March 29, 2021

    I do have this problem as well every now and then. I assume that it is caused by other problems in the tagging structure, for instance broken references or the like. Often when I resolve other issues indicated by the PAC3-test, these issues with the role assignment vanish.

    GreenRoofAuthor
    Inspiring
    September 6, 2020

    This has been voted as fixed, but to date the issue is not fixed. 

     

    I did report the issue at InDesign UserVoice as a possible bug, but so far I’ve had no response from developers to that post, and no indication of the timescale for fixing it. 

     

    In the meantime I’m still experiencing instability when exporting a tagged PDF from InDesign, with large parts of the document not role mapping correctly. I am having to workaround the problem by exporting my InDesign documents in sections and then stitch them together in Acrobat. 

     

    Some indication that Adobe are looking into this would be reassuring. 

    bchampagne
    Participant
    January 21, 2021

    Helo. I am having this exact issues. My paragraph styles are all tagged. When looking in the tagged panel in PDF, all is fine, but one you go into the properties of that tag is takes on the style name and accessibility assist programs read the style name. HELP!!!

    Community Expert
    August 25, 2020

    Hi GreenRoof,

    can you see a mutual characteristic in the paragraph styles where this does not work?

    Perhaps the styles are based on others or something like that.

     

    You said:

    "…if I export just a few pages at a time then the role mapping is working correctly. The problem seems to occur when I export the full document …"

     

    Yes, this sounds very much like a bug. You can report it at InDesign UserVoice:

    https://indesign.uservoice.com/forums/601180-adobe-indesign-bugs

     

    When done please come back here and share the URL for the report so that others can vote for fixing the issue.

     

    Thanks,
    Uwe Laubender

    ( ACP )

    GreenRoofAuthor
    Inspiring
    August 25, 2020

    Hi Uwe,

     

    Thanks very much for your feedback.

     

    I did already look for mutual characteristics, such as styles based on other styles, but there does not seem to be a common characteristic. Some of the paragraph styles which are based on other styles are role mapping correctly, while others are not, so I don't think that is the reason. The only common characteristic I can see is that the deeper you get into the brochure, i.e. where more paragraph styles come into play, the more the tags start to lose their role mapping. It is very odd, and there is no rhyme or reason to it. It is as if InDesign just cannot cope with processing the entire document properly, it just wimps out, which is pretty useless.

     

    It is very frustrating after I've set up all the tags in InDesign to later find I need to manually fix them one-by-one in Acrobat.

     

    Thanks for the link to user voice, I will report this as a bug. It is certainly bugging me! I will update here as per your suggestion.

     

    GreenRoofAuthor
    Inspiring
    August 25, 2020
    GreenRoofAuthor
    Inspiring
    August 25, 2020

    Update: this role mapping problem is occurring on every document I export as a tagged interactive PDF, no matter the size (i.e. from a small 12pp booklet to a large 125pp brochure). The first few pages of my exported document start off fine, with all the tags role mapped correctly in Acrobat, but then as the document progresses some of the tags start to break down with their tags not appearing and instead their original paragraph style names are displayed. I have tried exporting the PDF from my another Mac and I get the same result.

    Today I have discovered something interesting: if I export just a few pages at a time then the role mapping is working correctly. The problem seems to occur when I export the full document – InDesign does not seem to be able to handle all the information correctly en masse.

    Is this a known issue? Does anyone have a solution?