Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions afmt.odin
Original file line number Diff line number Diff line change
Expand Up @@ -1811,9 +1811,9 @@ rgb_to_8bit :: proc(rgb: RGB) -> (color: u8) {
case {128, 255, 255}: return 14
case {255, 255, 255}: return 15
case:
for color in u8(232)..=u8(255) {
if rgb == {008, 008, 008} + ((color - 232) * 10) {
return color
for _color in u8(232)..=u8(255) {
if rgb == {008, 008, 008} + ((_color - 232) * 10) {
return _color
}
}
}
Expand Down
2 changes: 0 additions & 2 deletions afmt_posix.odin
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
#+build !windows
package afmt

import "core:sys/posix"

@(private)
_set_utf8_terminal :: proc() {}

Expand Down
4 changes: 2 additions & 2 deletions colors.odin
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ print_color_guide :: proc(groups: bit_set[Color_Group] = {.all}, bg := true) {
}
cols[1].ansi = cols[0].ansi
cols[2].ansi = cols[0].ansi
name := tprintf(" %s", color_name_from_enum(id))
name = tprintf(" %s", color_name_from_enum(id))
rgb := tprintf("%3i %3i %3i", c.r, c.g, c.b)
hsl_ := hsl(c)
hsls := tprintf("%6.2f %.2f %.2f", hsl_[0], hsl_[1], hsl_[2])
Expand Down Expand Up @@ -117,7 +117,7 @@ print_color_guide_ex :: proc(groups: bit_set[Color_Group] = {.all}, bg := true,
}
cols[1].ansi = cols[0].ansi
cols[2].ansi = cols[0].ansi
name := tprintf(" %s", color_name_from_enum(id))
name = tprintf(" %s", color_name_from_enum(id))
rgb := tprintf("%3i %3i %3i", c.r, c.g, c.b)
hsl_ := hsl(c)
hsls := tprintf("%6.2f %.2f %.2f", hsl_[0], hsl_[1], hsl_[2])
Expand Down