]> code.delx.au - gnu-emacs/blobdiff - lisp/org/org-entities.el
; * lisp/emacs-lisp/derived.el (derived-mode-make-docstring):
[gnu-emacs] / lisp / org / org-entities.el
index 3670f3651378feaa68884c6d703e13ff9c681fcd..f8f218f6f55ea4091f08ce6870f5c877af03a0ce 100644 (file)
@@ -1,6 +1,6 @@
 ;;; org-entities.el --- Support for special entities in Org-mode
 
-;; Copyright (C) 2010-2014 Free Software Foundation, Inc.
+;; Copyright (C) 2010-2015 Free Software Foundation, Inc.
 
 ;; Author: Carsten Dominik <carsten at orgmode dot org>,
 ;;         Ulf Stegemann <ulf at zeitform dot de>
@@ -27,9 +27,8 @@
 
 ;;; Code:
 
-(require 'org-macs)
-
-(declare-function org-table-align "org-table" ())
+(declare-function org-toggle-pretty-entities "org"       ())
+(declare-function org-table-align            "org-table" ())
 
 (eval-when-compile
   (require 'cl))
@@ -568,6 +567,7 @@ Kind can be any of `latex', `html', `ascii', `latin1', or `utf8'."
     (goto-char pos)
     (org-table-align)))
 
+(defvar org-pretty-entities) ;; declare defcustom from org
 (defun org-entities-help ()
   "Create a Help buffer with all available entities."
   (interactive)
@@ -598,7 +598,9 @@ Kind can be any of `latex', `html', `ascii', `latin1', or `utf8'."
          (princ (format "   %-8s \\%-16s %-22s %-13s\n"
                         utf8 name latex html))))))
   (with-current-buffer "*Org Entity Help*"
-    (org-mode))
+    (org-mode)
+    (when org-pretty-entities
+      (org-toggle-pretty-entities)))
   (select-window (get-buffer-window "*Org Entity Help*")))