Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

German special letters as � � & a u m l ;

 
Peter Gragert
Ranch Hand
Posts: 424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I would like to replace oe by � in the border of a JPanel.
(others likewise )
I never did it before. Where do I have to look at?
Or is there even an easy way?
MfG
Peter
 
Tim Holloway
Saloon Keeper
Posts: 18366
56
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm afraid I don't understand. A JPanel is a blank area and of itself cannot contain text - though it may contain text objects such as JLabel's.
Java is Unicode-oriented, so use of Unicode codings for umlaut characters usw. is just a matter of defining your resources appropriately and making sure that the display fonts for the items in question have glyphs defined for those characters.
 
Peter Gragert
Ranch Hand
Posts: 424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The BORDER of a JPanel may get text: eg:
myPanel.setBorder( BorderFactory.createBorder("sch�n"));
(this would give sch[]n in the Border of the Panel)
Ok, I will see how to use unicode characters.
In any case: Thanks!
 
Peter Gragert
Ranch Hand
Posts: 424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Did not work, I tried \u0081 in a text, delivers [] and not an ü
So there has to be done something extra: What?
Greetings
Peter
 
Tim Holloway
Saloon Keeper
Posts: 18366
56
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That's because the font you've got assigned to that border has no glyph for \u0081. You'll have to attach a font that has glyphs for the umlaut characters.
Fonts in Java can be a nuisance, since they're OS-dependent constructs that Java must try and handle in an OS-independent way. The font.properties file in the jre lib directory is used to help match the two up.
 
Tim Holloway
Saloon Keeper
Posts: 18366
56
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That's because the font you've got assigned to that border has no glyph for \u0081. You'll have to attach a font that has glyphs for the umlaut characters.
Fonts in Java can be a nuisance, since they're OS-dependent constructs that Java must try and handle in an OS-independent way. The font.properties file in the jre lib directory is used to help match the two up.
 
Peter Gragert
Ranch Hand
Posts: 424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Tim,
I think it is clear now.
Peter
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic