Add overlay and background
These were heavily inspired by ocodo-svg-modelines
This commit is contained in:
parent
4884fe70e6
commit
474961355d
1 changed files with 32 additions and 0 deletions
|
@ -177,8 +177,40 @@
|
|||
'(:fill "#ccc" :font-family "Fantasque Sans" :filter nil
|
||||
:font-weight "bold" :font-style "italic"))
|
||||
|
||||
(defun oni-smt-background (theme)
|
||||
""
|
||||
(let ((stops '(("0%" "#484848" 0.3)
|
||||
("25%" "#484848" 0.3)
|
||||
("75%" "#484848" 0.3)
|
||||
("100%" "#111111" 0.3))))
|
||||
`((\defs
|
||||
(linearGradient
|
||||
:id "twisted" :x1 "0%" :y1 "0%" :x2 "100%" :y2 "25%"
|
||||
(stop :offset ,(first (nth 1 stops)) :stop-color ,(second (nth 1 stops)) :stop-opacity ,(third (nth 1 stops)))
|
||||
(stop :offset ,(first (nth 2 stops)) :stop-color ,(second (nth 2 stops)) :stop-opacity ,(third (nth 2 stops)))
|
||||
(stop :offset ,(first (nth 3 stops)) :stop-color ,(second (nth 3 stops)) :stop-opacity ,(third (nth 3 stops)))
|
||||
(stop :offset ,(first (nth 4 stops)) :stop-color ,(second (nth 4 stops)) :stop-opacity ,(third (nth 4 stops)))))
|
||||
(rect :width "100%" :height "100%" :x 0 :y 0 :fill "url(#twisted)"))))
|
||||
|
||||
(defun oni-smt-overlay (_)
|
||||
""
|
||||
(let ((stops '(("0%" "#FFFFFF" 0.1)
|
||||
("20%" "#111111" 0.0)
|
||||
("90%" "#111111" 0.5)
|
||||
("100%" "#111111" 0.8))))
|
||||
`((\defs
|
||||
(linearGradient
|
||||
:id "over-gradient" :x1 "0%" :y1 "0%" :x2 "0%" :y2 "100%"
|
||||
(stop :offset ,(first (nth 1 stops)) :stop-color ,(second (nth 1 stops)) :stop-opacity ,(third (nth 1 stops)))
|
||||
(stop :offset ,(first (nth 2 stops)) :stop-color ,(second (nth 2 stops)) :stop-opacity ,(third (nth 2 stops)))
|
||||
(stop :offset ,(first (nth 3 stops)) :stop-color ,(second (nth 3 stops)) :stop-opacity ,(third (nth 3 stops)))
|
||||
(stop :offset ,(first (nth 4 stops)) :stop-color ,(second (nth 4 stops)) :stop-opacity ,(third (nth 4 stops)))))
|
||||
(rect :width "100%" :height "100%" :x 0 :y 0 :fill "url(#over-gradient)"))))
|
||||
|
||||
(smt/deftheme oni-smt
|
||||
:prototype 'black-crystal
|
||||
:overlay 'oni-smt-overlay
|
||||
:background 'oni-smt-background
|
||||
:local-widgets (list (cons 'major-mode
|
||||
(smt/make-widget
|
||||
:prototype 'major-mode
|
||||
|
|
Loading…
Reference in a new issue