Results 1 to 3 of 3
  1. #1
    Deathslice is offline Member
    Join Date
    Jan 2015
    Location
    Miami, FL
    Posts
    86
    Rep Power
    0

    Default Content doesn't appear and resize properly when I minimize and maximize

    So I'm fairly new to JFrame and swing and I decided to create a mini application that is suppose to allow the user to buy whatever animal they want. I've lately been using Netbeans and the JFrame form design view and I'm not sure how I will be able to show how the application looks because the problems that I've encountered as of now are design problems(I guess I'll just have to show the source code if need be). The first problem is that when I try to maximize the size of the screen to some dimension, The picture that I have and the title directly below become anchor to the center of the screen. The Radio buttons align themselves to the left of the screen and the text box auto resizes horizontally and vertically. Everything looks good until you get to the button at the bottom of the screen. There is no way I can think of that can center the button every time you maximize the window or even decrease the window size to some other size besides the original size that you started with(All I've been talking about so far is that if the user moves the cursor to the edge of the screen and attempts to resize the window to some other dimension, the button doesn't stay anchored to the center of the screen). I've tried messing around with the properties tab to find a solution but nothing is working. The last problem is when I completely minimize the screen, none of the content on the screen follow the screen. It's only when I revert back to the original size do they come back. These are the design problems that I'm facing. Please response as soon as possible.
    Last edited by Deathslice; 03-15-2015 at 06:02 PM.

  2. #2
    KevinWorkman's Avatar
    KevinWorkman is offline Crazy Cat Lady
    Join Date
    Oct 2010
    Location
    Washington, DC
    Posts
    4,143
    Rep Power
    14

    Default Re: Content doesn't appear and resize properly when I minimize and maximize

    Holy wall of text, batman.

    Can you just post an MCVE (note: this should NOT be your entire project, just enough to see what's going on. Use hardcoded placeholder values wherever possible) and a short description of the problem?

    It sounds like you've got a problem with your layout or your painting code, but it's impossible to say without seeing your code.
    How to Ask Questions the Smart Way
    Static Void Games - GameDev tutorials, free Java and JavaScript hosting!
    Static Void Games forum - Come say hello!

  3. #3
    DarrylBurke's Avatar
    DarrylBurke is offline Forum Police
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    12,059
    Rep Power
    25

    Default Re: Content doesn't appear and resize properly when I minimize and maximize

    Quote Originally Posted by Deathslice View Post
    I've lately been using Netbeans and the JFrame form design view ...
    Quote Originally Posted by KevinWorkman View Post
    Can you just post an MCVE ...
    db <- runs far far away
    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

Similar Threads

  1. run() only works after minimize and maximize...
    By Josep_16 in forum Java Applets
    Replies: 5
    Last Post: 08-10-2011, 09:04 AM
  2. Replies: 10
    Last Post: 07-03-2011, 01:07 PM
  3. my JDialog doesn't want to resize as I say :P
    By patr1c1a in forum New To Java
    Replies: 3
    Last Post: 11-25-2010, 02:12 PM
  4. Replies: 6
    Last Post: 11-22-2010, 11:55 AM
  5. Minimize and maximize GUI
    By dejos456 in forum New To Java
    Replies: 6
    Last Post: 12-09-2009, 09:49 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
  •