;;; ediff-help.el --- Code related to the contents of Ediff help buffers
-;; Copyright (C) 1996-2011 Free Software Foundation, Inc.
+;; Copyright (C) 1996-2016 Free Software Foundation, Inc.
;; Author: Michael Kifer <kifer@cs.stonybrook.edu>
;; Package: ediff
(defconst ediff-long-help-message-compare3
"
p,DEL -previous diff | | -vert/horiz split | xy -copy buf X's region to Y
-n,SPC -next diff | h -hilighting | rx -restore buf X's old diff
+n,SPC -next diff | h -highlighting | rx -restore buf X's old diff
j -jump to diff | @ -auto-refinement | * -refine current region
gx -goto X's point| ## -ignore whitespace | ! -update diff regions
C-l -recenter | #c -ignore case |
(defconst ediff-long-help-message-compare2
"
p,DEL -previous diff | | -vert/horiz split |a/b -copy A/B's region to B/A
-n,SPC -next diff | h -hilighting | rx -restore buf X's old diff
+n,SPC -next diff | h -highlighting | rx -restore buf X's old diff
j -jump to diff | @ -auto-refinement | * -refine current region
gx -goto X's point| ## -ignore whitespace | ! -update diff regions
C-l -recenter | #c -ignore case |
(defconst ediff-long-help-message-narrow2
"
p,DEL -previous diff | | -vert/horiz split |a/b -copy A/B's region to B/A
-n,SPC -next diff | h -hilighting | rx -restore buf X's old diff
+n,SPC -next diff | h -highlighting | rx -restore buf X's old diff
j -jump to diff | @ -auto-refinement | * -refine current region
gx -goto X's point| ## -ignore whitespace | ! -update diff regions
C-l -recenter | #c -ignore case | % -narrow/widen buffs
(defconst ediff-long-help-message-word-mode
"
p,DEL -previous diff | | -vert/horiz split | xy -copy buf X's region to Y
-n,SPC -next diff | h -hilighting | rx -restore buf X's old diff
+n,SPC -next diff | h -highlighting | rx -restore buf X's old diff
j -jump to diff | |
gx -goto X's point| % -narrow/widen buffs | ! -recompute diffs
C-l -recenter | #c -ignore case |
(defconst ediff-long-help-message-merge
"
p,DEL -previous diff | | -vert/horiz split | x -copy buf X's region to C
-n,SPC -next diff | h -hilighting | r -restore buf C's old diff
+n,SPC -next diff | h -highlighting | r -restore buf C's old diff
j -jump to diff | @ -auto-refinement | * -refine current region
gx -goto X's point| ## -ignore whitespace | ! -update diff regions
C-l -recenter | #f/#h -focus/hide regions | + -combine diff regions
(ediff-documentation "Quick Help Commands")
(let (case-fold-search)
- (cond ((string= cmd "?") (re-search-forward "^`\\?'"))
- ((string= cmd "G") (re-search-forward "^`G'"))
- ((string= cmd "E") (re-search-forward "^`E'"))
- ((string= cmd "wd") (re-search-forward "^`wd'"))
- ((string= cmd "wx") (re-search-forward "^`wa'"))
- ((string= cmd "a/b") (re-search-forward "^`a'"))
- ((string= cmd "x") (re-search-forward "^`a'"))
- ((string= cmd "xy") (re-search-forward "^`ab'"))
- ((string= cmd "p,DEL") (re-search-forward "^`p'"))
- ((string= cmd "n,SPC") (re-search-forward "^`n'"))
- ((string= cmd "j") (re-search-forward "^`j'"))
- ((string= cmd "gx") (re-search-forward "^`ga'"))
- ((string= cmd "!") (re-search-forward "^`!'"))
- ((string= cmd "*") (re-search-forward "^`\\*'"))
- ((string= cmd "m") (re-search-forward "^`m'"))
- ((string= cmd "|") (re-search-forward "^`|'"))
- ((string= cmd "@") (re-search-forward "^`@'"))
- ((string= cmd "h") (re-search-forward "^`h'"))
- ((string= cmd "r") (re-search-forward "^`r'"))
- ((string= cmd "rx") (re-search-forward "^`ra'"))
- ((string= cmd "##") (re-search-forward "^`##'"))
- ((string= cmd "#c") (re-search-forward "^`#c'"))
- ((string= cmd "#f/#h") (re-search-forward "^`#f'"))
- ((string= cmd "X") (re-search-forward "^`A'"))
- ((string= cmd "v/V") (re-search-forward "^`v'"))
- ((string= cmd "</>") (re-search-forward "^`<'"))
- ((string= cmd "~") (re-search-forward "^`~'"))
- ((string= cmd "i") (re-search-forward "^`i'"))
- ((string= cmd "D") (re-search-forward "^`D'"))
- ((string= cmd "R") (re-search-forward "^`R'"))
- ((string= cmd "M") (re-search-forward "^`M'"))
- ((string= cmd "z/q") (re-search-forward "^`z'"))
- ((string= cmd "%") (re-search-forward "^`%'"))
- ((string= cmd "C-l") (re-search-forward "^`C-l'"))
- ((string= cmd "$$") (re-search-forward "^`\\$\\$'"))
- ((string= cmd "$*") (re-search-forward "^`\\$\\*'"))
- ((string= cmd "/") (re-search-forward "^`/'"))
- ((string= cmd "&") (re-search-forward "^`&'"))
- ((string= cmd "s") (re-search-forward "^`s'"))
- ((string= cmd "+") (re-search-forward "^`\\+'"))
- ((string= cmd "=") (re-search-forward "^`='"))
+ (cond ((string= cmd "?") (re-search-forward "^['`‘]\\?['’]"))
+ ((string= cmd "G") (re-search-forward "^['`‘]G['’]"))
+ ((string= cmd "E") (re-search-forward "^['`‘]E['’]"))
+ ((string= cmd "wd") (re-search-forward "^['`‘]wd['’]"))
+ ((string= cmd "wx") (re-search-forward "^['`‘]wa['’]"))
+ ((string= cmd "a/b") (re-search-forward "^['`‘]a['’]"))
+ ((string= cmd "x") (re-search-forward "^['`‘]a['’]"))
+ ((string= cmd "xy") (re-search-forward "^['`‘]ab['’]"))
+ ((string= cmd "p,DEL") (re-search-forward "^['`‘]p['’]"))
+ ((string= cmd "n,SPC") (re-search-forward "^['`‘]n['’]"))
+ ((string= cmd "j") (re-search-forward "^['`‘]j['’]"))
+ ((string= cmd "gx") (re-search-forward "^['`‘]ga['’]"))
+ ((string= cmd "!") (re-search-forward "^['`‘]!['’]"))
+ ((string= cmd "*") (re-search-forward "^['`‘]\\*['’]"))
+ ((string= cmd "m") (re-search-forward "^['`‘]m['’]"))
+ ((string= cmd "|") (re-search-forward "^['`‘]|['’]"))
+ ((string= cmd "@") (re-search-forward "^['`‘]@['’]"))
+ ((string= cmd "h") (re-search-forward "^['`‘]h['’]"))
+ ((string= cmd "r") (re-search-forward "^['`‘]r['’]"))
+ ((string= cmd "rx") (re-search-forward "^['`‘]ra['’]"))
+ ((string= cmd "##") (re-search-forward "^['`‘]##['’]"))
+ ((string= cmd "#c") (re-search-forward "^['`‘]#c['’]"))
+ ((string= cmd "#f/#h") (re-search-forward "^['`‘]#f['’]"))
+ ((string= cmd "X") (re-search-forward "^['`‘]A['’]"))
+ ((string= cmd "v/V") (re-search-forward "^['`‘]v['’]"))
+ ((string= cmd "</>") (re-search-forward "^['`‘]<['’]"))
+ ((string= cmd "~") (re-search-forward "^['`‘]~['’]"))
+ ((string= cmd "i") (re-search-forward "^['`‘]i['’]"))
+ ((string= cmd "D") (re-search-forward "^['`‘]D['’]"))
+ ((string= cmd "R") (re-search-forward "^['`‘]R['’]"))
+ ((string= cmd "M") (re-search-forward "^['`‘]M['’]"))
+ ((string= cmd "z/q") (re-search-forward "^['`‘]z['’]"))
+ ((string= cmd "%") (re-search-forward "^['`‘]%['’]"))
+ ((string= cmd "C-l") (re-search-forward "^['`‘]C-l['’]"))
+ ((string= cmd "$$") (re-search-forward "^['`‘]\\$\\$['’]"))
+ ((string= cmd "$*") (re-search-forward "^['`‘]\\$\\*['’]"))
+ ((string= cmd "/") (re-search-forward "^['`‘]/['’]"))
+ ((string= cmd "&") (re-search-forward "^['`‘]&['’]"))
+ ((string= cmd "s") (re-search-forward "^['`‘]s['’]"))
+ ((string= cmd "+") (re-search-forward "^['`‘]\\+['’]"))
+ ((string= cmd "=") (re-search-forward "^['`‘]=['’]"))
(t (error "Undocumented command! Type `G' in Ediff Control Panel to drop a note to the Ediff maintainer")))
) ; let case-fold-search
))
(defun ediff-indent-help-message ()
- (let* ((shift (/ (max 0 (- (window-width (selected-window))
+ (let* ((shift (/ (max 0 (- (window-width)
(ediff-help-message-line-length)))
2))
(str (make-string shift ?\ )))