Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Each Item With Different text Color in a combox

 
Muhammad Ahsan Jamshaid
Ranch Hand
Posts: 59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
HI..
i am Using combobox for the selecting font color Selection... i want to display each Color in combobox with same the font color as its name... like Pink Text should be in Pink Color and Red Should be displayed with RED with Red Text Color in the Combobox...
Any Idea or Clue...... Surely awaiting some good solution..
--Jamshaid..
 
Michael Dunn
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
this might be one way

 
Muhammad Ahsan Jamshaid
Ranch Hand
Posts: 59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks... It Worked......
--Jamhaid..
 
Muhammad Ahsan Jamshaid
Ranch Hand
Posts: 59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
My concepts regarding Playing with renderer class is week.. can any one refer me a good link or notes to study...

--Jamshaid..
 
Michael Dunn
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
doesn't look like there's a lot, but this has some info.
some of the examples on the page might be worth going through.

http://java.sun.com/docs/books/tutorial/uiswing/components/combobox.html#renderer
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic