Page 1 of 1

Carriage return

Posted: Mon Jan 11, 2021 10:31 am
by engi
Hi,

I use TsiLang components in a C++ Builder program.
In the [Strings] section, I have several sentences that contain carriage return (\n).
When these sentences are displayed in the GUI, the line break is not done and the \n character is displayed.
How can this problem be corrected?

Re: Carriage return

Posted: Mon Jan 11, 2021 10:34 am
by engi
I'm using TsiLang 7.8.4

Re: Carriage return

Posted: Mon Jan 11, 2021 11:41 am
by isiticov
Hello,
  1. There is a global variable siLang_Def_UsedInCpp declared in siComp unit. You can assign it to True at application's initialization and C++ special chars like \n, \t and others will be treated accordingly.
  2. Additionally, every TsiLang component has a public field named UsedInCpp, you can set it to true to achieve the same functionality.
But the easier would be to use the first solution.

Re: Carriage return

Posted: Mon Jan 11, 2021 1:00 pm
by engi
I used the first solution.
It works perfectly.

Thanks !