Adding an icon image on a tablecolumn

Hi,
Clicking on my Jtable columns i can order data in ascending or descending way...well...well....I'd like to add a special icon on the column i click, in this way the user can understand better in which way He/She has sorted the data.
Cheers.
Stefano

Hi,
Thank you anyway....this is the answer
http://exampledepot.com/egs/javax.swing.table/IconHead.html
Cheers.
Stefano

Similar Messages

  • Adding Icon / Image on a Submit / ValueHelp button

    Hi:
    Can any one tel me how to add Icon / Image on a Submit / ValueHelp button.
    Thanks
    Vijai

    Vijai,
    Check out Juergen's reply in below thread:-
    Adding Image in Button.
    Chintan

  • How Do I get icons image directory to work in a JAR file?

    Yes, I must admit after going through the tutorial and other stuff I am stiil stumped
    I have an application that uses the jlfgr icons for the toolbar, and it works fine as long as i actually run it from the directory that it is in.
    I would like to put in into a jAr file, and be able to execute it from other places.
    I have a Directory named PhoneBook
    in that are the classes I use
    AddressBook - the main class
    PersonEntry - The 'data class'
    and various other things like FileFilters.....
    inside that directory there are two more:
    images - contains all the icon images
    Data - where the default 'database' entries are stored.
    I use code like this:
         private void fillToolBar( JToolBar bar )
              Dummy = new JButton(new ImageIcon("images/New16.gif"));
              Dummy.setActionCommand("New");
              Dummy.addActionListener(this);
              Dummy.setToolTipText("New");
              bar.add( Dummy );
              // etc etc
    to get all the icons into the toolbar
    I have made a Jar file that has all the classes and all the directorys with the icons in it
    and so the program runs, but does not get the icons for the toolbar, I just get a whole load of 'dud' buttons.....
    AS this is the first time i've ever got the GUI to look right rather than just the code functioning properly
    I'd like to get the whole thing in a working Jar file
    So Could someone show me Step By Step, How I get my classes and images into a Jar file
    so that i can from a different directory go
    java - jar Phone.jar
    and have the GUI come up with all the images, assuming I'm totally thickheaded when it comes to Jar files.?
    I also can't get the images to show up if I merely run the 'program' from another directory than the one it is compiled in
    I can get the program to run, just not access the images with something like
    java -cp blah/blah/blah AddressBook
    {the main class is AddressBook }
    the data directory can be anywhere as I use a JFileChooser to allow the user to open and save desired files.
    I really would appreciate some clear workable help. {though I'm running out of Duke Dollars...}

    What you need is a correct path to the directory
    inside of the jar. This can be accomplished by adding
    a line to your main program like this:
    URL
    url=myProgram.class.getResource("images/New16.gif");
    Dummy = new JButton(new ImageIcon(URL));
    where myProgram.class is the name of the class
    file that contain the main method.
    Hope this helps....
    ;o)
    PS: I don't want your dukes...I got them coming out of
    my ears!
    O.K, that works thank you.
    I put something like:
    for all the 'buttons' in the toolbar
    URL url = null;
    Class ThisClass = this.getClass();
    url=ThisClass.getResource("images/New16.gif");
    Dummy = new JButton(new ImageIcon(url));
    Dummy.setActionCommand("New");
    Dummy.addActionListener(this);
    Dummy.setToolTipText("New Database");
    bar.add( Dummy );
    etc for all the rest of the 'buttons'
    After Reading the API docs on URL's etc I'm still not sure as to why it works, but it does....
    I am able now to place the class files in a jar along with the images and it all works fine
    although now I don't quite follow all my code....................
    I assume that
    url=ThisClass.getResource("images/New16.gif");
    returns some sort of 'relative url ' ???
    Thanks for the help though.

  • How to set folder icon image in OS X Lion?

    I set my folder's icon image in OS X Leopard before, but I don't know how to do that in Lion.  In Leopard you simply copy the icon image from an Info window of a file, and paste that into the folder's icon image in the top left corner of its Info window.  In Lion I don't see the icon of the file in its Info window as a preview, but rather I see only a generic JPG file icon.  Any ideas?

    Can you explain why there was no thumbnail for that file?
    The OS does not create or add thumbnails, previews, nor custom icons to images or other files. Although it displays files with what appears to be a custom icon, it is not part of the file itself; it is created on the fly, just for display. Since it is not part of the file, it does not appear in the Get Info window.
    Back in OS 9 days when you downloaded an image file from the web, either via drag and drop or via the download mechanism, the image file would typically be placed on the drive as a QuickTime image with both a custom icon and a preview image added to it.
    I skipped earlier versions of OS X, and started with Snow Leopard, so don't know about earlier versions of OS X. Apparently the auto creation and addition of a custom icon and preview have been dropped in later versions in favor of using Preview to generate a temporary (for display only) custom icon on the fly. One result of this is that image file sizes are kept reasonably small - adding a suite of custom icons and a preview image to the file itself increases the file size a lot; it's not unusual for those additions to double the file size, or more.

  • How to make an icon image using Photoshop

    I found out how to do this recently so I decided that I wanted to make a tut for those who don't know how to make an icon image. This icon image is for the libraries tab on your computer. Under the libararies tab there is Music, Pictures, Documents, and Photos
    First you will need the ICO (Icon image format) Format extension for photoshop which can be downloaded here:
    http://www.telegraphics.com.au/svn/icoformat/trunk/dist/README.html
    The download link and tutorial on how to install it is all in the link above.
    Once you have that all set you can now launch photoshop to create your icon image. Once you have launched it, create a new document with the size as in the image below.
    [IMG]http://i1297.photobucket.com/albums/ag25/dusty951512/256x256_zpsbf3dcf8e.png~original[/IMG]
    Create the image you want. I used a simple one by using the custom shape tool by pressing "U" on your keyboard and with the
    basic blending options.
    [IMG]http://i1297.photobucket.com/albums/ag25/dusty951512/IconImage_zpsd788c709.png~original[/IMG]
    The reason why the image is pixelated is because it is an icon image. Since the image is only 256x256 pixels when you zoom in on it that will get you the pixely result. The reason why I zoomed  in is so you can see it. But don't worry this is no the end result. Just continue reading and you will see.
    So once you have created the icon go ahead and press
    file>save as>(under format choose the ICO)>and choose the name that you want to name it. And save it in your C: drive. You will see why to save it in your C: drive in a sec.
    [IMG]http://i1297.photobucket.com/albums/ag25/dusty951512/SampleicoPic_zpsd252bfba.png~original[/IMG]
    So now that you have created the icon and saved it now you can create the new library.
    [IMG]http://i1297.photobucket.com/albums/ag25/dusty951512/NewLibrary_zps8ca703b2.png~original[/IMG]
    Name the library whatever you want I named it "Sample" for tutorial purposes. Notice how it gives you a default boring icon image for your library.
    [IMG]http://i1297.photobucket.com/albums/ag25/dusty951512/Sample1_zpsb5472840.png~original[/IMG]
    So now once you have created and named your library now it is time to get the icon image into place.
    Go to computer/c: Drive/users/YOU/ And now once you have reached this area you will need to access a hidden folder named "appdata" to do so press "Alt" then a menu bar will show. Click
    tools>folder options>and view. Find the option to view hidden folders then press apply then ok. Now we shall continue so AppData>Roaming>Microsoft>Windows>Libraries
    Now you should see all the libraries including the one you just created.
    [IMG]http://i1297.photobucket.com/albums/ag25/dusty951512/showhiddenfolder_zpsad4a3c94.png~orig inal[/IMG]
    [IMG]http://i1297.photobucket.com/albums/ag25/dusty951512/Libraries_zpsf6243bc0.png~original[/IMG]
    Once you have reached your destination then open a new text document with notepad and drag the library you just created in notepad. The result should look like this:
    [IMG]http://i1297.photobucket.com/albums/ag25/dusty951512/Notepad_zps251a86f0.png~original[/IMG]
    once you have reached this point click at the end of the second to last line down then press enter and enter in this information
    <iconReference>c:\"NAME OF ICO FILE YOU CREATED IN PS".ico</iconReference>
    Example:
    [IMG]http://i1297.photobucket.com/albums/ag25/dusty951512/iconreference_zps1c1a3eca.png~origina l[/IMG]
    Once you have entered that information go to file>save and the icon image should appear on the library you created.
    [IMG]http://i1297.photobucket.com/albums/ag25/dusty951512/Finished_zps267f893a.png~original[/IMG]
    Now you are officially finished. Go and spread the news and joy. Bye for now
    -Dusty951512

    It is Windows only because all those screen shots are exclusively Windows, the file structure and paths do not resemble those of the Mac in the least.  As a Mac user, there's nothing I could take from your tutorial.  Sorry, 
    No drives named with letters like C: on the Mac, for instance.  No backward slashes either, ever.  No such paths either.  No "Notepad" on the Mac, we use TextEdit; but such a text editor is not remotely needed on the Mac to make and/or edit icons.  Etc.
    Those folders are not even called "Libraries" on the Mac…  Nothing resembling your tutorial at all.
    The icons in the Finder's Sidebar are not customizable at all in recent version of OS X.
    =  =  =
    You can edit any post of yours only until someone replies to it.  At this time your post is not editable by you any longer.

  • I see a distortion icon image in Windows 8.1 but not in windows 8

    I saw distorted icon image in windows 8.1 but not in Windows 8. This bug doesn't affect Windows 8.1 functionality but causes some icons to look ugly, distorted, fuzzy.This bug can be seen in "Delete confirmation dialog box". The
    folder icon in delete confirmation dialog box will look distorted and ugly. Black edges will appear around the icon and the icon will not look correct.The same thing also happens in "Send To" menu.
    Also heard that this bug is not related to graphics card driver or any other thing.
    Hope windows will take necessary actions to solve this bug as soon as possible so that users like us can be satisfied with the new windows 8.1.

    Try running SFC scan. Refer the following link for more information:
    http://support.microsoft.com/kb/929833/en-us
    Balaji Kundalam

  • How to change icon images in Mavericks?

    I am having difficulty changing some Desktop Icon images in Mavericks.
    Some times I can (Macintosh HD), sometimes I cannot (Applications folder or alias), for example.
    Never had problem prior to 10.9

    To change your Applications folder icon:
    In Finder, press shift-command-G, paste in the following and press Go..
    /System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/ApplicationsFol derIcon.icns
    Change the name of ApplicationsFolderIcon.icns to ApplicationsFolderIcon.icns.backup
    Confirm this change by selecting Use .backup and enter your password
    Move the .icns file you want to use for your Applications folder and rename it ApplicationsFolderIcon.icns
    Enter your password when prompted
    Restart your computer, open Terminal, type
    killall Finder
    and press return.
    You should have a new Applications folder icon.
    To revert, delete the new file, change the name of the original file back to ApplicationsFolderIcon.icns and follow the rest of the steps above.
    [NB: This change may not stick through future OS updates]

  • PDF icon images appear on desktop, but not in folders?

    I just updated to Windows 7. Before the update I could only view pdf icons on the desktop and inside folders would be a screenshot pdf icon image of the file. This was very helpful when using a lot of pdf files.
    NOW, after installing Windows 7, I have the exact opposite. I can see PDF image icons on my desktop, but when I go into a folder, I get the standard Adobe pdf red-white icon (no image).
    Has anyone experienced this? Ive googled this and Im not the only one with this problem. Has anyone found a fix for this?
    Thanks
    Update: I forgot to add that PowerPoint files, jpegs and bmp files still work and you can still see the preview images. Just not PDFs.

    function(){return A.apply(null,[this].concat($A(arguments)))}
    ~graffiti wrote:
    What happens if you open an older PDF in Acrobat and do a "save as"? Does the icon come back?
    graffiti - thanks for the reply. I did as you suggested but it didnt work. Now some icons are showing up but I dont know why nor do I know if this is a adobe issue or a windows 7 issues. While googling it looks like each side is blaming the other. Here is a screen shot. Some icons appear and one does not. I opened it and re-saved it but still doesnt show a thumbnail.
    http://img845.imageshack.us/img845/4892/screenshotpdficons.jpg
    Thanks for helping. Any other suggestions?

  • Export Icon/image to Excel in Ce 7.2

    Hi Experts,
    Is it possible to export the Table icon/Image to Excel using CE 7.2. if yes then let me know the process.
    PS: Im able to export the table data to excel.
    Any help will greatly appricated.
    Thanks
    AB

    Hi,
    i think it is noting to with CE, depend on the lib you use poi or jxl
    i think poi should support that
    Hope this is help full for u
    Regards
    Vijay

  • Custom Icon Images for Folders in KM

    Hello Everyody,
                   I have to display folders such as Pesonal Documents, Public documents, Recently used, Favourites etc which are there in the entry point repository in KM. Right now all these folders are being displayed with the default icon image specified. I want to replace these default images with custom images but couldnt see any property where i can change the image path for these folders. I checked the details of all these folders and even went through the properties but there it shows only the default image name speciefied for that folder and no active settings where i can change the image path for custom icon. Kindly suggest how to implement custom image for KM folder icons.
    Thanking you all in advance,
    Regards,
    Sarabjeet.

    Hi,
    If I understood, you have a KM navigation iview, where some folders apperar. You want to change the icon for each of them differently.
    For this do the following:
    First have a look into the KM.navigation iview and get the layout set property. Go to System config->KM->Content management->User interface->Settings->LayoutSet and find the layout set you are using. Go to appropriate resource renderer and check the "<b>Icon setting</b>". Change it to: <b>iconreplace</b>.
    Now get the KM details for your folders and change the <b>IconSource</b> property to your image Example:
    /etc/public/mimes/images/add.gif
    Voila...the icons for these folders are changed!
    Hope this is your case.
    Romano

  • How can I drag and drop an icon/image into a panel??

    Dear Friends:
    How can I drag and drop an icon/image from one panel into another target panel at any position in target panel at my will??
    any good example code available??
    I search for quite a while, cannot find a very good one.
    please help
    Thanks
    Sunny

    [url http://java.sun.com/developer/JDCTechTips/2003/tt0318.html#1]DRAGGING TEXT AND IMAGES WITH SWING

  • Is it possible to put a drop shadow on text added to an image?

    Is it possible to put a drop shadow on text added to an image using Photoshop Elements 10?

    Yes.
    Open the Effects palette. In the drop-down. go to "Drop Shadows." You will find several listed. After you have applied, double click on the f on the text layer in the layers palette. This will bring up the Style Settings. Here you can fine-tune the shadow..
    Note that in the drop-down referenced above, there are also Bevels which may enhance your presentation.

  • Adding an "IMAQ Image.ctl" to the "Display State.ctl" of an XControl prevents LabVIEW from creating a probe of "Display State.ctl"

    I am working on an extended IMAQ Display control using LabVIEWs XControl capabilities.
    I need a copy of the original image passed to add some overlays which must not affect the original image. To achieve this I am creating a backup image in the "Init.vi" and deleting it in the "Uninit.vi". I am storing the reference of this image in the "Display State.ctl" which is part of every XControl.
    As soon as I am adding an "IMAQ Image.ctl" to the Display State cluster, it is no longer possible to generate a probe of the Display State cluster for debugging purposses. I am always getting the message: "Failed to load or create probe."
    Deleting the "IMAQ Image.ctl" from the cluster makes the probe working again.
    Is it a bug or am I doing something wrong?
    I am working with LabVIEW 8.5 and Vision 8.5.
    Regards
    Ingo Bartsch

    Hello Mr. Bartsch,
    is it possible for you to post a small example to reproduce the behaviour? It would be helpful to get a description in which way you use the typedef files.
    I found a example/knowledge base where some informations were included to XControl and LV but not with Vision.
    http://digital.ni.com/public.nsf/allkb/1DC1ADD2A136DA298625712C00635758?OpenDocument
    Best wishes
    Jan Kniewasser
    Jan Kniewasser | Applications Engineer | Tel.: +49 89 7413130 | Fax: +49 89 7146035

  • How get File Type Icon Image

    how get File Type Icon Image (Windows )
    FileSystemView.getSystemIcon( File );works in swing application, can not be used for javafx.scene.image.ImageView;

    Hmm, good question.
    Looking at the FileChooser, it looks like the native chooser is used so possibly the JFX guys didn't have to expose access to the icons to make it work. You might want someone to confirm, but my guess is there is no equivalent yet in JFX.
    Assuming there's nothing, you could try the hacks in here to convert the image: Image conversion between AWT and FX
    Failing that you're probably looking at raising a JIRA feature request to get it in a future release.
    Cheers,
    zonski
    Did you find this answer useful? If so, please mark as 'Correct' or 'Helpful'.

  • Adding/Editing "Old" Images

    A number of DNG images already existed on my HDD prior to installation of LR3. Now I would like to bring them into LR. Only practical way that I have found is, in Library view, to "Move" them from one folder to another folder. Just completed that maneuver for a number of them. I had added five other images, using the "Copy" mode. If I open the catalog called "All Photographs", the five show up as grayed out (already imported).So the following questions suggest themselves:
    Is there a way to import existing images, which does not involve creation of a new folder?
    What could have happened to the catalog created when those were imported?
    Is there a way to re-import an image without duplication?
    tks,
    jwc

    You wrote:
    Is there a way to import existing images, which does not involve creation of a new folder?"
    No, unless you give them different file names. As a general rule, not only for LR, you cannot have 2 files with the same name in one and the same folder.
    If for instance you rename an image file in LR and give it the same name as an already existing one, LR will add the suffix "-1" to the second file.
    "Is there a way to re-import an image without duplication?"
    Why would you want to do that? If it was possible you would replace one image-file with another that has the same name.
    If images are already in the catalog and for some reason you want them twice in LR, you have to do what you did: put them in  adifferent folder.
    WW

Maybe you are looking for

  • Will the MacBook Pro need a SIM card or any type of plan

    I'd like to know if there was a need to put a SIM card or some sort of insert when I get the MacBook . Do I need a plan to operate the laptop ? Aswell as programming ... Will Microsoft word and PowerPoint be included with the system or will I need to

  • Macbook keeps on freezing whole laptop just stops

    My mac has been doing this for about 1 and half weeks now i don't know why it's happening, i'm just useing it like i always do like checking emails, editing videos, looking at the web and then it just stops the only thing i can do is move the mouse,

  • Upgrade Oracle Database From Release 11.1.0.6.0 to Release 11.2.0.1.0

    Dear Experts , I need the procedure to do the upgrade Oracle DB From Release 11.1.0.6.0 to Release 11.2.0.1.0 We have RAC Setup, OS windows 2003 R2 Server Service Pack 2 I have 3 instance Epprod, Epval, Mnlptprod I am using the Same server as an appl

  • Two facts in a single olap

    Hi gurus We r facing a problem with Eis. We are having two fact tables,By using this two fact tables how can we build a Olap Model

  • Copy pix to iPad from PC

    I am new to the iPad. My desktop machine is a Win 7 PC. I have iTunes installed on it. I store pix as JPEGs in various folders on the HD filetree. How do I use the USB wire between Pc and iPod to copy/paste pix from my PC to my iPad? Many thanks. --