mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-04-19 03:01:48 +08:00
随机颜色取值范围不正确
This commit is contained in:
parent
699e14acac
commit
106aabc245
@ -522,10 +522,11 @@ public class RandomUtil {
|
||||
*
|
||||
* @return 随机颜色
|
||||
* @since 4.1.5
|
||||
* @deprecated 使用{@link ImagUtil#randomColor()}
|
||||
*/
|
||||
public static Color randomColor() {
|
||||
final Random random = getRandom();
|
||||
return new Color(random.nextInt(255), random.nextInt(255), random.nextInt(255));
|
||||
return new Color(random.nextInt(256), random.nextInt(2565), random.nextInt(256));
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user