diff options
author | Mattias EngdegÄrd <mattiase@acm.org> | 2020-06-12 18:12:37 +0200 |
---|---|---|
committer | Mattias EngdegÄrd <mattiase@acm.org> | 2020-06-21 21:22:26 +0200 |
commit | 9fe2bdb88a4ebd4b2286c1c2a2a2ba7411af01b6 (patch) | |
tree | 0979ec4f38172e25a0420eca5b22650c249a80f4 /lisp/erc/erc-lang.el | |
parent | 0792f8e4f0de2328c57d552a5845bdf77265a971 (diff) | |
download | emacs-9fe2bdb88a4ebd4b2286c1c2a2a2ba7411af01b6.tar.gz emacs-9fe2bdb88a4ebd4b2286c1c2a2a2ba7411af01b6.tar.bz2 emacs-9fe2bdb88a4ebd4b2286c1c2a2a2ba7411af01b6.zip |
Consolidate #RGB string parsers
Use a single parser of color strings in the #RGB, rgb:R/G/B and
rgbi:R/G/B formats, replacing four existing ones. Previously,
error-checking was spotty, handling of the rgbi: format not always
present, and normalization of the result was sometimes incorrect.
* src/dispextern.h: New prototype.
* src/xfaces.c (parse_hex_color_comp, parse_float_color_comp)
(parse_color_spec, Finternal-color_values_from_color_spec): New functions.
* test/src/xfaces-tests.el (xfaces-internal-color-values-from-color-spec):
New test.
* lisp/term/tty-colors.el (tty-color-standard-values):
Use internal-color-values-from-color-spec, replacing old parser.
* src/nsterm.m (ns_get_color):
* src/w32fns.c (x_to_w32_color):
* src/xterm.c (x_parse_color): Use parse_color_spec, replacing old
parsers.
(HEX_COLOR_NAME_LENGTH): Remove #define.
Diffstat (limited to 'lisp/erc/erc-lang.el')
0 files changed, 0 insertions, 0 deletions