Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ Libraries and TheIDE: i18n, Unicode and Internationalization » CHARSET_UTF8 not working?
Re: CHARSET_UTF8 not working? [message #48555 is a reply to message #48553] Fri, 21 July 2017 15:16 Go to previous messageGo to previous message
rafiwui is currently offline  rafiwui
Messages: 105
Registered: June 2017
Location: Stuttgart, Germany
Experienced Member
Oblivion wrote on Fri, 21 July 2017 14:44


As you know, U++ *.t files are meant be used for localization. But you don't really need use the English versions of the strings as default (or at all).

if in the *.cpp file you can simpyl write:

app.Title(t_("přihláška"));


This will make it the default string (the string to be localized, if needed.).


Two points on this:
1. I learned that it is no good programming style to put non-ASCII letters in pure source code Wink Smile
2. But I want a multinational application, so I need different language support and I don't know how to achieve this in this way.


Oblivion wrote on Fri, 21 July 2017 14:44


Also you don't need to call:

SetDefaultCharset(CHARSET_UTF8);


UTF8 is/should be enabled by default. This function is to support legacy applications.


It is even more curious that the string got "destroyed" then.
By the way: If I do it the way you showed me (put the czech string in the code) and don't uncomment the SetDefaultChar it works.
But why? Why doesn't it take the string correctly from the .t file but from the source code?


Greetings
Daniel
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Theide (feature): closing openend files when changing package
Next Topic: Custom Build Steps to generate .cpp files and then compile
Goto Forum:
  


Current Time: Tue Jun 11 21:35:43 CEST 2024

Total time taken to generate the page: 0.00947 seconds