Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Pick recently selected colors in java

I would like to add a color picker dialog to my app that remembers recently selected colors, so that it's easy to pick the exact same color as before, instead of getting several slight variations of a color.

I've tried but I couldn't do this with the standarard JColorChooser. JColorChooser has a recent-color panel in some look&feels (motif), but not in others (gtk). Also, there doesn't seem to be a way to prepopulate the set of recent colors, so there is no way to remember state.

What I would really like is an open source library with a better swing-based color picker solution. It has to be compatible with Java 5.

like image 949
amarillion Avatar asked Nov 15 '22 15:11

amarillion


1 Answers

Have you tried looking at the Tutorial's section "Creating a Custom Chooser Panel"? It looks like to can create a custom panel of saved selections either as a new panel or as part of other panels.

like image 159
Kathy Van Stone Avatar answered Dec 24 '22 07:12

Kathy Van Stone