소스 검색

org.el: Only set org-hide foreground if one is available

* org.el (org-mode): Add guard around set-face-foreground.

TINYCHANGE
Nikolai Weibull 11 년 전
부모
커밋
2d09804e19
1개의 변경된 파일3개의 추가작업 그리고 1개의 파일을 삭제
  1. 3 1
      lisp/org.el

+ 3 - 1
lisp/org.el

@@ -5431,7 +5431,9 @@ The following commands are available:
      (unless org-inhibit-startup-visibility-stuff
        (org-set-startup-visibility))))
   ;; Try to set org-hide correctly
-  (set-face-foreground 'org-hide (org-find-invisible-foreground)))
+  (let ((foreground (org-find-invisible-foreground)))
+    (if foreground
+        (set-face-foreground 'org-hide foreground))))
 
 ;; Update `customize-package-emacs-version-alist'
 (add-to-list 'customize-package-emacs-version-alist