summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
Diffstat (limited to 'lisp')
-rw-r--r--lisp/ChangeLog53
-rw-r--r--lisp/custom.el7
-rw-r--r--lisp/faces.el42
-rw-r--r--lisp/font-lock.el95
-rw-r--r--lisp/gdb-ui.el170
-rw-r--r--lisp/info-look.el4
-rw-r--r--lisp/isearch.el22
-rw-r--r--lisp/progmodes/sh-script.el24
8 files changed, 266 insertions, 151 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 6b91102a1e7..328cc3e8986 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,56 @@
+2004-02-28 Kim F. Storm <storm@cua.dk>
+
+ * gdb-ui.el (breakpoint-enabled-icon, breakpoint-disabled-icon):
+ Initialize margin area images to nil.
+ (breakpoint-bitmap): New defvar for breakpoint fringe bitmaps.
+ (breakpoint-enabled-bitmap-face)
+ (breakpoint-disabled-bitmap-face): New faces for bpt in fringe.
+ (gdb-info-breakpoints-custom): Use gdb-remove-breakpoint-icons.
+ (gdb-info-breakpoints-custom): Use gdb-put-breakpoint-icon.
+ (gdb-mouse-toggle-breakpoint): Handle bpt in fringe.
+ (gdb-reset): Use gdb-remove-breakpoint-icons.
+ (gdb-put-string): Add dprop arg to specify alternative display
+ property (for setting fringe bitmap).
+ (gdb-remove-strings): Doc fix.
+ (gdb-put-breakpoint-icon): New defun which displays a breakpoint
+ icon in fringe (if available), or else as icon or text in display
+ margin. Creates necessary icons in breakpoint-bitmap,
+ breakpoint-enabled-icon, and/or breakpoint-disabled-icon. Also
+ make left window margin if required.
+ (gdb-remove-breakpoint-icons): New defun to remove breakpoint
+ icons inserted by gdb-put-breakpoint-icon. Remove left margin if
+ no longer needed.
+ (gdb-assembler-custom): Use gdb-remove-breakpoint-icons and
+ gdb-put-breakpoint-icon.
+ (gdb-assembler-mode): Don't set left-margin-width here.
+
+2004-02-27 Kevin Ryde <user42@zip.com.au>
+
+ * info-look.el: In scheme-mode symbol regexp, disallow backquote and
+ comma, so that it DTRT in macros.
+
+2004-02-27 Markus Rost <rost@mathematik.uni-bielefeld.de>
+
+ * progmodes/sh-script.el (sh-shell-arg)
+ (sh-require-final-newline, sh-assignment-regexp, sh-builtins)
+ (sh-leading-keywords, sh-other-keywords): Fix custom type.
+
+2004-02-27 Dan Nicolaescu <dann@ics.uci.edu>
+
+ * faces.el (face-spec-set-match-display): Add a new attribute,
+ `min-colors'.
+ (region, highlight, secondary-selection): Use `min-colors`.
+
+ * custom.el (defface): Add documentation for `min-colors'.
+
+ * font-lock.el (font-lock-comment-face, font-lock-string-face)
+ (font-lock-keyword-face, font-lock-function-name-face)
+ (font-lock-variable-name-face, font-lock-constant-face): Use
+ `min-colors`.
+
+ * isearch.el (isearch, isearch-lazy-highlight-face): Use
+ `min-colors'.
+
2004-02-25 Vinicius Jose Latorre <viniciusjl@ig.com.br>
* ebnf2ps.el: Doc fix. For compatibility with Emacs 20, define
diff --git a/lisp/custom.el b/lisp/custom.el
index ea0567d3109..f5cfd55400a 100644
--- a/lisp/custom.el
+++ b/lisp/custom.el
@@ -1,6 +1,7 @@
;;; custom.el --- tools for declaring and initializing options
;;
-;; Copyright (C) 1996, 1997, 1999, 2001, 2002 Free Software Foundation, Inc.
+;; Copyright (C) 1996, 1997, 1999, 2001, 2002, 2004
+;; Free Software Foundation, Inc.
;;
;; Author: Per Abrahamsen <abraham@dina.kvl.dk>
;; Maintainer: FSF
@@ -306,6 +307,10 @@ following REQ are defined:
`background' (what color is used for the background text)
Should be one of `light' or `dark'.
+`min-colors' (the minimum number of colors the frame should support)
+ Should be an integer, it is compared with the result of
+ `display-color-cells'.
+
Read the section about customization in the Emacs Lisp manual for more
information."
;; It is better not to use backquote in this file,
diff --git a/lisp/faces.el b/lisp/faces.el
index 342ba5b60bd..ba655df01db 100644
--- a/lisp/faces.el
+++ b/lisp/faces.el
@@ -1,6 +1,6 @@
;;; faces.el --- Lisp faces
-;; Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
+;; Copyright (C) 1992,1993,1994,1995,1996,1998,1999,2000,2001,2002,2004
;; Free Software Foundation, Inc.
;; Maintainer: FSF
@@ -1314,6 +1314,8 @@ If FRAME is nil, the current FRAME is used."
(not (featurep 'motif)))
(and (memq 'x-toolkit options)
(featurep 'x-toolkit))))
+ ((eq req 'min-colors)
+ (>= (display-color-cells frame) (car options)))
((eq req 'class)
(memq (frame-parameter frame 'display-type) options))
((eq req 'background)
@@ -1892,14 +1894,18 @@ created."
(append minibuffer-prompt-properties (list 'face 'minibuffer-prompt)))
(defface region
- '((((type tty) (class color))
+ '((((class color) (min-colors 88) (background dark))
+ :background "blue3")
+ (((class color) (min-colors 88) (background light))
+ :background "lightgoldenrod2")
+ (((class color) (min-colors 16) (background dark))
+ :background "blue3")
+ (((class color) (min-colors 16) (background light))
+ :background "lightgoldenrod2")
+ (((class color) (min-colors 8))
:background "blue" :foreground "white")
(((type tty) (class mono))
:inverse-video t)
- (((class color) (background dark))
- :background "blue3")
- (((class color) (background light))
- :background "lightgoldenrod2")
(t :background "gray"))
"Basic face for highlighting the region."
:version "21.1"
@@ -1990,24 +1996,32 @@ created."
(defface highlight
- '((((type tty) (class color))
- :background "green" :foreground "black")
- (((class color) (background light))
+ '((((class color) (min-colors 88) (background light))
:background "darkseagreen2")
- (((class color) (background dark))
+ (((class color) (min-colors 88) (background dark))
:background "darkolivegreen")
+ (((class color) (min-colors 16) (background light))
+ :background "darkseagreen2")
+ (((class color) (min-colors 16) (background dark))
+ :background "darkolivegreen")
+ (((class color) (min-colors 8))
+ :background "green" :foreground "black")
(t :inverse-video t))
"Basic face for highlighting."
:group 'basic-faces)
(defface secondary-selection
- '((((type tty) (class color))
- :background "cyan" :foreground "black")
- (((class color) (background light))
+ '((((class color) (min-colors 88) (background light))
:background "yellow")
- (((class color) (background dark))
+ (((class color) (min-colors 88) (background dark))
+ :background "SkyBlue4")
+ (((class color) (min-colors 16) (background light))
+ :background "yellow")
+ (((class color) (min-colors 16) (background dark))
:background "SkyBlue4")
+ (((class color) (min-colors 8))
+ :background "cyan" :foreground "black")
(t :inverse-video t))
"Basic face for displaying the secondary selection."
:group 'basic-faces)
diff --git a/lisp/font-lock.el b/lisp/font-lock.el
index c7cd817b4f1..4deacb9e87f 100644
--- a/lisp/font-lock.el
+++ b/lisp/font-lock.el
@@ -1,6 +1,6 @@
;;; font-lock.el --- Electric font lock mode
-;; Copyright (C) 1992, 93, 94, 95, 96, 97, 98, 1999, 2000, 2001, 02, 2003
+;; Copyright (C) 1992, 93, 94, 95, 96, 97, 98, 1999, 2000, 2001, 02, 2003, 2004
;; Free Software Foundation, Inc.
;; Author: jwz, then rms, then sm
@@ -1560,24 +1560,34 @@ Sets various variables using `font-lock-defaults' (or, if nil, using
;; But now we do it the custom way. Note that `defface' will not overwrite any
;; faces declared above via `custom-declare-face'.
(defface font-lock-comment-face
- '((((type tty pc) (class color) (background light)) (:foreground "red"))
- (((type tty pc) (class color) (background dark)) (:foreground "red1"))
- (((class grayscale) (background light))
+ '((((class grayscale) (background light))
(:foreground "DimGray" :weight bold :slant italic))
(((class grayscale) (background dark))
(:foreground "LightGray" :weight bold :slant italic))
- (((class color) (background light)) (:foreground "Firebrick"))
- (((class color) (background dark)) (:foreground "chocolate1"))
+ (((class color) (min-colors 88) (background light))
+ (:foreground "Firebrick"))
+ (((class color) (min-colors 88) (background dark))
+ (:foreground "chocolate1"))
+ (((class color) (min-colors 16) (background light))
+ (:foreground "red"))
+ (((class color) (min-colors 16) (background dark))
+ (:foreground "red1"))
+ (((class color) (min-colors 8) (background light))
+ (:foreground "red"))
+ (((class color) (min-colors 8) (background dark))
+ (:foreground "red1"))
(t (:weight bold :slant italic)))
"Font Lock mode face used to highlight comments."
:group 'font-lock-highlighting-faces)
(defface font-lock-string-face
- '((((type tty) (class color)) (:foreground "green"))
- (((class grayscale) (background light)) (:foreground "DimGray" :slant italic))
+ '((((class grayscale) (background light)) (:foreground "DimGray" :slant italic))
(((class grayscale) (background dark)) (:foreground "LightGray" :slant italic))
- (((class color) (background light)) (:foreground "RosyBrown"))
- (((class color) (background dark)) (:foreground "LightSalmon"))
+ (((class color) (min-colors 88) (background light)) (:foreground "RosyBrown"))
+ (((class color) (min-colors 88) (background dark)) (:foreground "LightSalmon"))
+ (((class color) (min-colors 16) (background light)) (:foreground "RosyBrown"))
+ (((class color) (min-colors 16) (background dark)) (:foreground "LightSalmon"))
+ (((class color) (min-colors 8)) (:foreground "green"))
(t (:slant italic)))
"Font Lock mode face used to highlight strings."
:group 'font-lock-highlighting-faces)
@@ -1588,71 +1598,84 @@ Sets various variables using `font-lock-defaults' (or, if nil, using
:group 'font-lock-highlighting-faces)
(defface font-lock-keyword-face
- '((((type tty) (class color)) (:foreground "cyan" :weight bold))
- (((class grayscale) (background light)) (:foreground "LightGray" :weight bold))
+ '((((class grayscale) (background light)) (:foreground "LightGray" :weight bold))
(((class grayscale) (background dark)) (:foreground "DimGray" :weight bold))
- (((class color) (background light)) (:foreground "Purple"))
- (((class color) (background dark)) (:foreground "Cyan"))
+ (((class color) (min-colors 88) (background light)) (:foreground "Purple"))
+ (((class color) (min-colors 88) (background dark)) (:foreground "Cyan"))
+ (((class color) (min-colors 16) (background light)) (:foreground "Purple"))
+ (((class color) (min-colors 16) (background dark)) (:foreground "Cyan"))
+ (((class color) (min-colors 8)) (:foreground "cyan" :weight bold))
(t (:weight bold)))
"Font Lock mode face used to highlight keywords."
:group 'font-lock-highlighting-faces)
(defface font-lock-builtin-face
- '((((type tty) (class color)) (:foreground "blue" :weight light))
- (((class grayscale) (background light)) (:foreground "LightGray" :weight bold))
+ '((((class grayscale) (background light)) (:foreground "LightGray" :weight bold))
(((class grayscale) (background dark)) (:foreground "DimGray" :weight bold))
- (((class color) (background light)) (:foreground "Orchid"))
- (((class color) (background dark)) (:foreground "LightSteelBlue"))
+ (((class color) (min-colors 88) (background light)) (:foreground "Orchid"))
+ (((class color) (min-colors 88) (background dark)) (:foreground "LightSteelBlue"))
+ (((class color) (min-colors 16) (background light)) (:foreground "Orchid"))
+ (((class color) (min-colors 16) (background dark)) (:foreground "LightSteelBlue"))
+ (((class color) (min-colors 8)) (:foreground "blue" :weight bold))
(t (:weight bold)))
"Font Lock mode face used to highlight builtins."
:group 'font-lock-highlighting-faces)
(defface font-lock-function-name-face
- '((((type tty) (class color)) (:foreground "blue" :weight bold))
- (((class color) (background light)) (:foreground "Blue"))
- (((class color) (background dark)) (:foreground "LightSkyBlue"))
+ '((((class color) (min-colors 88) (background light)) (:foreground "Blue"))
+ (((class color) (min-colors 88) (background dark)) (:foreground "LightSkyBlue"))
+ (((class color) (min-colors 16) (background light)) (:foreground "Blue"))
+ (((class color) (min-colors 16) (background dark)) (:foreground "LightSkyBlue"))
+ (((class color) (min-colors 8)) (:foreground "blue" :weight bold))
(t (:inverse-video t :weight bold)))
"Font Lock mode face used to highlight function names."
:group 'font-lock-highlighting-faces)
(defface font-lock-variable-name-face
- '((((type tty) (class color)) (:foreground "yellow" :weight light))
- (((class grayscale) (background light))
+ '((((class grayscale) (background light))
(:foreground "Gray90" :weight bold :slant italic))
(((class grayscale) (background dark))
(:foreground "DimGray" :weight bold :slant italic))
- (((class color) (background light)) (:foreground "DarkGoldenrod"))
- (((class color) (background dark)) (:foreground "LightGoldenrod"))
+ (((class color) (min-colors 88) (background light)) (:foreground "DarkGoldenrod"))
+ (((class color) (min-colors 88) (background dark)) (:foreground "LightGoldenrod"))
+ (((class color) (min-colors 16) (background light)) (:foreground "DarkGoldenrod"))
+ (((class color) (min-colors 16) (background dark)) (:foreground "LightGoldenrod"))
+ (((class color) (min-colors 8)) (:foreground "yellow" :weight light))
(t (:weight bold :slant italic)))
"Font Lock mode face used to highlight variable names."
:group 'font-lock-highlighting-faces)
(defface font-lock-type-face
- '((((type tty) (class color)) (:foreground "green"))
- (((class grayscale) (background light)) (:foreground "Gray90" :weight bold))
+ '((((class grayscale) (background light)) (:foreground "Gray90" :weight bold))
(((class grayscale) (background dark)) (:foreground "DimGray" :weight bold))
- (((class color) (background light)) (:foreground "ForestGreen"))
- (((class color) (background dark)) (:foreground "PaleGreen"))
+ (((class color) (min-colors 88) (background light)) (:foreground "ForestGreen"))
+ (((class color) (min-colors 88) (background dark)) (:foreground "PaleGreen"))
+ (((class color) (min-colors 16) (background light)) (:foreground "ForestGreen"))
+ (((class color) (min-colors 16) (background dark)) (:foreground "PaleGreen"))
+ (((class color) (min-colors 8)) (:foreground "green"))
(t (:weight bold :underline t)))
"Font Lock mode face used to highlight type and classes."
:group 'font-lock-highlighting-faces)
(defface font-lock-constant-face
- '((((type tty) (class color)) (:foreground "magenta"))
- (((class grayscale) (background light))
+ '((((class grayscale) (background light))
(:foreground "LightGray" :weight bold :underline t))
(((class grayscale) (background dark))
(:foreground "Gray50" :weight bold :underline t))
- (((class color) (background light)) (:foreground "CadetBlue"))
- (((class color) (background dark)) (:foreground "Aquamarine"))
+ (((class color) (min-colors 88) (background light)) (:foreground "CadetBlue"))
+ (((class color) (min-colors 88) (background dark)) (:foreground "Aquamarine"))
+ (((class color) (min-colors 16) (background light)) (:foreground "CadetBlue"))
+ (((class color) (min-colors 16) (background dark)) (:foreground "Aquamarine"))
+ (((class color) (min-colors 8)) (:foreground "magenta"))
(t (:weight bold :underline t)))
"Font Lock mode face used to highlight constants and labels."
:group 'font-lock-highlighting-faces)
(defface font-lock-warning-face
- '((((type tty) (class color)) (:foreground "red"))
- (((class color) (background light)) (:foreground "Red" :weight bold))
- (((class color) (background dark)) (:foreground "Pink" :weight bold))
+ '((((class color) (min-colors 88) (background light)) (:foreground "Red" :weight bold))
+ (((class color) (min-colors 88) (background dark)) (:foreground "Pink" :weight bold))
+ (((class color) (min-colors 16) (background light)) (:foreground "Red" :weight bold))
+ (((class color) (min-colors 16) (background dark)) (:foreground "Pink" :weight bold)) (((class color) (min-colors 8)) (:foreground "red"))
(t (:inverse-video t :weight bold)))
"Font Lock mode face used to highlight warnings."
:group 'font-lock-highlighting-faces)
diff --git a/lisp/gdb-ui.el b/lisp/gdb-ui.el
index 32cce04c239..0040fb47f6e 100644
--- a/lisp/gdb-ui.el
+++ b/lisp/gdb-ui.el
@@ -1017,16 +1017,28 @@ static char *magick[] = {
0 0 0 1 0 1 0 1 0 0"
"PBM data used for disabled breakpoint icon.")
-(defvar breakpoint-enabled-icon
- (find-image `((:type xpm :data ,breakpoint-xpm-data :ascent 100)
- (:type pbm :data ,breakpoint-enabled-pbm-data :ascent 100)))
+(defvar breakpoint-enabled-icon nil
"Icon for enabled breakpoint in display margin")
-(defvar breakpoint-disabled-icon
- (find-image `((:type xpm :data ,breakpoint-xpm-data :conversion disabled :ascent 100)
- (:type pbm :data ,breakpoint-disabled-pbm-data :ascent 100)))
+(defvar breakpoint-disabled-icon nil
"Icon for disabled breakpoint in display margin")
+(defvar breakpoint-bitmap nil
+ "Bitmap for breakpoint in fringe")
+
+(defface breakpoint-enabled-bitmap-face
+ '((t
+ :inherit fringe
+ :foreground "red"))
+ "Face for enabled breakpoint icon in fringe.")
+
+(defface breakpoint-disabled-bitmap-face
+ '((t
+ :inherit fringe
+ :foreground "grey60"))
+ "Face for disabled breakpoint icon in fringe.")
+
+
;;-put breakpoint icons in relevant margins (even those set in the GUD buffer)
(defun gdb-info-breakpoints-custom ()
(let ((flag)(address))
@@ -1036,9 +1048,7 @@ static char *magick[] = {
(with-current-buffer buffer
(if (and (eq gud-minor-mode 'gdba)
(not (string-match "^\*" (buffer-name))))
- (if (display-images-p)
- (remove-images (point-min) (point-max))
- (gdb-remove-strings (point-min) (point-max))))))
+ (gdb-remove-breakpoint-icons (point-min) (point-max)))))
(with-current-buffer (gdb-get-buffer 'gdb-breakpoints-buffer)
(save-excursion
(goto-char (point-min))
@@ -1064,35 +1074,11 @@ static char *magick[] = {
(save-current-buffer
(set (make-local-variable 'gud-minor-mode) 'gdba)
(set (make-local-variable 'tool-bar-map)
- gud-tool-bar-map)
- (setq left-margin-width 2)
- (if (get-buffer-window (current-buffer))
- (set-window-margins (get-buffer-window
- (current-buffer))
- left-margin-width
- right-margin-width)))
+ gud-tool-bar-map))
;; only want one breakpoint icon at each location
(save-excursion
(goto-line (string-to-number line))
- (let ((start (progn (beginning-of-line)
- (- (point) 1)))
- (end (progn (end-of-line) (+ (point) 1))))
- (if (display-images-p)
- (progn
- (remove-images start end)
- (if (eq ?y flag)
- (put-image breakpoint-enabled-icon
- (+ start 1)
- "breakpoint icon enabled"
- 'left-margin)
- (put-image breakpoint-disabled-icon
- (+ start 1)
- "breakpoint icon disabled"
- 'left-margin)))
- (gdb-remove-strings start end)
- (if (eq ?y flag)
- (gdb-put-string "B" (+ start 1))
- (gdb-put-string "b" (+ start 1))))))))))))
+ (gdb-put-breakpoint-icon (eq flag ?y)))))))))
(end-of-line)))))
(if (gdb-get-buffer 'gdb-assembler-buffer) (gdb-assembler-custom)))
@@ -1106,7 +1092,10 @@ static char *magick[] = {
(with-selected-window (posn-window posn)
(save-excursion
(goto-char (posn-point posn))
- (if (posn-object posn)
+ (if (or (posn-object posn)
+ (and breakpoint-bitmap
+ (eq (car (fringe-bitmaps-at-pos (posn-point posn)))
+ breakpoint-bitmap)))
(gud-remove nil)
(gud-break nil)))))))
@@ -1691,18 +1680,10 @@ This arrangement depends on the value of `gdb-many-windows'."
(if (memq gud-minor-mode '(gdba pdb))
(if (string-match "^\*.+*$" (buffer-name))
(kill-buffer nil)
- (if (display-images-p)
- (remove-images (point-min) (point-max))
- (gdb-remove-strings (point-min) (point-max)))
- (setq left-margin-width 0)
+ (gdb-remove-breakpoint-icons (point-min) (point-max) t)
(setq gud-minor-mode nil)
(kill-local-variable 'tool-bar-map)
- (setq gud-running nil)
- (if (get-buffer-window (current-buffer))
- (set-window-margins (get-buffer-window
- (current-buffer))
- left-margin-width
- right-margin-width))))))))
+ (setq gud-running nil)))))))
(defun gdb-source-info ()
"Find the source file where the program starts and displays it with related
@@ -1733,7 +1714,7 @@ buffers."
(other-window 1)))
;;from put-image
-(defun gdb-put-string (putstring pos)
+(defun gdb-put-string (putstring pos &optional dprop)
"Put string PUTSTRING in front of POS in the current buffer.
PUTSTRING is displayed by putting an overlay into the current buffer with a
`before-string' STRING that has a `display' property whose value is
@@ -1741,7 +1722,8 @@ PUTSTRING."
(let ((gdb-string "x")
(buffer (current-buffer)))
(let ((overlay (make-overlay pos pos buffer))
- (prop (list (list 'margin 'left-margin) putstring)))
+ (prop (or dprop
+ (list (list 'margin 'left-margin) putstring))))
(put-text-property 0 (length gdb-string) 'display prop gdb-string)
(overlay-put overlay 'put-break t)
(overlay-put overlay 'before-string gdb-string))))
@@ -1749,7 +1731,7 @@ PUTSTRING."
;;from remove-images
(defun gdb-remove-strings (start end &optional buffer)
"Remove strings between START and END in BUFFER.
-Remove only strings that were put in BUFFER with calls to `put-string'.
+Remove only strings that were put in BUFFER with calls to `gdb-put-string'.
BUFFER nil or omitted means use the current buffer."
(unless buffer
(setq buffer (current-buffer)))
@@ -1760,6 +1742,72 @@ BUFFER nil or omitted means use the current buffer."
(delete-overlay overlay)))
(setq overlays (cdr overlays)))))
+(defun gdb-put-breakpoint-icon (enabled)
+ (let ((start (progn (beginning-of-line) (- (point) 1)))
+ (end (progn (end-of-line) (+ (point) 1))))
+ (gdb-remove-breakpoint-icons start end)
+ (if (display-images-p)
+ (if (>= (car (window-fringes)) 8)
+ (gdb-put-string
+ nil (1+ start)
+ `(left-fringe
+ ,(or breakpoint-bitmap
+ (setq breakpoint-bitmap
+ (define-fringe-bitmap
+ "\x3c\x7e\xff\xff\xff\xff\x7e\x3c")))
+ ,(if enabled
+ 'breakpoint-enabled-bitmap-face
+ 'breakpoint-disabled-bitmap-face)))
+ (when (< left-margin-width 2)
+ (save-current-buffer
+ (setq left-margin-width 2)
+ (if (get-buffer-window (current-buffer))
+ (set-window-margins (get-buffer-window
+ (current-buffer))
+ left-margin-width
+ right-margin-width))))
+ (put-image
+ (if enabled
+ (or breakpoint-enabled-icon
+ (setq breakpoint-enabled-icon
+ (find-image `((:type xpm :data
+ ,breakpoint-xpm-data
+ :ascent 100 :pointer hand)
+ (:type pbm :data
+ ,breakpoint-enabled-pbm-data
+ :ascent 100 :pointer hand)))))
+ (or breakpoint-disabled-icon
+ (setq breakpoint-disabled-icon
+ (find-image `((:type xpm :data
+ ,breakpoint-xpm-data
+ :conversion disabled
+ :ascent 100)
+ (:type pbm :data
+ ,breakpoint-disabled-pbm-data
+ :ascent 100))))))
+ (+ start 1) nil 'left-margin))
+ (when (< left-margin-width 2)
+ (save-current-buffer
+ (setq left-margin-width 2)
+ (if (get-buffer-window (current-buffer))
+ (set-window-margins (get-buffer-window
+ (current-buffer))
+ left-margin-width
+ right-margin-width))))
+ (gdb-put-string (if enabled "B" "b") (1+ start)))))
+
+(defun gdb-remove-breakpoint-icons (start end &optional remove-margin)
+ (gdb-remove-strings start end)
+ (if (display-images-p)
+ (remove-images start end))
+ (when remove-margin
+ (setq left-margin-width 0)
+ (if (get-buffer-window (current-buffer))
+ (set-window-margins (get-buffer-window
+ (current-buffer))
+ left-margin-width
+ right-margin-width))))
+
(defun gdb-put-arrow (putstring pos)
"Put arrow string PUTSTRING in the left margin in front of POS
in the current buffer. PUTSTRING is displayed by putting an
@@ -1813,9 +1861,7 @@ BUFFER nil or omitted means use the current buffer."
(setq gdb-arrow-position (point))
(gdb-put-arrow "=>" (point))))))
;; remove all breakpoint-icons in assembler buffer before updating.
- (if (display-images-p)
- (remove-images (point-min) (point-max))
- (gdb-remove-strings (point-min) (point-max))))
+ (gdb-remove-breakpoint-icons (point-min) (point-max)))
(with-current-buffer (gdb-get-buffer 'gdb-breakpoints-buffer)
(goto-char (point-min))
(while (< (point) (- (point-max) 1))
@@ -1832,24 +1878,7 @@ BUFFER nil or omitted means use the current buffer."
(with-current-buffer buffer
(goto-char (point-min))
(if (re-search-forward address nil t)
- (let ((start (progn (beginning-of-line) (- (point) 1)))
- (end (progn (end-of-line) (+ (point) 1))))
- (if (display-images-p)
- (progn
- (remove-images start end)
- (if (eq ?y flag)
- (put-image breakpoint-enabled-icon
- (+ start 1)
- "breakpoint icon enabled"
- 'left-margin)
- (put-image breakpoint-disabled-icon
- (+ start 1)
- "breakpoint icon disabled"
- 'left-margin)))
- (gdb-remove-strings start end)
- (if (eq ?y flag)
- (gdb-put-string "B" (+ start 1))
- (gdb-put-string "b" (+ start 1)))))))))))
+ (gdb-put-breakpoint-icon (eq flag ?y))))))))
(if (not (equal gdb-current-address "main"))
(set-window-point (get-buffer-window buffer) gdb-arrow-position))))
@@ -1864,7 +1893,6 @@ BUFFER nil or omitted means use the current buffer."
\\{gdb-assembler-mode-map}"
(setq major-mode 'gdb-assembler-mode)
(setq mode-name "Machine")
- (setq left-margin-width 2)
(setq fringes-outside-margins t)
(setq buffer-read-only t)
(use-local-map gdb-assembler-mode-map)
diff --git a/lisp/info-look.el b/lisp/info-look.el
index 89eb1d7e411..8242932c3af 100644
--- a/lisp/info-look.el
+++ b/lisp/info-look.el
@@ -1,7 +1,7 @@
;;; info-look.el --- major-mode-sensitive Info index lookup facility
;; An older version of this was known as libc.el.
-;; Copyright (C) 1995,96,97,98,99,2001,2003 Free Software Foundation, Inc.
+;; Copyright (C) 1995,96,97,98,99,2001,2003,2004 Free Software Foundation, Inc.
;; Author: Ralph Schleicher <rs@nunatak.allgaeu.org>
;; (did not show signs of life (Nov 2001) -stef)
@@ -808,7 +808,7 @@ Return nil if there is nothing appropriate in the buffer near point."
(info-lookup-maybe-add-help
:mode 'scheme-mode
- :regexp "[^()'\" \t\n]+"
+ :regexp "[^()`',\" \t\n]+"
:ignore-case t
;; Aubrey Jaffer's rendition from <URL:ftp://ftp-swiss.ai.mit.edu/pub/scm>
:doc-spec '(("(r5rs)Index" nil
diff --git a/lisp/isearch.el b/lisp/isearch.el
index d84510eb7a2..6eecd623cfd 100644
--- a/lisp/isearch.el
+++ b/lisp/isearch.el
@@ -1,6 +1,6 @@
;;; isearch.el --- incremental search minor mode
-;; Copyright (C) 1992, 93, 94, 95, 96, 97, 1999, 2000, 01, 2003
+;; Copyright (C) 1992, 93, 94, 95, 96, 97, 1999, 2000, 01, 2003, 2004
;; Free Software Foundation, Inc.
;; Author: Daniel LaLiberte <liberte@cs.uiuc.edu>
@@ -2128,26 +2128,30 @@ A value of nil means highlight all matches."
:group 'isearch)
(defface isearch
- '((((type tty pc) (class color))
- (:background "magenta4" :foreground "cyan1"))
- (((class color) (background light))
+ '((((class color) (min-colors 88) (background light))
;; The background must not be too dark, for that means
;; the character is hard to see when the cursor is there.
(:background "magenta2" :foreground "lightskyblue1"))
- (((class color) (background dark))
+ (((class color) (min-colors 88) (background dark))
(:background "palevioletred2" :foreground "brown4"))
+ (((class color) (min-colors 16))
+ (:background "magenta4" :foreground "cyan1"))
+ (((class color) (min-colors 8))
+ (:background "magenta4" :foreground "cyan1"))
(t (:inverse-video t)))
"Face for highlighting Isearch matches."
:group 'isearch-faces)
(defvar isearch 'isearch)
(defface isearch-lazy-highlight-face
- '((((type tty pc) (class color))
- (:background "turquoise3"))
- (((class color) (background light))
+ '((((class color) (min-colors 88) (background light))
(:background "paleturquoise"))
- (((class color) (background dark))
+ (((class color) (min-colors 88) (background dark))
(:background "paleturquoise4"))
+ (((class color) (min-colors 16))
+ (:background "turquoise3"))
+ (((class color) (min-colors 8))
+ (:background "turquoise3"))
(t (:underline t)))
"Face for lazy highlighting of Isearch matches other than the current one."
:group 'isearch-faces)
diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el
index a23dc0a307e..f765b37c76a 100644
--- a/lisp/progmodes/sh-script.el
+++ b/lisp/progmodes/sh-script.el
@@ -315,9 +315,7 @@ shell it really is."
:type '(repeat (cons (symbol :tag "Shell")
(choice (const :tag "No Arguments" nil)
(string :tag "Arguments")
- (cons :format "Evaluate: %v"
- (const :format "" eval)
- sexp))))
+ (sexp :format "Evaluate: %v"))))
:group 'sh-script)
(defcustom sh-imenu-generic-expression
@@ -498,9 +496,7 @@ This is buffer-local in every such buffer.")
See `sh-feature'."
:type '(repeat (cons (symbol :tag "Shell")
(choice (const :tag "require" t)
- (cons :format "Evaluate: %v"
- (const :format "" eval)
- sexp))))
+ (sexp :format "Evaluate: %v"))))
:group 'sh-script)
@@ -515,9 +511,7 @@ First grouping matches the variable name. This is upto and including the `='
sign. See `sh-feature'."
:type '(repeat (cons (symbol :tag "Shell")
(choice regexp
- (cons :format "Evaluate: %v"
- (const :format "" eval)
- sexp))))
+ (sexp :format "Evaluate: %v"))))
:group 'sh-script)
@@ -639,9 +633,7 @@ Note that on some systems not all builtins are available or some are
implemented as aliases. See `sh-feature'."
:type '(repeat (cons (symbol :tag "Shell")
(choice (repeat string)
- (cons :format "Evaluate: %v"
- (const :format "" eval)
- sexp))))
+ (sexp :format "Evaluate: %v"))))
:group 'sh-script)
@@ -663,9 +655,7 @@ system, the distinction here has been based on whether they influence the
flow of control or syntax. See `sh-feature'."
:type '(repeat (cons (symbol :tag "Shell")
(choice (repeat string)
- (cons :format "Evaluate: %v"
- (const :format "" eval)
- sexp))))
+ (sexp :format "Evaluate: %v"))))
:group 'sh-script)
@@ -702,9 +692,7 @@ flow of control or syntax. See `sh-feature'."
See `sh-feature'."
:type '(repeat (cons (symbol :tag "Shell")
(choice (repeat string)
- (cons :format "Evaluate: %v"
- (const :format "" eval)
- sexp))))
+ (sexp :format "Evaluate: %v"))))
:group 'sh-script)