1. /*
  2. * @(#)ColorUIResource.java 1.8 01/11/29
  3. *
  4. * Copyright 2002 Sun Microsystems, Inc. All rights reserved.
  5. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
  6. */
  7. package javax.swing.plaf;
  8. import java.awt.Color;
  9. import javax.swing.plaf.UIResource;
  10. /*
  11. * A subclass of Color that implements UIResource. UI
  12. * classes that create colors should use this class.
  13. * <p>
  14. * <strong>Warning:</strong>
  15. * Serialized objects of this class will not be compatible with
  16. * future Swing releases. The current serialization support is appropriate
  17. * for short term storage or RMI between applications running the same
  18. * version of Swing. A future release of Swing will provide support for
  19. * long term persistence.
  20. *
  21. * @see javax.swing.plaf.UIResource
  22. * @version 1.8 11/29/01
  23. * @author Hans Muller
  24. *
  25. */
  26. public class ColorUIResource extends Color implements UIResource
  27. {
  28. public ColorUIResource(int r, int g, int b) {
  29. super(r, g, b);
  30. }
  31. public ColorUIResource(int rgb) {
  32. super(rgb);
  33. }
  34. public ColorUIResource(float r, float g, float b) {
  35. super(r, g, b);
  36. }
  37. public ColorUIResource(Color c) {
  38. super(c.getRed(), c.getGreen(), c.getBlue());
  39. }
  40. }