I am using the following function to change the colour of the comment delimiter.

Whilst the code works for a dark background, the colour is not changed when using a light background.

(defun delimkl ()
  "Set comment delimiter colour."

  (if (eq 'dark (frame-parameter nil 'background-mode))
      (set-face-attribute 'font-lock-comment-delimiter-face nil
                            :foreground "#00FF00")

    (set-face-attribute 'font-lock-comment-delimiter-face nil
                          :foreground "#004700") ))

1 Answer 1


The code works in both cases as far as I can tell.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.