(set-face-attribute 'hl-line nil
(cl-case (alist-get 'background-mode (frame-parameters))
('light ; darker percent 5%
:background (color-darken-name (face-background 'highlight) 5)
)
('dark
:background (color-lighten-name (face-background 'default) 3)
))
)
The upper code does not work. I hope some one can correct this code.