diff options
| author | Paul Eggert | 2016-01-30 11:27:34 -0800 |
|---|---|---|
| committer | Paul Eggert | 2016-01-30 11:27:34 -0800 |
| commit | 82b089783e71b2aeef950eaecfe4cbc0735e64a2 (patch) | |
| tree | a826c20768071bda95a69b2632718c1641c6d0cc /lisp/htmlfontify.el | |
| parent | d27c8078ef766dae3587bc82b70128a70efaa223 (diff) | |
| parent | f7dc6d8b5bb318e02a4016d93f8b34de0716f4dc (diff) | |
| download | emacs-82b089783e71b2aeef950eaecfe4cbc0735e64a2.tar.gz emacs-82b089783e71b2aeef950eaecfe4cbc0735e64a2.zip | |
-
Diffstat (limited to 'lisp/htmlfontify.el')
| -rw-r--r-- | lisp/htmlfontify.el | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/lisp/htmlfontify.el b/lisp/htmlfontify.el index 964d7440332..431300c81c2 100644 --- a/lisp/htmlfontify.el +++ b/lisp/htmlfontify.el | |||
| @@ -1001,7 +1001,7 @@ merged by the user - `hfy-flatten-style' should do this." | |||
| 1001 | (append | 1001 | (append |
| 1002 | parent | 1002 | parent |
| 1003 | (hfy-face-to-style-i | 1003 | (hfy-face-to-style-i |
| 1004 | (hfy-face-attr-for-class v hfy-display-class)) )))) | 1004 | (hfy-face-attr-for-class v hfy-display-class)))))) |
| 1005 | (setq this | 1005 | (setq this |
| 1006 | (if val (case key | 1006 | (if val (case key |
| 1007 | (:family (hfy-family val)) | 1007 | (:family (hfy-family val)) |
| @@ -1020,7 +1020,7 @@ merged by the user - `hfy-flatten-style' should do this." | |||
| 1020 | (:italic (hfy-slant 'italic)))))) | 1020 | (:italic (hfy-slant 'italic)))))) |
| 1021 | (setq that (hfy-face-to-style-i next)) | 1021 | (setq that (hfy-face-to-style-i next)) |
| 1022 | ;;(lwarn t :warning "%S => %S" fn (nconc this that parent)) | 1022 | ;;(lwarn t :warning "%S => %S" fn (nconc this that parent)) |
| 1023 | (nconc this that parent))) ) | 1023 | (nconc this parent that))) ) |
| 1024 | 1024 | ||
| 1025 | (defun hfy-size-to-int (spec) | 1025 | (defun hfy-size-to-int (spec) |
| 1026 | "Convert SPEC, a CSS font-size specifier, to an Emacs :height attribute value. | 1026 | "Convert SPEC, a CSS font-size specifier, to an Emacs :height attribute value. |
| @@ -1058,13 +1058,19 @@ haven't encountered them yet. Returns a `hfy-style-assoc'." | |||
| 1058 | (nconc r (hfy-size (if x (round n) (* n 1.0)))) )) | 1058 | (nconc r (hfy-size (if x (round n) (* n 1.0)))) )) |
| 1059 | 1059 | ||
| 1060 | (defun hfy-face-resolve-face (fn) | 1060 | (defun hfy-face-resolve-face (fn) |
| 1061 | "For FN return a face specification. | ||
| 1062 | FN may be either a face or a face specification. If the latter, | ||
| 1063 | then the specification is returned unchanged." | ||
| 1061 | (cond | 1064 | (cond |
| 1062 | ((facep fn) | 1065 | ((facep fn) |
| 1063 | (hfy-face-attr-for-class fn hfy-display-class)) | 1066 | (hfy-face-attr-for-class fn hfy-display-class)) |
| 1067 | ;; FIXME: is this necessary? Faces can be symbols, but | ||
| 1068 | ;; not symbols refering to other symbols? | ||
| 1064 | ((and (symbolp fn) | 1069 | ((and (symbolp fn) |
| 1065 | (facep (symbol-value fn))) | 1070 | (facep (symbol-value fn))) |
| 1066 | (hfy-face-attr-for-class (symbol-value fn) hfy-display-class)) | 1071 | (hfy-face-attr-for-class |
| 1067 | (t nil))) | 1072 | (symbol-value fn) hfy-display-class)) |
| 1073 | (t fn))) | ||
| 1068 | 1074 | ||
| 1069 | 1075 | ||
| 1070 | (defun hfy-face-to-style (fn) | 1076 | (defun hfy-face-to-style (fn) |