cancel
Showing results for 
Search instead for 
Did you mean: 

TouchGFX TextArea Widget Re-orders the Text

crazycanuck256
Associate II

There was a post about this before, but the issue appeared to be happening for that individual only in a custom container, for me it has appeared on multiple screens.

In the example below, I've typed "1. Toggle Pump On/Off' and the text appears in the designer as "Toggle Pump On/Off .1", moving the 1. to the end and changing it's order. 

  • I'm running TouchGFX Designer 4.24.0
  • This is static text, no wild cards. There is only a single specified language (English).
  • Whether the Text ID is auto-generated or not has no impact.
  • If you inspect the text.xml file generated to hold the text, it appears as entered, not as rendered.
  • If I build this in Visual Studio targeting the simulator the text is re-arranged as it appears when rendered in the designer.

See the screen cap below.

Odd text Re-ordering issue.png

I have observed several circumstances under which this happens/does not happen:

  • Removing the "." after the 1 has no effect. (Text still re-arranged)
  • Adding additional leading numbers has no effect, nor does leading spaces.
  • Adding a leading letter (e.g., "x1. Toggle Pump On/Off") resolves the issue. (Text is no longer re-arranged).
  • If the text contains only numbers (including a decimal) text is not re-arranged.

It appears to be an issue that can arise when the text starts with a number

  • If I parenthesize text (e.g., "Volume (ml)") the parenthesized text is moved to the beginning of the string: "(ml) Volume".  The same behavior is seen with square brackets [ ] or curly brackets { }. So for example text like the following "{1} Toggle Pump On/Off {2}" is re-arranged as "{2} Toggle Pump On/Off {1}".
1 ACCEPTED SOLUTION

Accepted Solutions

In a new/blank simulator project the issue appears not to be present (as was the case with the other thread on here).  I therefore infer there's a setting somewhere that causes this issue to manifest. 

I inferred it might have something to do with the Typographies, and after some comparison between the new project default and my existing project, I eventually noticed a difference: someone here clicked the button which changes font direction from left-to-right to right-to-left (see attached screencap); the manifestation is a little unexpected (to me), but I don't normally used languages the are right-to-left so maybe the behavior was as would be expected. 

Thank you for your assistance, I consider this to be resolved.

View solution in original post

3 REPLIES 3
GaetanGodart
ST Employee

Hello @crazycanuck256 ,

 

I have tried reproducing the issue :

  • create new empty project
  • added a text area
  • changed text to "1. test (ml)"

It appears fine on Designer and on the simulator.
Can you try to reproduce the issue from an empty project and specify the steps so I can reproduce it?

I have also tried the project you shared but it seem you have not shared everything mandatory for it to work properly (ex: images used).
I have deleted everything except one of the screens and the text area that was on it and once again, why setting the text to "1. test (ml)" it displays fine on Designer and on the simulator.

 

I am afraid I cannot investigate the issue at the moment.
Waiting for your answer and either steps from an empty project or a zip.

 

Regards,

Gaetan Godart
Software engineer at ST (TouchGFX)

In a new/blank simulator project the issue appears not to be present (as was the case with the other thread on here).  I therefore infer there's a setting somewhere that causes this issue to manifest. 

I inferred it might have something to do with the Typographies, and after some comparison between the new project default and my existing project, I eventually noticed a difference: someone here clicked the button which changes font direction from left-to-right to right-to-left (see attached screencap); the manifestation is a little unexpected (to me), but I don't normally used languages the are right-to-left so maybe the behavior was as would be expected. 

Thank you for your assistance, I consider this to be resolved.


@crazycanuck256 wrote:

I consider this to be resolved.


Please mark that as the solution - to make it visible

https://community.st.com/t5/community-guidelines/help-others-to-solve-their-issues/ta-p/575256