2007-10-21 Dan Nicolaescu <dann@ics.uci.edu>
+ * emulation/edt-mapper.el (function-key-map):
+ (edt-map-key): Make it a function instead of using fset. Inline
+ edt-gnu-map-key and edt-lucid-map-key. Use featurep 'xemacs.
+ (edt-gnu-map-key, edt-lucid-map-key): Remove.
+ (edt-x-emacs-p): Remove.
+ (edt-emacs-variant, edt-window-system, edt-xserver):
+ Use featurep 'xemacs.
+
+ * net/eudc.el: Use (featurep 'xemacs) instead of the string test.
+ Replace eudc-xemacs-p with its definition.
+ (eudc-xemacs-p, eudc-emacs-p, eudc-xemacs-mule-p)
+ (eudc-emacs-mule-p): Remove.
+ (eudc-install-menu, eudc-mode): Replace eudc-emacs-p and
+ eudc-xemacs-p with feature tests.
+
+ * net/eudc-bob.el (eudc-bob-generic-menu, eudc-bob-mail-keymap)
+ (eudc-bob-url-keymap, eudc-bob-sound-keymap)
+ (eudc-bob-generic-keymap, eudc-bob-popup-menu)
+ (eudc-bob-toggle-inline-display):
+ * net/eudc-hotlist.el (eudc-hotlist-emacs-menu): Replace
+ eudc-emacs-p and eudc-xemacs-p with feature tests.
+
+ * net/eudcb-ph.el (eudc-ph-open-session): Replace
+ eudc-xemacs-mule-p with its former definition.
+
+ * progmodes/octave-mod.el (octave-xemacs-p): Remove.
+ (octave-abbrev-start): Replace octave-xemacs-p with
+ (featurep 'xemacs).
+
+ * progmodes/vera-mode.el (vera-xemacs): Remove.
+ (vera-mode-syntax-table): Replace vera-xemacs with
+ (featurep 'xemacs).
+
+ * progmodes/vhdl-mode.el (vhdl-xemacs): Remove.
+ (vhdl-doc-mode, vhdl-doc-variable, vhdl-compile-init)
+ (vhdl-speedbar-initialize, vhdl-ps-print-init)
+ (vhdl-forward-comment, vhdl-mode-map-init, vhdl-show-messages)
+ (vhdl-emacs-22, vhdl-emacs-21): Replace vhdl-xemacs
+ with (featurep 'xemacs).
+
+ * progmodes/antlr-mode.el (cond-emacs-xemacs-macfn, defunx)
+ (save-buffer-state-x):
+ * obsolete/fast-lock.el (fast-lock-verbose):
+ * emulation/viper-init.el (viper-xemacs-p)
+ (viper-cond-compile-for-xemacs-or-emacs):
+ * emacs-lisp/checkdoc.el (checkdoc-minor-mode-map):
+ * ps-print.el (case-fold-search):
+ * ediff-hook.el (ediff-cond-compile-for-xemacs-or-emacs):
+ * calculator.el (calculator-help): Use featurep 'xemacs.
+
* progmodes/prolog.el: Undo previous change.
(comint-prompt-regexp, comint-process-echoes): Pacify
byte-compiler.
(use-global-map calculator-saved-global-map))
(if (or (not calculator-electric-mode)
;; XEmacs has a problem with electric-describe-mode
- (string-match "XEmacs" (emacs-version)))
+ (featurep 'xemacs))
(describe-mode)
(electric-describe-mode))
(if calculator-electric-mode
;; compiler at hand (emacs or xemacs).
;; The autoload, below, is useless in Emacs because ediff-hook.el
;; is dumped with emacs, but it is needed in XEmacs
-;;;###autoload (defmacro ediff-cond-compile-for-xemacs-or-emacs (xemacs-form emacs-form) (if (string-match "XEmacs" emacs-version) xemacs-form emacs-form))
+;;;###autoload (defmacro ediff-cond-compile-for-xemacs-or-emacs (xemacs-form emacs-form) (if (featurep 'xemacs) xemacs-form emacs-form))
(defmacro ediff-cond-compile-for-xemacs-or-emacs (xemacs-form emacs-form)
- (if (string-match "XEmacs" emacs-version)
+ (if (featurep 'xemacs)
xemacs-form emacs-form))
;; This autoload is useless in Emacs because ediff-hook.el is dumped with
;; Override some bindings
(define-key map "\C-\M-x" 'checkdoc-eval-defun)
(define-key map "\C-x`" 'checkdoc-continue)
- (if (not (string-match "XEmacs" emacs-version))
+ (if (not (featurep 'xemacs))
(define-key map [menu-bar emacs-lisp eval-buffer]
'checkdoc-eval-current-buffer))
;; Add some new bindings under C-c ?
;;; Decide Emacs Variant, GNU Emacs or XEmacs (aka Lucid Emacs).
;;; Determine Window System, and X Server Vendor (if appropriate).
;;;
-(defconst edt-x-emacs-p (string-match "XEmacs" emacs-version)
+(defconst (featurep 'xemacs) (string-match "XEmacs" emacs-version)
"Non-nil if we are running XEmacs version 19, or higher.")
-(defconst edt-emacs-variant (if edt-x-emacs-p "xemacs" "gnu")
+(defconst edt-emacs-variant (if (featurep 'xemacs) "xemacs" "gnu")
"Indicates Emacs variant: GNU Emacs or XEmacs \(aka Lucid Emacs\).")
-(defconst edt-window-system (if edt-x-emacs-p (console-type) window-system)
+(defconst edt-window-system (if (featurep 'xemacs) (console-type) window-system)
"Indicates window system \(in GNU Emacs\) or console type \(in XEmacs\).")
(defconst edt-xserver (if (eq edt-window-system 'x)
- (if edt-x-emacs-p
+ (if (featurep 'xemacs)
;; The Cygwin window manager has a `/' in its
;; name, which breaks the generated file name of
;; the custom key map file. Replace `/' with a
;;; function-key-map.
;;;
(cond
- (edt-x-emacs-p
+ ((featurep 'xemacs)
(setq edt-return-seq (read-key-sequence "Hit carriage-return <CR> to continue "))
(setq edt-return (concat "[" (format "%s" (event-key (aref edt-return-seq 0))) "]")))
(t
;;;
;;; Key mapping functions
;;;
-(defun edt-lucid-map-key (ident descrip)
+(defun edt-map-key (ident descrip)
(interactive)
- (setq edt-key-seq (read-key-sequence (format "Press %s%s: " ident descrip)))
- (setq edt-key (concat "[" (format "%s" (event-key (aref edt-key-seq 0))) "]"))
- (cond ((not (equal edt-key edt-return))
- (set-buffer "Keys")
- (insert (format " (\"%s\" . %s)\n" ident edt-key))
- (set-buffer "Directions"))
- ;; bogosity to get next prompt to come up, if the user hits <CR>!
- ;; check periodically to see if this is still needed...
- (t
- (set-buffer "Keys")
- (insert (format " (\"%s\" . \"\" )\n" ident))
- (set-buffer "Directions")))
+ (if (featurep 'xemacs)
+ (progn
+ (setq edt-key-seq (read-key-sequence (format "Press %s%s: " ident descrip)))
+ (setq edt-key (concat "[" (format "%s" (event-key (aref edt-key-seq 0))) "]"))
+ (cond ((not (equal edt-key edt-return))
+ (set-buffer "Keys")
+ (insert (format " (\"%s\" . %s)\n" ident edt-key))
+ (set-buffer "Directions"))
+ ;; bogosity to get next prompt to come up, if the user hits <CR>!
+ ;; check periodically to see if this is still needed...
+ (t
+ (set-buffer "Keys")
+ (insert (format " (\"%s\" . \"\" )\n" ident))
+ (set-buffer "Directions"))))
+ (setq edt-key (read-key-sequence (format "Press %s%s: " ident descrip)))
+ (cond ((not (equal edt-key edt-return))
+ (set-buffer "Keys")
+ (insert (if (vectorp edt-key)
+ (format " (\"%s\" . %s)\n" ident edt-key)
+ (format " (\"%s\" . \"%s\")\n" ident edt-key)))
+ (set-buffer "Directions"))
+ ;; bogosity to get next prompt to come up, if the user hits <CR>!
+ ;; check periodically to see if this is still needed...
+ (t
+ (set-buffer "Keys")
+ (insert (format " (\"%s\" . \"\" )\n" ident))
+ (set-buffer "Directions"))))
edt-key)
-(defun edt-gnu-map-key (ident descrip)
- (interactive)
- (setq edt-key (read-key-sequence (format "Press %s%s: " ident descrip)))
- (cond ((not (equal edt-key edt-return))
- (set-buffer "Keys")
- (insert (if (vectorp edt-key)
- (format " (\"%s\" . %s)\n" ident edt-key)
- (format " (\"%s\" . \"%s\")\n" ident edt-key)))
- (set-buffer "Directions"))
- ;; bogosity to get next prompt to come up, if the user hits <CR>!
- ;; check periodically to see if this is still needed...
- (t
- (set-buffer "Keys")
- (insert (format " (\"%s\" . \"\" )\n" ident))
- (set-buffer "Directions")))
- edt-key)
-
-(fset 'edt-map-key (if edt-x-emacs-p 'edt-lucid-map-key 'edt-gnu-map-key))
(set-buffer "Keys")
(insert "
;;
;;;
;;; Restore function-key-map.
;;;
-(if (and edt-window-system (not edt-x-emacs-p))
+(if (and edt-window-system (not (featurep 'xemacs)))
(setq function-key-map edt-save-function-key-map))
(setq EDT-key-name "")
(while (not
(message "Viper version is %s" viper-version))
;; Is it XEmacs?
-(defconst viper-xemacs-p (string-match "XEmacs" emacs-version))
+(defconst viper-xemacs-p (featurep 'xemacs))
;; Is it Emacs?
(defconst viper-emacs-p (not viper-xemacs-p))
;; Tell whether we are running as a window application or on a TTY
;; compiler at hand.
;; Suggested by rms.
(defmacro viper-cond-compile-for-xemacs-or-emacs (xemacs-form emacs-form)
- (if (string-match "XEmacs" emacs-version)
+ (if (featurep 'xemacs)
xemacs-form emacs-form))
"Toggle inline display of an image."
(interactive)
(when (eudc-bob-can-display-inline-images)
- (cond (eudc-xemacs-p
+ (cond ((featurep 'xemacs)
(let ((overlays (append (overlays-at (1- (point)))
(overlays-at (point))))
overlay glyph)
(interactive "@e")
(run-hooks 'activate-menubar-hook)
(eudc-jump-to-event event)
- (if eudc-xemacs-p
+ (if (featurep 'xemacs)
(progn
(run-hooks 'activate-popup-menu-hook)
(popup-menu (eudc-bob-menu)))
(let ((map (make-sparse-keymap)))
(define-key map "s" 'eudc-bob-save-object)
(define-key map "!" 'eudc-bob-pipe-object-to-external-program)
- (define-key map (if eudc-xemacs-p
+ (define-key map (if (featurep 'xemacs)
[button3]
[down-mouse-3]) 'eudc-bob-popup-menu)
map))
(setq eudc-bob-sound-keymap
(let ((map (make-sparse-keymap)))
(define-key map [return] 'eudc-bob-play-sound-at-point)
- (define-key map (if eudc-xemacs-p
+ (define-key map (if (featurep 'xemacs)
[button2]
[down-mouse-2]) 'eudc-bob-play-sound-at-mouse)
map))
(setq eudc-bob-url-keymap
(let ((map (make-sparse-keymap)))
(define-key map [return] 'browse-url-at-point)
- (define-key map (if eudc-xemacs-p
+ (define-key map (if (featurep 'xemacs)
[button2]
[down-mouse-2]) 'browse-url-at-mouse)
map))
(setq eudc-bob-mail-keymap
(let ((map (make-sparse-keymap)))
(define-key map [return] 'goto-address-at-point)
- (define-key map (if eudc-xemacs-p
+ (define-key map (if (featurep 'xemacs)
[button2]
[down-mouse-2]) 'goto-address-at-mouse)
map))
(set-keymap-parent eudc-bob-image-keymap eudc-bob-generic-keymap)
(set-keymap-parent eudc-bob-sound-keymap eudc-bob-generic-keymap)
-(if eudc-emacs-p
- (progn
- (easy-menu-define eudc-bob-generic-menu
- eudc-bob-generic-keymap
- ""
- eudc-bob-generic-menu)
- (easy-menu-define eudc-bob-image-menu
- eudc-bob-image-keymap
- ""
- eudc-bob-image-menu)
- (easy-menu-define eudc-bob-sound-menu
- eudc-bob-sound-keymap
- ""
- eudc-bob-sound-menu)))
+(when (not (featurep 'xemacs))
+ (easy-menu-define eudc-bob-generic-menu
+ eudc-bob-generic-keymap
+ ""
+ eudc-bob-generic-menu)
+ (easy-menu-define eudc-bob-image-menu
+ eudc-bob-image-keymap
+ ""
+ eudc-bob-image-menu)
+ (easy-menu-define eudc-bob-sound-menu
+ eudc-bob-sound-keymap
+ ""
+ eudc-bob-sound-menu))
;;;###autoload
(defun eudc-display-generic-binary (data)
["Save and Quit" eudc-hotlist-quit-edit t]
["Exit without Saving" kill-this-buffer t]))
-(if eudc-emacs-p
- (easy-menu-define eudc-hotlist-emacs-menu
- eudc-hotlist-mode-map
- ""
- eudc-hotlist-menu))
+(when (not (featurep 'xemacs))
+ (easy-menu-define eudc-hotlist-emacs-menu
+ eudc-hotlist-mode-map
+ ""
+ eudc-hotlist-menu))
;;; arch-tag: 9b633ab3-6a6e-4b46-b12e-d96739a7e0e8
;;; eudc-hotlist.el ends here
;;{{{ Internal variables and compatibility tricks
-(defconst eudc-xemacs-p (string-match "XEmacs" emacs-version))
-(defconst eudc-emacs-p (not eudc-xemacs-p))
-(defconst eudc-xemacs-mule-p (and eudc-xemacs-p
- (featurep 'mule)))
-(defconst eudc-emacs-mule-p (and eudc-emacs-p
- (featurep 'mule)))
-
(defvar eudc-form-widget-list nil)
(defvar eudc-mode-map nil)
(setq major-mode 'eudc-mode)
(setq mode-name "EUDC")
(use-local-map eudc-mode-map)
- (if eudc-emacs-p
+ (if (not (featurep 'xemacs))
(easy-menu-define eudc-emacs-menu eudc-mode-map "" (eudc-menu))
(setq mode-popup-menu (eudc-menu)))
(run-mode-hooks 'eudc-mode-hook))
(defun eudc-install-menu ()
(cond
- ((and eudc-xemacs-p (featurep 'menubar))
+ ((and (featurep 'xemacs) (featurep 'menubar))
(add-submenu '("Tools") (eudc-menu)))
- (eudc-emacs-p
+ ((not (featurep 'xemacs))
(cond
((fboundp 'easy-menu-create-menu)
(define-key
nil)
;;;###autoload
-(cond ((not (string-match "XEmacs" emacs-version))
+(cond ((not (featurep 'xemacs))
(defvar eudc-tools-menu (make-sparse-keymap "Directory Search"))
(fset 'eudc-tools-menu (symbol-value 'eudc-tools-menu))
(define-key eudc-tools-menu [phone]
["Get Email" eudc-get-email t]
["Get Phone" eudc-get-phone t])))
(if (not (featurep 'eudc-autoloads))
- (if eudc-xemacs-p
+ (if (featurep 'xemacs)
(if (and (featurep 'menubar)
(not (featurep 'infodock)))
(add-submenu '("Tools") menu))
(set-buffer eudc-ph-process-buffer)
(erase-buffer)
(setq eudc-ph-read-point (point))
- (and eudc-xemacs-mule-p
+ (and (featurep 'xemacs) (featurep 'mule)
(set-buffer-file-coding-system 'binary t)))
(setq process (open-network-stream "ph" eudc-ph-process-buffer host port))
(if (null process)
:group 'fast-lock)
(defvar fast-lock-save-faces
- (when (save-match-data (string-match "XEmacs" (emacs-version)))
+ (when (featurep 'xemacs)
;; XEmacs uses extents for everything, so we have to pick the right ones.
font-lock-face-list)
"Faces that will be saved in a Font Lock cache file.
(and (eq (car args) :@) (null msg) ; (:@ ...spliced...)
(setq args (cdr args)
msg "(:@ ....) must return exactly one element"))
- (let ((ignore (if (string-match "XEmacs" emacs-version) :EMACS :XEMACS))
+ (let ((ignore (if (featurep 'xemacs) :EMACS :XEMACS))
(mode :BOTH) code)
(while (consp args)
(if (memq (car args) '(:EMACS :XEMACS :BOTH)) (setq mode (pop args)))
;; existing functions when they are `fboundp', provide shortcuts if they are
;; known to be defined in a specific Emacs branch (for short .elc)
(defmacro defunx (name arglist &rest definition)
- (let ((xemacsp (string-match "XEmacs" emacs-version)) reuses)
+ (let ((xemacsp (featurep 'xemacs)) reuses)
(while (memq (car definition)
'(:try :emacs-and-try :xemacs-and-try))
(if (eq (pop definition) (if xemacsp :xemacs-and-try :emacs-and-try))
(defmacro ignore-errors-x (&rest body)
(let ((specials '((scan-sexps . 4) (scan-lists . 5)))
spec nils)
- (if (and (string-match "XEmacs" emacs-version)
+ (if (and (featurep 'xemacs)
(null (cdr body)) (consp (car body))
(setq spec (assq (caar body) specials))
(>= (setq nils (- (cdr spec) (length (car body)))) 0))
`(let ((,modified (buffer-modified-p)))
(unwind-protect
(let ((buffer-undo-list t) (inhibit-read-only t)
- ,@(unless (string-match "XEmacs" emacs-version)
+ ,@(unless (featurep 'xemacs)
'((inhibit-point-motion-hooks t) deactivate-mark))
before-change-functions after-change-functions
buffer-file-name buffer-file-truename)
(delete-horizontal-space)
(insert (concat " " octave-continuation-string))))
-(defvar octave-xemacs-p
- (string-match "XEmacs\\|Lucid" emacs-version))
-
;;; Comments
(defun octave-comment-region (beg end &optional arg)
"Comment or uncomment each line in the region as Octave code.
(self-insert-command 1)
(let (c)
(insert last-command-char)
- (if (if octave-xemacs-p
+ (if (if (featurep 'xemacs)
(or (eq (event-to-character (setq c (next-event))) ??)
(eq (event-to-character c) help-char))
(or (eq (setq c (read-event)) ??)
;;; Code:
-;; XEmacs handling
-(defconst vera-xemacs (string-match "XEmacs" emacs-version)
- "Non-nil if XEmacs is used.")
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; Variables
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(modify-syntax-entry ?\{ "(}" syntax-table)
(modify-syntax-entry ?\} "){" syntax-table)
;; comment
- (if vera-xemacs
+ (if (featurep 'xemacs)
(modify-syntax-entry ?\/ ". 1456" syntax-table) ; XEmacs
(modify-syntax-entry ?\/ ". 124b" syntax-table)) ; Emacs
(modify-syntax-entry ?\* ". 23" syntax-table)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; XEmacs compatibility
-(when vera-xemacs
+(when (featurep 'xemacs)
(require 'font-lock)
(copy-face 'font-lock-reference-face 'font-lock-constant-face)
(copy-face 'font-lock-preprocessor-face 'font-lock-builtin-face))
;;; Code:
-;; XEmacs handling
-(defconst vhdl-xemacs (string-match "XEmacs" emacs-version)
- "Non-nil if XEmacs is used.")
;; Emacs 21+ handling
-(defconst vhdl-emacs-21 (and (<= 21 emacs-major-version) (not vhdl-xemacs))
+(defconst vhdl-emacs-21 (and (<= 21 emacs-major-version) (not (featurep 'xemacs)))
"Non-nil if GNU Emacs 21, 22, ... is used.")
-(defconst vhdl-emacs-22 (and (<= 22 emacs-major-version) (not vhdl-xemacs))
+(defconst vhdl-emacs-22 (and (<= 22 emacs-major-version) (not (featurep 'xemacs)))
"Non-nil if GNU Emacs 22, ... is used.")
(defvar compilation-file-regexp-alist)
;; add related general customizations
(custom-add-to-group 'vhdl-related 'hideshow 'custom-group)
-(if vhdl-xemacs
+(if (featurep 'xemacs)
(custom-add-to-group 'vhdl-related 'paren-mode 'custom-variable)
(custom-add-to-group 'vhdl-related 'paren-showing 'custom-group))
(custom-add-to-group 'vhdl-related 'ps-print 'custom-group)
(custom-add-to-group 'vhdl-related 'speedbar 'custom-group)
(custom-add-to-group 'vhdl-related 'line-number-mode 'custom-variable)
-(unless vhdl-xemacs
+(unless (featurep 'xemacs)
(custom-add-to-group 'vhdl-related 'transient-mark-mode 'custom-variable))
(custom-add-to-group 'vhdl-related 'user-full-name 'custom-variable)
(custom-add-to-group 'vhdl-related 'mail-host-address 'custom-variable)
newstr)))
;; `itimer.el': idle timer bug fix in version 1.09 (XEmacs 21.1.9)
-(when (and vhdl-xemacs (string< itimer-version "1.09")
+(when (and (featurep 'xemacs) (string< itimer-version "1.09")
(not noninteractive))
(load "itimer")
(when (string< itimer-version "1.09")
(defun vhdl-show-messages ()
"Get *Messages* buffer to show recent messages."
(interactive)
- (display-buffer (if vhdl-xemacs " *Message-Log*" "*Messages*")))
+ (display-buffer (if (featurep 'xemacs) " *Message-Log*" "*Messages*")))
(defun vhdl-use-direct-instantiation ()
"Return whether direct instantiation is used."
(define-key vhdl-mode-map "\M-\C-u" 'vhdl-backward-up-list)
(define-key vhdl-mode-map "\M-\C-a" 'vhdl-backward-same-indent)
(define-key vhdl-mode-map "\M-\C-e" 'vhdl-forward-same-indent)
- (unless vhdl-xemacs ; would override `M-backspace' in XEmacs
+ (unless (featurep 'xemacs) ; would override `M-backspace' in XEmacs
(define-key vhdl-mode-map "\M-\C-h" 'vhdl-mark-defun))
(define-key vhdl-mode-map "\M-\C-q" 'vhdl-indent-sexp)
(define-key vhdl-mode-map "\M-^" 'vhdl-delete-indentation)
(define-key vhdl-mode-map "\C-c\C-p\C-i" 'vhdl-port-paste-instance)
(define-key vhdl-mode-map "\C-c\C-p\C-s" 'vhdl-port-paste-signals)
(define-key vhdl-mode-map "\C-c\C-p\M-c" 'vhdl-port-paste-constants)
- (if vhdl-xemacs ; `... C-g' not allowed in XEmacs
+ (if (featurep 'xemacs) ; `... C-g' not allowed in XEmacs
(define-key vhdl-mode-map "\C-c\C-p\M-g" 'vhdl-port-paste-generic-map)
(define-key vhdl-mode-map "\C-c\C-p\C-g" 'vhdl-port-paste-generic-map))
(define-key vhdl-mode-map "\C-c\C-p\C-z" 'vhdl-port-paste-initializations)
(skip-chars-forward " \t\n"))))
;; XEmacs hack: work around buggy `forward-comment' in XEmacs 21.4+
-(unless (and vhdl-xemacs (string< "21.2" emacs-version))
+(unless (and (featurep 'xemacs) (string< "21.2" emacs-version))
(defalias 'vhdl-forward-comment 'forward-comment))
;; This is the best we can do in Win-Emacs.
(defun vhdl-ps-print-init ()
"Initialize postscript printing."
- (if vhdl-xemacs
+ (if (featurep 'xemacs)
(when (boundp 'ps-print-color-p)
(vhdl-ps-print-settings))
(make-local-variable 'ps-print-hook)
(save-excursion (beginning-of-line) (looking-at "[0-9]+:"))]
["Rescan Directory" vhdl-speedbar-rescan-hierarchy
:active (save-excursion (beginning-of-line) (looking-at "[0-9]+:"))
- ,(if vhdl-xemacs :active :visible) (not vhdl-speedbar-show-projects)]
+ ,(if (featurep 'xemacs) :active :visible) (not vhdl-speedbar-show-projects)]
["Rescan Project" vhdl-speedbar-rescan-hierarchy
:active (save-excursion (beginning-of-line) (looking-at "[0-9]+:"))
- ,(if vhdl-xemacs :active :visible) vhdl-speedbar-show-projects]
+ ,(if (featurep 'xemacs) :active :visible) vhdl-speedbar-show-projects]
["Save Caches" vhdl-save-caches vhdl-updated-project-list])))
;; hook-ups
(speedbar-add-expansion-list
(assoc (car sublist) regexp-alist))
(setq regexp-alist (cons (list (nth 0 sublist)
(if (= 0 (nth 1 sublist))
- (if vhdl-xemacs 9 nil)
+ (if (featurep 'xemacs) 9 nil)
(nth 1 sublist))
(nth 2 sublist) (nth 3 sublist))
regexp-alist)))
(defun vhdl-doc-variable (variable)
"Display VARIABLE's documentation in *Help* buffer."
(interactive)
- (unless vhdl-xemacs
+ (unless (featurep 'xemacs)
(help-setup-xref (list #'vhdl-doc-variable variable) (interactive-p)))
(with-output-to-temp-buffer
(if (fboundp 'help-buffer) (help-buffer) "*Help*")
(defun vhdl-doc-mode ()
"Display VHDL Mode documentation in *Help* buffer."
(interactive)
- (unless vhdl-xemacs
+ (unless (featurep 'xemacs)
(help-setup-xref (list #'vhdl-doc-mode) (interactive-p)))
(with-output-to-temp-buffer
(if (fboundp 'help-buffer) (help-buffer) "*Help*")
(error "`ps-print' requires floating point support"))
(let ((case-fold-search t))
- (cond ((string-match "XEmacs" emacs-version))
+ (cond ((featurep 'xemacs))
((string-match "Lucid" emacs-version)
(error "`ps-print' doesn't support Lucid"))
((string-match "Epoch" emacs-version)