Hello Guest

Author Topic: Word Wrap justified right and spaces.  (Read 3196 times)

vancext

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 7
    • View Profile
Word Wrap justified right and spaces.
« on: March 04, 2014, 01:19:34 am »
Heya, just wondering if someone could help me figure out a hack for tk2dTextMesh. I notice whenever I anchor text right and use word wrap, the spaces get pinned to the ends of the line-ending words, instead of being attached to the front of the word moved to the next line (the opposite of what needs to happen with left justification). The effect is a space at the end of every non-final line-ending word, creating a jagged justification.

Any easy way to fix?

Thank you for the help!


unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: Word Wrap justified right and spaces.
« Reply #1 on: March 04, 2014, 11:31:09 am »
tk2dTextMesh.FormatText is where the formatting occurs. The
Code: [Select]
else if (idx == ' '/* || idx == '.' || idx == ',' || idx == ':' || idx == ';' || idx == '!'*/)line is where the it treats the space character. You can tweak that there.