This week's book giveaway is in the Mac OS forum.
We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line!
See this thread for details.
The moose likes Swing / AWT / SWT and the fly likes Can I set the height and width of a JLable text? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Can I set the height and width of a JLable text?" Watch "Can I set the height and width of a JLable text?" New topic
Author

Can I set the height and width of a JLable text?

Jane Green
Greenhorn

Joined: Aug 22, 2003
Posts: 5
I want to set the JLable (or JButton) text font to be two times higher than the regular font height, is there a way to do it? Anybody know that?
Thanks a lot.
Jane
kyle amburn
Ranch Hand

Joined: Jul 29, 2001
Posts: 64
Sure, you can do this for any component.

Kyle
Jane Green
Greenhorn

Joined: Aug 22, 2003
Posts: 5
Thank you, that's good news. But seems I need more specific transform of the font: I want to stretch the text, that means I need the font height to be doubled but the width don't change. More suggestions? Thanks a lot.
Jane
 
GeeCON Prague 2014
 
subject: Can I set the height and width of a JLable text?