color_name 116 lib/tty/color-internal.c parse_256_or_true_color_name (const char *color_name) color_name 122 lib/tty/color-internal.c if (sscanf (color_name, "color%d%c", &i, &dummy) == 1 && i >= 0 && i < 256) color_name 127 lib/tty/color-internal.c if (sscanf (color_name, "gray%d%c", &i, &dummy) == 1 && i >= 0 && i < 24) color_name 131 lib/tty/color-internal.c if (strncmp (color_name, "rgb", 3) == 0 && color_name 132 lib/tty/color-internal.c color_name[3] >= '0' && color_name[3] < '6' && color_name 133 lib/tty/color-internal.c color_name[4] >= '0' && color_name[4] < '6' && color_name 134 lib/tty/color-internal.c color_name[5] >= '0' && color_name[5] < '6' && color_name[6] == '\0') color_name 136 lib/tty/color-internal.c return 16 + 36 * (color_name[3] - '0') + 6 * (color_name[4] - '0') + (color_name[5] - '0'); color_name 138 lib/tty/color-internal.c if (color_name[0] == '#') color_name 142 lib/tty/color-internal.c color_name++; color_name 143 lib/tty/color-internal.c len = (int) strlen (color_name); color_name 150 lib/tty/color-internal.c h[i] = parse_hex_digit (color_name[i]); color_name 198 lib/tty/color-internal.c tty_color_get_index_by_name (const char *color_name) color_name 200 lib/tty/color-internal.c if (color_name != NULL) color_name 205 lib/tty/color-internal.c if (strcmp (color_name, color_table[i].name) == 0) color_name 207 lib/tty/color-internal.c return parse_256_or_true_color_name (color_name); color_name 52 lib/tty/color-internal.h int tty_color_get_index_by_name (const char *color_name);