A way of getting a corresponding hex colour code given a Color object in Java?

前端 未结 4 1492
北荒
北荒 2020-12-17 22:57

I\'ve inspected the Java class documentation for Color and found that I can generate a Color object from a hex code string (e.g. \"#FFFFFF\") using the Co

4条回答
  •  心在旅途
    2020-12-17 23:31

    Read this: Getting Html color codes with a JColorChooser

    The answer has a method to convert a color to it's hex value.

提交回复
热议问题