Article View: borland.public.cppbuilder.internationalization
Article #196Re: Unicode char-s on control
From: Lesley Anne
Date: Wed, 27 Sep 2006 20:07
Date: Wed, 27 Sep 2006 20:07
24 lines
2161 bytes
2161 bytes
"Tumurbaatar S." <spam_tumur@magicnet.mn> wrote in message news:451aac8f@newsgroups.borland.com... > Hi! > I'm trying to write my first international app in BCB6. > It seems there's no way to display Unicode char-s that > do not belong to any charset/code page (like Windows-1251 and etc). > The Text and Caption properties accept only AnsiString string, so > Unicode char-s are not allowed. > Yes? Even though Text and Caption properties are listed as being AnsiString, you can assign WideString values to them as well, since the implementation of the AnsiString type isn't limited to single byte encodings. Unfortunately, I haven't been able to find a way to make them actually display correctly when given Unicode values higher than 0x00FF. The implementation of the display doesn't seem to have been done correctly. There are, however, third-party component libraries available to take up the slack. The one I've heard about the most often (though I haven't used it myself) is TNT. http://www.tntware.com/delphicontrols/unicode/ From the looks of it, you simply replace your TLabel's with TTntLabel's, TEdit's with TTntEdit's, etc. and then you can use Unicode values and have them display correctly, while keeping the ease-of-use of the VCL.
Technical Details
Message-ID:
<451ada0d$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news2.google.com!news4.google.com!news2.google.com!news.germany.com!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<451aac8f@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 10297d,c35059606ebe258 X-Google-Attributes: gid10297d,public X-Google-Language: ENGLISH,ASCII-7-bit From: "Lesley Anne" <mspfila-ng@yahoo.com> Newsgroups: borland.public.cppbuilder.internationalization References: <451aac8f@newsgroups.borland.com> Subject: Re: Unicode char-s on control Date: Wed, 27 Sep 2006 16:07:22 -0400 Lines: 26 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.2869 X-RFC2646: Format=Flowed; Response X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2962 NNTP-Posting-Host: 144.160.5.25 Message-ID: <451ada0d$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1159387661 144.160.5.25 (27 Sep 2006 13:07:41 -0700) Path: arc1-ca.pugleaf.net!g2news2.google.com!news4.google.com!news2.google.com!news.germany.com!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail