I am having an issue with my text mesh pro objects and getting soft hyphens to work properly. I read that TMP uses u00AD for soft hyphens but it is not working as expected. One of three things happen that are unexpected.
- If I add u00AD to my text it always inserts a space character even when it does not need to wrap. Depending on the font this space is a little square (result 2 from screenshot)
- the word breaks where I place the u00AD but does not show a “-” hyphen.
- depending on the font it never breaks.
In the screenshot I added u00AD
to all words where they can be split with soft hyphens. In the expected section I highlighted the softhyphens that are added correctly. As you can see from the two results the redwords show that the hyphens either show as a space or some square character depending on the font.
I thought the point of the soft hyphen was that a hyphen would be placed if and when the word needs to break, but if it does not need to break nothing would be placed there at all.
I modified my source fonts with FontForge to make sure that the hyphen gliph is set up to be used as the soft hyphen as well for both of these fonts but it is not being used properly. Should I be using something other than u00AD to insert the soft hyphen?
Here is the source text from the screenshot.
As the earu00ADly mornu00ADing sun peeked over the horiu00ADzon, castu00ADing a goldu00ADen glow across the dew-kissed meadu00ADow, Sarah felt a sense of tranu00ADquilu00ADiu00ADty wash over her. The genu00ADtle breeze caru00ADried the sweet frau00ADgrance of wildu00ADflowu00ADers, minu00ADgling with the earthu00ADy scent of damp soil. Birds chirped joyu00ADfulu00ADly in the trees, their meu00ADlodu00ADic songs addu00ADing to the seu00ADrene amu00ADbiu00ADance. Situ00ADting on a weathu00ADered woodu00ADen bench beu00ADneath an anu00ADcient oak tree, Sarah closed her eyes and lisu00ADtened to the symu00ADphou00ADny of nau00ADture around her. In that peaceu00ADful mou00ADment, she reu00ADalu00ADized how nau00ADture had a way of soothu00ADing the soul and reu00ADmindu00ADing her of life’s simu00ADple pleasu00ADures.