summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--xmake/core/base/colors.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/xmake/core/base/colors.lua b/xmake/core/base/colors.lua
index 942f1f081..22cfad4e3 100644
--- a/xmake/core/base/colors.lua
+++ b/xmake/core/base/colors.lua
@@ -184,7 +184,7 @@ function colors.rainbow256(index, seed, freq, spread)
index = seed + index / spread
-- make color code
- local code = (freq * index) % 240 + 18
+ local code = math.floor((freq * index) % 240 + 18)
-- make code
return string.format("#%d", code)