Skip to content
Browse files

Remove vestigial XEmacs and other unnecessary code

  • Loading branch information...
1 parent 0dfa005 commit 733a5729acd4e2adc4c468b7ac4996bc67cd6860 @jdtsmith committed Jan 27, 2014
Showing with 10 additions and 36 deletions.
  1. +1 −5 idlw-complete-structtag.el
  2. +0 −5 idlw-help.el
  3. +9 −12 idlw-shell.el
  4. +0 −14 idlwave.el
View
6 idlw-complete-structtag.el
@@ -111,7 +111,6 @@
(add-hook 'idlwave-update-rinfo-hook 'idlwave-structtag-reset)
;;; The main code follows below
-(defvar idlwave-completion-help-info)
(defun idlwave-complete-structure-tag ()
"Complete a structure tag.
This works by looking in the current file for a structure assignment to a
@@ -225,9 +224,6 @@ an up-to-date completion list."
;; Fake help in the source buffer for structure tags.
-;; kwd and name are global-variables here.
-(defvar name)
-(defvar kwd)
(defvar idlwave-help-do-struct-tag)
(defun idlwave-complete-structure-tag-help (mode word)
(cond
@@ -237,7 +233,7 @@ an up-to-date completion list."
(not (equal idlwave-current-tags-buffer
(get-buffer (idlwave-shell-buffer))))))
((eq mode 'set)
- (setq kwd word
+ (setq kwd word ;; dynamic var
idlwave-help-do-struct-tag idlwave-structtag-struct-location))
(t (error "This should not happen"))))
View
5 idlw-help.el
@@ -52,11 +52,6 @@
"Face for highlighting links into IDLWAVE online help."
:group 'idlwave-online-help)
-(defvar idlwave-help-activate-links-aggressively nil
- "Obsolete variable.")
-
-(defvar idlwave-completion-help-info)
-
(defvar idlwave-help-frame nil
"The frame for display of IDL online help.")
(defvar idlwave-help-frame-width 102
View
21 idlw-shell.el
@@ -700,15 +700,16 @@ the directory stack.")
;; So who can display faces?
(when (or (featurep 'xemacs) ; XEmacs can do also ttys
(fboundp 'tty-defined-colors) ; Emacs 21 as well
- window-system) ; Window systems always
+ (display-graphic-p)) ; Window systems always
(progn
(setq idlwave-shell-stop-line-overlay (make-overlay 1 1))
(overlay-put idlwave-shell-stop-line-overlay
'face idlwave-shell-stop-line-face))))
(t
- ;; IDLWAVE may decide. Will use a face on window systems, arrow elsewhere
- (if window-system
+ ;; IDLWAVE may decide. Will use a face plus arrow on window systems,
+ ;; just arrow elsewhere
+ (if (display-graphic-p)
(progn
(setq idlwave-shell-stop-line-overlay (make-overlay 1 1))
(overlay-put idlwave-shell-stop-line-overlay
@@ -3841,20 +3842,16 @@ Existing overlays are recycled, in order to minimize consumption."
(when use-glyph
(if old-buffers
(setq old-buffers (delq (current-buffer) old-buffers)))
- (if (fboundp 'set-specifier) ;; XEmacs
- (set-specifier left-margin-width (cons (current-buffer) 2))
- (if (< left-margin-width 2)
- (setq left-margin-width 2)))
+ (if (< left-margin-width 2)
+ (setq left-margin-width 2))
(let ((window (get-buffer-window (current-buffer) 0)))
(if window
(set-window-margins
window left-margin-width right-margin-width))))))
(if use-glyph
(while (setq buf (pop old-buffers))
(with-current-buffer buf
- (if (fboundp 'set-specifier) ;; XEmacs
- (set-specifier left-margin-width (cons (current-buffer) 0))
- (setq left-margin-width 0))
+ (setq left-margin-width 0)
(let ((window (get-buffer-window buf 0)))
(if window
(set-window-margins
@@ -3904,7 +3901,7 @@ only for glyphs)."
(overlay-put ov 'mouse-face 'highlight)
(overlay-put ov 'keymap idlwave-shell-debug-line-map))
(cond
- (window-system
+ ((display-graphic-p)
(if use-glyph
(let ((image-props (cdr (assq type idlwave-shell-bp-glyph)))
string)
@@ -4389,7 +4386,7 @@ Otherwise, just expand the file name."
(define-key idlwave-shell-mode-prefix-map k1 cmd))
(define-key idlwave-mode-prefix-map k1 cmd))
;; The debug modifier map
- (when (and mod window-system)
+ (when (and mod (display-graphic-p))
(if (char-or-string-p c2)
(setq k2 (vector (append mod-noshift
(list (if shift (upcase c2) c2)))))
View
14 idlwave.el
@@ -157,20 +157,6 @@
(require 'idlw-menus)
(require 'idlw-scan)
-;; For XEmacs
-(unless (fboundp 'line-beginning-position)
- (defalias 'line-beginning-position 'point-at-bol))
-(unless (fboundp 'line-end-position)
- (defalias 'line-end-position 'point-at-eol))
-(unless (fboundp 'char-valid-p)
- (defalias 'char-valid-p 'characterp))
-(unless (fboundp 'match-string-no-properties)
- (defalias 'match-string-no-properties 'match-string))
-
-(if (not (fboundp 'cancel-timer))
- (condition-case nil
- (require 'timer)
- (error nil)))
(declare-function idlwave-shell-get-path-info "idlw-shell")
(declare-function idlwave-shell-temp-file "idlw-shell")

0 comments on commit 733a572

Please sign in to comment.
Something went wrong with that request. Please try again.