Color Utils v1.2.0
This is the third public release of the library, it has been heavily tested but please feel free to report any issues found.
To add it as a…
Read MorePublished 02/20/2023 Updated 02/26/2023
ColorUtils is a small collection of utility functions to deal with coloring on Java.
Color setAlpha(Color color, int alpha);// Set the alpha value of a Color objectColor setAlpha(Color color, double alpha);// Set the alpha value of a Color objectint pack(int r, int g, int b);// Pack RGB color values into an integerdouble getDifference(Color colorA, Color colorB);// Compare two colors and return the difference between the color valuesString getHex(Color color);// Generate a hex color code from a Color objectString getHex(int rgbColor);// Generate a hex color code from an RGB integerColor fromHex(String hexColorCode);// Generate a new Color instance from a hex color codeAdd the following to your pom.xml as a maven dependency, or just download the latest release and import it with your IDE.
<dependency>
<groupId>com.konloch</groupId>
<artifactId>ColorUtils</artifactId>
<version>1.2.0</version>
</dependency>
The library is so tiny, take a look for yourself. Click here to view the source.
This is the third public release of the library, it has been heavily tested but please feel free to report any issues found.
To add it as a…
Read MoreThis is the second public release of the library, it has been heavily tested but please feel free to report any issues found.
To add it as a…
Read MoreThis is the first public release of the library, it has been heavily tested but please feel free to report any issues found.
To add it as a…
Read More