19 Replies Latest reply on Jul 31, 2016 3:14 AM by Peter Spier

    Hyphenation bug

    NIRC Level 1

      I have found what looks to be a bug in the InDesign hyphenation function. I first noticed it in CS6, but it has carried over to CC.

      The problem is when you have a hyphenated term where half the term is set in a different typeface. In my case, the word is

      prajña-wisdom

      where the first half is italic and the last half normal. The line will NEVER break at the hyphen, and the only choice is to put a space after the hyphen or a soft-line return, neither of which is a very good idea because of the possibility of a text reflow with later changes. (The same holds, by the way, if the first half is bold or bold italics.)

           I tried changing the hyphen to italics, but that didn't change anything. The only workaround I can find is to turn hyphenation off for the paragraph and then it breaks properly. Does this not qualify as a kind of bug...?

        • 1. Re: Hyphenation bug
          Willi Adelberger Most Valuable Participant

          Did you apply italic via character style? Does the character style have the same language as the rest of the paragraph or is it undefined?

          • 2. Re: Hyphenation bug
            NIRC Level 1

            The italic is not a character tag, just a simple manual change of the font, and there is no change of language. If you want to see, repeat the words prajña-wisdom again and again in a new file and then adjust the margins to force a break after the hyphen. If it works, then turn the hyphenation ON and you will see that it will break at wis- with a soft hyphen, but not where the first hard hyphen is. If you remove the italics, then it all works fine, whatever the hyphenation is set to.

              Thanks, by the way, for the speedy reply.

            • 3. Re: Hyphenation bug
              Peter Spier Most Valuable Participant (Moderator)

              Can you show us a screen shot of the text breaking automatically with and without the applied italics?

              • 4. Re: Hyphenation bug
                Peter Spier Most Valuable Participant (Moderator)

                Here it doesn't seem to matter if the text is italic or regular, so I don't think its th formatting causing the problem.

                • 5. Re: Hyphenation bug
                  Peter Spier Most Valuable Participant (Moderator)

                  I find the same problem with other multi-syllabic words on either side of the hyphen. Single syllable words break correctly, so I think this may be, as you say, a bug where ID is ignoring the typed hyphen entirely in preference to using the preferred hyphenation of the individual words. Applying [no language] to the words, which removes any reference to hyphenation rules, causes them to break a the typed hyphen.

                  • 6. Re: Hyphenation bug
                    Peter Spier Most Valuable Participant (Moderator)

                    You should report this as a bug at Feature Request/Bug Report Form

                    • 7. Re: Hyphenation bug
                      NIRC Level 1

                      Here is a screen shot. Both texts are exactly the same, but the paragraph below has the hyphenation turned off. (It also works if you just turn hyphenation off for a line or two.)

                      • 8. Re: Hyphenation bug
                        Peter Spier Most Valuable Participant (Moderator)

                        You needn't turn off hyphenation entirely, as I said above. You can work around this by assigning no language to the hyphenated words, which could be done pretty easily with a GREP style. The expression \<[^-\s]+-[^-\s]+\> matches from the start of a word all characters that are neither hyphen nor whitespace, the hyphen, and all characters not a hyphen or whitespace to the end of the word and seems to work for me.

                        • 9. Re: Hyphenation bug
                          Peter Spier Most Valuable Participant (Moderator)

                          here's an example of it at work:

                          Fix hypheantion.png

                          1 person found this helpful
                          • 10. Re: Hyphenation bug
                            Willi Adelberger Most Valuable Participant

                            You should never format in any way without styles.

                            • 11. Re: Hyphenation bug
                              Peter Spier Most Valuable Participant (Moderator)

                              How the formatting was applied here is completely irrelevant.

                              • 12. Re: Hyphenation bug
                                NIRC Level 1

                                In short, this function has not yet been worked into InDesign. If all I need is a temporary workaround (this is the first time it has happened to me since using the original CS1 and having produced dozens and dozens of books. I will try your solution or, failing that, just turn off the hyphenation. In either case, I will have to hunt down the culprits one by one.

                                     As for the warning of the other member about not using manual style changes like italics, I agree that would be a shock to ALL InDesign users who do text-intensive work.

                                • 13. Re: Hyphenation bug
                                  Peter Spier Most Valuable Participant (Moderator)

                                  If you use the GREP style as part of your applied paragraph style you will need to neither turn off hyphenation anywhere, nor will you need to search for hyphenated words. They will break only at the hyphen automatically.

                                   

                                  Note that I said Willi's comment was irrelevant to the problem, not that the use of styles was irrelevant in general. Particularly for longer documents that are text-heavy you will find that using styles is a much better workflow. Styles allow you to make formatting changes in one place (the style definition) and have that change cascade thought the entire document automatically. Local formatting changes are not affected by changing styles or style definitions, so you have to go through the document manually or using Find/Change (if it will work), to make corrections.

                                   

                                  The trick with using character styles is to do as little as possible in them. For example, in this case to make a word italic you would define an italic character style with ONLY the italic attribute, not a font name or size. A character style applied to selected text within a paragraph is not considered manual formatting so if you change the style definition to make the type size different, for example, your text with the character style will also change in all attributes except those specifically defined in that character style. Character styles are alos not stripped out if you apply a new paragraph style, so your italics will remain italic, but all the other attributes of the new paragraph style will apply.

                                   

                                  In a case where you have specific words that should be styled in this way it can be done automatically by applying your italic character style as a GREP style in your paragraph styles (ALL text has a paragraph style unless you deliberately set it to [No Paragraph Style] which takes some work). In this case type the word as the search string.

                                  • 14. Re: Hyphenation bug
                                    Peter Spier Most Valuable Participant (Moderator)

                                    NIRC wrote:

                                     

                                    In short, this function has not yet been worked into InDesign.

                                    No, it really looks like you found a genuine bug. I just looked at CS3 and there multi-syllabic hyphenated words seem to break to best fit the line, either at a hyphenation point in an individual word or at the typed hyphen. CS6 never uses the typed hyphen (I did not check CS4 or CS5, so I have no idea when the bug was introduced.

                                     

                                    I had some hope that adding a hyphenated word to the user dictionary would allow me to change the hyphenation points to see the typed hyphen, but sadly no luck. I don't believe ID is even recognizing a hyphenated word as a single word in the text and using the user dictionary.

                                    • 15. Re: Hyphenation bug
                                      jmvrankin Adobe Community Professional

                                      In Preferences > Dictionary, is your Hyphenation setting at Hunspell? Try setting it to Proximity. That has solved problems I've had with hyphenated words breaking incorrectly.

                                      1 person found this helpful
                                      • 16. Re: Hyphenation bug
                                        Peter Spier Most Valuable Participant (Moderator)

                                        Hah! That worked.

                                         

                                        Thanks.

                                         

                                        Still a bug, I think.

                                        • 17. Re: Hyphenation bug
                                          jmvrankin Adobe Community Professional

                                          For sure. I've also had problems with crashing during spell check that go away when I use Proximity instead of Hunspell. I don't really know what that means, but that, along with the goody hyphenation makes me not a fan of Hunspell.

                                          • 18. Re: Hyphenation bug
                                            NIRC Level 1

                                            Thanks for the suggesting about not using Hunspell, but our text uses several different languages and this makes it hard to shift back and forth. In any case, I haven't had any problems with it to date, so I would prefer just to turn hyphenation off for the time being--until the problem gets resolved.

                                            • 19. Re: Hyphenation bug
                                              Peter Spier Most Valuable Participant (Moderator)

                                              Dictionary choice is language-specific. You can choose Proximity for English and Hunspell for other languages.

                                               

                                              And one more time, you can leave hyphenation on and work around the bug using the GREP style I posted above.