• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Right Alignment of Text

 
Ahsan Saeed
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

I am making a midlet in languages like Urdu, Arabic etc. In these languages the text has to be right aligned. I did not come across any method to do this. So will it be possible to right align all text.(text in Lists, Forms, titles of screens etc)

Ahsan
 
Ahsan Saeed
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
BTW, I'm using MIDP 1.0.

Just another thought: If the phone's language is set to English the text would be left aligned. Maybe if the language is changed to Urdu/Arabic the text gets right aligned.

Any comments... ?

But still do you think there is a way to change text alignmnet in high level components programatically ?

I don't really want to do it the dirty way by adding spaces etc.

Ahsan
[ October 06, 2004: Message edited by: Ahsan Saeed ]
 
Roseanne Zhang
Ranch Hand
Posts: 1953
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Graphics.drawString(s, x, y, Graphics.TOP|Graphics.RIGHT);
 
Ahsan Saeed
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Roseanne Zhang:
Graphics.drawString(s, x, y, Graphics.TOP|Graphics.RIGHT);


Thanks. I know this can be done using low-level graphics. What about high level UI components(Lists, Forms, StringItems etc)
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic