diff options
| author | John Wiegley | 2016-02-22 11:33:54 -0800 |
|---|---|---|
| committer | John Wiegley | 2016-02-22 11:33:54 -0800 |
| commit | 81ef756e6aea369ec78f19b3609f01ceddc5851f (patch) | |
| tree | 183251df6d3bf87ccc1216cf187e141488dd7c82 /lisp | |
| parent | 23d463d40cca1b68ef4f74a303b748e0649c506c (diff) | |
| parent | a9c48d5c9e3cb5952aab1c6e8821677d49068a74 (diff) | |
| download | emacs-81ef756e6aea369ec78f19b3609f01ceddc5851f.tar.gz emacs-81ef756e6aea369ec78f19b3609f01ceddc5851f.zip | |
Merge from origin/emacs-25
a9c48d5 Additional fixes for file notification
6bd9d69 Fix documentation of 'global-disable-point-adjustment'
8c22ac9 ; Spelling fix
2975784 Set file modes of pinentry socket for extra safety
2667b3e Clarify GnuPG version compatibility chapter
5e34c36 Revert "Change the default socket location for pinentry"
e19c1c3 Kill off xref--display-history
5698947 Keep the xref buffer visible until the user quits it explicitly
e34fbde Change the default socket location for pinentry
5f89658 Mention how to enable pinentry feature
db51224 Sync with gnulib
aa5a794 Remove `semanticdb-save-all-db-idle' from `auto-save-hook'
2d8b2fd Restore point when writing semantic table to disk
27d3430 Mention pinentry.el in epa manual
5baa001 Fix Bug#22736
7261355 Grammar fix in doc string
d0f3b18 Naming fix for consistency
74ec92d Prefer customized value for GnuPG executable
ea0b604 Fix memory reservation on MS-Windows
c5f72aa Update NextStep readme and add wish list.
6de26a7 Report also result in `file-notify--test-event-handler'
5d17ae7 Improve file-notify-test08-watched-file-in-watched-dir
1cb1268 Fix todo-mode item date editing bugs
1e996cf Fix "[:upper:]" for non-ASCII characters
896f993 Allow customising the article mode cursor behavior
24c1c1d Use pop-to-buffer-same-window in woman.el
2a75f64 New filenotify test for bug#22736
c9bccf7 Report critical battery errors
d675db9 Make eww message toggling message clearer
5e0bb40 * lisp/calc/calc-units.el (math-standard-units): Update to 2014 CODATA adjustment.
fa8fd65 ; Improve character-folding entries in NEWS
3722a69 Fix bugs in window resizing code
289d5c6 Fix decoding DOS EOL in a unibyte buffer
2abcb06 Correct c-parse-state cache manipulation error.
14aec91 Take advantage of new GnuPG version check function
e80c2a7 Make GnuPG version check robuster
15a9464 Fix x-load-color-file pointer signedness
132dbf0 * lisp/time-stamp.el (time-stamp-time-zone): Fix doc string punct.
78ab6f1 Follow convention for greek letter constants.
106b5bb Add Stefan-Boltzmann constant to calc units table.
b96baa8 * lisp/calc/calc-units.el (math-build-units-table-buffer): Use special-mode.
5f91cf9 Avoid loading cl-lib for term/xterm.elc, eg in -Q -nw. (Bug#22669)
2d40f7d Fix soffice UserInstallation-URL for Windows
b1a3ebe Fix display of <pre> elements
57d0e3d ; * lisp/help-fns.el: Remove outdated comment.
7a0628d ; * admin/make-tarball.txt: Mention cleaning.
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/battery.el | 6 | ||||
| -rw-r--r-- | lisp/calc/calc-units.el | 85 | ||||
| -rw-r--r-- | lisp/calendar/todo-mode.el | 20 | ||||
| -rw-r--r-- | lisp/cedet/semantic/db-file.el | 32 | ||||
| -rw-r--r-- | lisp/cedet/semantic/db-mode.el | 1 | ||||
| -rw-r--r-- | lisp/custom.el | 2 | ||||
| -rw-r--r-- | lisp/doc-view.el | 5 | ||||
| -rw-r--r-- | lisp/emacs-lisp/cl-generic.el | 4 | ||||
| -rw-r--r-- | lisp/emacs-lisp/package.el | 15 | ||||
| -rw-r--r-- | lisp/epg-config.el | 82 | ||||
| -rw-r--r-- | lisp/epg.el | 10 | ||||
| -rw-r--r-- | lisp/filenotify.el | 63 | ||||
| -rw-r--r-- | lisp/gnus/gnus-art.el | 9 | ||||
| -rw-r--r-- | lisp/help-fns.el | 1 | ||||
| -rw-r--r-- | lisp/net/eww.el | 13 | ||||
| -rw-r--r-- | lisp/net/pinentry.el | 28 | ||||
| -rw-r--r-- | lisp/progmodes/cc-engine.el | 6 | ||||
| -rw-r--r-- | lisp/progmodes/xref.el | 113 | ||||
| -rw-r--r-- | lisp/time-stamp.el | 2 | ||||
| -rw-r--r-- | lisp/window.el | 26 | ||||
| -rw-r--r-- | lisp/woman.el | 6 |
21 files changed, 310 insertions, 219 deletions
diff --git a/lisp/battery.el b/lisp/battery.el index d0293697bef..b5e312f6c3e 100644 --- a/lisp/battery.el +++ b/lisp/battery.el | |||
| @@ -628,12 +628,12 @@ The following %-sequences are provided: | |||
| 628 | (cond ((looking-at "; charging") | 628 | (cond ((looking-at "; charging") |
| 629 | (setq battery-status "charging" | 629 | (setq battery-status "charging" |
| 630 | battery-status-symbol "+")) | 630 | battery-status-symbol "+")) |
| 631 | ((< (string-to-number load-percentage) battery-load-low) | ||
| 632 | (setq battery-status "low" | ||
| 633 | battery-status-symbol "-")) | ||
| 634 | ((< (string-to-number load-percentage) battery-load-critical) | 631 | ((< (string-to-number load-percentage) battery-load-critical) |
| 635 | (setq battery-status "critical" | 632 | (setq battery-status "critical" |
| 636 | battery-status-symbol "!")) | 633 | battery-status-symbol "!")) |
| 634 | ((< (string-to-number load-percentage) battery-load-low) | ||
| 635 | (setq battery-status "low" | ||
| 636 | battery-status-symbol "-")) | ||
| 637 | (t | 637 | (t |
| 638 | (setq battery-status "high" | 638 | (setq battery-status "high" |
| 639 | battery-status-symbol ""))) | 639 | battery-status-symbol ""))) |
diff --git a/lisp/calc/calc-units.el b/lisp/calc/calc-units.el index 0c8920848fc..07d9ac90d85 100644 --- a/lisp/calc/calc-units.el +++ b/lisp/calc/calc-units.el | |||
| @@ -43,6 +43,9 @@ | |||
| 43 | ;;; Measures, by François Cardarelli) | 43 | ;;; Measures, by François Cardarelli) |
| 44 | ;;; All conversions are exact unless otherwise noted. | 44 | ;;; All conversions are exact unless otherwise noted. |
| 45 | 45 | ||
| 46 | ;; CODATA values updated February 2016, using 2014 adjustment | ||
| 47 | ;; http://arxiv.org/pdf/1507.07956.pdf | ||
| 48 | |||
| 46 | (defvar math-standard-units | 49 | (defvar math-standard-units |
| 47 | '( ;; Length | 50 | '( ;; Length |
| 48 | ( m nil "*Meter" ) | 51 | ( m nil "*Meter" ) |
| @@ -136,8 +139,8 @@ | |||
| 136 | "31.10347680 g") ;; ESUWM, 1/12 exact value for lbt | 139 | "31.10347680 g") ;; ESUWM, 1/12 exact value for lbt |
| 137 | ( ct "(2/10) g" "Carat" nil | 140 | ( ct "(2/10) g" "Carat" nil |
| 138 | "0.2 g") ;; ESUWM | 141 | "0.2 g") ;; ESUWM |
| 139 | ( u "1.660538782*10^(-27) kg" "Unified atomic mass" nil | 142 | ( u "1.660539040*10^(-27) kg" "Unified atomic mass" nil |
| 140 | "1.660538782 10^-27 kg (*)");;(approx) CODATA | 143 | "1.660539040 10^-27 kg (*)");;(approx) CODATA |
| 141 | 144 | ||
| 142 | ;; Force | 145 | ;; Force |
| 143 | ( N "m kg/s^2" "*Newton" ) | 146 | ( N "m kg/s^2" "*Newton" ) |
| @@ -204,8 +207,8 @@ | |||
| 204 | ( C "A s" "Coulomb" ) | 207 | ( C "A s" "Coulomb" ) |
| 205 | ( Fdy "ech Nav" "Faraday" ) | 208 | ( Fdy "ech Nav" "Faraday" ) |
| 206 | ( e "ech" "Elementary charge" ) | 209 | ( e "ech" "Elementary charge" ) |
| 207 | ( ech "1.602176487*10^(-19) C" "Elementary charge" nil | 210 | ( ech "1.6021766208*10^(-19) C" "Elementary charge" nil |
| 208 | "1.602176487 10^-19 C (*)") ;;(approx) CODATA | 211 | "1.6021766208 10^-19 C (*)") ;;(approx) CODATA |
| 209 | ( V "W/A" "Volt" ) | 212 | ( V "W/A" "Volt" ) |
| 210 | ( ohm "V/A" "Ohm" ) | 213 | ( ohm "V/A" "Ohm" ) |
| 211 | ( Ω "ohm" "Ohm" ) | 214 | ( Ω "ohm" "Ohm" ) |
| @@ -254,47 +257,51 @@ | |||
| 254 | 257 | ||
| 255 | ;; Other physical quantities | 258 | ;; Other physical quantities |
| 256 | ;; The values are from CODATA, and are approximate. | 259 | ;; The values are from CODATA, and are approximate. |
| 257 | ( h "6.62606896*10^(-34) J s" "*Planck's constant" nil | 260 | ( h "6.626070040*10^(-34) J s" "*Planck's constant" nil |
| 258 | "6.62606896 10^-34 J s (*)") | 261 | "6.626070040 10^-34 J s (*)") |
| 259 | ( hbar "h / (2 pi)" "Planck's constant" ) ;; Exact | 262 | ( hbar "h / (2 pi)" "Planck's constant" ) ;; Exact |
| 260 | ( mu0 "4 pi 10^(-7) H/m" "Permeability of vacuum") ;; Exact | 263 | ( mu0 "4 pi 10^(-7) H/m" "Permeability of vacuum") ;; Exact |
| 261 | ( μ0 "mu0" "Permeability of vacuum") ;; Exact | 264 | ( μ0 "mu0" "Permeability of vacuum") ;; Exact |
| 262 | ( eps0 "1 / (mu0 c^2)" "Permittivity of vacuum" ) | 265 | ( eps0 "1 / (mu0 c^2)" "Permittivity of vacuum" ) |
| 263 | ( ε0 "eps0" "Permittivity of vacuum" ) | 266 | ( ε0 "eps0" "Permittivity of vacuum" ) |
| 264 | ( G "6.67428*10^(-11) m^3/(kg s^2)" "Gravitational constant" nil | 267 | ( G "6.67408*10^(-11) m^3/(kg s^2)" "Gravitational constant" nil |
| 265 | "6.67428 10^-11 m^3/(kg s^2) (*)") | 268 | "6.67408 10^-11 m^3/(kg s^2) (*)") |
| 266 | ( Nav "6.02214179*10^(23) / mol" "Avogadro's constant" nil | 269 | ( Nav "6.022140857*10^(23) / mol" "Avogadro's constant" nil |
| 267 | "6.02214179 10^23 / mol (*)") | 270 | "6.022140857 10^23 / mol (*)") |
| 268 | ( me "9.10938215*10^(-31) kg" "Electron rest mass" nil | 271 | ( me "9.10938356*10^(-31) kg" "Electron rest mass" nil |
| 269 | "9.10938215 10^-31 kg (*)") | 272 | "9.10938356 10^-31 kg (*)") |
| 270 | ( mp "1.672621637*10^(-27) kg" "Proton rest mass" nil | 273 | ( mp "1.672621898*10^(-27) kg" "Proton rest mass" nil |
| 271 | "1.672621637 10^-27 kg (*)") | 274 | "1.672621898 10^-27 kg (*)") |
| 272 | ( mn "1.674927211*10^(-27) kg" "Neutron rest mass" nil | 275 | ( mn "1.674927471*10^(-27) kg" "Neutron rest mass" nil |
| 273 | "1.674927211 10^-27 kg (*)") | 276 | "1.674927471 10^-27 kg (*)") |
| 274 | ( mmu "1.88353130*10^(-28) kg" "Muon rest mass" nil | 277 | ( mmu "1.883531594*10^(-28) kg" "Muon rest mass" nil |
| 275 | "1.88353130 10^-28 kg (*)") | 278 | "1.883531594 10^-28 kg (*)") |
| 276 | ( mμ "mmu" "Muon rest mass" nil | 279 | ( mμ "mmu" "Muon rest mass" nil |
| 277 | "1.88353130 10^-28 kg (*)") | 280 | "1.883531594 10^-28 kg (*)") |
| 278 | ( Ryd "10973731.568527 /m" "Rydberg's constant" nil | 281 | ( Ryd "10973731.568508 /m" "Rydberg's constant" nil |
| 279 | "10973731.568527 /m (*)") | 282 | "10973731.568508 /m (*)") |
| 280 | ( k "1.3806504*10^(-23) J/K" "Boltzmann's constant" nil | 283 | ( k "1.38064852*10^(-23) J/K" "Boltzmann's constant" nil |
| 281 | "1.3806504 10^-23 J/K (*)") | 284 | "1.38064852 10^-23 J/K (*)") |
| 282 | ( alpha "7.2973525376*10^(-3)" "Fine structure constant" nil | 285 | ( sigma "5.670367*10^(-8) W/(m^2 K^4)" "Stefan-Boltzmann constant" nil |
| 283 | "7.2973525376 10^-3 (*)") | 286 | "5.670367 10^-8 W/(m^2 K^4) (*)") |
| 287 | ( σ "sigma" "Stefan-Boltzmann constant" nil | ||
| 288 | "5.670367 10^-8 W/(m^2 K^4) (*)") | ||
| 289 | ( alpha "7.2973525664*10^(-3)" "Fine structure constant" nil | ||
| 290 | "7.2973525664 10^-3 (*)") | ||
| 284 | ( α "alpha" "Fine structure constant" nil | 291 | ( α "alpha" "Fine structure constant" nil |
| 285 | "7.2973525376 10^-3 (*)") | 292 | "7.2973525664 10^-3 (*)") |
| 286 | ( muB "927.400915*10^(-26) J/T" "Bohr magneton" nil | 293 | ( muB "927.4009994*10^(-26) J/T" "Bohr magneton" nil |
| 287 | "927.400915 10^-26 J/T (*)") | 294 | "927.4009994 10^-26 J/T (*)") |
| 288 | ( muN "5.05078324*10^(-27) J/T" "Nuclear magneton" nil | 295 | ( muN "5.050783699*10^(-27) J/T" "Nuclear magneton" nil |
| 289 | "5.05078324 10^-27 J/T (*)") | 296 | "5.050783699 10^-27 J/T (*)") |
| 290 | ( mue "-928.476377*10^(-26) J/T" "Electron magnetic moment" nil | 297 | ( mue "-928.4764620*10^(-26) J/T" "Electron magnetic moment" nil |
| 291 | "-928.476377 10^-26 J/T (*)") | 298 | "-928.4764620 10^-26 J/T (*)") |
| 292 | ( mup "1.410606662*10^(-26) J/T" "Proton magnetic moment" nil | 299 | ( mup "1.4106067873*10^(-26) J/T" "Proton magnetic moment" nil |
| 293 | "1.410606662 10^-26 J/T (*)") | 300 | "1.4106067873 10^-26 J/T (*)") |
| 294 | ( R0 "8.314472 J/(mol K)" "Molar gas constant" nil | 301 | ( R0 "8.3144598 J/(mol K)" "Molar gas constant" nil |
| 295 | "8.314472 J/(mol K) (*)") | 302 | "8.3144598 J/(mol K) (*)") |
| 296 | ( V0 "22.710981*10^(-3) m^3/mol" "Standard volume of ideal gas" nil | 303 | ( V0 "22.710947*10^(-3) m^3/mol" "Standard volume of ideal gas" nil |
| 297 | "22.710981 10^-3 m^3/mol (*)") | 304 | "22.710947 10^-3 m^3/mol (*)") |
| 298 | ;; Logarithmic units | 305 | ;; Logarithmic units |
| 299 | ( Np nil "*Neper") | 306 | ( Np nil "*Neper") |
| 300 | ( dB "(ln(10)/20) Np" "decibel"))) | 307 | ( dB "(ln(10)/20) Np" "decibel"))) |
| @@ -1628,7 +1635,7 @@ If COMP or STD is non-nil, put that in the units table instead." | |||
| 1628 | "TeX point will be `pt' instead of `texpt', for example.\n" | 1635 | "TeX point will be `pt' instead of `texpt', for example.\n" |
| 1629 | "To avoid conflicts, the unit names for pint and parsec will\n" | 1636 | "To avoid conflicts, the unit names for pint and parsec will\n" |
| 1630 | "be `pint' and `parsec' instead of `pt' and `pc'.")))) | 1637 | "be `pint' and `parsec' instead of `pt' and `pc'.")))) |
| 1631 | (view-mode) | 1638 | (special-mode) |
| 1632 | (message "Formatting units table...done")) | 1639 | (message "Formatting units table...done")) |
| 1633 | (setq math-units-table-buffer-valid t) | 1640 | (setq math-units-table-buffer-valid t) |
| 1634 | (let ((oldbuf (current-buffer))) | 1641 | (let ((oldbuf (current-buffer))) |
diff --git a/lisp/calendar/todo-mode.el b/lisp/calendar/todo-mode.el index 29d8dfcfb7f..94cd08eaa4e 100644 --- a/lisp/calendar/todo-mode.el +++ b/lisp/calendar/todo-mode.el | |||
| @@ -2262,9 +2262,8 @@ made in the number or names of categories." | |||
| 2262 | (mlist (append tmn-array nil)) | 2262 | (mlist (append tmn-array nil)) |
| 2263 | (tma-array todo-month-abbrev-array) | 2263 | (tma-array todo-month-abbrev-array) |
| 2264 | (mablist (append tma-array nil)) | 2264 | (mablist (append tma-array nil)) |
| 2265 | (yy (and oyear (unless (string= oyear "*") | 2265 | (yy (and oyear (string-to-number oyear))) ; 0 if year is "*". |
| 2266 | (string-to-number oyear)))) | 2266 | (mm (or (and omonth (if (string= omonth "*") 13 |
| 2267 | (mm (or (and omonth (unless (string= omonth "*") | ||
| 2268 | (string-to-number omonth))) | 2267 | (string-to-number omonth))) |
| 2269 | (1+ (- (length mlist) | 2268 | (1+ (- (length mlist) |
| 2270 | (length (or (member omonthname mlist) | 2269 | (length (or (member omonthname mlist) |
| @@ -2330,12 +2329,11 @@ made in the number or names of categories." | |||
| 2330 | (if omonth | 2329 | (if omonth |
| 2331 | (number-to-string mm) | 2330 | (number-to-string mm) |
| 2332 | (aref tma-array (1- mm)))))) | 2331 | (aref tma-array (1- mm)))))) |
| 2333 | (let ((yy (string-to-number year)) ; 0 if year is "*". | 2332 | ;; Since the number corresponding to the arbitrary |
| 2334 | ;; When mm is 13 (corresponding to "*" as value | 2333 | ;; month name "*" is out of the range of |
| 2335 | ;; of month), this raises an args-out-of-range | 2334 | ;; calendar-last-day-of-month, set it to 1 |
| 2336 | ;; error in calendar-last-day-of-month, so use 1 | 2335 | ;; (corresponding to January) to allow 31 days. |
| 2337 | ;; (corresponding to January) to get 31 days. | 2336 | (let ((mm (if (= mm 13) 1 mm))) |
| 2338 | (mm (if (= mm 13) 1 mm))) | ||
| 2339 | (if (> (string-to-number day) | 2337 | (if (> (string-to-number day) |
| 2340 | (calendar-last-day-of-month mm yy)) | 2338 | (calendar-last-day-of-month mm yy)) |
| 2341 | (user-error "%s %s does not have %s days" | 2339 | (user-error "%s %s does not have %s days" |
| @@ -2347,7 +2345,7 @@ made in the number or names of categories." | |||
| 2347 | monthname omonthname | 2345 | monthname omonthname |
| 2348 | day (cond | 2346 | day (cond |
| 2349 | ((not current-prefix-arg) | 2347 | ((not current-prefix-arg) |
| 2350 | (todo-read-date 'day mm oyear)) | 2348 | (todo-read-date 'day mm yy)) |
| 2351 | ((string= oday "*") | 2349 | ((string= oday "*") |
| 2352 | (user-error "Cannot increment *")) | 2350 | (user-error "Cannot increment *")) |
| 2353 | ((or (string= omonth "*") (string= omonthname "*")) | 2351 | ((or (string= omonth "*") (string= omonthname "*")) |
| @@ -5933,7 +5931,7 @@ number of the last the day of the month." | |||
| 5933 | (and day (setq day (if (eq day '*) | 5931 | (and day (setq day (if (eq day '*) |
| 5934 | (symbol-name '*) | 5932 | (symbol-name '*) |
| 5935 | (number-to-string day)))) | 5933 | (number-to-string day)))) |
| 5936 | (and month (setq month (if (eq month '*) | 5934 | (and month (setq month (if (= month 13) |
| 5937 | (symbol-name '*) | 5935 | (symbol-name '*) |
| 5938 | (number-to-string month)))) | 5936 | (number-to-string month)))) |
| 5939 | (if arg | 5937 | (if arg |
diff --git a/lisp/cedet/semantic/db-file.el b/lisp/cedet/semantic/db-file.el index d9dd1f94d33..0ae433fecb5 100644 --- a/lisp/cedet/semantic/db-file.el +++ b/lisp/cedet/semantic/db-file.el | |||
| @@ -287,22 +287,22 @@ Argument OBJ is the object to write." | |||
| 287 | (when (semanticdb-live-p obj) | 287 | (when (semanticdb-live-p obj) |
| 288 | (when (semanticdb-in-buffer-p obj) | 288 | (when (semanticdb-in-buffer-p obj) |
| 289 | (with-current-buffer (semanticdb-in-buffer-p obj) | 289 | (with-current-buffer (semanticdb-in-buffer-p obj) |
| 290 | 290 | (save-excursion | |
| 291 | ;; Make sure all our tag lists are up to date. | 291 | ;; Make sure all our tag lists are up to date. |
| 292 | (semantic-fetch-tags) | 292 | (semantic-fetch-tags) |
| 293 | 293 | ||
| 294 | ;; Try to get an accurate unmatched syntax table. | 294 | ;; Try to get an accurate unmatched syntax table. |
| 295 | (when (and (boundp semantic-show-unmatched-syntax-mode) | 295 | (when (and (boundp semantic-show-unmatched-syntax-mode) |
| 296 | semantic-show-unmatched-syntax-mode) | 296 | semantic-show-unmatched-syntax-mode) |
| 297 | ;; Only do this if the user runs unmatched syntax | 297 | ;; Only do this if the user runs unmatched syntax |
| 298 | ;; mode display entries. | 298 | ;; mode display entries. |
| 299 | (oset obj unmatched-syntax | 299 | (oset obj unmatched-syntax |
| 300 | (semantic-show-unmatched-lex-tokens-fetch)) | 300 | (semantic-show-unmatched-lex-tokens-fetch)) |
| 301 | ) | 301 | ) |
| 302 | 302 | ||
| 303 | ;; Make sure pointmax is up to date | 303 | ;; Make sure pointmax is up to date |
| 304 | (oset obj pointmax (point-max)) | 304 | (oset obj pointmax (point-max)) |
| 305 | )) | 305 | ))) |
| 306 | 306 | ||
| 307 | ;; Make sure that the file size and other attributes are | 307 | ;; Make sure that the file size and other attributes are |
| 308 | ;; up to date. | 308 | ;; up to date. |
diff --git a/lisp/cedet/semantic/db-mode.el b/lisp/cedet/semantic/db-mode.el index e8be18576c8..73cc7b5585b 100644 --- a/lisp/cedet/semantic/db-mode.el +++ b/lisp/cedet/semantic/db-mode.el | |||
| @@ -39,7 +39,6 @@ | |||
| 39 | (semanticdb-kill-hook kill-buffer-hook) | 39 | (semanticdb-kill-hook kill-buffer-hook) |
| 40 | (semanticdb-kill-hook change-major-mode-hook) ;; Not really a kill, but we need the same effect. | 40 | (semanticdb-kill-hook change-major-mode-hook) ;; Not really a kill, but we need the same effect. |
| 41 | (semanticdb-kill-emacs-hook kill-emacs-hook) | 41 | (semanticdb-kill-emacs-hook kill-emacs-hook) |
| 42 | (semanticdb-save-all-db-idle auto-save-hook) | ||
| 43 | ) | 42 | ) |
| 44 | "List of hooks and values to add/remove when configuring semanticdb.") | 43 | "List of hooks and values to add/remove when configuring semanticdb.") |
| 45 | 44 | ||
diff --git a/lisp/custom.el b/lisp/custom.el index f4045008ebf..056ca341197 100644 --- a/lisp/custom.el +++ b/lisp/custom.el | |||
| @@ -464,7 +464,7 @@ are not usually written so. | |||
| 464 | MEMBERS should be an alist of the form ((NAME WIDGET)...) where | 464 | MEMBERS should be an alist of the form ((NAME WIDGET)...) where |
| 465 | NAME is a symbol and WIDGET is a widget for editing that symbol. | 465 | NAME is a symbol and WIDGET is a widget for editing that symbol. |
| 466 | Useful widgets are `custom-variable' for editing variables, | 466 | Useful widgets are `custom-variable' for editing variables, |
| 467 | `custom-face' for edit faces, and `custom-group' for editing groups. | 467 | `custom-face' for editing faces, and `custom-group' for editing groups. |
| 468 | 468 | ||
| 469 | The remaining arguments should have the form | 469 | The remaining arguments should have the form |
| 470 | 470 | ||
diff --git a/lisp/doc-view.el b/lisp/doc-view.el index af7f1996cc5..9d912c3f6d9 100644 --- a/lisp/doc-view.el +++ b/lisp/doc-view.el | |||
| @@ -987,6 +987,11 @@ is named like ODF with the extension turned to pdf." | |||
| 987 | (doc-view-start-process "odf->pdf" doc-view-odf->pdf-converter-program | 987 | (doc-view-start-process "odf->pdf" doc-view-odf->pdf-converter-program |
| 988 | (list | 988 | (list |
| 989 | (concat "-env:UserInstallation=file://" | 989 | (concat "-env:UserInstallation=file://" |
| 990 | ;; The URL must be | ||
| 991 | ;; file:///C:/tmp/dir on Windows. | ||
| 992 | ;; https://wiki.documentfoundation.org/UserProfile. | ||
| 993 | (when (eq system-type 'windows-nt) | ||
| 994 | "/") | ||
| 990 | tmp-user-install-dir) | 995 | tmp-user-install-dir) |
| 991 | "--headless" "--convert-to" "pdf" | 996 | "--headless" "--convert-to" "pdf" |
| 992 | "--outdir" (doc-view--current-cache-dir) odf) | 997 | "--outdir" (doc-view--current-cache-dir) odf) |
diff --git a/lisp/emacs-lisp/cl-generic.el b/lisp/emacs-lisp/cl-generic.el index 5413bdbdf7f..7ad9f307f93 100644 --- a/lisp/emacs-lisp/cl-generic.el +++ b/lisp/emacs-lisp/cl-generic.el | |||
| @@ -1019,6 +1019,10 @@ The value returned is a list of elements of the form | |||
| 1019 | 1019 | ||
| 1020 | (cl--generic-prefill-dispatchers 0 (eql nil)) | 1020 | (cl--generic-prefill-dispatchers 0 (eql nil)) |
| 1021 | (cl--generic-prefill-dispatchers window-system (eql nil)) | 1021 | (cl--generic-prefill-dispatchers window-system (eql nil)) |
| 1022 | (cl--generic-prefill-dispatchers (terminal-parameter nil 'xterm--get-selection) | ||
| 1023 | (eql nil)) | ||
| 1024 | (cl--generic-prefill-dispatchers (terminal-parameter nil 'xterm--set-selection) | ||
| 1025 | (eql nil)) | ||
| 1022 | 1026 | ||
| 1023 | ;;; Support for cl-defstructs specializers. | 1027 | ;;; Support for cl-defstructs specializers. |
| 1024 | 1028 | ||
diff --git a/lisp/emacs-lisp/package.el b/lisp/emacs-lisp/package.el index 14650ba3ab6..dc050444b8d 100644 --- a/lisp/emacs-lisp/package.el +++ b/lisp/emacs-lisp/package.el | |||
| @@ -1453,9 +1453,8 @@ loading packages twice." | |||
| 1453 | (defvar package--downloads-in-progress nil | 1453 | (defvar package--downloads-in-progress nil |
| 1454 | "List of in-progress asynchronous downloads.") | 1454 | "List of in-progress asynchronous downloads.") |
| 1455 | 1455 | ||
| 1456 | (declare-function epg-check-configuration "epg-config" | 1456 | (declare-function epg-find-configuration "epg-config" |
| 1457 | (config &optional minimum-version)) | 1457 | (protocol &optional force)) |
| 1458 | (declare-function epg-configuration "epg-config" ()) | ||
| 1459 | (declare-function epg-import-keys-from-file "epg" (context keys)) | 1458 | (declare-function epg-import-keys-from-file "epg" (context keys)) |
| 1460 | 1459 | ||
| 1461 | ;;;###autoload | 1460 | ;;;###autoload |
| @@ -1555,11 +1554,15 @@ downloads in the background." | |||
| 1555 | (let ((default-keyring (expand-file-name "package-keyring.gpg" | 1554 | (let ((default-keyring (expand-file-name "package-keyring.gpg" |
| 1556 | data-directory)) | 1555 | data-directory)) |
| 1557 | (inhibit-message async)) | 1556 | (inhibit-message async)) |
| 1557 | (if (get 'package-check-signature 'saved-value) | ||
| 1558 | (when package-check-signature | ||
| 1559 | (epg-find-configuration 'OpenPGP)) | ||
| 1560 | (setq package-check-signature | ||
| 1561 | (if (epg-find-configuration 'OpenPGP) | ||
| 1562 | 'allow-unsigned))) | ||
| 1558 | (when (and package-check-signature (file-exists-p default-keyring)) | 1563 | (when (and package-check-signature (file-exists-p default-keyring)) |
| 1559 | (condition-case-unless-debug error | 1564 | (condition-case-unless-debug error |
| 1560 | (progn | 1565 | (package-import-keyring default-keyring) |
| 1561 | (epg-check-configuration (epg-configuration)) | ||
| 1562 | (package-import-keyring default-keyring)) | ||
| 1563 | (error (message "Cannot import default keyring: %S" (cdr error)))))) | 1566 | (error (message "Cannot import default keyring: %S" (cdr error)))))) |
| 1564 | (package--download-and-read-archives async)) | 1567 | (package--download-and-read-archives async)) |
| 1565 | 1568 | ||
diff --git a/lisp/epg-config.el b/lisp/epg-config.el index c41d97dbfac..8a208044cba 100644 --- a/lisp/epg-config.el +++ b/lisp/epg-config.el | |||
| @@ -23,6 +23,8 @@ | |||
| 23 | 23 | ||
| 24 | ;;; Code: | 24 | ;;; Code: |
| 25 | 25 | ||
| 26 | (eval-when-compile (require 'cl-lib)) | ||
| 27 | |||
| 26 | (defconst epg-package-name "epg" | 28 | (defconst epg-package-name "epg" |
| 27 | "Name of this package.") | 29 | "Name of this package.") |
| 28 | 30 | ||
| @@ -76,12 +78,66 @@ Note that the buffer name starts with a space." | |||
| 76 | 78 | ||
| 77 | (defconst epg-gpg-minimum-version "1.4.3") | 79 | (defconst epg-gpg-minimum-version "1.4.3") |
| 78 | 80 | ||
| 81 | (defconst epg-config--program-alist | ||
| 82 | '((OpenPGP | ||
| 83 | epg-gpg-program | ||
| 84 | epg-config--make-gpg-configuration | ||
| 85 | ("gpg2" . "2.1.6") ("gpg" . "1.4.3")) | ||
| 86 | (CMS | ||
| 87 | epg-gpgsm-program | ||
| 88 | epg-config--make-gpgsm-configuration | ||
| 89 | ("gpgsm" . "2.0.4"))) | ||
| 90 | "Alist used to obtain the usable configuration of executables. | ||
| 91 | The first element of each entry is protocol symbol, which is | ||
| 92 | either `OpenPGP' or `CMS'. The second element is a symbol where | ||
| 93 | the executable name is remembered. The third element is a | ||
| 94 | function which constructs a configuration object (actually a | ||
| 95 | plist). The rest of the entry is an alist mapping executable | ||
| 96 | names to the minimum required version suitable for the use with | ||
| 97 | Emacs.") | ||
| 98 | |||
| 99 | (defvar epg--configurations nil) | ||
| 100 | |||
| 79 | ;;;###autoload | 101 | ;;;###autoload |
| 80 | (defun epg-configuration () | 102 | (defun epg-find-configuration (protocol &optional force) |
| 81 | "Return a list of internal configuration parameters of `epg-gpg-program'." | 103 | "Find or create a usable configuration to handle PROTOCOL. |
| 104 | This function first looks at the existing configuration found by | ||
| 105 | the previous invocation of this function, unless FORCE is non-nil. | ||
| 106 | |||
| 107 | Then it walks through `epg-config--program-alist'. If | ||
| 108 | `epg-gpg-program' or `epg-gpgsm-program' is already set with | ||
| 109 | custom, use it. Otherwise, it tries the programs listed in the | ||
| 110 | entry until the version requirement is met." | ||
| 111 | (let ((entry (assq protocol epg-config--program-alist))) | ||
| 112 | (unless entry | ||
| 113 | (error "Unknown protocol %S" protocol)) | ||
| 114 | (cl-destructuring-bind (symbol constructor . alist) | ||
| 115 | (cdr entry) | ||
| 116 | (or (and (not force) (alist-get protocol epg--configurations)) | ||
| 117 | ;; If the executable value is already set with M-x | ||
| 118 | ;; customize, use it without checking. | ||
| 119 | (if (get symbol 'saved-value) | ||
| 120 | (let ((configuration (funcall constructor (symbol-value symbol)))) | ||
| 121 | (push (cons protocol configuration) epg--configurations) | ||
| 122 | configuration) | ||
| 123 | (catch 'found | ||
| 124 | (dolist (program-version alist) | ||
| 125 | (let ((executable (executable-find (car program-version)))) | ||
| 126 | (when executable | ||
| 127 | (let ((configuration | ||
| 128 | (funcall constructor executable))) | ||
| 129 | (when (ignore-errors | ||
| 130 | (epg-check-configuration configuration | ||
| 131 | (cdr program-version)) | ||
| 132 | t) | ||
| 133 | (push (cons protocol configuration) epg--configurations) | ||
| 134 | (throw 'found configuration)))))))))))) | ||
| 135 | |||
| 136 | ;; Create an `epg-configuration' object for `gpg', using PROGRAM. | ||
| 137 | (defun epg-config--make-gpg-configuration (program) | ||
| 82 | (let (config groups type args) | 138 | (let (config groups type args) |
| 83 | (with-temp-buffer | 139 | (with-temp-buffer |
| 84 | (apply #'call-process epg-gpg-program nil (list t nil) nil | 140 | (apply #'call-process program nil (list t nil) nil |
| 85 | (append (if epg-gpg-home-directory | 141 | (append (if epg-gpg-home-directory |
| 86 | (list "--homedir" epg-gpg-home-directory)) | 142 | (list "--homedir" epg-gpg-home-directory)) |
| 87 | '("--with-colons" "--list-config"))) | 143 | '("--with-colons" "--list-config"))) |
| @@ -113,10 +169,30 @@ Note that the buffer name starts with a space." | |||
| 113 | type args)))) | 169 | type args)))) |
| 114 | (t | 170 | (t |
| 115 | (setq config (cons (cons type args) config)))))) | 171 | (setq config (cons (cons type args) config)))))) |
| 172 | (push (cons 'program program) config) | ||
| 116 | (if groups | 173 | (if groups |
| 117 | (cons (cons 'groups groups) config) | 174 | (cons (cons 'groups groups) config) |
| 118 | config))) | 175 | config))) |
| 119 | 176 | ||
| 177 | ;; Create an `epg-configuration' object for `gpgsm', using PROGRAM. | ||
| 178 | (defun epg-config--make-gpgsm-configuration (program) | ||
| 179 | (with-temp-buffer | ||
| 180 | (call-process program nil (list t nil) nil "--version") | ||
| 181 | (goto-char (point-min)) | ||
| 182 | (when (looking-at "\\S-+ (") | ||
| 183 | (goto-char (match-end 0)) | ||
| 184 | (backward-char) | ||
| 185 | (forward-sexp) | ||
| 186 | (skip-syntax-forward "-" (point-at-eol)) | ||
| 187 | (list (cons 'program program) | ||
| 188 | (cons 'version (buffer-substring (point) (point-at-eol))))))) | ||
| 189 | |||
| 190 | ;;;###autoload | ||
| 191 | (defun epg-configuration () | ||
| 192 | "Return a list of internal configuration parameters of `epg-gpg-program'." | ||
| 193 | (declare (obsolete epg-find-configuration "25.1")) | ||
| 194 | (epg-config--make-gpg-configuration epg-gpg-program)) | ||
| 195 | |||
| 120 | (defun epg-config--parse-version (string) | 196 | (defun epg-config--parse-version (string) |
| 121 | (let ((index 0) | 197 | (let ((index 0) |
| 122 | version) | 198 | version) |
diff --git a/lisp/epg.el b/lisp/epg.el index 1f9db23478c..f4058ed35a4 100644 --- a/lisp/epg.el +++ b/lisp/epg.el | |||
| @@ -186,11 +186,11 @@ | |||
| 186 | compress-algorithm | 186 | compress-algorithm |
| 187 | &aux | 187 | &aux |
| 188 | (program | 188 | (program |
| 189 | (pcase protocol | 189 | (let ((configuration (epg-find-configuration protocol))) |
| 190 | (`OpenPGP epg-gpg-program) | 190 | (unless configuration |
| 191 | (`CMS epg-gpgsm-program) | 191 | (signal 'epg-error |
| 192 | (_ (signal 'epg-error | 192 | (list "no usable configuration" protocol))) |
| 193 | (list "unknown protocol" protocol))))))) | 193 | (alist-get 'program configuration))))) |
| 194 | (:copier nil) | 194 | (:copier nil) |
| 195 | (:predicate nil)) | 195 | (:predicate nil)) |
| 196 | protocol | 196 | protocol |
diff --git a/lisp/filenotify.el b/lisp/filenotify.el index 66e7fd7a315..21046a85a7a 100644 --- a/lisp/filenotify.el +++ b/lisp/filenotify.el | |||
| @@ -27,6 +27,9 @@ | |||
| 27 | 27 | ||
| 28 | ;;; Code: | 28 | ;;; Code: |
| 29 | 29 | ||
| 30 | (eval-when-compile | ||
| 31 | (require 'cl)) | ||
| 32 | |||
| 30 | (defconst file-notify--library | 33 | (defconst file-notify--library |
| 31 | (cond | 34 | (cond |
| 32 | ((featurep 'inotify) 'inotify) | 35 | ((featurep 'inotify) 'inotify) |
| @@ -54,18 +57,15 @@ different files from the same directory are watched.") | |||
| 54 | DESCRIPTOR should be an object returned by `file-notify-add-watch'. | 57 | DESCRIPTOR should be an object returned by `file-notify-add-watch'. |
| 55 | If it is registered in `file-notify-descriptors', a stopped event is sent." | 58 | If it is registered in `file-notify-descriptors', a stopped event is sent." |
| 56 | (let* ((desc (if (consp descriptor) (car descriptor) descriptor)) | 59 | (let* ((desc (if (consp descriptor) (car descriptor) descriptor)) |
| 57 | (file (if (consp descriptor) (cdr descriptor))) | ||
| 58 | (registered (gethash desc file-notify-descriptors)) | 60 | (registered (gethash desc file-notify-descriptors)) |
| 61 | (file (if (consp descriptor) (cdr descriptor) (caadr registered))) | ||
| 59 | (dir (car registered))) | 62 | (dir (car registered))) |
| 60 | 63 | ||
| 61 | (when (consp registered) | 64 | (when (consp registered) |
| 62 | ;; Send `stopped' event. | 65 | ;; Send `stopped' event. |
| 63 | (dolist (entry (cdr registered)) | 66 | (funcall |
| 64 | (funcall (cdr entry) | 67 | (cdr (assoc file (cdr registered))) |
| 65 | `(,descriptor stopped | 68 | `(,descriptor stopped ,(if file (expand-file-name file dir) dir))) |
| 66 | ,(or (and (stringp (car entry)) | ||
| 67 | (expand-file-name (car entry) dir)) | ||
| 68 | dir)))) | ||
| 69 | 69 | ||
| 70 | ;; Modify `file-notify-descriptors'. | 70 | ;; Modify `file-notify-descriptors'. |
| 71 | (if (not file) | 71 | (if (not file) |
| @@ -99,6 +99,15 @@ Otherwise, signal a `file-notify-error'." | |||
| 99 | "A pending file notification events for a future `renamed' action. | 99 | "A pending file notification events for a future `renamed' action. |
| 100 | It is a form ((DESCRIPTOR ACTION FILE [FILE1-OR-COOKIE]) CALLBACK).") | 100 | It is a form ((DESCRIPTOR ACTION FILE [FILE1-OR-COOKIE]) CALLBACK).") |
| 101 | 101 | ||
| 102 | (defun file-notify--event-watched-file (event) | ||
| 103 | "Return file or directory being watched. | ||
| 104 | Could be different from the directory watched by the backend library." | ||
| 105 | (let* ((desc (if (consp (car event)) (caar event) (car event))) | ||
| 106 | (registered (gethash desc file-notify-descriptors)) | ||
| 107 | (file (if (consp (car event)) (cdar event) (caadr registered))) | ||
| 108 | (dir (car registered))) | ||
| 109 | (if file (expand-file-name file dir) dir))) | ||
| 110 | |||
| 102 | (defun file-notify--event-file-name (event) | 111 | (defun file-notify--event-file-name (event) |
| 103 | "Return file name of file notification event, or nil." | 112 | "Return file name of file notification event, or nil." |
| 104 | (directory-file-name | 113 | (directory-file-name |
| @@ -234,26 +243,6 @@ EVENT is the cadr of the event in `file-notify-handle-event' | |||
| 234 | (funcall (cadr pending-event) (car pending-event)) | 243 | (funcall (cadr pending-event) (car pending-event)) |
| 235 | (setq pending-event nil)) | 244 | (setq pending-event nil)) |
| 236 | 245 | ||
| 237 | ;; Check for stopped. | ||
| 238 | (setq | ||
| 239 | stopped | ||
| 240 | (or | ||
| 241 | stopped | ||
| 242 | (and | ||
| 243 | (memq action '(deleted renamed)) | ||
| 244 | (= (length (cdr registered)) 1) | ||
| 245 | ;; Not, when a file is backed up. | ||
| 246 | (not (and (stringp file1) (backup-file-name-p file1))) | ||
| 247 | (or | ||
| 248 | ;; Watched file or directory is concerned. | ||
| 249 | (string-equal | ||
| 250 | (file-name-nondirectory file) | ||
| 251 | (file-name-nondirectory (car registered))) | ||
| 252 | ;; File inside a watched directory is concerned. | ||
| 253 | (string-equal | ||
| 254 | (file-name-nondirectory file) | ||
| 255 | (car (cadr registered))))))) | ||
| 256 | |||
| 257 | ;; Apply callback. | 246 | ;; Apply callback. |
| 258 | (when (and action | 247 | (when (and action |
| 259 | (or | 248 | (or |
| @@ -273,18 +262,24 @@ EVENT is the cadr of the event in `file-notify-handle-event' | |||
| 273 | (nth 0 entry) (file-name-nondirectory file1))))) | 262 | (nth 0 entry) (file-name-nondirectory file1))))) |
| 274 | ;;(message | 263 | ;;(message |
| 275 | ;;"file-notify-callback %S %S %S %S %S" | 264 | ;;"file-notify-callback %S %S %S %S %S" |
| 276 | ;;(file-notify--descriptor desc file) action file file1 registered) | 265 | ;;(file-notify--descriptor desc (car entry)) |
| 266 | ;;action file file1 registered) | ||
| 277 | (if file1 | 267 | (if file1 |
| 278 | (funcall | 268 | (funcall |
| 279 | callback | 269 | callback |
| 280 | `(,(file-notify--descriptor desc file) ,action ,file ,file1)) | 270 | `(,(file-notify--descriptor desc (car entry)) |
| 271 | ,action ,file ,file1)) | ||
| 281 | (funcall | 272 | (funcall |
| 282 | callback | 273 | callback |
| 283 | `(,(file-notify--descriptor desc file) ,action ,file))))) | 274 | `(,(file-notify--descriptor desc (car entry)) ,action ,file)))) |
| 284 | 275 | ||
| 285 | ;; Modify `file-notify-descriptors'. | 276 | ;; Send `stopped' event. |
| 286 | (when stopped | 277 | (when (and (memq action '(deleted renamed)) |
| 287 | (file-notify-rm-watch (file-notify--descriptor desc file)))))) | 278 | ;; Not, when a file is backed up. |
| 279 | (not (and (stringp file1) (backup-file-name-p file1))) | ||
| 280 | ;; Watched file or directory is concerned. | ||
| 281 | (string-equal file (file-notify--event-watched-file event))) | ||
| 282 | (file-notify-rm-watch (file-notify--descriptor desc (car entry)))))))) | ||
| 288 | 283 | ||
| 289 | ;; `kqueue', `gfilenotify' and `w32notify' return a unique descriptor | 284 | ;; `kqueue', `gfilenotify' and `w32notify' return a unique descriptor |
| 290 | ;; for every `file-notify-add-watch', while `inotify' returns a unique | 285 | ;; for every `file-notify-add-watch', while `inotify' returns a unique |
diff --git a/lisp/gnus/gnus-art.el b/lisp/gnus/gnus-art.el index c66ca535998..4d8cb802b48 100644 --- a/lisp/gnus/gnus-art.el +++ b/lisp/gnus/gnus-art.el | |||
| @@ -518,6 +518,12 @@ each invocation of the saving commands." | |||
| 518 | (item :tag "never" nil) | 518 | (item :tag "never" nil) |
| 519 | (sexp :tag "once" :format "%t\n" :value t))) | 519 | (sexp :tag "once" :format "%t\n" :value t))) |
| 520 | 520 | ||
| 521 | (defcustom gnus-article-show-cursor nil | ||
| 522 | "If non-nil, show the cursor in the Article buffer even when not selected." | ||
| 523 | :version "25.1" | ||
| 524 | :group 'gnus-article | ||
| 525 | :type 'bool) | ||
| 526 | |||
| 521 | (defcustom gnus-saved-headers gnus-visible-headers | 527 | (defcustom gnus-saved-headers gnus-visible-headers |
| 522 | "Headers to keep if `gnus-save-all-headers' is nil. | 528 | "Headers to keep if `gnus-save-all-headers' is nil. |
| 523 | If `gnus-save-all-headers' is non-nil, this variable will be ignored. | 529 | If `gnus-save-all-headers' is non-nil, this variable will be ignored. |
| @@ -4484,7 +4490,8 @@ commands: | |||
| 4484 | (set (make-local-variable 'nobreak-char-display) nil) | 4490 | (set (make-local-variable 'nobreak-char-display) nil) |
| 4485 | ;; Enable `gnus-article-remove-images' to delete images shr.el renders. | 4491 | ;; Enable `gnus-article-remove-images' to delete images shr.el renders. |
| 4486 | (set (make-local-variable 'shr-put-image-function) 'gnus-shr-put-image) | 4492 | (set (make-local-variable 'shr-put-image-function) 'gnus-shr-put-image) |
| 4487 | (setq cursor-in-non-selected-windows nil) | 4493 | (unless gnus-article-show-cursor |
| 4494 | (setq cursor-in-non-selected-windows nil)) | ||
| 4488 | (gnus-set-default-directory) | 4495 | (gnus-set-default-directory) |
| 4489 | (buffer-disable-undo) | 4496 | (buffer-disable-undo) |
| 4490 | (setq buffer-read-only t | 4497 | (setq buffer-read-only t |
diff --git a/lisp/help-fns.el b/lisp/help-fns.el index 2021885e996..c3a5f26d261 100644 --- a/lisp/help-fns.el +++ b/lisp/help-fns.el | |||
| @@ -296,7 +296,6 @@ suitable file is found, return nil." | |||
| 296 | (substring-no-properties lib-name 0 -1) | 296 | (substring-no-properties lib-name 0 -1) |
| 297 | lib-name) | 297 | lib-name) |
| 298 | file-name)) | 298 | file-name)) |
| 299 | ;; The next three forms are from `find-source-lisp-file'. | ||
| 300 | (src-file (locate-library file-name t nil 'readable))) | 299 | (src-file (locate-library file-name t nil 'readable))) |
| 301 | (and src-file (file-readable-p src-file) src-file)))))) | 300 | (and src-file (file-readable-p src-file) src-file)))))) |
| 302 | 301 | ||
diff --git a/lisp/net/eww.el b/lisp/net/eww.el index 7f9f4fad414..91a17755244 100644 --- a/lisp/net/eww.el +++ b/lisp/net/eww.el | |||
| @@ -410,6 +410,10 @@ Currently this means either text/html or application/xhtml+xml." | |||
| 410 | (condition-case nil | 410 | (condition-case nil |
| 411 | (decode-coding-region (point) (point-max) encode) | 411 | (decode-coding-region (point) (point-max) encode) |
| 412 | (coding-system-error nil)) | 412 | (coding-system-error nil)) |
| 413 | (save-excursion | ||
| 414 | ;; Remove CRLF before parsing. | ||
| 415 | (while (re-search-forward "\r$" nil t) | ||
| 416 | (replace-match "" t t))) | ||
| 413 | (libxml-parse-html-region (point) (point-max)))))) | 417 | (libxml-parse-html-region (point) (point-max)))))) |
| 414 | (source (and (null document) | 418 | (source (and (null document) |
| 415 | (buffer-substring (point) (point-max))))) | 419 | (buffer-substring (point) (point-max))))) |
| @@ -1531,11 +1535,10 @@ If CHARSET is nil then use UTF-8." | |||
| 1531 | (defun eww-toggle-fonts () | 1535 | (defun eww-toggle-fonts () |
| 1532 | "Toggle whether to use monospaced or font-enabled layouts." | 1536 | "Toggle whether to use monospaced or font-enabled layouts." |
| 1533 | (interactive) | 1537 | (interactive) |
| 1534 | (message "Fonts are now %s" | 1538 | (setq shr-use-fonts (not shr-use-fonts)) |
| 1535 | (if (setq shr-use-fonts (not shr-use-fonts)) | 1539 | (eww-reload) |
| 1536 | "on" | 1540 | (message "Proportional fonts are now %s" |
| 1537 | "off")) | 1541 | (if shr-use-fonts "on" "off"))) |
| 1538 | (eww-reload)) | ||
| 1539 | 1542 | ||
| 1540 | (defun eww-toggle-colors () | 1543 | (defun eww-toggle-colors () |
| 1541 | "Toggle whether to use HTML-specified colors or not." | 1544 | "Toggle whether to use HTML-specified colors or not." |
diff --git a/lisp/net/pinentry.el b/lisp/net/pinentry.el index 27374afe4bf..082a9c8ff89 100644 --- a/lisp/net/pinentry.el +++ b/lisp/net/pinentry.el | |||
| @@ -26,7 +26,8 @@ | |||
| 26 | ;; This package allows GnuPG passphrase to be prompted through the | 26 | ;; This package allows GnuPG passphrase to be prompted through the |
| 27 | ;; minibuffer instead of graphical dialog. | 27 | ;; minibuffer instead of graphical dialog. |
| 28 | ;; | 28 | ;; |
| 29 | ;; To use, add allow-emacs-pinentry to ~/.gnupg/gpg-agent.conf, and | 29 | ;; To use, add "allow-emacs-pinentry" to "~/.gnupg/gpg-agent.conf", |
| 30 | ;; reload the configuration with "gpgconf --reload gpg-agent", and | ||
| 30 | ;; start the server with M-x pinentry-start. | 31 | ;; start the server with M-x pinentry-start. |
| 31 | ;; | 32 | ;; |
| 32 | ;; The actual communication path between the relevant components is | 33 | ;; The actual communication path between the relevant components is |
| @@ -48,6 +49,8 @@ | |||
| 48 | 49 | ||
| 49 | ;;; Code: | 50 | ;;; Code: |
| 50 | 51 | ||
| 52 | (eval-when-compile (require 'cl-lib)) | ||
| 53 | |||
| 51 | (defgroup pinentry nil | 54 | (defgroup pinentry nil |
| 52 | "The Pinentry server" | 55 | "The Pinentry server" |
| 53 | :version "25.1" | 56 | :version "25.1" |
| @@ -171,17 +174,18 @@ will not be shown." | |||
| 171 | (ignore-errors | 174 | (ignore-errors |
| 172 | (let (delete-by-moving-to-trash) | 175 | (let (delete-by-moving-to-trash) |
| 173 | (delete-file server-file))) | 176 | (delete-file server-file))) |
| 174 | (setq pinentry--server-process | 177 | (cl-letf (((default-file-modes) ?\700)) |
| 175 | (make-network-process | 178 | (setq pinentry--server-process |
| 176 | :name "pinentry" | 179 | (make-network-process |
| 177 | :server t | 180 | :name "pinentry" |
| 178 | :noquery t | 181 | :server t |
| 179 | :sentinel #'pinentry--process-sentinel | 182 | :noquery t |
| 180 | :filter #'pinentry--process-filter | 183 | :sentinel #'pinentry--process-sentinel |
| 181 | :coding 'no-conversion | 184 | :filter #'pinentry--process-filter |
| 182 | :family 'local | 185 | :coding 'no-conversion |
| 183 | :service server-file)) | 186 | :family 'local |
| 184 | (process-put pinentry--server-process :server-file server-file)))) | 187 | :service server-file)) |
| 188 | (process-put pinentry--server-process :server-file server-file))))) | ||
| 185 | 189 | ||
| 186 | (defun pinentry-stop () | 190 | (defun pinentry-stop () |
| 187 | "Stop a Pinentry service." | 191 | "Stop a Pinentry service." |
diff --git a/lisp/progmodes/cc-engine.el b/lisp/progmodes/cc-engine.el index 8f2acf3cd61..f5aa4df7c2b 100644 --- a/lisp/progmodes/cc-engine.el +++ b/lisp/progmodes/cc-engine.el | |||
| @@ -3241,7 +3241,7 @@ comment at the start of cc-engine.el for more info." | |||
| 3241 | ;; pair element into an open paren element. Doing that would mean that the | 3241 | ;; pair element into an open paren element. Doing that would mean that the |
| 3242 | ;; new open paren wouldn't have the required preceding paren pair element. | 3242 | ;; new open paren wouldn't have the required preceding paren pair element. |
| 3243 | ;; | 3243 | ;; |
| 3244 | ;; This function is called from c-after-change. | 3244 | ;; This function is called from c-before-change. |
| 3245 | 3245 | ||
| 3246 | ;; The caches of non-literals: | 3246 | ;; The caches of non-literals: |
| 3247 | ;; Note that we use "<=" for the possibility of the second char of a two-char | 3247 | ;; Note that we use "<=" for the possibility of the second char of a two-char |
| @@ -3265,7 +3265,7 @@ comment at the start of cc-engine.el for more info." | |||
| 3265 | ;; below `here'. To maintain its consistency, we may need to insert a new | 3265 | ;; below `here'. To maintain its consistency, we may need to insert a new |
| 3266 | ;; brace pair. | 3266 | ;; brace pair. |
| 3267 | (let ((here-bol (c-point 'bol here)) | 3267 | (let ((here-bol (c-point 'bol here)) |
| 3268 | too-high-pa ; recorded {/(/[ next above here, or nil. | 3268 | too-high-pa ; recorded {/(/[ next above or just below here, or nil. |
| 3269 | dropped-cons ; was the last removed element a brace pair? | 3269 | dropped-cons ; was the last removed element a brace pair? |
| 3270 | pa) | 3270 | pa) |
| 3271 | ;; The easy bit - knock over-the-top bits off `c-state-cache'. | 3271 | ;; The easy bit - knock over-the-top bits off `c-state-cache'. |
| @@ -3277,7 +3277,7 @@ comment at the start of cc-engine.el for more info." | |||
| 3277 | 3277 | ||
| 3278 | ;; Do we need to add in an earlier brace pair, having lopped one off? | 3278 | ;; Do we need to add in an earlier brace pair, having lopped one off? |
| 3279 | (if (and dropped-cons | 3279 | (if (and dropped-cons |
| 3280 | (< too-high-pa (+ here c-state-cache-too-far))) | 3280 | (<= too-high-pa here)) |
| 3281 | (c-append-lower-brace-pair-to-state-cache too-high-pa here here-bol)) | 3281 | (c-append-lower-brace-pair-to-state-cache too-high-pa here here-bol)) |
| 3282 | (setq c-state-cache-good-pos (or (c-state-cache-after-top-paren) | 3282 | (setq c-state-cache-good-pos (or (c-state-cache-after-top-paren) |
| 3283 | (c-state-get-min-scan-pos))))) | 3283 | (c-state-get-min-scan-pos))))) |
diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index 2fd7297a2e8..f983525e928 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el | |||
| @@ -414,16 +414,17 @@ elements is negated." | |||
| 414 | (set-buffer (marker-buffer marker)) | 414 | (set-buffer (marker-buffer marker)) |
| 415 | (xref--goto-char marker))) | 415 | (xref--goto-char marker))) |
| 416 | 416 | ||
| 417 | (defun xref--pop-to-location (item &optional window) | 417 | (defun xref--pop-to-location (item &optional action) |
| 418 | "Go to the location of ITEM and display the buffer. | 418 | "Go to the location of ITEM and display the buffer. |
| 419 | WINDOW controls how the buffer is displayed: | 419 | ACTION controls how the buffer is displayed: |
| 420 | nil -- switch-to-buffer | 420 | nil -- switch-to-buffer |
| 421 | `window' -- pop-to-buffer (other window) | 421 | `window' -- pop-to-buffer (other window) |
| 422 | `frame' -- pop-to-buffer (other frame)" | 422 | `frame' -- pop-to-buffer (other frame) |
| 423 | If SELECT is non-nil, select the target window." | ||
| 423 | (let* ((marker (save-excursion | 424 | (let* ((marker (save-excursion |
| 424 | (xref-location-marker (xref-item-location item)))) | 425 | (xref-location-marker (xref-item-location item)))) |
| 425 | (buf (marker-buffer marker))) | 426 | (buf (marker-buffer marker))) |
| 426 | (cl-ecase window | 427 | (cl-ecase action |
| 427 | ((nil) (switch-to-buffer buf)) | 428 | ((nil) (switch-to-buffer buf)) |
| 428 | (window (pop-to-buffer buf t)) | 429 | (window (pop-to-buffer buf t)) |
| 429 | (frame (let ((pop-up-frames t)) (pop-to-buffer buf t)))) | 430 | (frame (let ((pop-up-frames t)) (pop-to-buffer buf t)))) |
| @@ -436,51 +437,60 @@ WINDOW controls how the buffer is displayed: | |||
| 436 | 437 | ||
| 437 | ;; The xref buffer is used to display a set of xrefs. | 438 | ;; The xref buffer is used to display a set of xrefs. |
| 438 | 439 | ||
| 439 | (defvar-local xref--display-history nil | 440 | (defmacro xref--with-dedicated-window (&rest body) |
| 440 | "List of pairs (BUFFER . WINDOW), for temporarily displayed buffers.") | 441 | `(let* ((xref-w (get-buffer-window xref-buffer-name)) |
| 441 | 442 | (xref-w-dedicated (window-dedicated-p xref-w))) | |
| 442 | (defun xref--save-to-history (buf win) | 443 | (unwind-protect |
| 443 | (let ((restore (window-parameter win 'quit-restore))) | 444 | (progn |
| 444 | ;; Save the new entry if the window displayed another buffer | 445 | (when xref-w |
| 445 | ;; previously. | 446 | (set-window-dedicated-p xref-w 'soft)) |
| 446 | (when (and restore (not (eq (car restore) 'same))) | 447 | ,@body) |
| 447 | (push (cons buf win) xref--display-history)))) | 448 | (when xref-w |
| 448 | 449 | (set-window-dedicated-p xref-w xref-w-dedicated))))) | |
| 449 | (defun xref--display-position (pos other-window buf) | 450 | |
| 450 | ;; Show the location, but don't hijack focus. | 451 | (defun xref--show-pos-in-buf (pos buf select) |
| 451 | (let ((xref-buf (current-buffer))) | 452 | (let ((xref-buf (current-buffer)) |
| 452 | (with-selected-window (display-buffer buf other-window) | 453 | win) |
| 454 | (with-selected-window | ||
| 455 | (xref--with-dedicated-window | ||
| 456 | (display-buffer buf)) | ||
| 453 | (xref--goto-char pos) | 457 | (xref--goto-char pos) |
| 454 | (run-hooks 'xref-after-jump-hook) | 458 | (run-hooks 'xref-after-jump-hook) |
| 455 | (let ((buf (current-buffer)) | 459 | (let ((buf (current-buffer))) |
| 456 | (win (selected-window))) | 460 | (setq win (selected-window)) |
| 457 | (with-current-buffer xref-buf | 461 | (with-current-buffer xref-buf |
| 458 | (setq-local other-window-scroll-buffer buf) | 462 | (setq-local other-window-scroll-buffer buf)))) |
| 459 | (xref--save-to-history buf win)))))) | 463 | (when select |
| 464 | (select-window win)))) | ||
| 460 | 465 | ||
| 461 | (defun xref--show-location (location) | 466 | (defun xref--show-location (location &optional select) |
| 462 | (condition-case err | 467 | (condition-case err |
| 463 | (let* ((marker (xref-location-marker location)) | 468 | (let* ((marker (xref-location-marker location)) |
| 464 | (buf (marker-buffer marker))) | 469 | (buf (marker-buffer marker))) |
| 465 | (xref--display-position marker t buf)) | 470 | (xref--show-pos-in-buf marker buf select)) |
| 466 | (user-error (message (error-message-string err))))) | 471 | (user-error (message (error-message-string err))))) |
| 467 | 472 | ||
| 468 | (defun xref-show-location-at-point () | 473 | (defun xref-show-location-at-point () |
| 469 | "Display the source of xref at point in the other window, if any." | 474 | "Display the source of xref at point in the appropriate window, if any." |
| 470 | (interactive) | 475 | (interactive) |
| 471 | (let* ((xref (xref--item-at-point)) | 476 | (let* ((xref (xref--item-at-point)) |
| 472 | (xref--current-item xref)) | 477 | (xref--current-item xref)) |
| 473 | (when xref | 478 | (when xref |
| 474 | (xref--show-location (xref-item-location xref))))) | 479 | ;; Try to avoid the window the current xref buffer was |
| 480 | ;; originally created from. | ||
| 481 | (if (window-live-p xref--window) | ||
| 482 | (with-selected-window xref--window | ||
| 483 | (xref--show-location (xref-item-location xref))) | ||
| 484 | (xref--show-location (xref-item-location xref)))))) | ||
| 475 | 485 | ||
| 476 | (defun xref-next-line () | 486 | (defun xref-next-line () |
| 477 | "Move to the next xref and display its source in the other window." | 487 | "Move to the next xref and display its source in the appropriate window." |
| 478 | (interactive) | 488 | (interactive) |
| 479 | (xref--search-property 'xref-item) | 489 | (xref--search-property 'xref-item) |
| 480 | (xref-show-location-at-point)) | 490 | (xref-show-location-at-point)) |
| 481 | 491 | ||
| 482 | (defun xref-prev-line () | 492 | (defun xref-prev-line () |
| 483 | "Move to the previous xref and display its source in the other window." | 493 | "Move to the previous xref and display its source in the appropriate window." |
| 484 | (interactive) | 494 | (interactive) |
| 485 | (xref--search-property 'xref-item t) | 495 | (xref--search-property 'xref-item t) |
| 486 | (xref-show-location-at-point)) | 496 | (xref-show-location-at-point)) |
| @@ -491,16 +501,14 @@ WINDOW controls how the buffer is displayed: | |||
| 491 | (get-text-property (point) 'xref-item))) | 501 | (get-text-property (point) 'xref-item))) |
| 492 | 502 | ||
| 493 | (defvar-local xref--window nil | 503 | (defvar-local xref--window nil |
| 494 | "ACTION argument to call `display-buffer' with.") | 504 | "The original window this xref buffer was created from.") |
| 495 | 505 | ||
| 496 | (defun xref-goto-xref () | 506 | (defun xref-goto-xref () |
| 497 | "Jump to the xref on the current line and bury the xref buffer." | 507 | "Jump to the xref on the current line and select its window." |
| 498 | (interactive) | 508 | (interactive) |
| 499 | (let ((xref (or (xref--item-at-point) | 509 | (let ((xref (or (xref--item-at-point) |
| 500 | (user-error "No reference at point"))) | 510 | (user-error "No reference at point")))) |
| 501 | (window xref--window)) | 511 | (xref--show-location (xref-item-location xref) t))) |
| 502 | (xref-quit) | ||
| 503 | (xref--pop-to-location xref window))) | ||
| 504 | 512 | ||
| 505 | (defun xref-query-replace-in-results (from to) | 513 | (defun xref-query-replace-in-results (from to) |
| 506 | "Perform interactive replacement of FROM with TO in all displayed xrefs. | 514 | "Perform interactive replacement of FROM with TO in all displayed xrefs. |
| @@ -573,7 +581,8 @@ references displayed in the current *xref* buffer." | |||
| 573 | current-beg (car pair) | 581 | current-beg (car pair) |
| 574 | current-end (cdr pair) | 582 | current-end (cdr pair) |
| 575 | current-buf (marker-buffer current-beg)) | 583 | current-buf (marker-buffer current-beg)) |
| 576 | (pop-to-buffer current-buf) | 584 | (xref--with-dedicated-window |
| 585 | (pop-to-buffer current-buf)) | ||
| 577 | (goto-char current-beg) | 586 | (goto-char current-beg) |
| 578 | (when (re-search-forward from current-end noerror) | 587 | (when (re-search-forward from current-end noerror) |
| 579 | (setq found t))) | 588 | (setq found t))) |
| @@ -586,7 +595,6 @@ references displayed in the current *xref* buffer." | |||
| 586 | 595 | ||
| 587 | (defvar xref--xref-buffer-mode-map | 596 | (defvar xref--xref-buffer-mode-map |
| 588 | (let ((map (make-sparse-keymap))) | 597 | (let ((map (make-sparse-keymap))) |
| 589 | (define-key map [remap quit-window] #'xref-quit) | ||
| 590 | (define-key map (kbd "n") #'xref-next-line) | 598 | (define-key map (kbd "n") #'xref-next-line) |
| 591 | (define-key map (kbd "p") #'xref-prev-line) | 599 | (define-key map (kbd "p") #'xref-prev-line) |
| 592 | (define-key map (kbd "r") #'xref-query-replace-in-results) | 600 | (define-key map (kbd "r") #'xref-query-replace-in-results) |
| @@ -614,27 +622,10 @@ references displayed in the current *xref* buffer." | |||
| 614 | (dotimes (_ n) | 622 | (dotimes (_ n) |
| 615 | (setq xref (xref--search-property 'xref-item backward))) | 623 | (setq xref (xref--search-property 'xref-item backward))) |
| 616 | (cond (xref | 624 | (cond (xref |
| 617 | (xref--pop-to-location xref)) | 625 | (xref--show-location (xref-item-location xref) t)) |
| 618 | (t | 626 | (t |
| 619 | (error "No %s xref" (if backward "previous" "next")))))) | 627 | (error "No %s xref" (if backward "previous" "next")))))) |
| 620 | 628 | ||
| 621 | (defun xref-quit (&optional kill) | ||
| 622 | "Bury temporarily displayed buffers, then quit the current window. | ||
| 623 | |||
| 624 | If KILL is non-nil, also kill the current buffer. | ||
| 625 | |||
| 626 | The buffers that the user has otherwise interacted with in the | ||
| 627 | meantime are preserved." | ||
| 628 | (interactive "P") | ||
| 629 | (let ((window (selected-window)) | ||
| 630 | (history xref--display-history)) | ||
| 631 | (setq xref--display-history nil) | ||
| 632 | (pcase-dolist (`(,buf . ,win) history) | ||
| 633 | (when (and (window-live-p win) | ||
| 634 | (eq buf (window-buffer win))) | ||
| 635 | (quit-window nil win))) | ||
| 636 | (quit-window kill window))) | ||
| 637 | |||
| 638 | (defconst xref-buffer-name "*xref*" | 629 | (defconst xref-buffer-name "*xref*" |
| 639 | "The name of the buffer to show xrefs.") | 630 | "The name of the buffer to show xrefs.") |
| 640 | 631 | ||
| @@ -724,15 +715,15 @@ Return an alist of the form ((FILENAME . (XREF ...)) ...)." | |||
| 724 | 715 | ||
| 725 | (defvar xref--read-pattern-history nil) | 716 | (defvar xref--read-pattern-history nil) |
| 726 | 717 | ||
| 727 | (defun xref--show-xrefs (xrefs window &optional always-show-list) | 718 | (defun xref--show-xrefs (xrefs display-action &optional always-show-list) |
| 728 | (cond | 719 | (cond |
| 729 | ((and (not (cdr xrefs)) (not always-show-list)) | 720 | ((and (not (cdr xrefs)) (not always-show-list)) |
| 730 | (xref-push-marker-stack) | 721 | (xref-push-marker-stack) |
| 731 | (xref--pop-to-location (car xrefs) window)) | 722 | (xref--pop-to-location (car xrefs) display-action)) |
| 732 | (t | 723 | (t |
| 733 | (xref-push-marker-stack) | 724 | (xref-push-marker-stack) |
| 734 | (funcall xref-show-xrefs-function xrefs | 725 | (funcall xref-show-xrefs-function xrefs |
| 735 | `((window . ,window)))))) | 726 | `((window . ,(selected-window))))))) |
| 736 | 727 | ||
| 737 | (defun xref--prompt-p (command) | 728 | (defun xref--prompt-p (command) |
| 738 | (or (eq xref-prompt-for-identifier t) | 729 | (or (eq xref-prompt-for-identifier t) |
| @@ -761,16 +752,16 @@ Return an alist of the form ((FILENAME . (XREF ...)) ...)." | |||
| 761 | 752 | ||
| 762 | ;;; Commands | 753 | ;;; Commands |
| 763 | 754 | ||
| 764 | (defun xref--find-xrefs (input kind arg window) | 755 | (defun xref--find-xrefs (input kind arg display-action) |
| 765 | (let ((xrefs (funcall (intern (format "xref-backend-%s" kind)) | 756 | (let ((xrefs (funcall (intern (format "xref-backend-%s" kind)) |
| 766 | (xref-find-backend) | 757 | (xref-find-backend) |
| 767 | arg))) | 758 | arg))) |
| 768 | (unless xrefs | 759 | (unless xrefs |
| 769 | (user-error "No %s found for: %s" (symbol-name kind) input)) | 760 | (user-error "No %s found for: %s" (symbol-name kind) input)) |
| 770 | (xref--show-xrefs xrefs window))) | 761 | (xref--show-xrefs xrefs display-action))) |
| 771 | 762 | ||
| 772 | (defun xref--find-definitions (id window) | 763 | (defun xref--find-definitions (id display-action) |
| 773 | (xref--find-xrefs id 'definitions id window)) | 764 | (xref--find-xrefs id 'definitions id display-action)) |
| 774 | 765 | ||
| 775 | ;;;###autoload | 766 | ;;;###autoload |
| 776 | (defun xref-find-definitions (identifier) | 767 | (defun xref-find-definitions (identifier) |
diff --git a/lisp/time-stamp.el b/lisp/time-stamp.el index 79524fb7280..c053ea6e924 100644 --- a/lisp/time-stamp.el +++ b/lisp/time-stamp.el | |||
| @@ -106,7 +106,7 @@ otherwise would have been updated." | |||
| 106 | 106 | ||
| 107 | (defcustom time-stamp-time-zone nil | 107 | (defcustom time-stamp-time-zone nil |
| 108 | "The time zone to be used by \\[time-stamp]. | 108 | "The time zone to be used by \\[time-stamp]. |
| 109 | Its format is that of the ZONE argument of the `format-time-string' function," | 109 | Its format is that of the ZONE argument of the `format-time-string' function." |
| 110 | :type '(choice (const :tag "Emacs local time" nil) | 110 | :type '(choice (const :tag "Emacs local time" nil) |
| 111 | (const :tag "Universal Time" t) | 111 | (const :tag "Universal Time" t) |
| 112 | (const :tag "system wall clock time" wall) | 112 | (const :tag "system wall clock time" wall) |
diff --git a/lisp/window.el b/lisp/window.el index e4669c1f6e7..c45e60e6204 100644 --- a/lisp/window.el +++ b/lisp/window.el | |||
| @@ -3241,9 +3241,9 @@ move it as far as possible in the desired direction." | |||
| 3241 | (setq ignore 'preserved) | 3241 | (setq ignore 'preserved) |
| 3242 | (setq right first-right) | 3242 | (setq right first-right) |
| 3243 | (while (and right | 3243 | (while (and right |
| 3244 | (or (window-size-fixed-p right horizontal 'preserved)) | 3244 | (or (window-size-fixed-p right horizontal 'preserved) |
| 3245 | (<= (window-size right horizontal t) | 3245 | (<= (window-size right horizontal t) |
| 3246 | (window-min-size right horizontal 'preserved t))) | 3246 | (window-min-size right horizontal 'preserved t)))) |
| 3247 | (setq right | 3247 | (setq right |
| 3248 | (or (window-right right) | 3248 | (or (window-right right) |
| 3249 | (progn | 3249 | (progn |
| @@ -3352,12 +3352,12 @@ negative, shrink selected window by -DELTA lines or columns." | |||
| 3352 | (window--resize-mini-window minibuffer-window (- delta))) | 3352 | (window--resize-mini-window minibuffer-window (- delta))) |
| 3353 | ((window--resizable-p nil delta horizontal) | 3353 | ((window--resizable-p nil delta horizontal) |
| 3354 | (window-resize nil delta horizontal)) | 3354 | (window-resize nil delta horizontal)) |
| 3355 | ((window--resizable-p nil delta horizontal 'preserved) | ||
| 3356 | (window-resize nil delta horizontal 'preserved)) | ||
| 3357 | ((eq this-command 'enlarge-window) | ||
| 3358 | (user-error "Cannot enlarge selected window")) | ||
| 3355 | (t | 3359 | (t |
| 3356 | (window-resize | 3360 | (error "Cannot enlarge selected window"))))) |
| 3357 | nil (if (> delta 0) | ||
| 3358 | (window-max-delta nil horizontal) | ||
| 3359 | (- (window-min-delta nil horizontal))) | ||
| 3360 | horizontal))))) | ||
| 3361 | 3361 | ||
| 3362 | (defun shrink-window (delta &optional horizontal) | 3362 | (defun shrink-window (delta &optional horizontal) |
| 3363 | "Make the selected window DELTA lines smaller. | 3363 | "Make the selected window DELTA lines smaller. |
| @@ -3387,12 +3387,12 @@ Also see the `window-min-height' variable." | |||
| 3387 | (window--resize-mini-window minibuffer-window delta)) | 3387 | (window--resize-mini-window minibuffer-window delta)) |
| 3388 | ((window--resizable-p nil (- delta) horizontal) | 3388 | ((window--resizable-p nil (- delta) horizontal) |
| 3389 | (window-resize nil (- delta) horizontal)) | 3389 | (window-resize nil (- delta) horizontal)) |
| 3390 | ((window--resizable-p nil (- delta) horizontal 'preserved) | ||
| 3391 | (window-resize nil (- delta) horizontal 'preserved)) | ||
| 3392 | ((eq this-command 'shrink-window) | ||
| 3393 | (user-error "Cannot shrink selected window")) | ||
| 3390 | (t | 3394 | (t |
| 3391 | (window-resize | 3395 | (error "Cannot shrink selected window"))))) |
| 3392 | nil (if (> delta 0) | ||
| 3393 | (- (window-min-delta nil horizontal)) | ||
| 3394 | (window-max-delta nil horizontal)) | ||
| 3395 | horizontal))))) | ||
| 3396 | 3396 | ||
| 3397 | (defun maximize-window (&optional window) | 3397 | (defun maximize-window (&optional window) |
| 3398 | "Maximize WINDOW. | 3398 | "Maximize WINDOW. |
diff --git a/lisp/woman.el b/lisp/woman.el index 28a47986c2f..a4a0da209cb 100644 --- a/lisp/woman.el +++ b/lisp/woman.el | |||
| @@ -1654,7 +1654,7 @@ Do not call directly!" | |||
| 1654 | (setq woman-frame (make-frame))))) | 1654 | (setq woman-frame (make-frame))))) |
| 1655 | (set-buffer (get-buffer-create bufname)) | 1655 | (set-buffer (get-buffer-create bufname)) |
| 1656 | (condition-case nil | 1656 | (condition-case nil |
| 1657 | (display-buffer (current-buffer)) | 1657 | (pop-to-buffer-same-window (current-buffer)) |
| 1658 | (error (pop-to-buffer (current-buffer)))) | 1658 | (error (pop-to-buffer (current-buffer)))) |
| 1659 | (buffer-disable-undo) | 1659 | (buffer-disable-undo) |
| 1660 | (setq buffer-read-only nil) | 1660 | (setq buffer-read-only nil) |
| @@ -2064,14 +2064,14 @@ alist in `woman-buffer-alist' and return nil." | |||
| 2064 | (if (zerop woman-buffer-number) | 2064 | (if (zerop woman-buffer-number) |
| 2065 | (let ((buffer (get-buffer (cdr (car woman-buffer-alist))))) | 2065 | (let ((buffer (get-buffer (cdr (car woman-buffer-alist))))) |
| 2066 | (if buffer | 2066 | (if buffer |
| 2067 | (display-buffer buffer) | 2067 | (pop-to-buffer-same-window buffer) |
| 2068 | ;; Delete alist element: | 2068 | ;; Delete alist element: |
| 2069 | (setq woman-buffer-alist (cdr woman-buffer-alist)) | 2069 | (setq woman-buffer-alist (cdr woman-buffer-alist)) |
| 2070 | nil)) | 2070 | nil)) |
| 2071 | (let* ((prev-ptr (nthcdr (1- woman-buffer-number) woman-buffer-alist)) | 2071 | (let* ((prev-ptr (nthcdr (1- woman-buffer-number) woman-buffer-alist)) |
| 2072 | (buffer (get-buffer (cdr (car (cdr prev-ptr)))))) | 2072 | (buffer (get-buffer (cdr (car (cdr prev-ptr)))))) |
| 2073 | (if buffer | 2073 | (if buffer |
| 2074 | (display-buffer buffer) | 2074 | (pop-to-buffer-same-window buffer) |
| 2075 | ;; Delete alist element: | 2075 | ;; Delete alist element: |
| 2076 | (setcdr prev-ptr (cdr (cdr prev-ptr))) | 2076 | (setcdr prev-ptr (cdr (cdr prev-ptr))) |
| 2077 | (if (>= woman-buffer-number (length woman-buffer-alist)) | 2077 | (if (>= woman-buffer-number (length woman-buffer-alist)) |