How can I make a JTable wider than the cumulation of its columns??

I have a JTable that overrides tableChanged to modify its size based on how many rows and columns it has and adding 16 pixels. Everything works great with adding 16 pixels to the bottom of my table, but when I try to add 16 pixels to the right side, the columns grow to fill the space even though I have AUTO_RESIZE_OFF.
I want there to be 16 pixels between the edge of my last column and the edge of the scroll pane when I have scrolled all the way to the right.
Does anybody know how to do this?? I have been messing with it for hours!
Tonya
P.S. Here is the code so far:
     class AlgoResultsSpreadsheetTable extends JTable {
          AlgoResultsSpreadsheetTable() {
               super();
               setAutoResizeMode(JTable.AUTO_RESIZE_OFF);
               setOpaque(false);
          public void tableChanged(TableModelEvent e) {
               super.tableChanged(e);
               setMinimumSize(new Dimension((getColumnCount() * 75) + 16,
                         (getRowCount() + 1) * 16));
               setPreferredSize(new Dimension((getColumnCount() * 75) + 16,
                         (getRowCount() + 1) * 16));
               JTableHeader header = getTableHeader();
               header.setPreferredSize(
                         new Dimension((getColumnCount() * 75) + 16, 200));
     }

Nevermind... I just figured it out:
               Enumeration<TableColumn> enu = getColumnModel().getColumns();
               while (enu.hasMoreElements()) {
                    TableColumn column = enu.nextElement();
                    column.setPreferredWidth(75);
                    column.setMaxWidth(75);
                    column.setResizable(false);
               }

Similar Messages

  • How can I make my bookmarks menu (NOT the toolbar) into two columns?

    I have to scroll up and down because I have a lot of bookmarks which can be annoying. It would be nice if I could make them into multiple vertical columns. Thanks guys.

    Multicolumn Bookmarks extension <br />
    https://addons.mozilla.org/en-US/firefox/addon/74381/

  • How can i make voiceover read paragraphs than reading the entire page

    how can i make voiceover read paragraphs than reading the entire page of an ebook

    If you are using rectangle as layer or accordion menu then you can use 100% width for these page items.
    In control strip options , when you select the rectangle you can view 100% width button which would make it browser width.
    http://tv.adobe.com/watch/muse-feature-tour/muse-design-for-flexible-browser-width/
    Thanks,
    Sanjit

  • I only see the phone numbers of my contacts when using iMessage on my MAC, whereas I see the names on my iPhone. Why, and how can I make it so I see the names (and pics) on my MAC?

    I only see the phone numbers of my contacts when using iMessage on my MAC, whereas I see the names on my iPhone. Why, and how can I make it so I see the names (and pics) on my MAC?

    Thanks Eric, but that was already turned on. I just now tried turning it off and on again, no change. Actually, I"m more interested in seeing the names than the pictures. I now only see the phone numbers and generic avatars where pics would be.

  • When i burn videos to a dvd-r disc it works on my macbook but not on a windows/pc or my dvd player. How can i make it work on all the above and not just a mac product?

    when i burn videos to a dvd-r disc it works on my macbook but not on a windows/pc or my dvd player. How can i make it work on all the above and not just a mac product?

    Unfortunately, the recording & movie industry does not respect the rights of the people who make them money, and thus you can only use the paid-for content in ways they see fit. Even if I lived in a bunker where no one else could possibly see the movie I paid for, therefor I'm not 'sharing it illegally', I would still not be allowed in a blue moon to copy that movie to DVD for TV viewing. Someone will tell you to get an AppleTV. How about Apple give us one for free? Until this changes, people wanting to use their content in multiple locations will continue to download music & movies via torrents, legally or illegally.

  • How can you make your persona show on the top and bottom? Also can you make it bigger at the top to show more of the picture?

    How can you make your persona show on the top and bottom?
    Also can you make it bigger at the top to show more of the picture?

    Add extra empty toolbars if you want to see more of the persona.<br />
    You can create extra toolbars to get extra space via View > Toolbars > Customize<br />
    You have to put something on a toolbar (drag a Space item onto it) before closing the Customize window because empty toolbars are automatically removed.<br />
    See http://kb.mozillazine.org/Toolbar_customization

  • How can I make a survey automatically identify the user in the results?

    How can I make a survey automatically identify the user in the results (so that it won't be anonymous)?

    I am not sure what information to provide.  Here is what I am trying to do.  I am trying to create an HR questionnaire with multiple choice questions and several multiline textboxes to capture comments.  I want to send it out by email address and/or embed the questionnaire somewhere on the company's intranet website.  But we don't want the questionnaire to be anonymous. If someone makes a particular comment, we want to be able to communicate with the person who made that particular comment.  How would we be able to trace the person? By email address, or by user ID?

  • How can I move a title longer than the screen, no the page but just the title in FCP X?

    How can I move a title longer than the screen, not the page but just the title in FCP X?

    Select the title clip in the Timeline, Then Transform. Either click and drag or use the Inspector Position parameters to adjust.
    Russ

  • How can I make an appointment to see the staff to repair

    How can I make an appointment to see the staff to repair

    If in US
    http://www.apple.com/retail/storelist/

  • How can I make Calen Mob pick up the right colors

    How can I make Calen Mob pick up the right colors from Google Calendar. In fact, how can I contact the developer that made Calen Mob Pro. I hear it was Blue tag but they either sold it or dropped it because they make no claim for it.  Does anyone kknow of a group calendar for IOS that will report the color choices as well as the  data? Calenmob Pro just brings in one color for every date and appt. Thanks!

    Where did you get LR2.2? The most recent public version is LR2.1!
    Try an external EXIF reader like EXIFReader.
    Don

  • Realtek network card seems to be disappeared. how can i make it visible again for the OS?

    i can't access my LAN card. somehow it is disappeared. how can i make it visible again for the OS? my OS is windows 7. thanks very much for your help

    right click on the button bar, then select "customize toolbar", drag any button you like into the toolbar and you're done!
    Diego

  • How can I make an image placed in the body tag expand to the entire width of the browser?

    How can I make an image placed in the body tag expand to the entire width of the browser?I

    background-repeat -- best used with small image tiles.
    background-gradient  - Ultimate CSS Gradient Generator - ColorZilla.com
    background-size:cover - Resizable Full Page Background Image
    Nancy O.

  • TS4293 How can I make iMovie to show me the AVCHD files importet by iPhoto?

    My iMovie 11 shows the videos from my iPhone importet by iPhoto, but not all the videos importet the same way from my camera. It works fine with the videos recorded in MP4 but not at all with the AVCHD. How can I make iMovie to show me the AVCHD files? iPhoto imports and shows the AVCHD fine. Also I could import the AVCHD files with iMovie but then they would be twice on my computer and use a  lot of space.
    thanks for your help

    Right now, iMovie won't edit AVCHD wrapped files. You have a few options:
    1. Import the videos with iMovie. Afterwards, you may add the imported movies to iPhoto if you want.
    2. Import the videos with another app. (Too numerous to mention.)
    3. Convert the videos with a third-party tool.
    4. Wait for a future version of iMovie that adds this capability.

  • Everything on all the webpages are so small, and only take up half the screen. How can I make it bigger, without changing the settings on my computer and by that change the size of everything on my computer.

    Everything on all the webpages are so small, and only take up half the screen. How can I make it bigger, without changing the settings on my computer and by that change the size of everything on my computer.

    The Firefox [https://support.mozilla.com/en-US/kb/Page+Zoom Page Zoom] feature does a domain by domain level of saving the users preferred zoom level settings, there is no default Page Zoom level setting in Firefox, as with some other browsers.
    Try the Default FullZoom Level extension: <br />
    https://addons.mozilla.org/en-US/firefox/addon/6965
    Or the NoSquint extension: <br />
    https://addons.mozilla.org/en-US/firefox/addon/2592/

  • How can I make my Apple tv play the music I am listening on my iMac?

    How can I make my Apple tv play the  music I am listening on my iMac? The idea is having same music in two rooms.

    Welcome to the Apple Community.
    In the lower RH corner of iTunes is the Airplay device selctor.
    Click on it, select multiple speakers and check the computer and Apple TV from the list.

Maybe you are looking for

  • CCM help

    Hi SRM Gurus,   I had a query regarding the transfer of product master to CCM.How do i transfer the products from SRM/R/3 to CCM?ALso how is my delta load enabled for the producst already in CCM? Please can nay one give a detailed confiuration docume

  • Contact name is wrong in the invoice print out

    Hi folks, contact person name is wrong in the invoice pint out,but in sales doc the sales group number and name is correct. what is the solution for tha above issue? Regards srinivas

  • JMS Cache Sync - is multicast used for

    I wanted to verify whether or not the JMS clustering service was using mutlicast for initial discovery of other cache instances in the cluster environment or not. Thanks for any assistance.

  • IOS 5 to iOS 6 - will i loose data on my iPhone?

    Hi, I am planning for an official upgrade from iOS 5 to iOS 6, so wondering if i loose my messages and other data from my iPhone. I am not in a position to backup my iPhone as the iTunes is not recognizing my phone, it prompts me to format my phone t

  • Why do my recurring calender entries keep getting deleted?

    Good Morning People, I've got a user who can't create a recurring calendar entry (set to recur everyday) without the entry being deleted automatically a few seconds later, i've tried various things, managed settings, reboot the device, added the prof