Difference in sizes, how to fix?

I have two panels and I use a CardPanel layout to navigate from one panel to the other.
Now when my first panel is on the screen, it is in it's natural size, meaning that i didn't tinker with the size and it just displays in its default size. Now when i goto my second panel, the size remains the same and my second panel is much larger than my first one, and because the size remains the same, i have to maximize the window. How can i make it so that when using card layout when i goto my second panel, i can make it my own size, or make it so that it is displayed in its default size?

Sorry, will post it in Swing forum next time.
I tried to do it using next method and i got this error when i RUN the program:
java.awt.Dimension[width=10,height=10]Exception in thread "main" java.lang.IllegalArgumentException: cannot add to layout: constraint must be a string
     at java.awt.CardLayout.addLayoutComponent(Unknown Source)
     at java.awt.Container.addImpl(Unknown Source)
     at java.awt.Container.add(Unknown Source)
     at RenamePanel.<init>(RenamePanel.java:63)
     at Driver.main(Driver.java:12)
so i used a different way of using the "show" method.

Similar Messages

  • Difference matte and how to fix the result?

    I did find this "tutorial" video of how to use Difference Matte:
    http://www.mefeedia.com/entry/difference-matte/10818096/
    But I would like to know, how I can edit the result?
    I did the Difference Matte and stuff, but I have a hole/transparent section in my object (in my ahnd in this case) after the difference matte. How can I fix it so I can select the one part/section of my hand that is transparent?

    Apologies ... totally misunderstood what the problem was! So you have areas that are keying out that you actually don't want to key out, right? Tom is steering you right as usual. You need to apply a garbage matte on an additional duplicated layer of your hand element. The Garbage Matte layer should be a rough selection of the central part of the hand element, the Difference Matte layer provides the fine edges to your hand element ... together they combine to produce a single apparent hand element ( with no holes in it! )

  • When converting a .pptx file of 6MB to .pdf, the file size ballooned to 25MB. The original file was created on a PC. What happened? Why? How to fix? Thx.

    When converting a .pptx file of 6MB to .pdf, the file size ballooned to 25MB. The original file was created on a PC. What happened? Why? How to fix? Thx.

    gssharpe wrote:
    What happened?
    Nothing much. Different formats.
    How to fix?
    Try editing the original file. Resample pics to a lower resolution, check out other graphics, check table borders (eliminate any dotted lines or borders), check font usage. When generating PDF, try Save As (instead of Print > Save As), although I don't expect that'll make much difference.
    Next, open the PDF in Preview, choose File > Save As, choose Format: PDF, Quartz Filterz: Reduce File Size. If that isn't enough, you can use ColorSync Utility to duplicate the Reduce File Size filter, and then edit it for a more aggressive size reduction. But keep in mind that size reduction means lower quality.

  • After successful install, all my adobe cc docs, when open, change pointer arrow, i-beam and window to oversize. When doc closes all return to normal size. I'm on a PC. Screen res set to medium 1920x1200. Any ideas how to fix?

    After successful install, all my adobe cc docs, when open, change pointer arrow, i-beam and window elements to oversize. When doc closes all return to normal size. I'm on a PC. Screen res set to medium 1920x1200. Any ideas how to fix?

    Ok thanks Linxup I would recommend posting in the respective forums for each of those software titles as opposed to the Creative Cloud Download & Install forum.  The relevant forums are as follows:
    InDesign - InDesign
    Illustrator - Illustrator

  • I recently downloaded a 10.6.8 update and a game program has now been reduced in size.  It's specifications are set for full screen, but it is about 1/4 of the size.  Any ideas how to fix?

    I recently downloaded a 10.6.8 update and a game program has now been reduced in size.  It's specifications are set for full screen, but it is about 1/4 of the size.  Any ideas how to fix?

    Hi, I have got the same problem but all is 1/4 the size have you fixed it?

  • Keyboard viewer on my iMac (running Snow Leopard) recently has lost small size. Green " " button is just moving big keyboard size up. I would appreciate  a hint how to fix it. Alex

    Keyboard viewer on my iMac (running Snow Leopard) recently has lost small size. Green "+" button is just moving big keyboard size up. I would appreciate  a hint how to fix the problem. Alex

    You can resize the keyboard window, positioning the mouse pointer at the edge of the window, clicking and dragging to the desired size.

  • How to fix the size of JFrame

    Hi Friends,
    How to fix the size of JFrame so that it can not br able to resize beyond a
    certain limit .
    i want this because i my screen if it is resized as small then the component of screen changes there location and position.
    plz help.

    You can... sort of
    The setSize() method is nasty because you don't get the event until you release the button, so the frame resizes and then snaps back. However, if you put the ComponentListener on the frame's JRootPane, you get a stream of resize events (because the window typically needs to be able to dynamically redraw itself). You can still use the setSize() method, but it is potentially confusing to the user, because the window border gets disconnected from the cursor, and as the mouse is moved further, the frame flickers between its instantaneous new size and max size.
    For a better user experience, use Robot to programmatically reposition the mouse back to the screen location equivalent to the maximum dimension.

  • How to fix the size of the frame or window?

    Hi,
    Do you know how to fix the size of the frame or window so that the user cannot minimize or maximize it?
    Thanks.

    Frame's setResizable(false);.

  • How to fix the decimal part(round) i.e. fix the size of float.

    how to fix the decimal part(round) i.e. fix the size of float.

    You can use BigDecimal to round of your number.
    float f = 5.678f;
    f = new BigDecimal(f).setScale(2, BigDecimal.ROUND_HALF_UP).floatValue();If you just want to display the float with a certain number of decimals, you can use java.text.DecimalFormat
    DecimalFormat df = new DecumalFormat("0.00"); // two decimals
    float f = 5.678f;
    System.out.println(df.format(f)); // should show up as 5.68

  • 0x8056530b error enabling disk deduplication on Windows Server 2012 R2 Volume - any ideas why or how to fix?

    I'm getting the following error when trying to enable disk de-duplication on a volume on my Windows 2012 R2 file server.  The error is:
    "There was an error updating Data Deduplication on volume: MSFT_DedupVolume.Volume='\\?\Volume{8dfc4322-9997-11e3-93f5-005056a84b9b}\' - HRESULT 0x8056530b, The specified volume type is not supported. Deduplication is supported on fixed, write-enabled
    NTFS data volumes and CSV backed by NTFS data volumes."
    The volume in question is a 1TB VMFS volume mounted to the virtual machine that is the Windows file server.  I could find no info anywhere that references this error as it relates to a standard mounted volume or VMware or VMFS. 
    Any ideas on what could be the problem or how to fix it?  I could find nothing in the log files other than an entry which is basically a repeat of the error above.
    Any help would be greatly appreciated.
    - ADEHART
    P.S. This is a volume that was previously mounted on an older Windows 2003 server.  Not sure if that may make a difference.

    have you compared this issue to the ones that are successful and compared what is different?
    Have you made sure of the following:
    Servers
    See the following list for server requirements for deduplication:
    • Server hardware should meet the minimum requirements for running Windows Server 2012. The deduplication feature was designed to support minimal configurations such as a single processor system with 4 GB of RAM and one SATA hard disk drive.
    • If you plan to support deduplication on multiple volumes on the same server, you need to plan an appropriately size for the system to ensure that it can process the data. The general rule is that the server needs 1 CPU-core and 350 MB of free memory to run a deduplication job on a single volume, and that job can process about 100 GB per hour or around 2 TB per day. Deduplication scales with additional CPU core processors and available memory to enable parallel processing of multiple volumes.
    For example: If you have a server with 16 CPU core processors and 16 GB of memory, deduplication uses 25% of the system memory in the default Background Processing mode, and in this case, that would be 4 GB. If you divide by 350 MB, you can calculate that the server could process about 11 volumes at a time. If you add 8 GB of memory, the system could process 17 volumes at a time. If you set an optimization job to run in Throughput mode, the system will use up to 50% of the system’s memory for the optimization job.
    • Data Deduplication supports up to 90 volumes at a time; however, deduplication can simultaneously process one volume per physical CPU core processor plus one. Hyper-threading does not impact this because only physical core processors can be used to process a volume. A system with 16 CPU core processors and 90 volumes will process 17 volumes at a time until all 90 volumes are done, if there is sufficient memory.
    • Virtual server instances should follow the same guidance as physical hardware regarding server resources.
    Volumes
    Volumes that are candidates for deduplication must conform to the following requirements:
    • Must not be a system or boot volume. Deduplication is not supported on operating system volumes.
    • Can be partitioned as a master boot record (MBR) or a GUID Partition Table (GPT), and must be formatted using the NTFS file system.
    • Can reside on shared storage, such as storage that uses a Fibre Channel or an SAS array, or when an iSCSI SAN and Windows Failover Clustering is fully supported.
    • Do not rely on Cluster Shared Volumes (CSVs). You can access data if a deduplication-enabled volume is converted to a CSV, but you cannot continue to process files for deduplication.
    • Do not rely on the Microsoft Resilient File System (ReFS).
    • Can’t be larger than 64 TB in size.
    • Must be exposed to the operating system as non-removable drives. Remotely-mapped drives are not supported.
    Note
    Files with extended attributes, encrypted files, files smaller than 32 KB, and reparse point files are not processed by deduplication.

  • VC3 Not Starting?? - How to fix Win 7 64Bit

    I had problems with this but was able to figure it out..
    Please Like or Thank if it works.. x)
    VC3 seems to have been made for older windows plataforms.
    There is a property on Windows 7 that allows you to "attempt" to run this by Turning OFF DEP.
    It is most likely that this will fix your problem.  How is it that you turn OFF DEP?
    Steps:
    Righ Click "My Computer"
    Click Properties
    Left Hand Panel you will have a option that says: "Advanced System Settings"  - Click it
    System Properties will open up - Make sure that you are under the "Advanced" tab
    First Option will be "Performance Settings"  - Click it
    Click the "Data Execution Prevention" tab
    Choose the Second Option " Turn on DEP for all programs and services except those i select"
    Click "Add"   
    Browse To: C:\Program Files\ Adobe\ Visual Comunicator 3\ Bin\VisualComnicator3.exe    -- Choose the EXE File
    If 64 Bit: C:\Program Files (x86)\ Adobe\ Visual Comunicator 3\ Bin\ VisualComunicator3.exe -- Choose the EXE File
    Make Sure to add both AlphaCG.exe and Visual Communicator.exe to your list
    Click apply -- if it was the firs time you've used this setting make sure to restart the computer before attempting to start VC3.
    You should be able to run VC3 with no problems..
    Why this happens?? usually you need to use this feature of microsoft when running a program with a old engine. Probably Adobe build VC3 around their old engine. As long as it works you should be happy!!
    Don't forget to thanks if it works!!!!

    Hi xXJP.entXx,
    I tried your fix as indicated above and I still get my error messages telling me that VC3 can't determine my video card settings and that I need to be sure they are set as indicated in the error message (which they are).  See the error window screen prints below and then my setting screen prints.
    My display setting screen prints:
    I have even tried setting the screen size to be the 4:3 format with 32 or 16 bit true color and it doesn't seem to make a difference.
    Any other sugggestions/fixes would be appreciated.
    I was planning on showcasing this software tomorrow at the Niagara Falls Public Library to their Teen Librarian Coordinator who is looking to set up a video program for teens.  At the present, I have nothing similar to VC3 to demo, but I do have working software for Windows Live Movie Maker, Avid Studios, Roxio Movie Maker and Adobe Premiere Pro CS5.5.  I'm finding the Adobe Premiere Pro CS5.5 is a bit more complex than the other software mentinoed and its cost may make it out of reach for the library's pilot program.
    I sure wish Adobe would take some of the money from their record last quarter profits and get this VC3 updated to VC4 so that it will work with newer USB camera connections, wide-screen monitors and if possible, HD (although not really necessary)!
    http://www.adobe.com/aboutadobe/pressroom/pressreleases/201112/Q411Earnings.html
    If anyone has any other suggestions, please post ASAP!  Tomorrow is coming quickly and I'd love to showcase VC3 as I believe it will be the best fit for their pilot program!
    Thanks,
    Max

  • MBA 11 (2013) pinch zoom does not work after some time, how to fix it ?

    Recently I purchased MBA 11 (2013) model ( 4GB ram & 1.3 Ghz dual core). Although I use iPhone 5 & iPad 4 but never used mac. So when I found the track pad is capable of pinch zoom(along with other gesture) I was excited. But later I found after opening few apps (like safari, chrome etc) pinch zoom stop working . I need to restart in order to make it work again. Other gestures works fine just issue with the pinch zoom. Along with this issue I have some other questions as well
    1) How to fix this pinch zoom issue?
    2) I use eclipse for android development, but when I connect android phone/tablet - os crashes, no idea why?
    3) How to uninstall & update apps properly which was downloaded from web (like I installed x-code) ?
    4) I want to use mouse (i am comfortable) - I need to know whether right click, wheel, ling click & drag works perfectly.
    5) How to back up the os if something goes wrong I can retrieve from there ?

    Error 2, 4 (or -4), 6, 40, 1000, 9006
    Follow Troubleshooting security software. Often, uninstalling third-party security software will resolve these errors.
    There may be third-party software that modifies your default packet size in Windows by inserting a TcpWindowSize entry into your registry. Your default packet size being set incorrectly can cause these errors. Contact the manufacturer of the software that installed the packet size modification for assistance or follow this article by Microsoft: How to reset Internet Protocol (TCP/IP).
    Verify that access to ports 80 and 443 are allowed on your network.
    Verify that communication to albert.apple.com or photos.apple.com is not blocked by a firewall, or other Internet security setting.
    Discard the .ipsw file, open iTunes and attempt to download the update again. See the steps underAdvanced Steps > Rename, move, or delete the iOS software file (.ipsw) below for file locations.
    Restore your device while connected to a different network.
    Restore using a different computer.
    http://support.apple.com/kb/TS3694#error6

  • How to fix a problem with my book pro that has a gray screen with a folder with a question mark on it

    does any one know how to fix a problem with my book pro that has a gray screen with a folder with a question mark on it?

    Hello Mokhtary123 and welcome to Apple Support Communities,
    It will help us diagnose your problem to know the exact model, size, year built, RAM installed and OS you're running.
    But basically your system can't find the boot disk. Usually this is a symptom of a dead/dying/corrupted hard drive;
    A flashing question mark or globe appears when you start your Mac - Apple Support
    OS X Recovery
    http://support.apple.com/en-us/HT4718

  • Hello, I have a big problem with Firefox: Session Manager & Undo Closed Tab addons are not working, Sync Is not working. History is working. How to fix this?

    Firefox remembers history but doesn't remember closed tabs, sessions.
    It happened after updating Fox to v. 19.0.2 on one computer.
    In Firefox Options is set Use Custom Settings For History, everything is checked except Always Use Private Browsing Mode. So I am not in private browsing.
    When I press on Undo Closed Button nothing happens & in session manager Save Session Button is greyed out. I've tried installing other add-ons that can remember tabs. tried to disable/reinstall these 2 add-ons. Did't help. On my 2nd computer I have same add-ons, same settings and they are working normally. on 3rd computer undo closed tabs works also. How to fix this? I decided to ask before doing Firefox Reset...
    Sync is a separate problem. It works, but quite often it logs me out of Sync account. Then I can log in only using long recovery key and password (choosing option I don't have device with me because it does not accept keys for pairing device.)
    Thanks for reading.

    I have exactly the same settings in Options (in both computers)
    for history, these 2 add-ons and all other stuff in Options. The only difference is that on 1 pc sessions can be saved and closed tabs can be reopened, on other main pc they stopped to work. + no any other add-on that does similar things works on this pc.
    It is also interesting that I can reopen closed visited sites from History Panel, but not by pressing the Button. For now I only manually bookmark links to a temporary folder.
    Recently (some 2 month ago) I pressed x and Firefox closed all tabs without saving them without displaying save & quit pop up.
    so I changed 4 settings in about.config
    browser.tabs.warn on close true
    browser.warn on quit true
    browser.warn on restart true
    browser.show.quit warning true
    but the problem with sessions appeared only 1 week ago.
    So I guess the problem is not with the History settings or other settings. Seems that something responsible for button or for storing info about tabs/sessions got corrupted. :(

  • How to fix a faulty partition table, How to fix a faulty partition table

    I have a 400gb partition on my 500gb HD, the remaining 100gb was split up in 3 partitions. I deleted 2 of these partitions, restarted and now Disk Utility claims my 400gb drive is now 53gb, accessing files has become impossible.
    I can still see all the files listed but am unable to open them or copy them, I get a -36 error.
    I have thrown Disk Utility, DiskWarrior, TechTool Pro and some lesser known tools at it but none of them wants to repair the volume.
    Sounds to me like a busted partition table, after all that was all that was altered, in theory I should be able to access my files. Does anyone have any suggestions on how to fix this?

    Problem solved, I used iPartition to resize the partition back to its original size after which I could copy all data off.

Maybe you are looking for