Hi All,
  I am developing a swing application using JDK 1.3.  I have created a
JTree and I have written these lines of code to change the icons shown in
the tree.

  DefaultTreeCellRenderer renderer = new DefaultTreeCellRenderer() ;

  renderer.setLeafIcon(new ImageIcon("leaf.ico")) ;
  renderer.setClosedIcon(new ImageIcon("closed.ico")) ;
  renderer.setOpenIcon(new ImageIcon("open.ico")) ;
  
  tree.setCellRenderer(renderer) ;


  The above lines were taken from the Sun Java Tutorial. The icons are in
the same directory in which the .java and .class files exists. What is the
problem? The default icons are not displayed but these icons are also not
displayed.

Can anyone help me in this matter.

waiting for a reply.

-------------------------------------------------------------------------------
Kirubakaran S
NCST

Mail me at:
===========
[EMAIL PROTECTED]



_______________________________________________
Swing mailing list
[EMAIL PROTECTED]
http://eos.dk/mailman/listinfo/swing

Reply via email to