hexdd[] is defined in decl.c */
| 798 | |
| 799 | /* hexdd[] is defined in decl.c */ |
| 800 | boolean |
| 801 | onlyhexdigits(const char *buf) |
| 802 | { |
| 803 | const char *dp = buf; |
| 804 | |
| 805 | for (dp = buf; *dp; ++dp) { |
| 806 | if (!(strchr(hexdd, *dp) || *dp == '-')) |
| 807 | return FALSE; |
| 808 | } |
| 809 | return TRUE; |
| 810 | } |
| 811 | |
| 812 | int32_t |
| 813 | rgbstr_to_int32(const char *rgbstr) |