GNU bug report logs -
#23383
[PATCH] Support completion of color functions in CSS mode
Previous Next
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
Hello Etienne, thanks for the patch.
On Wed, Apr 27, 2016 at 12:48 AM, Etienne Prud'homme
<e.e.f.prudhomme <at> gmail.com> wrote:
> The attached patch adds completion for CSS color functions such as
> `rgb()'. Values were taken from the “CSS Color Module Level 4”.
> It can
> be found at: https://drafts.csswg.org/css-color/#color-type
It will be nice to have completion for those new color functions. Some
feedback regarding the patch follows.
- In the completion definitions we've tried to stay as close as possible
to the structure used in the CSS spec. This means that instead of
introducing `color-functions' we should make `color' complete directly
to "rgb()", "rgba()", and so on, then `hex-color', `named-color' and
the literal `currentcolor' (I think we can skip
`deprecated-system-color'). `named-color' will then contain the
literal color names like `color' does now.
- One of the tests in test/lisp/textmodes/css-mode-tests.el needs
updating. To see this, run `make lisp/textmodes/css-mode-tests' from
the test directory.
- Please wrap lines around column 70 or so to stay in line with the rest
of the file.
> As a sidenote, how should we handle functions? Since they use
> parentheses, the point is going to be outside of parentheses.
>
> Eg.
> rgba()*
> ^(point)
True, I'm not sure how to best solve it.
> Also, should we include the parameters number?
I think that's rather a job for something like ElDoc (I'm currently
working on adding ElDoc support to CSS mode).
-- Simen
[Message part 2 (text/html, inline)]
This bug report was last modified 9 years and 3 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.