Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Agile forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Max Size Text in JTextField

Struan Kay
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I hava a jtextfield on a component with a Gridbag layout. I want the text in the Textfield to be the maximum height possible, such that it just fits vertically into the field. I know I can change the font but how do I decide the size or is the a better way of doing it.

The information displayed is purely numerical I don't suppose there's and 8 segment display component that I'm missing is there?


With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic