Skip to main content
Participant
August 30, 2018
Resuelto

Is there any method to avoid hyphenation before a charcter in different words throughout an InDesign document?

  • August 30, 2018
  • 2 respuestas
  • 1904 visualizaciones

I am using FML Malayalam fonts (not based on Unicode) to design a newspaper. Hunspell dictionaries are totally useless for these kind of fonts. In Malayalam language some characters have to go along with other characters to make it meaningful. Eg. കാടി - in this word of four charecters the first and third characters are constants while second and fourth characters act like vowels. But we cannot seperate a constant from its vowel and these vowel charecters appear after almost every constants in every words.

In FML Malayalam fonts all characters appear seperately. The letters in this font are assigned to english letters and symbols.

Hence I am looking for a way to keep them together in every word throughout a document. I have already tried adding charecters with along with tildes to dictionary but that also doesn't work well as some charecters are assigned to symbols like '(,{,]', etc. As there are numerous words in the language, Adding words to dictionary with hyphenation properties is also not an easy option

I even tried using Nonbreaking hyphen feature but turns out that while joining one word, another two or more breaks.

    Este tema ha sido cerrado para respuestas.
    Mejor respuesta de Peter Kahrel

    That also didnt work well as expected. As i had mentioned earlier, the malayalam letters are assigned to all keys on keyboard including the symbols.

    These are the Malayalam consonants:

    IJKLMNOPQRSTUWVXYZ[\]^_`abcdefghijkl¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖרÙÚÛÜÝÞßàáâãäåï∙

    These are vowels that come before a consonant:

    st{

    And these are vowels that come after a consonant:

    mnopqruvwxyz

    I still hope there might be some method to get this working in InDesign.


    Instead of keeping together CV (consonant+vowel) pairs, maybe it's better to insert discretionary breaks after CV pairs:

    Find what: [IJKLMNOPQRSTUWVXYZ\[\\\]\^_`abcdefghijkl¡¢£¤¥\¦§¨©ª«¬®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ ×ØÙÚÛÜÝÞßàáâãäåï∙]\K([mnopqruvwxyz])

    Change to: $1~k

    Which paraphrases as 'Find V preceded by C, replace the V with itself and discretionary line break'. Note the added backslashes before [ \ ] and | -- these are special symbols in Grep, and you need to indicate that you're looking for the literal characters. (That's probably why it didn't work for you earlier.)

    This probably works better because keeping various combinations together doesn't guarantee that words will break at every permissible place.

    2 respuestas

    winterm
    Legend
    August 30, 2018

    Sorry, know nothing about Malayalam language…

    Speaking in terms of Latin languages, this will found any word character

    a\K\w

    or just any character

    a\K.

    that follows character a.

    You can apply nobreak char style to it, and pairs aa, ab, ac, ..., az, a1, a9, or even a’, a:, a! and so on (using the second regex) will never break.

    Also you can make it case-insensitive:

    (?i)a\K\w

    Hopefully this can help you to find a suitable solution.

    Note: these regex will work on CS6 and higher. For lower versions you should use regular Positive Lookbehind: (?<=a)\w or (?<=a). instead of \K

    Legend
    August 30, 2018

    One of the things you could look at doing is create a character style that ONLY has the "No Break" option enabled, and then create a basic paragraph style in which you use apply this character style to the letter pairs that are not allowed to break using a GREP style, and use the basic paragraph style as the foundation for the core styles in your templates. E.g. base body-copy on it, and then you can base other styles on body-copy e.g. bulleted lists  etc.

    Character style:

    Paragraph style:

    [1] Select the Character style

    [2] enter the letter pair

    [3] click New GREP Style to insert another one for the next letter pair, and repeat [1] and [2]

    Civi_vmAutor
    Participant
    September 2, 2018

    There are over 60 consonants in malayalam language, and over 20 vowels. The letters are assigned to all character keys on the keyboard. Even if I were to create pairs, I would have to make them for 60 consonants with these 20 vowels, thats 60*20=1200 pairs. Creating 1200 pairs of GREP styles is not feasible.

    FRIdNGE
    September 2, 2018

    … But, in this case,  play 1,200 pairs with 1 grep style is simple!

    Best,

    Michel, for FRIdNGE