Results 1 to 2 of 2
  1. #1
    adiotrox is offline Member
    Join Date
    Feb 2012
    Rep Power

    Question To maximize JTextArea on maximizing the Jframe ?

    i have a JFrame which contains a JTextArea now on it's default size it looks good but when i clicked on maximizing option the frame gets bigger but the text area is still smaller,is there any way that on maximizing the frame the text area size also increases itself ??
    Any comment will be appreciated.

  2. #2
    Fubarable's Avatar
    Fubarable is offline Moderator
    Join Date
    Jun 2008
    Blog Entries
    Rep Power

    Default Re: To maximize JTextArea on maximizing the Jframe ?

    The key to this is in the layout managers your GUI is using. If the JTextArea (which is usually held by a JScrollPane) is held by a container that allows the scrollpane to enlarge when the container enlarges, such as a BorderLayout in the CENTER position, you're all set. For more on how to use the layout managers, please check out: Lesson: Laying Out Components Within a Container

Similar Threads

  1. Replies: 2
    Last Post: 11-08-2011, 06:12 AM
  2. How to Maximize the JFrame ?
    By MarMer in forum AWT / Swing
    Replies: 5
    Last Post: 06-07-2011, 05:19 AM
  3. Disable Maximize button in JFrame?
    By Manish87 in forum AWT / Swing
    Replies: 0
    Last Post: 02-01-2011, 04:39 PM
  4. Replies: 6
    Last Post: 11-22-2010, 12:55 PM
  5. JFrame maximizing
    By Java Tip in forum Java Tip
    Replies: 0
    Last Post: 03-12-2008, 12:19 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts