Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-5095570

Color object should return a hex via some method like getHex()

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Won't Fix
    • Icon: P4 P4
    • None
    • 6
    • client-libs
    • x86
    • windows_xp

      Name: gm110360 Date: 09/01/2004


      A DESCRIPTION OF THE REQUEST :
      I use Color objects all the time and have always wondered why there wan't a getHex() method or something to allow a web developer to get the color value in that form.

      JUSTIFICATION :
      It would have many other steps to convert the same outside of the core language (plus it just makes sense)

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      I could do something like this:
      Color r = new Color("#ff0000");
      or
      Color r = Color.DARK_GRAY;
      String hexValue = r.getHex();

      CUSTOMER SUBMITTED WORKAROUND :
      Write my own methods to handle this...
      (Incident Review ID: 301647)
      ======================================================================

            dav Andrei Dmitriev (Inactive)
            gmanwanisunw Girish Manwani (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: