Skip to main content

Accented characters work in LCDUIT but not in LWUIT

3 replies [Last post]
ukyo
Offline
Joined: 2008-02-22
Points: 0

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
saturon

- Did you set the label's font to the bitmap font defined in the
resource editor?

The questionmarks you get are because the microemulator / phone does not
support turkish characters (right?) - you need the bitmap fonts e.g.
images - to be drawn by lwuit.

-----Original Message-----
From: lwuit-users@mobileandembedded.org
[mailto:lwuit-users@mobileandembedded.org]
Sent: Donnerstag, 25. Juni 2009 07:48
To: users@lwuit.dev.java.net
Subject: Accented characters work in LCDUIT but not in LWUIT

Hi,

I'm trying to convert my application to LWTUIT. The first problem I'm
facing is abut fonts. The issue is dead simple. I've got this code

private String appTitle = "ğĞüÜöÖçÇıİşŞ";
Label welcomeLabel = new Label(appWelcome);

All I get is "??üÜöÖçÇ????" in the title. Chars replaced with question
mark

I've added a font in ResourceEditor and added those characters, set the
theme style to use the fonts. I see correct characters in ResourceEditor
but I get question marks in emulator and on my real phone.

I'm using Netbeans 6.7RC3 and Microemulator on Mac. There's no problem
with fonts being displayed on the phone and the emulator with out of the
box LCDUIT apps

Any thoughts?
[Message sent by forum member 'ukyo' (ukyo)]

http://forums.java.net/jive/thread.jspa?messageID=352840

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@lwuit.dev.java.net
For additional commands, e-mail: users-help@lwuit.dev.java.net

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@lwuit.dev.java.net
For additional commands, e-mail: users-help@lwuit.dev.java.net

Ukyo Virgden

Hi,

Thanks for the reply. The phone does support turkish characters. When
I create a LCDUI project, Visual Midlet in Netbeans, The characters
display correctly both on microemulator and on the phone.

I've done the following
1- In ResourceEditor, created a font named "DefaultFont" and added the
accented chars to the charset
2- In theme, I've set a global font property and set it to
Bitmap:DefaultFont.

When I fire up the app in the emulator, I see the correct font but
question mark instead of accented chars and also the very same on the
phone (Nokia S60 latest)

I could not figure it out. I can see correct chars on the phone and
emulator for LCDUI but not for LWUIT

Any ideas? I'd greatly appreciate any comments
Thanks in advance,

Ukyo

On 25.Haz.2009, at 11:27, saturon wrote:

>
> - Did you set the label's font to the bitmap font defined in the
> resource editor?
>
> The questionmarks you get are because the microemulator / phone does
> not
> support turkish characters (right?) - you need the bitmap fonts e.g.
> images - to be drawn by lwuit.
>
>
> -----Original Message-----
> From: lwuit-users@mobileandembedded.org
> [mailto:lwuit-users@mobileandembedded.org]
> Sent: Donnerstag, 25. Juni 2009 07:48
> To: users@lwuit.dev.java.net
> Subject: Accented characters work in LCDUIT but not in LWUIT
>
>
> Hi,
>
> I'm trying to convert my application to LWTUIT. The first problem I'm
> facing is abut fonts. The issue is dead simple. I've got this code
>
> private String appTitle = "ğĞüÜöÖçÇıİşŞ";
> Label welcomeLabel = new Label(appWelcome);
>
> All I get is "??üÜöÖçÇ????" in the title. Chars replaced with
> question
> mark
>
> I've added a font in ResourceEditor and added those characters, set
> the
> theme style to use the fonts. I see correct characters in
> ResourceEditor
> but I get question marks in emulator and on my real phone.
>
> I'm using Netbeans 6.7RC3 and Microemulator on Mac. There's no problem
> with fonts being displayed on the phone and the emulator with out of
> the
> box LCDUIT apps
>
> Any thoughts?
> [Message sent by forum member 'ukyo' (ukyo)]
>
> http://forums.java.net/jive/thread.jspa?messageID=352840
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@lwuit.dev.java.net
> For additional commands, e-mail: users-help@lwuit.dev.java.net
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@lwuit.dev.java.net
> For additional commands, e-mail: users-help@lwuit.dev.java.net
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@lwuit.dev.java.net
For additional commands, e-mail: users-help@lwuit.dev.java.net

Shai Almog

Hi,
You should check the character encoding for the compiler in NetBeans.
Right click project. Select Properties->Compiler Look in the "Encoding"
combobox.
> Hi,
>
> Thanks for the reply. The phone does support turkish characters. When
> I create a LCDUI project, Visual Midlet in Netbeans, The characters
> display correctly both on microemulator and on the phone.
>
> I've done the following
> 1- In ResourceEditor, created a font named "DefaultFont" and added the
> accented chars to the charset
> 2- In theme, I've set a global font property and set it to
> Bitmap:DefaultFont.
>
> When I fire up the app in the emulator, I see the correct font but
> question mark instead of accented chars and also the very same on the
> phone (Nokia S60 latest)
>
> I could not figure it out. I can see correct chars on the phone and
> emulator for LCDUI but not for LWUIT
>
> Any ideas? I'd greatly appreciate any comments
> Thanks in advance,
>
> Ukyo
>
> On 25.Haz.2009, at 11:27, saturon wrote:
>
>>
>> - Did you set the label's font to the bitmap font defined in the
>> resource editor?
>>
>> The questionmarks you get are because the microemulator / phone does not
>> support turkish characters (right?) - you need the bitmap fonts e.g.
>> images - to be drawn by lwuit.
>>
>>
>> -----Original Message-----
>> From: lwuit-users@mobileandembedded.org
>> [mailto:lwuit-users@mobileandembedded.org]
>> Sent: Donnerstag, 25. Juni 2009 07:48
>> To: users@lwuit.dev.java.net
>> Subject: Accented characters work in LCDUIT but not in LWUIT
>>
>>
>> Hi,
>>
>> I'm trying to convert my application to LWTUIT. The first problem I'm
>> facing is abut fonts. The issue is dead simple. I've got this code
>>
>> private String appTitle = "ğĞüÜöÖçÇıİşŞ";
>> Label welcomeLabel = new Label(appWelcome);
>>
>> All I get is "??üÜöÖçÇ????" in the title. Chars replaced with question
>> mark
>>
>> I've added a font in ResourceEditor and added those characters, set the
>> theme style to use the fonts. I see correct characters in ResourceEditor
>> but I get question marks in emulator and on my real phone.
>>
>> I'm using Netbeans 6.7RC3 and Microemulator on Mac. There's no problem
>> with fonts being displayed on the phone and the emulator with out of the
>> box LCDUIT apps
>>
>> Any thoughts?
>> [Message sent by forum member 'ukyo' (ukyo)]
>>
>> http://forums.java.net/jive/thread.jspa?messageID=352840
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@lwuit.dev.java.net
>> For additional commands, e-mail: users-help@lwuit.dev.java.net
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@lwuit.dev.java.net
>> For additional commands, e-mail: users-help@lwuit.dev.java.net
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@lwuit.dev.java.net
> For additional commands, e-mail: users-help@lwuit.dev.java.net
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@lwuit.dev.java.net
For additional commands, e-mail: users-help@lwuit.dev.java.net