Carriage return

All announcements, questions and issues related to the TsiLang Components Suite.
Post Reply
engi
Posts: 6
Joined: Tue Jan 06, 2009 10:03 am

Carriage return

Post 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?
engi
Posts: 6
Joined: Tue Jan 06, 2009 10:03 am

Re: Carriage return

Post by engi »

I'm using TsiLang 7.8.4
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Re: Carriage return

Post 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.
Best regards,
Igor Siticov.
engi
Posts: 6
Joined: Tue Jan 06, 2009 10:03 am

Re: Carriage return

Post by engi »

I used the first solution.
It works perfectly.

Thanks !
Post Reply