• Post Reply Bookmark Topic Watch Topic
  • New Topic

JList transparent? Possibility to draw  RSS feed

 
Mathew Mintalm
Ranch Hand
Posts: 103
Eclipse IDE Firefox Browser Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello everyone, I would like to ask you something, im trying to create such transparent panel with possibility to draw rectangles on:



Someone told me that I should list JList to do it, but still i could not figure it out, how to make this jlist transparent with possibility to draw.

Thanks for support
 
Darryl Burke
Bartender
Posts: 5167
11
Java Netbeans IDE Opera
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't see any involvement of JList here. I would guess you misinterpreted advice to use a java.util.List and iterate over the list in a paintComponent override to paint the rectangles.

Some learning resources:
http://download.oracle.com/javase/tutorial/uiswing/index.html
http://download.oracle.com/javase/tutorial/uiswing/painting/index.html
http://download.oracle.com/javase/tutorial/collections/index.html
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!