diff options
| author | Miles Bader | 2006-02-22 06:54:10 +0000 |
|---|---|---|
| committer | Miles Bader | 2006-02-22 06:54:10 +0000 |
| commit | b434f199dbbc2694a69538ee95e5e583f6357f71 (patch) | |
| tree | ea87d2540063659d9cfdb24462bb4c0336a6ec47 | |
| parent | 9d826e0eaf8a4e2f1cf5aac74d6b02ccc393af8d (diff) | |
| parent | a1b24e137f75b9f5fdbd5526947a70c462c5e5bf (diff) | |
| download | emacs-b434f199dbbc2694a69538ee95e5e583f6357f71.tar.gz emacs-b434f199dbbc2694a69538ee95e5e583f6357f71.zip | |
Revision: emacs@sv.gnu.org/emacs--unicode--0--patch-21
Merge from emacs--devo--0
Patches applied:
* emacs--devo--0 (patch 97-112)
- Update from CVS
- Merge from erc--emacs--0
- Update from CVS: src/regex.c (extend_range_table_work_area): Fix typo.
- Merge from gnus--rel--5.10
* gnus--rel--5.10 (patch 37)
- Update from CVS
90 files changed, 4197 insertions, 2734 deletions
diff --git a/admin/ChangeLog b/admin/ChangeLog index 1b855f7c4ed..1543c17d3a6 100644 --- a/admin/ChangeLog +++ b/admin/ChangeLog | |||
| @@ -1,3 +1,13 @@ | |||
| 1 | 2006-02-20 Kim F. Storm <storm@cua.dk> | ||
| 2 | |||
| 3 | * FOR-RELEASE (NEW FEATURES): Completed work on this item: | ||
| 4 | Rework how fringe bitmaps are defined and used. | ||
| 5 | Currently, bitmap usage and bitmap appearence are "mixed-up" in a | ||
| 6 | one-level representation. It would be cleaner to split the | ||
| 7 | representation into a two-level model where first level maps | ||
| 8 | bitmap usage to a bitmap name, and second level maps bitmap name to | ||
| 9 | a bitmap appearence. | ||
| 10 | |||
| 1 | 2006-01-27 Chong Yidong <cyd@stupidchicken.com> | 11 | 2006-01-27 Chong Yidong <cyd@stupidchicken.com> |
| 2 | 12 | ||
| 3 | * FOR-RELEASE: string allocation bugs fixed. | 13 | * FOR-RELEASE: string allocation bugs fixed. |
diff --git a/admin/FOR-RELEASE b/admin/FOR-RELEASE index ab17c84eab9..ef73ec4436e 100644 --- a/admin/FOR-RELEASE +++ b/admin/FOR-RELEASE | |||
| @@ -33,16 +33,14 @@ Assigned to Bill Wohler <wohler@newt.com>. | |||
| 33 | 33 | ||
| 34 | * NEW FEATURES | 34 | * NEW FEATURES |
| 35 | 35 | ||
| 36 | ** Rework how fringe bitmaps are defined and used. | ||
| 37 | Currently, bitmap usage and bitmap appearence are "mixed-up" in a | ||
| 38 | one-level representation. It would be cleaner to split the | ||
| 39 | representation into a two-level model where first level maps | ||
| 40 | bitmap usage to a bitmap name, and second level maps bitmap name to | ||
| 41 | a bitmap appearence. | ||
| 42 | [Assigned to KFS] | ||
| 43 | |||
| 44 | * BUGS | 36 | * BUGS |
| 45 | 37 | ||
| 38 | ** Reiner Steib's 23 Jan 2006 bug report that tool bar icons don't update. | ||
| 39 | |||
| 40 | ** Ralf Angeli's 4 Jul 2005 bug report about scroll-preserve-screen-position. | ||
| 41 | |||
| 42 | ** Martin Rudalics' 30 Jan 2006 bug report about overlays at end of buffer. | ||
| 43 | |||
| 46 | ** TCP server processes do not work on Windows. | 44 | ** TCP server processes do not work on Windows. |
| 47 | 45 | ||
| 48 | TCP/IP server processes created with `make-network-process' consume | 46 | TCP/IP server processes created with `make-network-process' consume |
| @@ -50,6 +48,15 @@ excesive CPU on some Windows environments. Usages of 50% and 100% | |||
| 50 | CPU time have been observed on different Window XP configurations. | 48 | CPU time have been observed on different Window XP configurations. |
| 51 | Seems to be a problem in sys_select in w32proc.c. | 49 | Seems to be a problem in sys_select in w32proc.c. |
| 52 | 50 | ||
| 51 | In its current form, it sys_select says the socket is ready, so we | ||
| 52 | call server_accept_connection which again calls accept() which returns | ||
| 53 | -1 with errno == WSAEWOULDBLOCK (10035) indicating that there is no | ||
| 54 | pending connection to accept. | ||
| 55 | |||
| 56 | It seems that to fix this, w32 server sockets must use WSAAsyncSelect | ||
| 57 | + FD_ACCEPT to request notifications of incoming connections... | ||
| 58 | |||
| 59 | |||
| 53 | * DOCUMENTATION | 60 | * DOCUMENTATION |
| 54 | 61 | ||
| 55 | ** Add a node to the Lisp manual describing key sequences from the | 62 | ** Add a node to the Lisp manual describing key sequences from the |
diff --git a/etc/ChangeLog b/etc/ChangeLog index 565b2d3e220..8c1e5782db5 100644 --- a/etc/ChangeLog +++ b/etc/ChangeLog | |||
| @@ -1,3 +1,17 @@ | |||
| 1 | 2006-02-18 Bill Wohler <wohler@newt.com> | ||
| 2 | |||
| 3 | Release MH-E version 7.92. | ||
| 4 | |||
| 5 | * NEWS, MH-E-NEWS: Update for MH-E release 7.92. | ||
| 6 | |||
| 7 | 2006-02-17 Kenichi Handa <handa@m17n.org> | ||
| 8 | |||
| 9 | * TUTORIAL.translators (TUTORIAL.cn): Update the maintainer. | ||
| 10 | |||
| 11 | 2006-02-17 Sun Yijiang <sunyijiang@gmail.com> | ||
| 12 | |||
| 13 | * TUTORIAL.cn: Reworked. | ||
| 14 | |||
| 1 | 2006-02-14 Chong Yidong <cyd@stupidchicken.com> | 15 | 2006-02-14 Chong Yidong <cyd@stupidchicken.com> |
| 2 | 16 | ||
| 3 | * NEWS: Changes in handling of file local variables. | 17 | * NEWS: Changes in handling of file local variables. |
diff --git a/etc/ERC-NEWS b/etc/ERC-NEWS index ada1d02785d..67345efe090 100644 --- a/etc/ERC-NEWS +++ b/etc/ERC-NEWS | |||
| @@ -1,6 +1,8 @@ | |||
| 1 | ERC NEWS -*- outline -*- | 1 | ERC NEWS -*- outline -*- |
| 2 | 2 | ||
| 3 | * Changes in ERC 5.1.2 (unreleased) | 3 | * Changes in ERC 5.2 (unreleased) |
| 4 | |||
| 5 | * Changes in ERC 5.1.2 | ||
| 4 | 6 | ||
| 5 | ** Fix compiler errors in erc-autojoin.el and erc-dcc.el. | 7 | ** Fix compiler errors in erc-autojoin.el and erc-dcc.el. |
| 6 | 8 | ||
diff --git a/etc/MH-E-NEWS b/etc/MH-E-NEWS index 8dc89e3cbcf..74470e47e25 100644 --- a/etc/MH-E-NEWS +++ b/etc/MH-E-NEWS | |||
| @@ -6,6 +6,14 @@ Copying and distribution of this file, with or without modification, | |||
| 6 | are permitted in any medium without royalty provided the copyright | 6 | are permitted in any medium without royalty provided the copyright |
| 7 | notice and this notice are preserved. | 7 | notice and this notice are preserved. |
| 8 | 8 | ||
| 9 | * Changes in MH-E 7.92 | ||
| 10 | |||
| 11 | Version 7.92, the third 8.0 beta release, removes the "sed -i" in the | ||
| 12 | Makefile (SF #1432060), tunes the setting of `mh-image-load-path', | ||
| 13 | works around systems that do not have face inheritance, fixes several | ||
| 14 | issues with searching on XEmacs, and creates the correct MIME type | ||
| 15 | when including OpenOffice documents. | ||
| 16 | |||
| 9 | * Changes in MH-E 7.91 | 17 | * Changes in MH-E 7.91 |
| 10 | 18 | ||
| 11 | Version 7.91 is the second 8.0 beta release and fixes several bugs | 19 | Version 7.91 is the second 8.0 beta release and fixes several bugs |
| @@ -1945,24 +1945,32 @@ behavior in older versions of Emacs). | |||
| 1945 | 1945 | ||
| 1946 | *** Topic cryptography added, enabling easy gpg topic encryption and | 1946 | *** Topic cryptography added, enabling easy gpg topic encryption and |
| 1947 | decryption. Per-topic basis enables interspersing encrypted-text and | 1947 | decryption. Per-topic basis enables interspersing encrypted-text and |
| 1948 | clear-text within a single file to your hearts content, using symmetric | 1948 | clear-text within a single file to your heart's content, using symmetric |
| 1949 | and/or public key modes. Time-limited key caching, user-provided | 1949 | and/or public key modes. Time-limited key caching, user-provided |
| 1950 | symmetric key hinting and consistency verification, auto-encryption of | 1950 | symmetric key hinting and consistency verification, auto-encryption of |
| 1951 | pending topics on save, and more, make it easy to use encryption in | 1951 | pending topics on save, and more, make it easy to use encryption in |
| 1952 | powerful ways. | 1952 | powerful ways. |
| 1953 | 1953 | ||
| 1954 | *** many substantial fixes and refinements, including: | 1954 | *** Default command prefix changed to "\C-c " (control-c space), to avoid |
| 1955 | intruding on user's keybinding space. Customize the | ||
| 1956 | `allout-command-prefix' variable to your preference. | ||
| 1957 | |||
| 1958 | *** Allout now uses text overlay's `invisible' property (and others) for | ||
| 1959 | concealed text, instead of selective-display. This simplifies the code, in | ||
| 1960 | particularly avoiding the need for kludges for isearch dynamic-display, | ||
| 1961 | discretionary handling of edits of concealed text, undo concerns, etc. | ||
| 1962 | |||
| 1963 | *** Many substantial fixes and refinements, including: | ||
| 1955 | 1964 | ||
| 1956 | - repaired inhibition of inadvertent edits to concealed text | 1965 | - repaired inhibition of inadvertent edits to concealed text |
| 1957 | - repaired retention of topic body hanging indent upon topic depth shifts | 1966 | - repaired retention of topic body hanging indent upon topic depth shifts |
| 1958 | - prevent "containment discontinuities" where a topic is shifted deeper | 1967 | - refuse to create "containment discontinuities", where a |
| 1959 | than the offspring-depth of its container | 1968 | topic is shifted deeper than the offspring-depth of its' container |
| 1960 | - easy to adopt the distinctive bullet of a topic in a topic created | 1969 | - bulleting variation is simpler and more accommodating, both in the |
| 1961 | relative to it, or select a new one, or use the common topic bullet | 1970 | default behavior and in ability to vary when creating new topics |
| 1962 | - plain bullets, by default, now alternate between only two characters | 1971 | - many internal fixes and refinements |
| 1963 | ('.' and ','), yielding less cluttered outlines | 1972 | - many module and function docstring clarifications |
| 1964 | - many internal fixes | 1973 | - version number incremented to 2.2 |
| 1965 | - version number incremented to 2.1 | ||
| 1966 | 1974 | ||
| 1967 | ** The variable `woman-topic-at-point' was renamed | 1975 | ** The variable `woman-topic-at-point' was renamed |
| 1968 | to `woman-use-topic-at-point' and behaves differently: if this | 1976 | to `woman-use-topic-at-point' and behaves differently: if this |
| @@ -3074,7 +3082,7 @@ See the file GNUS-NEWS or the node "Oort Gnus" in the Gnus manual for details. | |||
| 3074 | --- | 3082 | --- |
| 3075 | ** MH-E changes. | 3083 | ** MH-E changes. |
| 3076 | 3084 | ||
| 3077 | Upgraded to MH-E version 7.91. There have been major changes since | 3085 | Upgraded to MH-E version 7.92. There have been major changes since |
| 3078 | version 5.0.2; see MH-E-NEWS for details. | 3086 | version 5.0.2; see MH-E-NEWS for details. |
| 3079 | 3087 | ||
| 3080 | ** Calendar changes: | 3088 | ** Calendar changes: |
| @@ -4671,6 +4679,13 @@ or bottom edge of a window. It does not move other window edges. | |||
| 4671 | +++ | 4679 | +++ |
| 4672 | ** Customizable fringe bitmaps | 4680 | ** Customizable fringe bitmaps |
| 4673 | 4681 | ||
| 4682 | *** New buffer-local variables `fringe-indicator-alist' and | ||
| 4683 | `fringe-cursor-alist' maps between logical (internal) fringe indicator | ||
| 4684 | and cursor symbols and the actual fringe bitmaps to be displayed. | ||
| 4685 | This decouples the logical meaning of the fringe indicators from the | ||
| 4686 | physical appearence, as well as allowing different fringe bitmaps to | ||
| 4687 | be used in different windows showing different buffers. | ||
| 4688 | |||
| 4674 | *** New function `define-fringe-bitmap' can now be used to create new | 4689 | *** New function `define-fringe-bitmap' can now be used to create new |
| 4675 | fringe bitmaps, as well as change the built-in fringe bitmaps. | 4690 | fringe bitmaps, as well as change the built-in fringe bitmaps. |
| 4676 | 4691 | ||
diff --git a/etc/TUTORIAL.cn b/etc/TUTORIAL.cn index ce22ac0b349..2546b84e465 100644 --- a/etc/TUTORIAL.cn +++ b/etc/TUTORIAL.cn | |||
| @@ -1,150 +1,136 @@ | |||
| 1 | Emacs ¿ìËÙÖ¸ÄÏ. | 1 | Emacs ¿ìËÙÖ¸ÄÏ£¨²é¿´°æÈ¨ÉùÃ÷ÇëÖÁ±¾ÎÄĩ⣩ |
| 2 | 2 | ||
| 3 | Emacs Ö¸Áîͨ³£°üº¬ÓÐ CONTROL ¼ü£¨ÓÐʱºòÒÔ CTRL »ò CTL À´±êʾ£©»òÊÇ | 3 | ¡¾×¢Ò⣺λÓÚ¡¾¡¿Ö®¼äµÄÄÚÈÝÊÇÒë×¢£¬±ÈÈç±¾ÐУ¬ÏÂͬ¡£¡¿ |
| 4 | META ¼ü£¨ÓÐʱºòÒÔ EDIT »ò ALT À´±êʾ£©¡£ÎªÁ˱ÜÃâÿһ´Î¶¼ÒªÐ´³öÆäÈ«Ãû£¬ | ||
| 5 | ÎÒÃǽ«»áʹÓÃÏÂÊöµÄËõд£º | ||
| 6 | 4 | ||
| 7 | C-<chr> ±íʾµ±¼üÈë×ÖÔª <chr> ʱ °´×¡ CONTROL ¼ü¡£ | 5 | Emacs ¼üÅÌÃüÁîͨ³£°üº¬ CONTROL ¼ü£¨ÓÐʱºòÒÔ CTRL »ò CTL À´±êʾ£©ºÍ |
| 8 | Òò´Ë£¬C-f ¾ÍÊÇ£º°´×¡ CONTROL ¼üÔÙ¼üÈë f ¡£ | 6 | META ¼ü£¨ÓÐʱºòÓà EDIT »ò ALT À´±êʾ£©¡£ÎªÁ˱ÜÃâÿ´Î¶¼ÒªÐ´³öÈ«Ãû£¬ÎÒÃÇ |
| 9 | M-<chr> ±íʾµ±¼üÈë×ÖÔª <chr> ʱ °´×¡ META »ò EDIT »ò ALT ¼ü¡£ | 7 | Ô¼¶¨Ê¹ÓÃÏÂÊöËõд£º |
| 10 | Èç¹ûûÓÐ META ¡¢ EDIT »ò ALT ¼üʱ£¬Ôò¿ÉÒÔÓà | ||
| 11 | ¡¸°´Ò»Ï ESC ¼üÈ»ºó·Å¿ª£¬ÔÙ¼üÈë <chr> µÄ²½Ö衹 | ||
| 12 | À´×÷ÎªÌæ´ú¡£ÎÒÃÇÒÔ <ESC> À´±íʾ ESC ¼ü¡£ | ||
| 13 | 8 | ||
| 14 | ÖØÒª±¸Íü¼£ºÒªÀ뿪 Emacs ²Ù×÷½×¶Î£¨ session £©£¬¼üÈë C-x C-c £¨Á½¸ö×Ö | 9 | C-<chr> ±íʾµ±ÊäÈë×Ö·û <chr> ʱ°´×¡ CONTROL ¼ü¡£ |
| 15 | Ôª£©¡£Î»ÔÚ×ó²à±ß½çµÄ¡¸>>¡¹×ÖÔªÊÇÈÃÄú¿ÉÒÔÊÔÖøÊ¹ÓõÄÖ¸ÁîµÄÌáʾ¡£¾ÙÀýÀ´Ëµ£º | 10 | Òò´Ë C-f ¾Í±íʾ£º°´×¡ CONTROL ¼üÔÙÊäÈë f¡£ |
| 16 | <<Blank lines inserted around following line by help-with-tutorial>> | ||
| 17 | [Middle of page left blank for didactic purposes. Text continues below] | ||
| 18 | >> ÏÖÔÚ¼üÈë C-v £¨ View next screen £©ÒÔÒÆµ½Ï¸öÓ©Ä»¡£ | ||
| 19 | £¨ÊÔÊÔ¿´£¬¼üÈë×ÖÔª v ʱ£¬°´×¡ CONTROL ¼ü£© | ||
| 20 | ´ÓÏÖÔÚ¿ªÊ¼£¬ÄúÓ¦¸ÃÔÚÿ´ÎÔĶÁÍêĿǰµÄөĻʱ×öÒ»´ÎÕâ¸ö¶¯×÷¡£ | ||
| 21 | 11 | ||
| 22 | ҪעÒâµÄÊÇ£¬µ±Äú´ÓÒ»¸öÓ©Ä»ÒÆµ½ÁíÒ»¸öʱ£¬Öмä»áÓÐÁ½ÐÐÖØ¸´£»ÕâÑù×öÊÇΪÁË | 12 | M-<chr> ±íʾµ±ÊäÈë×Ö·û <chr> ʱ°´×¡ META£¨»ò EDIT »ò ALT£©¼ü¡£ |
| 23 | ÌṩһЩÁ¬ÐøÐÔ£¬ÈÃÄú¿ÉÒÔ½ÓÐøµØÔĶÁÎÄ×Ö¡£ | 13 | Èç¹ûÄãµÄ¼üÅÌÉÏûÓÐ META ¡¢EDIT »ò ALT ¼ü£¬ÓÃÏÂÊö·½·¨Ò²µÈЧ£º |
| 14 | ÏȰ´Ò»Ï ESC ¼üÈ»ºó·Å¿ª£¬ÔÙÊäÈë <chr>¡£ÎÒÃÇÓà <ESC> À´±íʾ | ||
| 15 | ESC ¼ü¡£ | ||
| 24 | 16 | ||
| 25 | ÄúÐèÒªÖªµÀµÄµÚÒ»¼þÊÂÊÇÈçºÎÔÚÎÄ×ÖÖÐÒÆ¶¯¡£ÄúÒѾ֪µÀÁË¿ÉÒÔ C-v À´ÏòÇ°ÒÆ | 17 | ÖØÒªÌáʾ£ºÒªÍ˳ö Emacs£¬ÇëÓà C-x C-c£¨Á½¸öÁ¬ÐøµÄ×éºÏ¼ü£©¡£ÏÂÎÄÖÐ×ó±ß¶¥ |
| 26 | ¶¯Ò»¸öÓ©Ä»¡£ÒªÏòºóÒÆ¶¯Ò»¸öÓ©Ä»£¬Ôò¼üÈë M-v £¨°´×¡ META ¼ü£¬È»ºó¼üÈë v | 18 | Ðеġ°>>¡±×ÖÑùÓÃÀ´ÌáʾÄã³¢ÊÔ¼üÅÌÃüÁî¡£±ÈÈ磺 |
| 27 | £¬»òÊÇÈç¹ûÄúûÓÐ META ¡¢ EDIT »ò ALT ¼üʱ¼üÈë <ESC>v £©¡£ | 19 | <<Blank lines inserted around following line by help-with-tutorial>> |
| 20 | [±¾Ò³µ±ÖÐÌØÒâÁô³öһЩ¿Õ°×ÊdzöÓÚ½ÌѧĿµÄ£¬Çë¼ÌÐøÍùºó¿´] | ||
| 21 | >> ÏÖÔÚÊäÈë C-v £¨²é¿´ÏÂÒ»ÆÁÎÄ×Ö£©Òƶ¯µ½ÏÂÒ»ÆÁ¡£ | ||
| 22 | £¨±ð½ôÕÅ£¬ÔÚÊäÈë×Ö·û v µÄͬʱעÒâÒª°´×¡ CONTROL ¼ü£© | ||
| 23 | ´ÓÏÖÔÚ¿ªÊ¼£¬Ã¿¶ÁÍ굱ǰһÆÁÄã¶¼ÐèÒªÕâÑù×öÒ»´Î¡£ | ||
| 28 | 24 | ||
| 29 | >> ÊÔÖø¼üÈë M-v È»ºó C-v £¬Á¬Ðø¸ö¼¸´Î¡£ | 25 | ÖµµÃ×¢ÒâµÄÊÇ£¬µ±Äã´ÓÉÏÒ»ÆÁ¹öµ½ÏÂÒ»ÆÁʱ£¬Öмä»áÓÐÁ½ÐеÄÖØ¸´£»ÕâÑù×öÊÇΪ |
| 26 | ÁËά³Ö¹öÆÁµÄÁ¬ÐøÐÔ£¬·½±ãÄã˳³©¡¢Á¬ÐøµØÔĶÁ¡£ | ||
| 30 | 27 | ||
| 31 | ¡¾ÏÖÔÚÄú¿ÉÒÔ C-v Ö¸ÁîÒÆµ½ºóÃæ¡¸·Ò롹һ½Ú£¬ÒÔÈ¡µÃ¹Øì¶±¾ÎĵķÒëÏà¹ØÊ | 28 | ÓÃ±à¼Æ÷£¬¿ªÃŵÚÒ»¼þʾÍÊÇѧ»áÔÚÎÄ×ÖÖÐÒÆ¶¯¡£ÄãÒѾ֪µÀÁË C-v ¿ÉÒÔÏòÏÂÒÆ |
| 32 | ÏȻºóÒÔ M-v Ö¸Áî»Øµ½ÕâÀï¡£¡¿ | 29 | ¶¯Ò»ÆÁ£¬ÒªÍùÉÏÒÆ£¬ÇëÓà M-v £¨Ò²¾ÍÊǰ´×¡ META ¼ü£¬È»ºóÊäÈëv£¬Èç¹ûÄãûÓÐ |
| 30 | META¡¢EDIT »ò ALT ¼üÄÇô¾ÍÏȰ´ <ESC> ÔÙ°´ v£©¡£ | ||
| 33 | 31 | ||
| 32 | >> ÊÔÊÔ M-v£¬È»ºóÔÙÊÔÊÔ C-v£¬À´»ØåÞ¼¸´Î¡£ | ||
| 34 | 33 | ||
| 35 | * ÕªÒª£¨ SUMMARY £© | ||
| 36 | ------------------- | ||
| 37 | 34 | ||
| 38 | ÒÔϵÄÖ¸ÁîÔÚ¼ìÔÄөĻʱÏ൱ÓÐÓ㺡¾ÎÒÃÇÏÖÔÚÒÔ¡¸Ó©Ä»¡¹À´±íʾ¡¸ÏÔʾµµ°¸ÄÚ | 35 | * С½á£¨SUMMARY£© |
| 39 | ÈݵÄÇøÓò¡¹£¬ÒòΪĿǰÊÇ´¦ÔÚ Emacs Öеĵ¥´°¸ñ£¨ window £©ÏÔʾ״̬£¬Èç¹û | 36 | ----------------- |
| 40 | ÊÇÔÚ¶à´°¸ñµÄ״̬Ï£¬ÕâÀïËù½éÉܵÄÖ¸ÁîÔò×÷ÓÃÔÚ¡¸¹¤×÷ÖеĴ°¸ñ¡¹¡£ÓйØì¶´° | ||
| 41 | ¸ñµÄ½éÉÜ£¬Çë¼û´°¸ñ£¨ windows £©Ò»½Ú¡£¡¿ | ||
| 42 | 37 | ||
| 43 | C-v ÏòÇ°ÒÆ¶¯Ò»¸öÓ©Ä»£¯´°¸ñ | 38 | ÒÔÏÂÃüÁîÔÚ·Ò³ä¯ÀÀʱÏ൱ÓÐÓ㺠|
| 44 | M-v ÏòºóÒÆ¶¯Ò»¸öÓ©Ä»£¯´°¸ñ | ||
| 45 | C-l Çå³ýÓ©Ä»£¯´°¸ñ£¬ÔÙÖØÐÂÏÔʾËùÓÐÎÄ×Ö£¬ | ||
| 46 | ÓαêËùÔÚλÖûáÏÔʾì¶Ó©Ä»£¯´°¸ñµÄÖÐÑë¡£ | ||
| 47 | £¨ÊÇ CONTROL-L ¶ø²»ÊÇ CONTROL-1 £© | ||
| 48 | 39 | ||
| 49 | >> ÕÒ³öÓαêµÄλÖ㬲¢×¢ÒâÆä¸½½üµÄÎÄ×ÖΪºÎ¡£È»ºó¼üÈë C-l ¡£ | 40 | C-v ÏòÇ°ÒÆ¶¯Ò»ÆÁ |
| 50 | ÔÙ´ÎÕÒ³öÓαêµÄλÖã¬È·ÈÏÒ»ÏÂÏàͬµÄÎÄ×ÖÏÖÔÚҲλÔÚÆä¸½½ü¡£ | 41 | M-v ÏòºóÒÆ¶¯Ò»ÆÁ |
| 42 | C-l ÖØ»æÆÁÄ»£¬²¢½«¹â±êËùÔÚÐÐÖÃÓÚÆÁÄ»µÄÖÐÑë | ||
| 43 | £¨×¢ÒâÊÇ CONTROL-L£¬²»ÊÇ CONTROL-1£© | ||
| 51 | 44 | ||
| 52 | Èç¹ûÄúµÄÖÕ¶Ë»úÓÐ PageUp Óë PageDn ¼üµÄ»°£¬ÄúÒ²¿ÉÒÔʹÓÃËüÃÇÀ´ÒÔөĻΪµ¥ | 45 | >> ÕÒµ½¹â±ê£¬ÁôÒâÆä¸½½üµÄÎÄ×Ö£¬È»ºóÊäÈë C-l¡£ |
| 53 | λµØÒƶ¯£¬µ«ÊÇʹÓà C-v ºÍ M-v »á±È½ÏÓÐЧÂÊ¡£ | 46 | ÕÒÕÒ¹â±êÔÚÄÄÀÄã»á·¢Ï֯䏽½üµÄÎÄ×Ö²¢Ã»Óб仯¡£ |
| 54 | 47 | ||
| 48 | Èç¹ûÄãµÄ¼üÅÌÉÏÓÐ PageUp ºÍ PageDn£¬Ò²¿ÉÒÔÓÃÕâÁ½¸ö¼üÀ´¹öÆÁ¡£²»¹ýʹÓà | ||
| 49 | C-v ºÍ M-v µÄЧÂÊÒª¸ü¸ßһЩ¡£ | ||
| 55 | 50 | ||
| 56 | * »ù±¾µÄÓÎ±ê¿ØÖÆ£¨ BASIC CURSOR CONTROL £© | ||
| 57 | ------------------------------------------ | ||
| 58 | 51 | ||
| 59 | Ó©Ä»µ½Ó©Ä»µÄÒÆ¶¯ÊǺÜÓÐÓ㬵«ÊÇÄúÈçºÎÒÆ¶¯µ½Î»ì¶Ó©Ä»ÄÚÎÄ×ÖÖеÄÌØ¶¨Î»ÖÃÄØ£¿ | 52 | * »ù±¾µÄ¹â±ê¿ØÖÆ£¨BASIC CURSOR CONTROL£© |
| 53 | ---------------------------------------- | ||
| 54 | |||
| 55 | ÕûÆÁµÄÒÆ¶¯ºÜÓÐÓ㬵«ÊÇÈçºÎÔÚÎÄ×ÖÖо«È·¶¨Î»ÄØ£¿ | ||
| 60 | 56 | ||
| 61 | Óм¸ÖÖ·½Ê½¿ÉÒÔ½øÐС£Äú¿ÉÒÔʹÓ÷½Ïò¼ü£¬µ«Êǽ«ÄúµÄÊÖ·ÅÔÚ±ê×¼µÄ¡²¼üÅÌ¡³Î» | 57 | Óм¸ÖÖ·½Ê½¿ÉÒÔÑ¡Ôñ¡£Ó÷½Ïò¼üµ±È»¿ÉÒÔ£¬²»¹ý¸üÓÐЧÂʵķ½·¨ÊDZ£³ÖË«ÊÖλÓÚ |
| 62 | Ö㬲¢ÇÒʹÓÃÖ¸Áî C-p ¡¢ C-b ¡¢ C-f ºÍ C-n ½«±È½ÏÓÐЧÂÊ¡£ÕâЩ×ÖÔªºÍËĸö | 58 | Ö÷¼üÅÌÇø£¬È»ºóʹÓà C-p ¡¢ C-b ¡¢ C-f ºÍ C-n ÕâËĸöÃüÁî¡£ËüÃǵŦÄܺͷ½ |
| 63 | ·½Ïò¼ü¡²µÄ¹¦ÄÜ¡³ÊÇͬµÈµÄ£¬ÈçÏÂËùʾ£º | 59 | Ïò¼üÊÇÒ»ÑùµÄ£¬ÈçÏÂͼËùʾ£º |
| 64 | 60 | ||
| 65 | ǰһÐÐ C-p | 61 | ÉÏÒ»ÐÐ C-p |
| 66 | : | 62 | : |
| 67 | : | 63 | : |
| 68 | ÏòºóÒÆ C-b .... ĿǰÓαêλÖà .... ÏòÇ°ÒÆ C-f | 64 | Ïò×óÒÆ C-b .... Ŀǰ¹â±êλÖà .... ÏòÓÒÒÆ C-f |
| 69 | : | 65 | : |
| 70 | : | 66 | : |
| 71 | ºóÒ»ÐÐ C-n | 67 | ÏÂÒ»ÐÐ C-n |
| 72 | 68 | ||
| 73 | >> ÒÔ C-n »ò C-p ½«ÓαêÒÆµ½Í¼ÐεÄÖÐÑë¡£ | 69 | >> Óà C-n »ò C-p ½«¹â±êÒÆµ½ÉÏͼµÄÖÐÑë¡£ |
| 74 | ¼üÈë C-l »á¿´µ½Õû¸öͼÐÎÏÔʾÔÚÓ©Ä»µÄÖÐÑë¡£ | 70 | °´ C-l£¬Õû·ùͼ»á±»ÏÔʾÔÚÆÁÄ»µÄÖÐÑë¡£ |
| 75 | 71 | ||
| 76 | Äú»á·¢ÏÖÓÃ×ÖĸËù´ú±íµÄÒâÒåÀ´¼ÇÒäËüÃǺÜÈÝÒ×£ºP ±íʾ previous ¡¢ N ±íʾ | 72 | ¡°P N B F¡±Ëĸö×Öĸ·Ö±ð´ú±íÁËËĸö´Ê£¬ÓÃÕâËĸö´Ê¼ÇÒäÕâЩ×éºÏ¼ü»á¸üÈÝÒ×£º |
| 77 | next ¡¢ B ±íʾ backward ¡¢¶ø F Ôò±íʾ forward ¡£Äú½«¡¸×ÜÊÇ¡¹Óõ½ÕâЩÓÎ | 73 | P ´ú±í previous£¨ÉÏÒ»ÐУ©£¬N ´ú±í next£¨ÏÂÒ»ÐУ©£¬B ´ú±í backward£¨»Ø |
| 78 | ±êÒÆ¶¯Ö¸Áî¡£ | 74 | ÍË£©£¬¶ø F Ôò´ú±í forward£¨Ç°½ø£©¡£ÕâЩ×éºÏ¼ü½ñºó½«ÓëÄãÐÎÓ°²»Àë¡£ |
| 79 | 75 | ||
| 80 | >> °´¼¸´Î C-n °ÑÓαêÍùÏÂÒÆ¶¯µ½ÕâÐС£ | 76 | >> °´¼¸´Î C-n °Ñ¹â±êÍùÏÂŲµ½ÕâÀï¡£ |
| 81 | 77 | ||
| 82 | >> °´¼¸´Î C-f ÍùÇ°ÒÆµ½ÕâÐУ¬È»ºóÔÙÒÔ C-p ÍùºóÒÆ¶¯¡£ | 78 | >> Óà C-f °Ñ¹â±êÒÆ¶¯µ½ÕâÒ»ÐУ¬È»ºóÔÙÓà C-p ÍùÉÏŲ¡£ |
| 83 | ¿´¿´µ±ÓαêÔÚ±¾ÐÐÖÐÑëʱ£¬C-p µÄ¶¯×÷ÊÇÔõÑù¡£ | 79 | ×¢Òâ¹Û²ìµ±¹â±êÔÚÒ»ÐеÄÖÐÑëʱ C-p ÃüÁîµÄÐÐΪ¡£ |
| 84 | 80 | ||
| 85 | ÿһ¸öÎÄ×ÖÐж¼ÒÔÒ»¸ö Newline ×ÖÔª×÷Ϊ½áÊø£¬ËüÊÇÓÃÀ´ÓëÏÂÒ»ÐÐ×÷Ϊ·Ö±ð¡£ | 81 | ÿÐÐÎÄ×Ö¶¼ÒÔÒ»¸ö¡°»»Ðзû¡±½áÊø£¬¡°»»Ðзû¡±°ÑÐÐÓëÐÐÇø·Ö¿ªÀ´¡£ÎļþµÄ×îºó |
| 86 | ÔÚÄúµµ°¸ÖеÄ×îºóÒ»ÐÐÓ¦¸ÃÒªÓÐÒ»¸ö Newline À´×÷Ϊ½áÊø£¨µ«ÊÇ Emacs ²¢²»Ò» | 82 | Ò»ÐÐÒ²Ó¦¸ÃÒ²ÓÐÒ»¸ö»»Ðзû£¨²»¹ý Emacs ²¢²»Ç¿ÖÆÒªÇóÕâÒ»µã£©¡£ |
| 87 | ¶¨ÐèÒªËüÀ´±à¼µµ°¸£©¡£ | ||
| 88 | 83 | ||
| 89 | >> ÊÔÖøÔÚÒ»ÐпªÊ¼µÄµØ·½¼üÈë C-b ¡£½á¹ûÓ¦¸Ã»áÒÆ¶¯µ½Ç°Ò»ÐеÄ×îºóÃæ¡£ | 84 | >> ÔÚÒ»ÐеÄÐÐÍ·ÊäÈë C-b¡£ |
| 90 | ÕâÊÇÒòΪËüÍùºóÒÆ¶¯Ê±Ô½¹ýÁË Newline ×ÖÔª¡£ | 85 | ¹â±êÓ¦¸Ã»áÒÆ¶¯µ½Ç°Ò»ÐеÄÐÐ⣬ÒòΪ¹â±êÔÚ»ØÍ˹ý³ÌÖÐÔ½¹ýÁË»»Ðзû¡£ |
| 91 | 86 | ||
| 92 | C-f Ò²¿ÉÒÔºÍ C-b Ò»ÑùµØÔ½¹ý Newline ×ÖÔª¡£¡¾Newline ×ÖÔªÊÇ¡¸²»¿É¼û | 87 | ͬÑù C-f Ò²¿ÉÒÔÏñ C-b Ò»ÑùÔ½¹ý»»Ðзû¡£ |
| 93 | £¨ invisible £©×ÖÔª¡¹£¬ÔÚ±à¼Æ÷ÖÐÒ»°ã¿´²»µ½Ëü£¬ÕâÀïÖ»ÊǸæËßÄú£ºÔÚÐÐÊ× | ||
| 94 | ÔÙÍùǰ×ߣ¬ÄÇôÓαê»áÅܵ½Ç°Ò»ÐУ¨Èç¹ûÓÐǰһÐеϰ£©£»ÔÚÐÐβÔÙÍùºó×ߣ¬ÄÇ | ||
| 95 | ôÓαê»áÅܵ½ºóÒ»ÐУ¨Èç¹ûÓкóÒ»Ðеϰ£©¡£¡¸Ô½¹ý Newline ×ÖÔª¡¹»áÈÃÓαê | ||
| 96 | Åܵ½ÁíÍâÒ»ÐС£¡¿ | ||
| 97 | 88 | ||
| 98 | >> ¶à°´¼¸´Î C-b£¬×Ô¼º¸Ð¾õÒ»ÏÂÓαêÔÚÄÄ¡£ | 89 | >> Á¬°´¼¸´Î C-b£¬¸ÐÊÜһϹâ±êµÄÒÆ¶¯¡£ |
| 99 | È»ºó°´¼¸´Î C-f »Øµ½ÕâÐеÄβ°Í¡£ | 90 | È»ºó°´¼¸´Î C-f »Øµ½±¾ÐеÄÐÐβ¡£ |
| 100 | ÔÙ°´Ò»´Î C-f ¾Í¿ÉÒÔÒÆµ½ÏÂÒ»ÐÐÁË¡£ | 91 | ÔÙ°´Ò»´Î C-f£¬¹â±ê»áÒÆ¶¯µ½ÏÂÒ»ÐС£ |
| 101 | 92 | ||
| 102 | µ±ÄúÒÆ¶¯Óα괩ԽөϵÄÉÏ·½»òÏ·½Ê±£¬Ôڱ߽çÍâµÄÎÄ×Ö»áÒÆÎ»½øÈëÓ©Ä»ÄÚ¡£Õâ | 93 | µ±ÄãÒÆ¶¯¹â±ê´©Ô½ÆÁÄ»µÄÉÏϱ߽çʱ£¬Ôڱ߽çÍâµÄÎÄ×Ö»áÒÆ¶¯µ½ÆÁÄ»ÄÚ£¬Õâ³ÆÎª |
| 103 | ³ÆÎª¡¸¾í¶¯¡¹¡£ËüÈà Emacs ¿ÉÒÔ½«ÓαêÒÆ¶¯µ½ÎÄ×ÖÖеÄÈÎÒâÌØ¶¨Î»Öã¬Í¬Ê± | 94 | ¡°¹ö¶¯¡±£¨scrolling£©¡£¹ö¶¯Ê¹µÃ¹â±ê¿ÉÒÔ±»Òƶ¯µ½ÎÄ×ÖÖеÄÈκÎλÖ㬲¢ÇÒ»¹ |
| 104 | £¨Óα꣩²»»áÅܳöÓ©Ä»Íâ¡£ | 95 | ²»»áÈùâ±êÅܵ½ÆÁÄ»Íâ±ßÈ¥¡£ |
| 105 | 96 | ||
| 106 | >> ÊÔÖøÒÔ C-n ½«ÓαêÔ½¹ýөĻϷ½£¬È»ºó¿´¿´·¢ÉúÁËʲôÊ¡£ | 97 | >> Óà C-n ½«¹â±êÏÂÒÆ£¬Ò»Ö±Ô½¹ýÆÁÄ»±ß½ç£¬Í¬Ê±¹Û²ì·¢ÉúÁËʲô±ä»¯¡£ |
| 107 | 98 | ||
| 108 | Èç¹ûÒ»¸ö×ÖÔªÒ»¸ö×ÖÔªµØÒƶ¯Ì«ÂýµÄ»°£¬Äú¿ÉÒÔÒ»¸ö×ÖÒ»¸ö×ÖµØÒƶ¯¡£M-f | 99 | Èç¹ûÄãÏÓÒ»¸ö×Ö·ûÒ»¸ö×Ö·ûµØÅ²¹â±êÌ«Âý£¬Ä㻹¿ÉÒÔÒ»¸ö´ÊÒ»¸ö´ÊµØÌø¡£M-f |
| 109 | (META-f) ÍùÇ°ÒÆ¶¯Ò»¸ö×Ö£¬M-b ÔòÍùºóÒÆ¶¯Ò»¸ö×Ö¡£¡¾¶ÔÖÐÎÄÀ´Ëµ£¬ÔòÊÇÒÆ¶¯ | 100 | (META-f) ¿ÉÒÔ½«¹â±êÍùÇ°ÒÆ¶¯Ò»¸ö´Ê£¬¶ø M-b ÔòÊÇÍùºóÒÆ¡£¡¾ÕâÀïµÄ¡°´Ê¡±Ö¸ |
| 110 | µ½ÏÂÒ»¸ö»òÏÂÒ»¸ö±êµã·ûºÅµÄËùÔÚ¡£¡¿ | 101 | Ó¢Îĵ¥´Ê£¬¶ÔÖÐÎÄÀ´Ëµ£¬ÔòÊÇÖ¸ÒÆ¶¯µ½ÏÂÒ»¸ö±êµã·ûºÅ¡£¡¿ |
| 111 | 102 | ||
| 112 | >> ¼üÈëһЩ M-f ºÍ M-b¡£ | 103 | >> ÊÔÊÔ M-f ºÍ M-b¡£ |
| 113 | 104 | ||
| 114 | µ±ÄúÔÚÒ»¸ö×ÖµÄÖмäʱ£¬M-f »áÒÆ¶¯µ½Õâ¸ö×ÖµÄβ°Í¡£µ±ÄúÔÚ×ÖÓë×Ö¼äµÄ¿Õ°×ʱ£¬ | 105 | Èç¹û¹â±êÍ£ÔÚÒ»¸ö´ÊµÄÖм䣬M-f »áÒÆ¶¯µ½Õâ¸ö´ÊµÄĩβ¡£Èç¹û¹â±ê´¦ÓÚ´ÊÓë´Ê |
| 115 | M-f »áÒÆ¶¯µ½ÏÂÒ»¸ö×ÖµÄβ°Í¡£M-b µÄЧ¹ûÏàËÆ£¬Ö»ÊÇ·½Ïò²»Í¬¡£ | 106 | Ö®¼äµÄ¿Õ°×´¦£¬M-f »áÒÆ¶¯µ½ÏÂÒ»¸ö´ÊµÄĩβ¡£M-b µÄ¹¦ÄÜÀàËÆ£¬Ö»ÊÇ·½ÏòÏà·´¡£ |
| 116 | 107 | ||
| 117 | >> °´¼¸´Î M-f ºÍ M-b£¬Öмä¼ÐÔÓһЩ C-f ºÍ C-b£¬ | 108 | >> °´¼¸´Î M-f ºÍ M-b£¬Öмä¼ÐÔÓһЩ C-f ºÍ C-b¡£ |
| 118 | ÕâÑù×ÓÄú¾Í¿ÉÒÔ¹Û²ì M-f ºÍ M-b ÔÚ¸÷ÖÖ¡¸Î»ÔÚ×Ö¼ä»ò×ÖÔª¼ä¡¹ | 109 | Äã¿ÉÒԹ۲쵽 M-f ºÍ M-b ÔÚ²»Í¬Î»ÖÃÉÏËù±íÏÖ³öÀ´µÄ²»Í¬ÐÐΪ¡£ |
| 119 | µÄ²»Í¬Î»Öã¬Ëù±íÏÖ³öÀ´µÄÐÐΪ¡£ | ||
| 120 | 110 | ||
| 121 | Çë×¢Òâ C-f ¡¢ C-b ºÍ M-f ¡¢ M-b Á½¶ÔÖ®¼äµÄÏàËÆÐÔ¡£¡¸¾³£¡¹µÄ×´¿öÊÇ£º | 111 | Çë×¢Òâ C-f ¡¢C-b ºÍ M-f ¡¢M-b Á½¶ÔÖ®¼äµÄÀà±È¹ØÏµ¡£Í¨³£µÄ¹ßÀýÊÇ£ºMETA ϵ |
| 122 | META ×ÖÔªÊÇÓÃÀ´×÷ΪÓ롸ÒÔÓïÑÔ¶¨Òå³öµÄµ¥Î»£¨×Ö¡¢¾ä×Ó¡¢¶ÎÂ䣩¡¹ÓйصIJ٠| 112 | ÁÐ×éºÏ¼üÓÃÀ´²Ù×÷¡°ÓÉÓïÑÔ¶¨ÒåµÄµ¥Î»£¨±ÈÈç´Ê¡¢¾ä×Ó¡¢¶ÎÂ䣩¡±£¬¶ø CONTROL |
| 123 | ×÷£¬¶ø CONTROL ×ÖÔªÔòÊÇ×÷ÓÃÔÚ¡¸ÓëÄúËù±à¼Î޹صġº»ù±¾¡»µ¥Î»£¨×ÖÔª»òÐÐ | 113 | ϵÁÐ×éºÏ¼üÓÃÀ´²Ù×÷¡°ÓëÓïÑÔÎ޹صĻù±¾µ¥Î»£¨±ÈÈç×Ö·û¡¢Ðеȵȣ©¡±¡£ |
| 124 | µÈ£©¡¹ÉÏ¡£ | ||
| 125 | 114 | ||
| 126 | Õâ¸öÏàËÆÐÔÔÚ¡¸ÐÐÓë¾ä×Ó¡¹Ö®¼äҲͬÑùÊÊÓãºC-a ºÍ C-e »á½«ÓαêÒÆ¶¯µ½¡¸Ò» | 115 | ÀàËÆµÄ¹ßÀýÔÚ¡°ÐС±Óë¡°¾ä×Ó¡±Ö®¼äҲͬÑùÊÊÓãºC-a ºÍ C-e ¿ÉÒÔ½«¹â±êÒÆ¶¯µ½ |
| 127 | ÐС¹µÄ ¿ªÊ¼ºÍ½áβ´¦£¬¶øM-a ºÍ M-e Ôò½«ÓαêÒÆ¶¯µ½¡¸Ò»¾ä¡¹µÄ ¿ªÊ¼ºÍ½áβ | 116 | ¡°Ò»ÐС±µÄÍ·²¿ºÍβ²¿£»¶ø M-a ºÍ M-e Ôò½«¹â±êÒÆ¶¯µ½¡°Ò»¾ä¡±µÄÍ·²¿ºÍβ²¿¡£ |
| 128 | ´¦¡£ | ||
| 129 | 117 | ||
| 130 | >> ÊÔÖø°´Á½´Î C-a£¬ÔÙ°´Á½´Î C-e¡£ | 118 | >> °´Á½´Î C-a£¬ÔÙ°´Á½´Î C-e¡£ |
| 131 | ÊÔÖø°´Á½´Î M-a£¬ÔÙ°´Á½´Î M-e¡£ | 119 | °´Á½´Î M-a£¬ÔÙ°´Á½´Î M-e¡£ |
| 132 | 120 | ||
| 133 | ¿´Ò»ÏÂÎªÊ²Ã´ÖØ¸´µÄ C-a Ö¸Áî»áûÓÐ×÷Ó㬶øÖظ´µÄ M-a Ö¸ÁîÔò¼ÌÐøÒÆ¶¯µ½Ï | 121 | ÏëÒ»ÏëÎªÊ²Ã´ÖØ¸´µÄ C-a ÃüÁî»áûÓÐ×÷Ó㬶øÖظ´µÄ M-a ÃüÁîÔò»áÈùâ±ê²»¶Ï |
| 134 | Ò»¸ö¾ä×Ó¡£ËäÈ»Õâ²¢²»ÄÜ˵ÊÇÍêÈ«Àà±È£¬µ«ÊÇÆäÖÐÿ¸öÖ¸ÁîµÄÐÐΪ¿´ÆðÀ´¶¼Ê®·Ö | 122 | µØ»ØÍ˵½ÉÏÒ»¸ö¾ä×Ó¡£ËäÈ»Õâ¸öÀà±È¹æÂɲ¢²»Ñϸñ£¬µ«ÊǺÜ×ÔÈ»¡£ |
| 135 | ×ÔÈ»¡£ | ||
| 136 | 123 | ||
| 137 | ÓαêÔÚÎÄ×ÖÖеÄλÖÃÒ²¿ÉÒÔ³Æ×÷¡¸µã루 point £©¡¹¡£¼òµ¥À´Ëµ¾ÍÊÇ£ºÓαê±í | 124 | ¹â±êÍ£ÁôµÄλÖÃÒ²¿ÉÒÔ³Æ×÷¡°µãλ¡±£¨point£©¡£»òÕ߸ɴà˵£¬¹â±êָʾ³öÁËÆÁÄ» |
| 138 | ÏÖ³öÓ©Ä»ÖС¸µãλ¡¹ËùÔÚµÄÎÄ×ÖλÖᣠ| 125 | ÉÏ¡°µãλ¡±ÔÚÎı¾ÖеÄλÖᣠ|
| 139 | 126 | ||
| 140 | ÕâÀïÊÇһЩ¼òµ¥¡¸ÓαêÒÆ¶¯£¨ cursor-moving £©²Ù×÷¡¹µÄÕûÀí£¬ÆäÖÐÒ²°üÀ¨ÁË | 127 | ÕâÀï¶Ô¼òµ¥µÄ¹â±êÒÆ¶¯ÃüÁî×öÒ»¸ö×ܽᣬÆäÖÐÒ²°üÀ¨ÁËÕû´ÊºÍÕû¾äµÄÒÆ¶¯£º |
| 141 | ¡¸×ֺ;䡹µÄÒÆ¶¯Ö¸Á | ||
| 142 | 128 | ||
| 143 | C-f ÍùÇ°ÒÆ¶¯Ò»¸ö×ÖÔª | 129 | C-f ÏòÓÒÒÆ¶¯Ò»¸ö×Ö·û |
| 144 | C-b Íù»ØÒƶ¯Ò»¸ö×ÖÔª | 130 | C-b Ïò×óÒÆ¶¯Ò»¸ö×Ö·û |
| 145 | 131 | ||
| 146 | M-f ÍùÇ°ÒÆ¶¯Ò»¸ö×Ö¡¾ÖÐÎÄÊÇÒÆ¶¯µ½ÏÂÒ»¸ö±êµã·ûºÅ¡¿ | 132 | M-f ÏòÓÒÒÆ¶¯Ò»¸ö´Ê¡¾ÖÐÎÄÊÇÒÆ¶¯µ½ÏÂÒ»¸ö±êµã·ûºÅ¡¿ |
| 147 | M-b Íù»ØÒƶ¯Ò»¸ö×Ö¡¾ÖÐÎÄÊÇÒÆ¶¯µ½ÉÏÒ»¸ö±êµã·ûºÅ¡¿ | 133 | M-b Ïò×óÒÆ¶¯Ò»¸ö´Ê¡¾ÖÐÎÄÊÇÒÆ¶¯µ½ÉÏÒ»¸ö±êµã·ûºÅ¡¿ |
| 148 | 134 | ||
| 149 | C-n ÒÆ¶¯µ½ÏÂÒ»ÐÐ | 135 | C-n ÒÆ¶¯µ½ÏÂÒ»ÐÐ |
| 150 | C-p ÒÆ¶¯µ½ÉÏÒ»ÐÐ | 136 | C-p ÒÆ¶¯µ½ÉÏÒ»ÐÐ |
| @@ -152,906 +138,852 @@ META ×ÖÔªÊÇÓÃÀ´×÷ΪÓ롸ÒÔÓïÑÔ¶¨Òå³öµÄµ¥Î»£¨×Ö¡¢¾ä×Ó¡¢¶ÎÂ䣩¡¹ÓйصIJ٠| |||
| 152 | C-a ÒÆ¶¯µ½ÐÐÊ× | 138 | C-a ÒÆ¶¯µ½ÐÐÊ× |
| 153 | C-e ÒÆ¶¯µ½ÐÐβ | 139 | C-e ÒÆ¶¯µ½ÐÐβ |
| 154 | 140 | ||
| 155 | M-a ÒÆ»Ø¾äÊ× | 141 | M-a ÒÆ¶¯µ½¾äÊ× |
| 156 | M-e ÒÆµ½¾äβ | 142 | M-e ÒÆ¶¯µ½¾äβ |
| 157 | 143 | ||
| 158 | >> Á·Ï°¼¸´ÎÕâЩָÁî¡£ÕâЩ¶¼ÊÇ×ʹÓõ½µÄÖ¸Áî¡£ | 144 | >> °ÑÉÏÃæËùÓеÄÃüÁî¶¼Á·Ï°¼¸´Î£¬ÕâЩ¿É¶¼ÊÇ×î³£ÓõÄÃüÁî¡£ |
| 159 | 145 | ||
| 160 | »¹ÓÐÁ½¸öÖØÒªµÄÓα궯×÷£¨ cursor-motion £©Ö¸ÁM-<£¨ META Less-than £©£¬ | 146 | ÕâÀﻹҪ½éÉÜÁ½¸öÖØÒªµÄ¹â±êÒÆ¶¯ÃüÁM-< £¨META СÓںţ©¿ÉÒÔ½«¹â±êÒÆ¶¯µ½ |
| 161 | ÒÆ¶¯µ½ÎÄ×ÖµÄ×ʼ£¬ÒÔ¼°M->£¨ META Greater-than £©£¬Òƶ¯µ½ÎÄ×ÖµÄ×îºó¡£ | 147 | ËùÓÐÎÄ×ÖµÄ×ͷ£»M-> £¨META ´óÓںţ©¿ÉÒÔ½«¹â±êÒÆ¶¯µ½ËùÓÐÎÄ×ÖµÄ×îĩβ¡£ |
| 162 | 148 | ||
| 163 | Ôڴ󲿷ݵÄÖÕ¶Ë»ú£¬¡¸<¡¹ÊÇÔÚ comma ÉÏ·½£¬ËùÒÔÄú±ØÐëҪʹÓà shift ¼üÀ´¼ü | 149 | ×¢Ò⣬Ôڴ󲿷ּüÅÌÉÏ£¬Ð¡Óںţ¨<£©ÐèÒªÓÃÉϵµ¼ü£¨Shift£©À´ÊäÈ룬ËùÒÔÔÚÕâ |
| 164 | Èë¡£ÔÚÕâЩÖÕ¶Ë»úÉÏ£¬Äú±ØÐëʹÓà shift ¼üÀ´¼üÈë M-<£»Ã»ÓÐʹÓà shift ¼ü£¬ | 150 | Щ¼üÅÌÉÏÄãÓ¦¸ÃÓà Shift ¼üÀ´ÊäÈë M-<£¬Èç¹û²»°´ Shift ¼ü£¬ÄãÊäÈëµÄ»áÊÇ |
| 165 | Äú¾Í±ä³É¼üÈë M-comma ÁË¡£ | 151 | M-comma£¨META ¶ººÅ£©¡£ |
| 166 | 152 | ||
| 167 | >> ÏÖÔÚÊÔһϠM-< £¬ÒƵ½±¾¿ìËÙÖ¸ÄϵÄ×ʼ¡£ | 153 | >> ÊÔÒ»ÊÔ M-< £¬ÒƵ½±¾¿ìËÙÖ¸ÄϵÄ×ʼ¡£ |
| 168 | È»ºóÔÙÖØ¸´µØÊ¹Óà C-v »Øµ½ÕâÀï¡£ | 154 | È»ºóÔÙ°´¼¸´Î C-v »Øµ½ÕâÀï¡£ |
| 169 | 155 | ||
| 170 | >> ÏÖÔÚÊÔһϠM-> £¬ÒƵ½±¾¿ìËÙÖ¸ÄϵÄ×îºó¡£ | 156 | >> ÊÔÒ»ÊÔ M-> £¬ÒƵ½±¾¿ìËÙÖ¸ÄϵÄ×îĩβ¡£ |
| 171 | È»ºóÔÙÖØ¸´µØÊ¹Óà M-v »Øµ½ÕâÀï¡£ | 157 | È»ºóÔÙ°´¼¸´Î M-v »Øµ½ÕâÀï¡£ |
| 172 | 158 | ||
| 173 | Èç¹ûÄúµÄÖÕ¶Ë»úÓз½Ïò¼üµÄ»°£¬ÄúÒ²¿ÉÒÔÓ÷½Ïò¼üÒÆ¶¯ÓαꡣÎÒÃÇÓÐÈý¸öÀíÓɽ¨ | 159 | Èç¹ûÄãµÄ¼üÅÌÉÏÓз½Ïò¼üµÄ»°£¬Ò²¿ÉÒÔÓÃËüÃÇÀ´Òƶ¯¹â±ê¡£²»¹ýÎÒÃÇÓÐÈý¸öÀíÓÉ |
| 174 | ÒéÄúѧϰ C-b ¡¢ C-f ¡¢ C-n ¡¢ ºÍ C-p £º(1) ÈκεÄÖÕ¶Ë»ú¶¼ÄÜʹÓá£(2) | 160 | ÍÆ¼öÄãѧϰ C-b ¡¢C-f ¡¢C-n ¡¢ºÍ C-p£º£¨1£©ËüÃÇÔÚÈκμüÅÌÉ϶¼ÄÜÓᣣ¨2£© |
| 175 | Ò»µ©ÄúʹÓà Emacs Ï൱ÊìÁ·ÁË£¬Äú»á·¢ÏÖ¼üÈëÕâЩ CONTROL ×ÖÔª£¬±ÈÆðʹÓ÷½ | 161 | µ±ÄãÊìÁ·Ê¹Óà Emacs Ö®ºó£¬Äã»á·¢ÏÖÓÃÕâЩ×éºÏ¼ü±ÈÓ÷½Ïò¼üÒª¿ìµÃ¶à£¬ÒòΪÄã |
| 176 | Ïò¼ü¿ì¶àÁË£¨ÒòΪÄú²»ÐèÒª½«ÊÖÒÆ¿ª´ò×ÖÇø£©¡£(3) Ò»µ©ÄúʹÓÃÕâЩ CONTROL | 162 | µÄÊÖ²»ÐèÒªÀ뿪´ò×ÖÇø¡££¨3£©Ò»µ©Äãϰ¹ßÁËʹÓÃÕâЩ×éºÏ¼ü£¬ÄãÒ²¿ÉÒÔºÜÈÝÒ×µØ |
| 177 | ×ÖÔªÖ¸Áî³ÉΪϰ¹ß£¬ÄúÒ²¿ÉÒÔºÜÈÝÒ×µØÑ§»áÆäËû½ø½×µÄÓα궯×÷Ö¸Áî¡£ | 163 | ÊÊÓ¦ÆäËü¸ü¸ß¼¶µÄ¹â±êÒÆ¶¯ÃüÁî¡£ |
| 178 | 164 | ||
| 179 | ´ó²¿·ÝµÄ Emacs Ö¸Áî½ÓÊÜÊý×Ö²ÎÊý£»¶Ô´ó²¿·ÝµÄÖ¸Áî¶øÑÔ£¬ËüµÄ×÷ÓÃÊÇÖ¸¶¨ÖØ | 165 | ´ó²¿·ÖµÄ Emacs ÃüÁî½ÓÊÜÊý×Ö²ÎÊý£¬²¢ÇÒ¶ÔÓÚ¶àÊýÃüÁî¶øÑÔ£¬ÕâЩÊý×Ö²ÎÊýµÄ×÷ |
| 180 | ¸´´ÎÊý¡£ÄúÒªÖ¸¶¨Ò»¸öÖ¸ÁîµÄÖØ¸´´ÎÊýµÄ×÷·¨ÊÇ£ºÏȼüÈë C-u£¬È»ºóÔÚÄú¼üÈëÖ¸ | 166 | ÓÃÊÇÖ¸¶¨ÃüÁîµÄÖØ¸´´ÎÊý¡£ÎªÒ»¸öÃüÁîÖ¸¶¨Êý×Ö²ÎÊý£¨Ò²¾ÍÊÇÖØ¸´´ÎÊý£©µÄ·½·¨ |
| 181 | Áîǰ£¬¼üÈë´ú±íÖØ¸´´ÎÊýµÄÊýλ¡£Èç¹ûÄúÓÐÒ»¸ö META£¨»ò EDIT »ò ALT £©¼ü£¬ | 167 | ÊÇ£ºÏÈÊäÈë C-u£¬È»ºóÊäÈëÊý×Ö×÷Ϊ²ÎÊý£¬×îºóÔÙÊäÈëÃüÁî¡£Èç¹ûÄãÓÐMETA £¨»ò |
| 182 | ÄÇôÄú»¹ÓÐÁíÍâÒ»¸öÌæ´ú×÷·¨À´ÊäÈëÊý×Ö²ÎÊý£º°´×¡ META ¼üʱ´òÈëÕâÊý×Ö¡£ÎÒ | 168 | EDIT »ò ALT£©¼ü£¬ÄÇô»¹ÓÐÁíÒ»ÖÖ°ì·¨£º°´×¡ META ¼ü²»¶¯£¬È»ºóÊäÈëÊý×Ö¡£²» |
| 183 | Ãǽ¨ÒéÄúѧϰ C-u µÄ·½·¨£¬ÒòΪËüÔÚÈκÎÖÕ¶Ë»ú¶¼¿ÉÒÔʹÓᣴËÒ»Êý×Ö²ÎÊýÒ² | 169 | ¹ýÎÒÃÇ»¹Êǽ¨ÒéÄãÓà C-u£¬ÒòΪËüÔÚÈκÎÖÕ¶Ë»úÉ϶¼ÄÜÓá£ÕâÖÖÊý×Ö²ÎÊýÒ²³ÆÎª |
| 184 | ³Æ×÷Ϊ¡¸×ÖÊײÎÊý¡¹£¬ÒòΪÄúÔÚÕâ²ÎÊýËù×÷Óõ½µÄÖ¸Áîǰ¼üÈëËü¡£ | 170 | ¡°Ç°×º²ÎÊý¡±£¬Òâ˼ÊÇ˵Õâ¸ö²ÎÊýÊÇÏÈÓÚʹÓÃËüµÄÃüÁî¶øÊäÈëµÄ¡£ |
| 185 | 171 | ||
| 186 | ¾ÙÀýÀ´Ëµ£¬ C-u 8 C-f ÏòÇ°ÒÆ¶¯ 8 ¸ö×ÖÔª¡£ | 172 | ¾ÙÀýÀ´Ëµ£¬ C-u 8 C-f »áÏòÇ°ÒÆ¶¯ 8 ¸ö×Ö·û¡£ |
| 187 | 173 | ||
| 188 | >> ÊÔÖøÒÔÒ»¸öÊý×Ö²ÎÊýÀ´Ê¹Óà C-n »ò C-p£¬ | 174 | >> Ϊ C-n »òÕß C-p Ö¸¶¨Ò»¸öÊý×Ö²ÎÊý£¬ÕâÑùÄã¿ÉÒÔÖ»ÓÃÒ»¸öÃüÁî¾Í°Ñ¹â±êÒÆ¶¯ |
| 189 | Ö»Ò»¸öÖ¸Áî¾Í½«ÓαêÒÆ¶¯µ½ÕâÐеĸ½½ü¡£ | 175 | µ½±¾Ðеĸ½½ü¡£ |
| 190 | 176 | ||
| 191 | ´ó²¿·ÝµÄÖ¸ÁîʹÓÃÊý×Ö²ÎÊýÀ´×÷ΪÆäÖØ¸´´ÎÊý£¬µ«ÊÇÆäÖÐÓÐЩָÁîÔòÊÇ×÷ΪÆäËû | 177 | ËäÈ»´ó²¿·ÖÃüÁîÓÃÊý×Ö²ÎÊýÀ´×÷ΪÆäÖØ¸´´ÎÊý£¬µ«ÊÇÒ²ÓÐЩÃüÁîÀýÍ⣬ËüÃǽ«Êý |
| 192 | ÓÃ;¡£Óм¸¸öÖ¸ÁĿǰÄúÉÐδѧµ½£©½«Ëü×÷ΪÆì±ê -- ÒÔÒ»¸ö×ÖÊײÎÊýµÄÐÍ̬ | 178 | ×Ö²ÎÊýÁí×öËüÓᣱÈÈçÓÐЩÃüÁĿǰ»¹Ã»Ñ§µ½£©½ö½ö½«Ç°×º²ÎÊý×÷Ϊһ¸ö±ê |
| 193 | ³öÏÖ£¬¶ø²»¹ÜÆäֵΪºÎ£¬ËüÃÇÈÃÕâÖ¸Áî×öЩ²»Ò»ÑùµÄÊ¡£ | 179 | Ö¾¡ª¡ªÖ»ÒªÓÐÒ»¸öǰ׺²ÎÊý³öÏÖ£¬²»¹ÜÆäֵΪºÎ£¬ÃüÁîµÄ¹¦Äܶ¼»á¸Ä±ä¡£ |
| 194 | 180 | ||
| 195 | C-v ºÍ M-v ÔòÊÇÁíÒ»ÀàµÄÀýÍâ¡£µ±¸ø¶¨Ò»¸ö²ÎÊýʱ£¬ËüÃÇ¾í¶¯¡¸ËùÖ¸¶¨µÄÊýÁ¿ | 181 | ¶ø C-v ºÍ M-v ÔòÊôÓÚÁíÒ»ÖÖÀàÐ͵ÄÀýÍâ¡£µ±¸ø¶¨Ò»¸ö²ÎÊýʱ£¬ËüÃǽ«¹ö¶¯ÄãÖ¸ |
| 196 | µÄÐУ¨ÒÔÐÐΪµ¥Î»£©¡¹£¬¶ø²»ÊÇÒÔ¡¸Ó©Ä»¡¹Îªµ¥Î»¾í¶¯¡£¾ÙÀýÀ´Ëµ£¬C-u 8 C-v | 182 | ¶¨µÄ¡°ÐÐÊý¡±£¬¶ø²»ÊÇ¡°ÆÁÊý¡±¡£¾ÙÀýÀ´Ëµ£¬C-u 8 C-v ½«ÆÁÄ»ÏòϹö¶¯ 8 ÐУ¬ |
| 197 | ½«ÏÔʾөĻ¾í¶¯ 8 ÐС£ | 183 | ¶ø²»ÊÇ 8 ÆÁ¡£ |
| 198 | 184 | ||
| 199 | >> ÏÖÔÚÊÔÖø¼üÈë C-u 8 C-v¡£ | 185 | >> ÏÖÔÚÊÔÊÔ¿´£¬ÊäÈë C-u 8 C-v¡£ |
| 200 | 186 | ||
| 201 | ÕâÖ¸ÁîÓ¦¸ÃÒѾ½«Ó©Ä»ÏòÉÏÒÆÁË 8 ÐС£ÈôÄúÏ뽫ËüÔٴεØÏòÏÂ¾í¶¯£¬Äú¿ÉÒÔÔÚ | 187 | Õâ¸öÃüÁîÓ¦¸ÃÒѾ½«ÎÄ×ÖÏòÉϹö¶¯ÁË 8 ÐС£Èç¹ûÄãÏ뽫ËüÔٴεØÏòϹö¶¯£¬Äã¿É |
| 202 | Ö´ÐÐ M-v ʱ¸ø¶¨Ò»¸ö²ÎÊý¡£ | 188 | ÒÔ¸ø¶¨Ò»¸ö²ÎÊýÈ»ºóÖ´ÐÐ M-v¡£ |
| 203 | 189 | ||
| 204 | Èç¹ûÄúÕýÔÚʹÓà X ´°¿Úϵͳ£¬ÔÚ Emacs ´°¿Ú×óÊÖ²àÓ¦¸ÃÓÐÒ»¸ö³ÆÎª¡¸¾í¶¯Ö᡹ | 190 | Èç¹ûÄãÕýÔÚʹÓÃÒ»¸ö´°¿Úϵͳ£¬±ÈÈç X11 »òÕß΢ÈíµÄ Windows£¬ÄÇôÔÚ Emacs |
| 205 | µÄ³¤·½ÐÍÇøÓò¡£Äú¿ÉÒÔÓû¬ÊóÔÚ¾í¶¯Öá°´Ò»ÏÂÀ´¾í¶¯ÎÄ×Ö¡£ | 191 | ´°¿ÚµÄ×ó±ß»òÕßÓÒ±ßÓ¦¸ÃÓÐÒ»¸ö³¤·½ÐεÄÇøÓò½Ð¡°¹ö¶¯Ìõ¡±£¬Äã¿ÉÒÔÓÃÊó±ê²Ù×Ý |
| 192 | ¹ö¶¯ÌõÀ´¹ö¶¯ÎÄ×Ö¡£ | ||
| 206 | 193 | ||
| 207 | >> ÊÔÖøÔÚ¡¸¾í¶¯ÖáÄÚ·´°×ÇøÓòÉÏ¡¹Ñ¹Ò»ÏÂÖмäÅ¥¡£ÕâÓ¦¸Ã»á½«ÎÄ×Ö¾í¶¯µ½ | 194 | >> ÊÔ×ÅÔÚ¡°¹ö¶¯ÌõÄڵķ´°×ÇøÓò¡±Éϰ´Ò»ÏÂÊó±êÖмü¡£ |
| 208 | ¡¸ÓÉÄúËù°´Ò»Ï»¬ÊóµÄµØ·½¡¹Ëù¾ö¶¨µÄλÖᣠ| 195 | ÎÄ×ÖÓ¦¸Ã»á¹ö¶¯µ½Êó±êËùָʾµÄλÖᣠ|
| 209 | 196 | ||
| 210 | >> µ±°´×¡Öмäʱ£¬ÊÔÖø½«»¬ÊóÉÏÏÂÒÆ¶¯¡£ | 197 | >> µ±°´×¡Öмüʱ£¬ÊÔ׎«Êó±êÉÏÏÂÒÆ¶¯¡£ |
| 211 | Äú»á¿´µ½ÎÄ×ÖËæÖøÄúÒÆ¶¯»¬Êó¶øÉÏÏÂÒÆ¶¯¡£ | 198 | Äã»á¿´µ½ÎÄ×ÖËæ×ÅÊó±êµÄÒÆ¶¯¶øÉÏϹö¶¯¡£ |
| 199 | ¡¾Windows °æ±¾·ûºÏ Windows ³ÌÐòµÄ´«Í³²Ù×÷ϰ¹ß£¬ÉÏÊö²Ù×÷²»ÊÊÓᣡ¿ | ||
| 212 | 200 | ||
| 213 | 201 | ||
| 214 | * µ± EMACS ·¢´ôʱ£¨ WHEN EMACS IS HUNG £© | 202 | * ÔÚ EMACS ʧȥÏìÓ¦µÄʱºò£¨WHEN EMACS IS HUNG£© |
| 215 | ----------------------------------------- | 203 | ----------------------------------------------- |
| 216 | 204 | ||
| 217 | Èç¹û Emacs Í£Ö¹»ØÓ¦ÄúµÄÖ¸ÁÄú¿ÉÒÔ¼üÈë C-g À´°²È«µØÍ£Ö¹Ëü¡£ÄúÒ²¿ÉÒÔʹ | 205 | Èç¹û Emacs ¶ÔÄãµÄÃüÁîʧȥÏìÓ¦£¬Äã¿ÉÒԺܰ²È«µØÓà C-g À´ÖÕÖ¹Õâ¸öÃüÁî¡£ |
| 218 | Óà C-g À´Í£Ö¹Ö´Ðйý¾ÃµÄÖ¸Áî¡£ | 206 | C-g Ò²¿ÉÒÔ±»ÓÃÀ´ÖÕÖ¹Ò»¸öÖ´Ðйý¾ÃµÄÃüÁî¡£ |
| 219 | 207 | ||
| 220 | ÄúÒ²¿ÉÒÔʹÓà C-g À´È¡ÏûÊý×Ö²ÎÊý»òÄú²»ÏëÒªÍê³ÉµÄÖ¸Áî¡£ | 208 | C-g »¹¿ÉÒÔ±»À´È¡ÏûÊý×Ö²ÎÊýºÍÄÇЩÊäÈëµ½Ò»°ëµÄÃüÁî¡£ |
| 221 | 209 | ||
| 222 | >> ¼üÈë C-u 100 ÒÔÉ趨һ¸ö 100 µÄÊý×Ö²ÎÊý£¬È»ºó¼üÈë C-g¡£ | 210 | >> ÊäÈë C-u 100 É趨һ¸öֵΪ 100 µÄÊý×Ö²ÎÊý£¬È»ºó°´ C-g¡£ |
| 223 | ÏÖÔÚ¼üÈë C-f¡£ËüÓ¦¸ÃÖ»»áÒÆ¶¯Ò»¸ö×ÖÔª£¬ÒòΪÄúÒѾÒÔ C-g | 211 | ÏÖÔÚÔÙ°´ C-f£¬¹â±êÓ¦¸ÃÖ»»áÒÆ¶¯Ò»¸ö×Ö·û£¬ÒòΪÄãÒѾÓà C-g È¡ÏûÁ˲ÎÊý¡£ |
| 224 | È¡ÏûÁ˲ÎÊý¡£ | ||
| 225 | 212 | ||
| 226 | Èç¹ûÄúÒѾ²»Ð¡ÐĵؼüÈëÒ»¸ö <ESC>£¬Äú¿ÉÒÔ C-g À´È¡ÏûËü¡£ | 213 | Èç¹ûÄ㲻СÐİ´ÁËһϠ<ESC>£¬ÄãÒ²¿ÉÒÔÓà C-g À´È¡ÏûËü¡£ |
| 214 | ¡¾Õâ¸ö˵·¨ËƺõÓÐÎÊÌ⣬ÒòΪ°´ÕÕÕâ¸ö°´¼ü˳ÐòÊäÈëµÄÓ¦¸ÃÊÇ C-M-g¡£ | ||
| 215 | È¡Ïû<ESC> µÄÕýÈ·×ö·¨ÊÇÔÙÁ¬°´Á½´Î <ESC>¡£¡¿ | ||
| 227 | 216 | ||
| 228 | 217 | ||
| 229 | * ÎÞЧ»¯µÄÖ¸Á DISABLED COMMANDS £© | 218 | * ±»½ûÓõÄÃüÁDISABLED COMMANDS£© |
| 230 | ------------------------------------- | 219 | ----------------------------------- |
| 231 | 220 | ||
| 232 | ÓÐһЩ Emacs Ö¸Áî±»¡¸ÎÞЧ»¯¡¹ÁË£¬Òò´Ë³õѧÕß²»»áÒâÍâµØÊ¹Óõ½ËüÃÇ¡£ | 221 | ÓÐһЩ Emacs ÃüÁî±»¡°½ûÓá±ÁË£¬ÒÔ±ÜÃâ³õѧÕßÔÚ²»Á˽âÆäÈ·Çй¦ÄܵÄÇé¿öÏÂÎó |
| 222 | ÓÃÕâЩÃüÁÔì³ÉÂé·³¡£ | ||
| 233 | 223 | ||
| 234 | Èç¹ûÄú¼üÈëÁËijһ¸öÎÞЧ»¯µÄÖ¸ÁEmacs »áÏÔʾһ¸öѶϢ£¬ËµÃ÷Õâ¸öÖ¸ÁîÊÇʲ | 224 | Èç¹ûÄãÓõ½ÁËÒ»¸ö±»½ûÓõÄÃüÁEmacs »áÏÔʾһ¸öÌáʾÏûÏ¢£¬¸æËßÄãÕâ¸öÃüÁî |
| 235 | ô£¬²¢ÇÒѯÎÊÄúÊÇ·ñÏëÒª¼ÌÐø£¬È»ºóÖ´ÐÐÕâÖ¸Áî¡£ | 225 | µ½µ×ÊǸÉʲôµÄ£¬Ñ¯ÎÊÄãÊÇ·ñÒª¼ÌÐø£¬²¢Ôڵõ½ÄãµÄ¿Ï¶¨Ö®ºóÔÙÖ´ÐÐÕâÃüÁî¡£ |
| 236 | 226 | ||
| 237 | Èç¹ûÄúÕæµÄÏëÒªÊÔÒ»ÏÂÕâ¸öÖ¸ÁÄÇôÔÚµ± Emacs ѯÎÊÄúʱ£¬Çë¼üÈë¿Õ°×¡£Ò» | 227 | ÄãÒªÊÇÕæµÄÏëÖ´Ðб»½ûÓõÄÃüÁÄÇôÔÚ Emacs ѯÎÊÄãµÄʱºòÓ¦¸Ã°´¿Õ¸ñ¡£Ò»°ã |
| 238 | °ãÀ´Ëµ£¬Èç¹ûÄú²»ÏëÒªÖ´ÐÐÕâ¸öÎÞЧ»¯µÄÖ¸ÁÇëÒÔ¡ºn¡»À´»Ø´ðËü¡£ | 228 | À´Ëµ£¬Èç¹ûÄã²»ÏëÖ´ÐУ¬°´¡°n¡±¾ÍÐÐÁË¡£ |
| 239 | 229 | ||
| 240 | >> ¼üÈë C-x C-l £¨ÕâÊǸöÎÞЧ»¯µÄÖ¸Á | 230 | >> ÊÔÊÔ C-x C-l £¨ÕâÊÇÒ»¸ö±»½ûÓõÄÃüÁ |
| 241 | È»ºó¼üÈë n À´»Ø´ðÎÊÌâ¡£ | 231 | È»ºóÓà n À´»Ø´ðÎÊÌâ¡£ |
| 242 | 232 | ||
| 243 | 233 | ||
| 244 | * ´°¸ñ£¨ WINDOWS £© | 234 | * ´°¸ñ£¨WINDOWS£© |
| 245 | ------------------- | 235 | ----------------- |
| 246 | 236 | ||
| 247 | Emacs ¿ÉÒÔÓÐÊý¸ö´°¸ñ£¬Ã¿Ò»¸öÏÔʾËü×Ô¼ºµÄÎÄ×Ö¡£ÎÒÃÇÔÚÉÔºó»á½âÊÍÈçºÎʹÓà | 237 | Emacs ¿ÉÒÔÓжà¸ö´°¸ñ£¬Ã¿¸ö´°¸ñ¶¼ÏÔʾ²»Í¬µÄÎÄ×Ö¡£ÎÒÃǺóÃæÔÙ½éÉÜÔõô¶Ô¸¶ |
| 248 | ¶àÖØ´°¸ñ¡£ÏÖÔÚÎÒÃÇÏëÒª½âÊÍÈçºÎ³ýÈ¥¶àÓàµÄ´°¸ñ£¬È»ºó»Øµ½»ù±¾µÄµ¥´°¸ñ±à¼¡£ | 238 | ¶à¸ö´°¸ñ£¬ÏÖÔÚÏÈÈÃÎÒÃÇÏȸãÃ÷°×ÈçºÎ¹Øµô¶àÓàµÄ´°¸ñ¡£ÆäʵҲºÜ¼òµ¥£º |
| 249 | ËüºÜ¼òµ¥£º | ||
| 250 | 239 | ||
| 251 | C-x 1 One window £¨¼´£¬³ýÈ¥ÆäËûËùÓеĴ°¸ñ£©¡£ | 240 | C-x 1 Ö»±£ÁôÒ»¸ö´°¸ñ£¨Ò²¾ÍÊǹصôÆäËûËùÓеĴ°¸ñ£©¡£ |
| 252 | 241 | ||
| 253 | ÄÇÊǸö CONTROL-x ºóÃæ¸úÖøÊý×Ö 1 ¡£C-x 1 ½«º¬ÓÐÓαêµÄ´°¸ñÀ©´óµ½Õû¸öÓ©Ä»¡£ | 242 | Ò²¾ÍÊÇÏȰ´ CONTROL-x È»ºóÔÙ°´ 1¡£C-x 1 »á±£Áô¹â±êËùÔڵĴ°¸ñ£¬²¢½«ÆäÀ©´ó |
| 254 | Ëü½«ËùÓÐÆäËûµÄ´°¸ñ³ýÈ¥¡£ | 243 | µ½Õû¸öÆÁÄ»£¬Í¬Ê±¹ØµôËùÓÐÆäËüµÄ´°¸ñ¡£ |
| 255 | 244 | ||
| 256 | >> ÒÆ¶¯Óα굽±¾Ðв¢ÇÒ¼üÈë C-u 0 C-l¡£ | 245 | >> °Ñ¹â±êÒÆµ½±¾ÐÐÈ»ºóÊäÈë C-u 0 C-l¡£ |
| 257 | >> ¼üÈë CONTROL-h k CONTROL-f¡£ | ||
| 258 | ¿´¿´Õâ¸ö´°¸ñÔÚµ±Ò»¸öеĴ°¸ñ³öÏÖ | ||
| 259 | £¨ÒÔÏÔʾÓÐ¹Ø CONTROL-f Ö¸ÁîµÄÎĵµÊ±£©£¬ËüÊÇÈçºÎËõСµÄ¡£ | ||
| 260 | 246 | ||
| 261 | >> ¼üÈë C-x 1 ÒÔʹÎĵµÁÐ±í´°¸ñÏûʧ¡£ | 247 | >> ÊäÈë CONTROL-h k CONTROL-f¡£¹Û²ìµ±Ò»¸öд°¸ñ³öÏÖʱµ±Ç°´°¸ñ£¨ÓÃÀ´ÏÔʾ |
| 248 | CONTROL-f ÃüÁîµÄÎĵµ£©ÊÇÈçºÎËõСµÄ¡£ | ||
| 262 | 249 | ||
| 263 | Õâ¸öÖ¸Áî²¢²»ÏñÄúÏÈǰËùѧ¹ýµÄÖ¸ÁîÄǰ㣬Ëü°üÀ¨ÁËÁ½¸ö×ÖÔª¡£ËüÊÇÒÔ×ÖÔª | 250 | >> ÊäÈë C-x 1 ¹ØµôÎĵµ´°¸ñ¡£ |
| 264 | CONTROL-x ×÷Ϊ¿ªÊ¼¡£ÓÐÒ»Õû¸öϵÁеÄÖ¸ÁîÊÇÒÔ CONTROL-x ×÷Ϊ¿ªÊ¼£»ËüÃÇÖ® | ||
| 265 | ÖÐÓÐÐí¶àÊÇÓ롸´°¸ñ¡¢µµ°¸¡¢ÔÝ´æÇøÒÔ¼°Ïà¹ØÊÂÎÓйصġ£ÕâЩָÁîÓÐ 2 ¡¢ | ||
| 266 | 3 »ò 4 ¸ö×ÖÔª³¤¡£ | ||
| 267 | 251 | ||
| 252 | Õâ¸öÃüÁî¸úÏÈǰѧµ½µÄÃüÁ̫һÑù£¬ÒòΪËü°üº¬ÁËÁ½¸ö×Ö·û£¬ÒÔ CONTROL-x ¿ª | ||
| 253 | ʼ¡£ÓÐһϵÁÐÃüÁî¶¼ÊÇÒÔ CONTROL-x ¿ªÊ¼µÄ£¬ÕâЩÃüÁîÐí¶à¶¼¸ú¡°´°¸ñ¡¢Îļþ¡¢ | ||
| 254 | »º³åÇø¡¾»º³åÇø£¨buffer£©»áÔÚºóÎÄÏêϸ½éÉÜ¡¿¡±µÈµÈÖîÈç´ËÀàµÄ¶«Î÷Óйأ¬Æä | ||
| 255 | ÖÐÓÐЩÃüÁî¿ÉÄÜÓÐ 2 ¸ö¡¢3 ¸ö»òÕß 4 ¸ö×Ö·û³¤¡£ | ||
| 268 | 256 | ||
| 269 | * ²åÈëÓëɾ³ý£¨ INSERTING AND DELETING £© | ||
| 270 | ---------------------------------------- | ||
| 271 | 257 | ||
| 272 | Èç¹ûÄúÏëÒª²åÈëÎÄ×Ö£¬°ÑËü¼üÈë¾ÍÊÇÁË¡£Äú¿ÉÒÔ¿´µ½µÄ×ÖÔª£¬ÏñÊÇ A ¡¢ 7 ¡¢ * | 258 | * ²åÈëÓëɾ³ý£¨INSERTING AND DELETING£© |
| 273 | µÈ£¬±» Emacs ÊÓΪÎÄ×Ö²¢ÇÒ¿ÉÒÔÖ±½Ó²åÈë¡£¼üÈë <Return> | 259 | -------------------------------------- |
| 274 | £¨ carriage-return ¼ü£©ÒÔ²åÈëÒ»¸ö Newline ×ÖÔª¡£ | ||
| 275 | 260 | ||
| 276 | Äú¿ÉÒÔ¼üÈë <Delback> ÒÔɾ³ýÄú×îºó¼üÈëµÄ×ÖÔª¡£<Delback> ÊÇÒ»¸öµÄ¼üÅ̼ü | 261 | ²åÈëÎÄ×ֺܼòµ¥£¬ÇüüÅ̾ÍÐÐÁË¡£ÄãÄÜ¿´µ½µÄ×Ö·û£¬±ÈÈç A¡¢7¡¢* µÈµÈ£¬¶¼±» |
| 277 | -- ¾ÍÊÇÄúͨ³£ÔÚ Emacs Í⣬ʹÓÃÀ´¡¸É¾³ýÄú×îºó¼üÈë×ÖÔª¡¹µÄͬһ¸ö¡£Ò»°ãÀ´ | 262 | Emacs ÊÓΪÎÄ×Ö²¢ÇÒ¿ÉÒÔÖ±½Ó²åÈë¡£Çà <Return>£¨»Ø³µ¼ü£©»á²åÈëÒ»¸ö»»Ðзû¡£ |
| 278 | ˵ÊǸöÔÚ <Return> ÉÏ·½ÊýÐеĴó¼ü£¬Í¨³£±êʾΪ¡ºDelete¡»¡¢¡ºDel¡»»ò | ||
| 279 | ¡ºBackspace¡»¡£ | ||
| 280 | 263 | ||
| 281 | Èç¹ûÔÚÄÇÀïÓиö±êʾΪ¡ºBackspace¡»µÄ´ó¼ü£¬ÄÇôÄÇÒ»¸ö¾ÍÊÇÄúʹÓÃÀ´×÷Ϊ | 264 | Äã¿ÉÒÔÓà <Delback> À´É¾³ý×îºóÊäÈëµÄµÄÒ»¸ö×Ö·û£¬Õâ¸ö¸úÄãÔÚ Emacs Ö®ÍâµÄ |
| 282 | <Delback> µÄ¼üÁË¡£Ä³¸öµØ·½¿ÉÄÜÒ²»áÓÐÁíÒ»¸ö±êʾΪ¡ºDelete¡»µÄ¼ü£¬µ«ÄǸö | 265 | Ó÷¨Ó¦¸ÃÒ»Ñù¡£Ò»°ãÀ´Ëµ <Delback> ¾ÍÊÇλÓÚ <Return> ¼üÉÏ·½Ä³´¦µÄÒ»¸ö´óºÅ |
| 283 | ²¢²»ÊÇ <Delback> ¡£ | 266 | ¼ü£¬Í¨³£±»±êʾΪ¡°Delete¡±¡¢¡°Del¡±»òÕß¡°Backspace¡±¡£ |
| 284 | 267 | ||
| 285 | ¸üÒ»°ãµØËµ£¬ <Delback> ½«Î»ì¶Ä¿Ç°ÓαêλÖÃǰһ¸ö×ÖÔª¼ÓÒÔɾ³ý¡£ | 268 | Èç¹ûÄãÕÒµ½Á˱ê×Å¡°Backspace¡±µÄ¼ü£¬ÄÇôËüÓ¦¸Ã¾ÍÊÇ <Delback>£»¼´±ãÄãÓÖÔÚ |
| 269 | ¼üÅÌÆäËüµØ·½ÕÒµ½ÁËÒ»¸ö±êʾΪ¡°Del¡±µÄ¼ü£¬ÄÇôËüÒ²Ó¦¸Ã²»ÊÇ <Delback>¡£ | ||
| 286 | 270 | ||
| 287 | >> ÏÖÔÚ×ö -- ¼üÈëһЩ×ÖÔª£¬È»ºó¼üÈ뼸´Î <Delback> À´É¾³ýËüÃÇ¡£ | 271 | Ò»ÖÖ¸üͨÓõÄ˵·¨ÊÇ£¬<Delback> ½«Î»ÓÚ¹â±êǰµÄÒ»¸ö×Ö·ûɾ³ý¡£ |
| 288 | ²»Òªµ£ÐÄÕâ¸öµµ°¸»á±»¸ü¶¯£»Äú²»»áÓ°Ïìµ½ÔÀ´µÄ¿ìËÙÖ¸ÄÏ¡£ | ||
| 289 | £¨ÄúÏÖÔÚ¿´µ½µÄ£©ÕâÒ»¸öÊÇÄúµÄ¸öÈË¿½±´¡£ | ||
| 290 | 272 | ||
| 291 | µ±Ò»ÐÐÎÄ×Ö±äµÃ±È¡¸ÔÚ´°¸ñÖеÄÒ»ÐС¹³¤Ê±£¬ÕâÒ»ÐÐÎÄ×ֻᡸ½ÓÐø¡¹µ½µÚ¶þÐд° | 273 | >> ÏÖÔÚ¾ÍÊÔÊÔ¡ª¡ªÇõã×Ö£¬È»ºó°´¼¸Ï <Delback> ɾ³ýËüÃÇ¡£ |
| 292 | ¸ñÐС£Õâʱһ¸ö·´Ð±Ïß¡¸\¡¹£¨»òÈç¹ûÄúʹÓô°¿Ú»¯µÄÏÔʾ£¬ÔòÊÇÒ»¸öССÍäÍä | 274 | ²»Óõ£ÐÄÄã»áÐÞ¸ÄÎļþ£¬Äã¸Éʲô¶¼Ã»¹ØÏµ£¬ÕâÀï¾ÍÊÇר¸øÄãÁ·Ï°Óõġ£ |
| 293 | µÄ¼ýÍ·£©»áλÔÚÆäÓұ߽çÒÔÖ¸³ö´ËÐнÓÐøÖø¡£ | ||
| 294 | 275 | ||
| 295 | >> ²åÈëÎÄ×Ö£¬Ò»Ö±µ½Äú´ïµ½Óұ߽磬ȻºóÔÙ¼ÌÐø²åÈë¡£ | 276 | Èç¹ûÒ»ÐÐÎÄ×ֺܳ¤¡¢³¬³öÁË´°¸ñµÄ¿í¶È£¬ÏÔʾ²»ÏµIJ¿·Ö»áÔÚ½ôÁÚµÄÏÂÒ»ÐмÌÐø |
| 296 | Äú»á¿´µ½Ò»¸ö½ÓÐøÐгöÏÖ¡£ | 277 | ÏÔʾ¡£Õâʱ»áÓÐÒ»¸ö·´Ð±Ïߣ¨¿ØÖÆÌ¨ÏÂÊÇ·´Ð±Ïߣ¬Èç¹ûÄãÓÃͼÐδ°¿Úϵͳ£¬ÔòÓ¦ |
| 278 | ¸ÃÊÇÒ»¸öССµÄתÍä¼ýÍ·£©ÏÔʾÔÚÓÒ±ßÑØ£¬±íÃ÷ÕâÊÇijһÐеĽÓÐøÏÔʾ¡£ | ||
| 297 | 279 | ||
| 298 | >> ʹÓà <Delback> ɾ³ýһЩÎÄ×Ö£¬Ö±µ½´ËÐÐÔٴγÉΪһ¸ö´°¸ñÐС£ | 280 | >> ÊäÈëÎÄ×Ö£¬Ò»Ö±µ½ÆÁÄ»µÄÓұ߽磬Ȼºó¼ÌÐø£¬Äã»á¿´µ½Ò»¸ö½ÓÐøÐгöÏÖ¡£ |
| 299 | ½ÓÐøÐÐÏûʧÁË¡£ | ||
| 300 | 281 | ||
| 301 | Äú¿ÉÒÔÏñɾ³ýÆäËû×ÖÔªÒ»ÑùµØÉ¾³ý Newline ×ÖÔª¡£½«Î»ÔÚÁ½ÐÐÖÐµÄ Newline ×Ö | 282 | >> Óà <Delback> ɾµôһЩÎÄ×Ö£¬Ö±µ½´ËÐ㤶ÈСÓÚ´°¸ñ¿í¶È£¬½ÓÐøÐоÍÏûʧÁË¡£ |
| 302 | Ԫɾ³ý»áÈÃËüÃǺϲ¢³ÉΪһÐС£Èç¹ûºÏ²¢µÄ½á¹ûʹÕâÒ»ÐÐÌ«³¤£¬ÒÔÖÂÎÞ·¨·ûºÏ´° | ||
| 303 | ¸ñµÄ¿í¶È£¬Ëü»áÒÔÒ»¸ö½ÓÐøÐÐÀ´ÏÔʾ¡£ | ||
| 304 | 283 | ||
| 305 | >> ÒÆ¶¯Óα굽±¾ÐеĿªÍ·²¢¼üÈë <Delback>¡£ | 284 | Äã¿ÉÒÔÏñɾ³ýÆäËû×Ö·ûÒ»Ñùɾ³ý»»Ðзû¡£É¾³ýÁ½ÐÐÖмäµÄ»»Ðзû»á½«Á½Ðкϲ¢³É |
| 306 | Õâ»á½«±¾ÐÐÓëÆäǰһÐнáºÏΪһÐС£ | 285 | Ò»ÐС£Èç¹ûºÏ²¢µÄ½á¹ûʹÕâÒ»ÐÐÌ«³¤£¬³¬³öÁË´°¸ñµÄ¿í¶È£¬Ëü¾Í»áÒÔÒ»¸ö½ÓÐøÐÐ |
| 286 | À´ÏÔʾ¡£ | ||
| 307 | 287 | ||
| 308 | >> ¼üÈë <Return> ÒÔÖØÐ²åÈëÄú¸Õ²Åɾ³ýµÄ Newline ×ÖÔª¡£ | 288 | >> ÒÆ¶¯¹â±êµ½±¾ÐеĿªÍ·²¢ÊäÈë <Delback>¡£ |
| 289 | Õâʱ±¾ÐÐÓëÆäǰһÐн«±»ºÏ²¢ÎªÒ»ÐС£ | ||
| 309 | 290 | ||
| 310 | ¼ÇµÃ´ó²¿·ÝµÄ Emacs Ö¸Áî¶¼¿ÉÒÔ¸øÓèÒ»¸öÖØ¸´¼ÆÊý£¨ repeat count £©£»ÕâÒ² | 291 | >> ÊäÈë <Return> ÖØÐ²åÈëÄã¸Õ²Åɾ³ýµÄ»»Ðзû¡£ |
| 311 | °üÀ¨ÁËÎÄ×Ö×ÖÔª¡£Öظ´Ò»¸öÎÄ×Ö×ÖÔª»á½«Ëü²åÈëÊý´Î¡£ | ||
| 312 | 292 | ||
| 313 | >> ÏÖÔÚ¾ÍÊÔһϠ-- ¼üÈë C-u 8 * ÒÔ²åÈë ********¡£ | 293 | Ç°ÃæËµ¹ý£¬´ó²¿·ÖµÄ Emacs ÃüÁî¶¼¿ÉÒÔÖ¸¶¨Öظ´´ÎÊý£¬ÕâÆäÖÐÒ²°üÀ¨ÊäÈë×Ö·ûµÄ |
| 294 | ÃüÁî¡£ÖØ¸´Ö´ÐÐÊäÈë×Ö·ûµÄÃüÁîʵ¼ÊÉϾÍÊÇÊäÈë¶à¸öÒ»ÑùµÄ×Ö·û¡£ | ||
| 314 | 295 | ||
| 315 | ÄúÏÖÔÚÒѾѧµ½ÁË¡¸¼üÈë¸öʲô¶«Î÷½ø Emacs ÒÔ¼°ÐÞÕý´íÎ󡹵Ĵ󲿷ݻù±¾·½ | 296 | >> ÊÔÊÔ C-u 8 *£¬Õ⽫»á²åÈë ********¡£ |
| 316 | ·¨¡£ÄúÒ²¿ÉÒÔ¡¸ÒÔ×Ö»òÐÐΪµ¥Î»¡¹µØÉ¾³ý¡£ÕâÀïÓзݹØì¶¡¸É¾³ý²Ù×÷¡¹µÄÕªÒª£º | ||
| 317 | 297 | ||
| 318 | <Delback> ɾ³ýÓαêËùÔÚµÄ Ç°Ò»¸ö×ÖÔª | 298 | ºÃ£¬ÏÖÔÚÄãÓ¦¸ÃÒÑ¾ÕÆÎÕÁË×î»ù±¾µÄµÄÎı¾²åÈëºÍÐ޸ŦÄÜ£¬Æäʵɾ³ý»¹¿ÉÒÔ |
| 319 | C-d ɾ³ýÓαêËùÔÚµÄ ºóÒ»¸ö×ÖÔª | 299 | ¡°ÒÔ´ÊΪµ¥Î»¡±½øÐУ¬ÏÂÃæÊÇÒ»¸ö¹ØÓÚ¡°É¾³ý¡±²Ù×÷µÄС½á£º |
| 320 | 300 | ||
| 321 | M-<Delback> ɾ³ýÓαêËùÔÚµÄ Ç°Ò»¸ö×Ö | 301 | <Delback> ɾ³ý¹â±êǰµÄÒ»¸ö×Ö·û |
| 322 | M-d ɾ³ýÓαêËùÔÚµÄ ºóÒ»¸ö×Ö | 302 | C-d ɾ³ý¹â±êºóµÄÒ»¸ö×Ö·û |
| 323 | 303 | ||
| 324 | C-k ɾ³ý´ÓÓαêËùÔÚµ½¡¸ÐÐβ¡¹¼äµÄ×ÖÔª | 304 | M-<Delback> ÒÆ³ý¹â±êǰµÄÒ»¸ö´Ê |
| 325 | M-k ɾ³ý´ÓÓαêËùÔÚµ½¡¸¾äβ¡¹¼äµÄ×ÖÔª | 305 | M-d ÒÆ³ý¹â±êºóµÄÒ»¸ö´Ê |
| 326 | 306 | ||
| 327 | ×¢Ò⡸<Delback> ºÍ C-d¡¹»¹ÓС¸M-<Delback> ºÍ M-d¡¹ÊÇÆ½ÐеØ×Ô C-f ºÍ | 307 | C-k ÒÆ³ý´Ó¹â±êµ½¡°ÐÐβ¡±¼äµÄ×Ö·û |
| 328 | M-f À©³ä³öÀ´µÄ£¨àÅ£¬<Delback> ²¢²»ÊÇ¿ØÖÆ×ÖÔª£¬µ«ÊÇûʲôºÃµ£Ðĵģ©¡£ | 308 | M-k ÒÆ³ý´Ó¹â±êµ½¡°¾äβ¡±¼äµÄ×Ö·û |
| 329 | C-k ºÍ M-k ÔÚijÖ̶ֳÈÉÏÓë C-e ºÍ M-e Ò»Ñù£¬Èç¹û°Ñ¡¸Ò»ÐС¹ºÍ¡¸Ò»¾ä¡¹×÷ | ||
| 330 | ΪÀà±ÈµÄ»°¡£ | ||
| 331 | 309 | ||
| 332 | ÄúÒ²¿ÉÒÔÖ»ÒÔÒ»ÖÖ·½·¨À´É¾³ý»º³åÇøÄÚµÄÈκβ¿·Ý£¬ÏÈÒÆ¶¯µ½ÄúÏëҪɾ³ýµÄ²¿·Ý | 310 | ¡¾¿ÉÄÜÄãÒѾעÒâµ½ÁË¡°É¾³ý£¨delete£©¡±ºÍ¡°ÒƳý£¨kill£©¡±µÄÓôÊÇø±ð£¬ºó |
| 333 | µÄÒ»¶Ë£¬È»ºó¼üÈë C-@ »ò C-SPC £¨ÈÎÒ»¸ö¼´¿É£©¡££¨ SPC Ö¸µÄÊÇ Space Bar | 311 | ÎÄ»áÓÐÏêϸ˵Ã÷¡£¡¿ |
| 334 | £©ÔÙÒÆµ½ÄDz¿·ÝµÄÁíÒ»¶Ë£¬½ÓÖø¼üÈë C-w ¡£ÕâÑù¾Í»á°Ñ½éì¶ÕâÁ½¸öλÖüäµÄËù | ||
| 335 | ÓÐÎÄ×Öɾ³ý¡£ | ||
| 336 | 312 | ||
| 337 | >> ÒÆ¶¯Óα굽ÉÏÒ»¶Î¿ªÍ·µÄ¡¸Äú¡¹×Ö¡£ | 313 | ×¢Òâ¡°<Delback> ºÍ C-d¡±»¹ÓС°M-<Delback> ºÍ M-d¡±ÊǸù¾ÝǰÊö¹ßÀý´Ó C-f |
| 338 | >> ¼üÈë C-SPC ¡£ Emacs Ó¦¸Ã»áÔÚÓ©Ä»µÄÏ·½ÏÔʾһ¸ö¡¸Mark set¡¹Ñ¶Ï¢¡£ | 314 | ºÍ M-f ÑÜÉú³öÀ´µÄ£¨Æäʵ<Delback>²»ÊÇ¿ØÖÆ×Ö·û£¬ÎÒÃÇÏȺöÂÔÕâÒ»µã£©¡£C-k |
| 339 | >> ÒÆ¶¯Óα굽µÚ¶þÐÐÖеġ¸¶Ë¡¹×Ö¡£ | 315 | ºÍ M-k µÄ¹ØÏµÔÚijÖ̶ֳÈÉÏÓë C-e ºÍ M-e Ò»Ñù¡ª¡ªÈç¹û°Ñ¡°Ò»ÐС±ºÍ¡°Ò»¾ä¡± |
| 340 | >> ¼üÈë C-w ¡£ÕâÑù»á°Ñ´Ó¡¸Äú¡¹¿ªÊ¼µ½¸ÕºÃ¡¸¶Ë¡¹Ö®Ç°µÄÎÄ×Öɾ³ý¡£ | 316 | ×÷Ò»¸öÀà±ÈµÄ»°¡£ |
| 341 | 317 | ||
| 342 | ҪעÒâµÄÊÇ¡¸É±µô£¨ killing £©¡¹ºÍ¡¸É¾³ý£¨ deleting £©¡¹µÄ²»Í¬ÔÚì¶±»É± | 318 | ÄãÒ²¿ÉÒÔÓÃÒ»ÖÖͳһµÄ°ì·¨À´ÒƳý»º³åÇøÀïµÄÈκÎÒ»²¿·Ö£ºÊ×ÏȰѹâ±êÒÆ¶¯µ½Äã |
| 343 | µôµÄ¿ÉÒÔÀ»Ø£¬¶ø±»É¾³ýµÄÔò²»ÄÜ¡£¡¾ÓеãÄÑÒÔÀí½â£¬Äú¿ÉÒÔÕâôÏ룺(1)¡¸±» | 319 | ÏëÒªÒÆ³ýµÄÇøÓòµÄÒ»¶Ë£¬È»ºó°´ C-@ »ò C-SPC£¨ÈÎÒ»¼´¿É£¬SPCÖ¸¿Õ¸ñ£©¡¾×¢Ò⣬ |
| 344 | ɱµôµÄ¡¹ÉдæÊ¬¹Ç£¬¶ø¡¸±»É¾³ýµÄ¡¹Ôòʬ¹ÇÎÞ´æÁË£¡¿É¼ûµÃ¶ÔµçÄÔ×ÊÁÏÀ´Ëµ£¬ | 320 | C-SPC ÍùÍù±»ÖÐÎÄÓû§É趨³ÉÊäÈë·¨Èȼü£¬Èç¹ûÕâÑù£¬C-SPC ¾Í±»ÏµÍ³À¹½Ø¶øÎÞ |
| 345 | ¡¸É¾³ý¡¹±È¡¸É±µô¡¹ÑÏÖØ¶àÁË¡£(2)ʵ¼ÊÉÏ£¬¾ÍË㱻ɾ³ýÁË£¬ÎÒÃÇ»¹ÊÇÓм¼Êõ¿É | 321 | ·¨ÊäÈë¸ø Emacs ÁË£¬Òò´ËÕâÀﻹÊÇÍÆ¼öʹÓÃC-@¡£¡¿£¬È»ºóÔÙÒÆ¶¯µ½ÁíÒ»¶Ë£¬ÔÙ |
| 346 | ÒÔ°ÑËü¾È»ØÀ´£¬ÓÈÆäÊÇÎÄ×Ö×ÊÁÏ£¬Ç°ÌáÊÇɾ³ýºó²»ÄܽøÐÐʵÌå¼ÇÒäÌåµÄ¸ñʽ»¯¶¯ | 322 | °´ C-w ¾Í¿ÉÒÔ°ÑλÓÚÕâÁ½µãÖ®¼äµÄËùÓÐÎÄ×ÖÒÆ³ýÁË¡£ |
| 347 | ×÷¡£µ«Õâ¶Ôì¶Ò»°ãʹÓÃÕß¶øÑÔÊDz»¿ÉÄܵģ¬Òò´Ë¾Í²»¿¼ÂÇÕâÇéÐÎÁË¡£¡¿ÖØÐ²åÈë | ||
| 348 | ±»É±µôµÄÎÄ×Ö³ÆÎª¡¸À»Ø£¨ yanking £©¡¹¡£Ò»°ã¶øÑÔ£¬¿ÉÒÔÒÆ³ýµôºÜ¶àÎÄ×ÖµÄ | ||
| 349 | Ö¸Áî»á°ÑÄÇЩÎÄ×Ö´¢´æÆðÀ´£¨ËüÃÇÉ趨³ÉÄú¿ÉÒÔ½«ÎÄ×ÖÀ»Ø£©£¬¶øÄÇЩֻÊÇɾ³ý | ||
| 350 | Ò»¸ö×ÖÔª»òÕßÖ»ÊdzýÈ¥¿Õ°×Ðлò¿Õ°×µÄÖ¸ÁÔò²»»á´¢´æÕâЩ±»É¾³ýµÄÎÄ×Ö£¨Òò | ||
| 351 | ´ËÄú²»Äܽ«ÄÇÎÄ×ÖÀ»Ø£©¡£ | ||
| 352 | 323 | ||
| 353 | >> ÒÆ¶¯Óα굽һ·Ç¿Õ°×ÐеĿªÊ¼¡£ | 324 | >> ÒÆ¶¯¹â±êµ½ÉÏÒ»¶Î¿ªÍ·µÄ¡°Ä㡱×Ö¡£ |
| 354 | È»ºó¼üÈë C-k ɱµôÔÚÄÇÒ»ÐÐÉϵÄÎÄ×Ö¡£ | 325 | >> ÊäÈë C-@ ¡£Emacs Ó¦¸Ã»áÔÚÆÁÄ»µÄÏ·½ÏÔʾһ¸ö¡°Mark set¡±µÄÏûÏ¢¡£ |
| 355 | >> µÚ¶þ´Î¼üÈë C-k¡£Äú½«»á¿´µ½Ëüɱµô¸úÔÚÄÇÒ»ÐкóÃæµÄ Newline ×ÖÔª¡£ | 326 | >> ÒÆ¶¯¹â±êµ½µÚ¶þÐÐÖеġ°¶Ë¡±×Ö¡£ |
| 327 | >> ÊäÈë C-w£¬¾Í»á°Ñ´Ó¡°Ä㡱¿ªÊ¼µ½¡°¶Ë¡±Ö®Ç°µÄÎÄ×ÖÈ«²¿ÒƳý¡£ | ||
| 356 | 328 | ||
| 357 | Çë×¢Òâµ¥¶ÀµÄ C-k »á°ÑÒ»ÐеÄÄÚÈÝɱµô£¬¶øµÚ¶þ¸ö C-k Ôò»áɱµôÄÇÒ»Ðб¾Éí£¬ | 329 | ×¢Òâ,¡°ÒƳý£¨kill£©¡±ºÍ¡°É¾³ý£¨delete£©¡±µÄ²»Í¬ÔÚÓÚ±»ÒƳýµÄ¶«Î÷¿ÉÒÔÕÒ»Ø |
| 358 | ²¢ÇÒʹµÃËùÓÐÆäËûµÄÐÐÏòÉÏÒÆ¶¯¡£C-k ÒÔºÜÌØ±ðµÄ·½Ê½À´´¦ÀíÊý×Ö²ÎÊý£¬Ëü»áɱ | 330 | À´£¬¶ø±»É¾³ýµÄ¾Í²»ÐÐÁË¡£¡¾Êµ¼ÊÉÏ£¬ÒƳýµôµÄ¶«Î÷ËäÈ»¿´ÆðÀ´¡°Ïûʧ¡±ÁË£¬µ« |
| 359 | µôºÜ¶àÐÐÒÔ¼°ËüÃǵÄÄÚÈÝ£¬Õâ²»½ö½öÊÇÖØ¸´¶øÒÑ£¬C-u 2 C-k »á°ÑÁ½ÐÐÒÔ¼°ËüÃÇ | 331 | ʵ¼ÊÉϱ» Emacs ¼Ç¼ÁËÏÂÀ´£¬Òò´Ë»¹¿ÉÒÔÕÒ»ØÀ´£»¶øÉ¾³ýµôµÄ¶«Î÷ËäȻҲ¿ÉÄÜ»¹ |
| 360 | µÄ Newline ×ÖԪɱµô£»Èç¹ûÖ»ÊǼüÈë C-k Á½´Î²¢²»»áÕâÑù¡£ | 332 | ÔÚÄÚ´æÀµ«ÊÇÒѾ±»Emacs¡°Åׯú¡±ÁË£¬ËùÒÔ¾ÍÕÒ²»»ØÀ´ÁË¡£¡¿ÖØÐ²åÈë±»ÒÆ³ý |
| 333 | µÄÎÄ×Ö³ÆÎª¡°Õٻأ¨yank£©¡±¡£Ò»°ã¶øÑÔ£¬ÄÇЩ»áÈ¥³ýºÜ¶àÎÄ×ÖµÄÃüÁî»á°ÑÈ¥³ý | ||
| 334 | µôµÄÎÄ×Ö´¢´æÆðÀ´£¨ËüÃDZ»É趨³ÉÁË¡°¿ÉÕٻء±£©£¬¶øÄÇЩֻÊÇÈ¥³ýÒ»¸ö×Ö·û»ò | ||
| 335 | ÕßÖ»ÊÇÈ¥³ý¿Õ°×µÄÃüÁî¾Í²»»á´¢´æÄÇЩ±»È¥³ýµôµÄ¶«Î÷£¨Òò´ËÄã¾ÍÎÞ·¨Õٻأ©¡£ | ||
| 361 | 336 | ||
| 362 | ½«±»É±µôµÄÎÄ×ֻظ´µÄ¶¯×÷³ÆÎª¡¸À»Ø£¨ yanking £©¡¹¡££¨°ÑËüÏëÏñ³ÉÄú°Ñ±ð | 337 | >> ÒÆ¶¯¹â±êµ½Ò»·Ç¿Õ°×ÐеÄÐÐÍ·£¬È»ºóÊäÈë C-k ÒÆ³ýÄÇÒ»ÐÐÉϵÄÎÄ×Ö¡£ |
| 363 | ÈË´ÓÄúÉíÉ϶áÈ¥µÄ¶«Î÷ÃÍÁ¦µØÀ»ØÀ´£©Äú¿ÉÒÔÔÚÄúɾ³ýÎÄ×ֵĵط½À»Ø£¬Ò²¿ÉÒÔ | ||
| 364 | ÔÚÎÄ×ֵįäËûµØ·½À»Ø¡£Äú¿ÉÒÔÀ»ØÊý´ÎͬÑùµÄÎÄ×Ö£¬ÒÔÖÆ×÷ËüµÄÊý·Ý¿½±´¡£ | ||
| 365 | 338 | ||
| 366 | À»ØµÄÖ¸ÁîΪ C-y¡£Ëü»áÔÚĿǰÓαêµÄλÖÃÖØÐ²åÈë×îºóɱµôµÄÎÄ×Ö¡£ | 339 | >> ÔÙ´Î C-k£¬Äã¿ÉÒÔ¿´µ½ËüÒÆ³ýÁ˸úÔÚÄÇÒ»ÐкóÃæµÄ»»Ðзû¡£ |
| 367 | 340 | ||
| 368 | >> ÊÔÊÔ¿´£»¼üÈë C-y ½«ÎÄ×ÖÀ»Ø¡£ | 341 | ×¢Ò⣬µ¥¶ÀµÄ C-k »á°ÑÒ»ÐеÄÄÚÈÝÒÆ³ý£¬¶øµÚ¶þ¸ö C-k Ôò»áÒÆ³ý»»Ðзû£¬²¢Ê¹ |
| 342 | ÆäºóËùÓеÄÐж¼ÏòÉÏÒÆ¶¯¡£C-k ´¦ÀíÊý×Ö²ÎÊýµÄ·½Ê½ºÜÌØ±ð£¬Ëü»á°Ñ²ÎÊýÖ¸¶¨µÄ | ||
| 343 | ÄÇô¶àÐÐÁ¬Í¬ÆäºóµÄ»»ÐзûÒ»ÆðÒÆ³ý£¬¶ø²»½ö½öÊÇÖØ¸´ C-k ¶øÒÑ¡£±ÈÈç C-u 2 | ||
| 344 | C-k »á°ÑÁ½ÐÐÒÔ¼°ËüÃǵĻ»ÐзûÒÆ³ý£»¶øÈç¹ûÖ»ÊÇÊäÈë C-k Á½´ÎÏÔÈ»²»ÊÇÕâ¸ö½á | ||
| 345 | ¹û¡£ | ||
| 369 | 346 | ||
| 370 | Èç¹ûÄúÁ¬ÐøµØ×öÁËÊý´Î C-k£¬ËùÓб»É±µôµÄÎÄ×Ö¶¼»á±»´¢´æÔÚÒ»Æð£¬Òò´Ë×öÒ»´Î | 347 | ½«±»ÒƳýµÄÎÄ×Ö»Ö¸´µÄ¶¯×÷³ÆÎª¡°Õٻأ¨yanking£©¡±¡££¨¾ÍºÃÏñÄã°Ñ±ðÈË´ÓÄãÉí |
| 371 | C-y ¾Í»á°ÑËùÓÐÕâЩÐж¼À»ØÀ´¡£ | 348 | ±ßÒÆ×ߵĶ«Î÷ÓÖÃÍÁ¦µØÀ»ØÀ´¡££©Äã¿ÉÒÔÔÚÄãɾ³ýÎÄ×ֵĵط½Õٻأ¬Ò²¿ÉÒÔÔÚ±ð |
| 349 | µÄµØ·½Õٻأ¬»¹¿ÉÒÔ¶à´ÎÕÙ»ØÍ¬ÑùµÄÎÄ×ÖÒԵõ½ËüµÄ¶à¸ö¿½±´¡£ | ||
| 372 | 350 | ||
| 373 | >> ÏÖÔÚ×öһϣ¬¼üÈë C-k Êý´Î¡£ | 351 | ÕٻصÄÃüÁîÊÇ C-y¡£Ëü»áÔÚ¹â±êËùÔÚ´¦²åÈëÄã×îºóÒÆ³ýµÄÎÄ×Ö¡£ |
| 374 | 352 | ||
| 375 | ÏÖÔÚÒª»Ø¸´ÄÇЩɱµôµÄÎÄ×Ö£º | 353 | >> ÊÔÊÔ¿´£¬ÊäÈë C-y ½«ÎÄ×ÖÕٻء£ |
| 376 | 354 | ||
| 377 | >> ¼üÈë C-y¡£È»ºó°ÑÓαêÍùÏÂÒÆ¶¯¸ö¼¸ÐУ¬ÔÙÒ»´Î¼üÈë C-y¡£ | 355 | Èç¹ûÄãÒ»´ÎÁ¬°´Á˺ü¸Ï C-k£¬ÄÇôËùÓб»ÒƳýµÄÐлᱻ´æ´¢ÔÚÒ»Æð£¬Ö»ÒªÒ»¸ö |
| 378 | ÄúÏÖÔÚÖªµÀÈçºÎ¸´ÖÆÄ³Ð©ÎÄ×ÖÁË¡£ | 356 | C-y ¾Í¿ÉÒÔ°ÑËüÃǶ¼Õٻء£ |
| 379 | 357 | ||
| 380 | Èç¹ûÄúÓÐһЩÎÄ×ÖÏëÒªÀ»ØÀ´£¬µ«ÊǺóÀ´ÄúÓÖɱÁËijЩ¶«Î÷£¬ÄÇô¸ÃÔõô×öÄØ£¿ | 358 | >> ÔÚÕâÀïÊÔÊÔ£¬Á¬Ðø°´¼¸´Î C-k¡£ |
| 381 | C-y »á°Ñ×î½üɱµôµÄÀ»ØÀ´£¬µ«ÊÇÏÈǰµÄÎÄ×Ö²¢Ã»ÓÐÏûʧ£¬Äú¿ÉÒÔÓà M-y À´»Ø | ||
| 382 | µ½Ëü¡£µ±ÄúÒѾʹÓà C-y °Ñ×î½üɱµôµÄÀ»ØÀ´Ö®ºó£¬ÔÙ¼üÈë M-y À´°ÑÕâЩÀ»Ø | ||
| 383 | À´µÄÎÄ×ÖÌæ»»ÎªÏÈǰËùɱµôµÄ¡£Ò»´ÎÓÖÒ»´ÎµØ¼üÈë M-y »á°ÑÏÈǰÔÙÏÈǰËùɱµô | ||
| 384 | µÄÎÄ×Ö´ø»ØÀ´¡£µ±Äúµ½ÁËÄúÏëÕÒµÄÎÄ×Öʱ£¬Äú²»ÐèÒª×öÈκÎÊÂÀ´±£´æËü£¬Ö»Òª¼Ì | ||
| 385 | ÐøÄúµÄ±à¼£¬°ÑÕâЩÒÑÀ»ØµÄÎÄ×ÖÁôÔÚÄÇÀï¾ÍºÃ¡£ | ||
| 386 | 359 | ||
| 387 | Èç¹ûÄú M-y ×öÁ˺ܶà´Î£¬Äú¿ÉÄÜ»á»Øµ½Æðʼµã£¬Ò²¾ÍÊÇ×î½üɱµôµÄ¡£ | 360 | ÏÖÔÚÔÙÀ´»Ö¸´¸Õ¸Õ±»ÎÒÃÇÒÆ³ýµÄÎÄ×Ö£º |
| 388 | 361 | ||
| 389 | >> ɱµôÒ»ÐУ¬µ½´¦ÈÆÈÆ£¬ÔÙɱµôÁíÒ»ÐС£ | 362 | >> °´ C-y¡£È»ºó°Ñ¹â±êÍùÏÂÒÆ¶¯¼¸ÐУ¬ÔÙ°´Ò»´Î C-y¡£ |
| 390 | È»ºóÓà C-y ½«µÚ¶þ´ÎɱµôµÄÄÇÐдø»ØÀ´¡£ | 363 | ÏÖÔÚÄãÓ¦¸ÃÖªµÀÔõô¸´ÖÆÎÄ×ÖÁË¡£ |
| 391 | È»ºóÔÙÓà M-y£¬Ëü½«»á±»µÚÒ»´ÎɱµôµÄÄÇÐÐÈ¡´ú¡£ | ||
| 392 | ÔÙ×ö¼¸´Î M-y ¿´¿´Äú»áµÃµ½Ê²Ã´¡£ | ||
| 393 | ²»¼ä¶ÏµØ×ö£¬Ö±µ½µÚ¶þ¸öɱµôÐлØÀ´£¬ÔÙ×ö¸ö¼¸´Î¡£ | ||
| 394 | Èç¹ûÄúÏëµÄ»°£¬Äú¿ÉÒÔÊÔÖø¸ø M-y ÕýµÄ»òÊǸºµÄ²ÎÊý¡£ | ||
| 395 | 364 | ||
| 365 | C-y ¿ÉÒÔ°Ñ×î½üÒÆ³ýµÄÎÄ×ÖÕٻأ¬µ«Èç¹ûÄãÏëÕٻصĶ«Î÷²»ÊÇ×î½üÒÆ³ýµÄ£¬¸ÃÔõ | ||
| 366 | ô°ìÄØ£¿ËüÃǵ±È»Ã»Óжª£¬Äã¿ÉÒÔÓà M-y À´ÕÙ»ØËüÃÇ¡£ÔÚÓà C-y ÕÙ»Ø×î½üÒÆ³ý | ||
| 367 | µÄÎÄ×ÖÖ®ºó£¬½ô½Ó×ÅÔÙÓà M-y ¾Í¿ÉÒÔÕÙ»ØÔÙǰһ´Î±»ÒƳýµÄÎÄ×Ö£¬ÔÙ°´Ò»´Î | ||
| 368 | M-y ÓÖ¿ÉÒÔÕÙ»ØÔÙÉÏÒ»´ÎµÄ£¬Òò´ËÖ»Òª¶à°´¼¸´Î M-y ¾Í¿ÉÒÔÕÒµ½ÄãÏëÒªÕٻصĶ« | ||
| 369 | Î÷ÁË¡£ÕÒµ½ÁËÖ®ºó£¬ÄãʲôҲ²»ÓÃ×ö£¬°ÑËüÃÇÁÀÔÚÄÇÀ¼ÌÐøÄãµÄ±à¼¾ÍÐÐÁË¡£ | ||
| 396 | 370 | ||
| 397 | * È¡Ïû¶¯×÷£¨ UNDO £© | 371 | Èç¹ûÄãÒ»´Î°´ M-y °´Á˺ܶàÏ£¬Äã¿ÉÄÜ»á»Øµ½Æðʼµã£¬Ò²¾ÍÊÇ×î½üÒÆ³ýµÄÎÄ×Ö¡£ |
| 398 | -------------------- | 372 | ¡¾¿´µÃ³öÕâʵ¼ÊÉÏÊÇÒ»¸ö»·¡£¡¿ |
| 399 | 373 | ||
| 400 | Èç¹ûÄú¶ÔÎÄ×Ö×öÁËһЩ¸Ä±ä£¬ºóÀ´¾õµÃËüÊǸö´íÎó£¬Äú¿ÉÒÔ Undo Ö¸ÁîÈ¡ÏûÕâÒ» | 374 | >> ÒÆ³ýÒ»ÐУ¬Òƶ¯Ò»Ï¹â±ê£¬È»ºóÔÙÒÆ³ýÁíÍâÒ»ÐС£ |
| 401 | ¸ö¸Ä±ä£¬C-x u¡£ | 375 | °´ C-y ½«µÚ¶þ´ÎÒÆ³ýµÄÄÇÐÐÕÙ»ØÀ´¡£ |
| 376 | ½ô½Ó×ÅÔÙ°´ M-y£¬Ëü½«»á±»µÚÒ»´ÎÒÆ³ýµÄÄÇÐÐÈ¡´ú¡£ | ||
| 377 | ÊÔ×ÅÔÙ°´¼¸Ï M-y ¿´¿´»á·¢Éúʲô¡£ | ||
| 378 | ÔÙ¼ÌÐø£¬Ö±µ½µÚ¶þÐб»ÕÙ»ØÀ´£¬È»ºóÔÙ×ö¸ö¼¸´Î¡£ | ||
| 379 | Èç¹ûÄãÔ¸Ò⣬Äã¿ÉÒÔÊÔןø M-y Ö¸¶¨Ò»¸öÕýµÄ»ò¸ºµÄ²ÎÊý¡£ | ||
| 402 | 380 | ||
| 403 | ͨ³£ C-x u »á°ÑÒ»¸öÖ¸ÁîËùÔì³ÉµÄ¸Ä±äÈ¡Ïûµô£»Èç¹ûÄúÔÚÒ»ÐÐÖÐÖØ¸´ÁËÐí¶à´Î | 381 | |
| 404 | C-x u£¬Ã¿Ò»¸öÖØ¸´¶¼»áÈ¡Ïû¶îÍâµÄÖ¸Áî¡£ | 382 | * ³·Ïú£¨UNDO£© |
| 383 | -------------- | ||
| 384 | |||
| 385 | Èç¹ûÄãÐÞ¸ÄÁËÒ»¶ÎÎÄ×Ö£¬ÓÖ¾õµÃ¸ÄµÃ²»ºÃ£¬¿ÉÒÔÓà undo ÃüÁî½øÐг·Ïú£º | ||
| 386 | C-x u¡£ | ||
| 387 | |||
| 388 | ͨ³£ C-x u »áÏû³ýÒ»¸öÃüÁîËùÔì³ÉµÄËùÓиı䣻Èç¹ûÄãÔÚÒ»ÐÐÖÐÁ¬Ðø¶à´ÎµØÊ¹Óà | ||
| 389 | C-x u£¬Äã»á°ÑÒÔǰµÄÃüÁîÒ²ÒÀ´Î³·Ïú¡£ | ||
| 405 | 390 | ||
| 406 | µ«ÊÇÓÐÁ½¸öÀýÍ⣺ | 391 | µ«ÊÇÓÐÁ½¸öÀýÍ⣺ |
| 407 | (1) ûÓиıäÎÄ×ÖµÄÖ¸Áî²»Ë㣨Õâ°üÀ¨ÁËÓαêÒÆ¶¯µÄÖ¸ÁÓоíÖáÖ¸Á£» | 392 | 1£© ûÓиıäÎÄ×ÖµÄÃüÁî²»Ë㣨°üÀ¨¹â±êÒÆ¶¯ÃüÁîºÍ¹ö¶¯ÃüÁ |
| 408 | (2) ×ÔÐмüÈëµÄ×ÖÔªÒÔһȺһȺ -- ÿȺ×î¶à 20 ¸ö -- À´½øÐд¦Àí¡£ | 393 | 2£© ´Ó¼üÅÌÊäÈëµÄ×Ö·ûÒÔ×éΪµ¥Î»¡ª¡ªÃ¿×é 20 ¸ö×Ö·û¡ª¡ªÀ´½øÐд¦Àí¡£ |
| 409 | £¨ÕâÊÇΪÁ˼õÉÙÄúÔÚÈ¡Ïû¡¸²åÈëÎÄ×Ö¶¯×÷¡¹Ëù±ØÐë¼üÈë C-x u µÄ´ÎÊý£© | 394 | £¨ÕâÊÇΪÁ˼õÉÙÄãÔÚ³·Ïú¡°²åÈëÎÄ×Ö¡±¶¯×÷ʱÐèÒªÊäÈë C-x u µÄ´ÎÊý£© |
| 410 | 395 | ||
| 411 | >> ÒÔ C-k ½«ÕâÒ»ÐÐɱµô£¬È»ºó¼üÈë C-x u ºóËü»áÔٴγöÏÖ¡£ | 396 | >> Óà C-k ½«ÕâÒ»ÐÐÒÆ³ý£¬È»ºóÊäÈë C-x u £¬Ëü»áÔٴγöÏÖ¡£ |
| 412 | 397 | ||
| 413 | C-_ ÊÇÁíÒ»¸öÈ¡ÏûÖ¸ÁËüµÄ×÷ÓÃ¾ÍºÍ C-x u Ò»Ñù£¬µ«ÊÇÔÚÒ»ÐÐÖÐËü±È½ÏÈÝÒ× | 398 | C-_ Ò²Êdz·ÏúÃüÁËüµÄ×÷Óøú C-x u Ò»Ñù£¬µ«ÊÇËü±È½ÏÈÝÒ×¶à´ÎÊäÈë¡£C-_ µÄ |
| 414 | ¼üÈëÐí¶à´Î¡£C-_ µÄȱµãÊÇÔÚijЩ¼üÅÌÖв»Ì«Çå³þÈçºÎ¼üÈëËü£¬ÕâÒ²ÊÇΪʲôÎÒ | 399 | ȱµãÊÇÔÚijЩ¼üÅÌÉÏ¿ÉÄܲ»Ì«ÈÝÒ×°´£¬ÕâÒ²ÕýÊÇÎÒÃÇͬʱÌṩ C-x u µÄÔÒò¡£ÔÚ |
| 415 | ÃÇͬʱÌṩ C-x u µÄÔÒò¡£ÔÚijЩÖÕ¶Ë»ú£¬Äú¿ÉÒÔ°´×¡ CONTROL ÔÙ¼üÈë / £¬ | 400 | ijЩÖÕ¶ËÉÏ£¬Äã¿ÉÒÔ°´×¡ CONTROL ÔÙ°´¡°/¡±À´ÊäÈë C-_¡£ |
| 416 | À´¼üÈë C-_¡£ | ||
| 417 | 401 | ||
| 418 | Ò»¸öÊý×Ö²ÎÊý¶Ô C-_ or C-x u À´Ëµ£¬ÊÇ×÷ÎªÖØ¸´µÄ´ÎÊý¡£ | 402 | Êý×Ö²ÎÊý¶ÔÓÚ C-_ ºÍ C-x u µÄÒâÒåÊÇÖ´Ðг·ÏúµÄÖØ¸´´ÎÊý¡£ |
| 419 | 403 | ||
| 420 | 404 | ||
| 421 | * µµ°¸£¨ FILE £© | 405 | * Îļþ£¨FILE£© |
| 422 | ---------------- | 406 | -------------- |
| 423 | 407 | ||
| 424 | ΪÁËʹÄú±à¼µÄÎÄ×ÖÓÀ¾Ã±£´æ£¬Äú±ØÐë°ÑËü·Åµ½Ò»¸öµµ°¸ÖС£²»È»£¬µ±ÄúÀ뿪 | 408 | Ïë±£´æ¹¤×÷³É¹û¾ÍÒª¼ÇµÃ´æÅÌ£¬·ñÔòÒ»µ©Í˳ö Emacs Äã±à¼µÄÎÄ×־Ͷ¼¶ªÁË¡£Òª |
| 425 | Emacs ºó£¬Ëü¾Í»áËæÖ®Ïûʧ¡£ÎªÁ˰ÑÄúµÄÎÄ×Ö·ÅÔÚµµ°¸ÖУ¬Äú±ØÐëÔÚÄú¼üÈëÕâЩ | 409 | ´æÅÌ£¬¾ÍÒªÔÚ±à¼Ç°¡°Ñ°ÕÒ¡±µ½Ò»¸ö´æÅÌÎļþ¡££¨Õâ¸ö¹ý³Ìͨ³£Ò²±»³ÆÎª¡°·ÃÎÊ¡± |
| 426 | ÎÄ×Öǰ¡¸ÕÒ£¨ find £©¡¹µµ°¸¡££¨ÕâÒ²³ÆÖ®Îª¡¸°Ý·Ã£¨ visiting £©¡¹µµ°¸£© | 410 | Îļþ¡££© |
| 427 | 411 | ||
| 428 | ÕÒÒ»¸öµµ°¸±íʾÄú¿ÉÒÔÔÚ Emacs Öп´µ½µµ°¸µÄÄÚÈÝ¡£´ÓÐí¶à·½ÃæÀ´¿´£¬Ëü¾ÍÏñ | 412 | ѰÕÒµ½Ò»¸öÎļþÒâζ×ÅÄã¿ÉÒÔÔÚ Emacs Àï²é¿´Õâ¸öÎļþµÄÄÚÈÝ¡£´ÓºÜ¶à½Ç¶È½²£¬ |
| 429 | ÊÇÄúÖ±½Ó±à¼ÄǸöµµ°¸Ò»Ñù¡£È»¶ø£¬Ö±µ½Äú¡¸´¢´æ¡¹Õâ¸öµµ°¸Ö®Ç°£¬ÄúʹÓà | 413 | Õâ¾ÍµÈÓÚÄãÔÚÖ±½Ó±à¼Õâ¸öÎļþ¡£µ«ÊÇÄãËù×öµÄÐÞ¸ÄÖ»ÓÐÔÚ¡°´æÅÌ¡±µÄʱºò²Å»á |
| 430 | Emacs ±à¼Ëù×ö³öµÄ¸Ä±ä²¢²»»á±£´æÏÂÀ´¡£Õâ¾ÍÊÇΪʲôµ±Äú²»ÏëҪʱ£¬Äú¿ÉÒÔ | 414 | ±»Ð´ÈëÎļþ¡£Ò²ÕýÒòΪÈç´Ë£¬Äã¿ÉÒÔ¶ªÆúÒ»¸ö¸Äµ½Ò»°ëµÄÎļþ¶ø²»±Ø°ÑÕâ¸ö²Ð·Ï |
| 431 | ±ÜÃâÁôÏÂÐ޸ĵ½Ò»°ëµÄµµ°¸ÔÚϵͳÖС£¼´Ê¹µ±Äú´¢´æÁË£¬Emacs Ò²»á°ÑÔ±¾µÄµµ | 415 | ÎļþÒ²±£´æµ½¼ÆËã»úÉÏ¡£×îºó¾ÍËãÄãÕæÕý´æÁËÅÌ£¬Emacs Ò²»á°Ñ´æÅÌǰµÄÎļþÖØ |
| 432 | °¸ÒÔÒ»¸ö²»Í¬µÄÃû³Æ±£ÁôÏÂÀ´£¬ÈôÄúÉÔºó¾õµÃÄúµÄ¸Ä±äÊÇÒ»¸ö´íÎóµÄ»°£¬¾Í¿ÉÒÔ | 416 | ÃüÃû±£´æ£¬ÒÔ·ÀÄã¸ÄÍêÖ®ºóÓÖÏë·´»Ú¡£ |
| 433 | ʹÓÃËü¡£ | ||
| 434 | 417 | ||
| 435 | ÔÚ¿¿½üÓ©Ä»µÄÏ·½£¬Äú¿ÉÒÔ¿´µ½ÓÉÆÆÕۺſªÊ¼Óë½áÊøµÄÒ»ÐÐ -- ͨ³£ÊÇÒÔ¡¸--:-- | 418 | ÔÚÆÁÄ»µÄÏ·½£¬ÄãÓ¦¸ÃÄܹ»¿´µ½Í·Î²¶¼ÊǶÌÏß¡°-¡±µÄÒ»ÐУ¬Æä¿ªÍ·Í¨³£¶¼ÊÇÖîÈç |
| 436 | TUTORIAL.cn¡¹»òÆäËûÀàËÆµÄ¶«Î÷×÷Ϊ¿ªÊ¼¡£ÕâÊÇÓ©Ä»µÄÒ»²¿·Ö£¬Í¨³£ÓÃÀ´±íʾ | 419 | ¡°--:-- TUTORIAL.cn¡±ÕâÑùµÄ¶«Î÷£¬ÕâЩÎÄ×־ʹú±íÁËÄ㵱ǰÕýÔÚ·ÃÎʵÄÎļþ¡£ |
| 437 | ÄúÕýÔڰݷõĵµ°¸¡£ÏÖÔÚ£¬ÄúÕýÔڰݷõĵµ°¸½Ð×ö¡¸TUTORIAL.cn¡¹£¬ËüÊÇÄú¸ö | 420 | ÏÖÔÚÄã·ÃÎʵÄÎļþ½Ð¡°TUTORIAL.cn¡±£¬ËüÖ»ÊǸøÄã¸öÈËÁÙʱʹÓõÄÒ»¸ö¿½±´¡£Ö» |
| 438 | È˵Ŀ½±´¡£µ±ÄúÒÔ Emacs ÕÒ³öÒ»¸öµµ°¸Ê±£¬ÄǸöµµ°¸µÄÃû×־ͻá³öÏÖÔÚÄǸöµØ | 421 | ÒªÄãÓà Emacs ѰÕÒµ½Ò»¸öÎļþ£¬ÎļþÃû¾Í»á³öÏÖÔÚÉÏÊöλÖᣠ|
| 439 | ·½¡£ | ||
| 440 | 422 | ||
| 441 | ¹Øì¶Ñ°ÕÒµµ°¸µÄÖ¸ÁîÖУ¬ÓÐÒ»¸öºÜÌØ±ðµÄÊÇ£¬Äú±ØÐë˵³öÕâ¸öÄúÏëÒªµÄµµ°¸Ãû³Æ¡£ | 423 | ѰÕÒÎļþµÄÃüÁîÓÐÒ»¸öÌØ±ðÖ®´¦£¬ÄǾÍÊÇÄã±ØÐë¸ø³öÎļþÃû¡£ÎÒÃdzÆÕâ¸öÃüÁî |
| 442 | ÎÒÃÇ˵Õâ¸öÖ¸Á´ÓÖÕ¶Ë»úÖжÁ½øÁËÒ»¸ö²ÎÊý¡¹¡££¨ÔÚÕâ¸öÀý×ÓÖУ¬Õâ²ÎÊý¾ÍÊÇ | 424 | ¡°´ÓÖն˶ÁÈëÁËÒ»¸ö²ÎÊý¡±£¨ÔÚÕâÀÕâ¸ö²ÎÊýÏÔÈ»¾ÍÊÇÎļþÃû£©¡£µ±ÄãÊäÈëÁË |
| 443 | µµ°¸µÄÃû³Æ£©µ±Äú¼üÈëÕâ¸öÖ¸Áîºó£¬ | 425 | Õâ¸öÃüÁîÖ®ºó£º |
| 444 | 426 | ||
| 445 | C-x C-f ÕÒÒ»¸öµµ°¸ | 427 | C-x C-f ѰÕÒÒ»¸öÎļþ |
| 446 | 428 | ||
| 447 | Emacs »áÒªÄú¼üÈëµµÃû¡£ÄúËù¼üÈëµÄµµÃû»á³öÏÖÔÚÓ©Ä»µÄµ×ÐС£ÔÚ±»ÓÃÀ´×÷ΪÕâ | 429 | Emacs »áÌáʾÄãÊäÈëÎļþÃû¡£ÄãÊäÈëµÄÎļþÃû»á³öÏÖÔÚÆÁÄ»×îµ×¶ËµÄÒ»ÐУ¬ÕâÒ» |
| 448 | ÖÖÐÎʽµÄÊäÈëʱ£¬µ×Ðб»³ÆÎªÐ¡»º³åÇø£¨ minibuffer £©¡£Äú¿ÉÒÔʹÓÃÕý³£µÄ | 430 | Ðб»³ÆÎªÐ¡»º³å£¨minibuffer£©£¬ÔÚС»º³åÀïÄã¿ÉÒÔʹÓÃͨ³£µÄ Emacs ±à¼ÃüÁî |
| 449 | Emacs ±à¼Ö¸ÁîÀ´±à¼Õâ¸öµµÃû¡£ | 431 | À´±à¼ÎļþÃû¡£ |
| 450 | 432 | ||
| 451 | µ±ÄúÕýÔÚ¼üÈëµµÃûʱ£¨»òÊÇÈκεÄС»º³åÇøÊäÈëʱ£©£¬Äú¿ÉÒÔÓà C-g Õâ¸öÖ¸Áî | 433 | ÔÚС»º³åÀïÊäÈëÎļþÃû£¨ÆäʵÊäÈë±ðµÄ¶«Î÷Ò²Ò»Ñù£©Ê±¿ÉÒÔÓà C-g È¡Ïû¡£ |
| 452 | À´È¡ÏûËü¡£ | ||
| 453 | 434 | ||
| 454 | >> ¼üÈë C-x C-f£¬È»ºó¼üÈë C-g¡£Õâ»áÈ¡ÏûС»º³åÇø£¬ | 435 | >> ÊäÈë C-x C-f£¬È»ºóÊäÈë C-g |
| 455 | ²¢ÇÒÒ²»áÈ¡ÏûʹÓÃÕâ¸öС»º³åÇøµÄ C-x C-f Ö¸Áî¡£ | 436 | Õâ»á¹ØµôС»º³å£¬Í¬Ê±Ò²»áÈ¡ÏûʹÓÃС»º³åµÄ C-x C-f ÃüÁî¡£ |
| 456 | Òò´ËÄúûÓÐÕÒÈκεµ°¸¡£ | 437 | µ±È»ÁË£¬ÄãҲûÓÐÕÒÈκÎÎļþ¡£ |
| 457 | 438 | ||
| 458 | µ±ÄúÒѾ¼üÈëÁËÕâ¸öµµÃû£¬Çë¼üÈë <Return> À´½áÊøËü¡£È»ºó C-x C-f Ö¸Áî¾Í | 439 | ÊäÈëÍêÎļþÃûÖ®ºóÓà <Return> ½áÊø£¬È»ºó C-x C-f ÃüÁʼ¹¤×÷²¢ÕÒµ½ÄãÖ¸¶¨ |
| 459 | »á¿ªÊ¼ÔË×÷£¬²¢ÇÒÕÒµ½ÄúËùÑ¡ÔñµÄµµ°¸¡£Ð¡»º³åÇøÔÚµ± C-x C-f Ö¸Áî½áÊøÊ±¾Í | 440 | µÄÎļþ¡£Ð¡»º³åÔÚ C-x C-f ÃüÁî½áÊøÖ®ºóÒ²»áÏûʧ¡£ |
| 460 | »áÏûʧ¡£ | ||
| 461 | 441 | ||
| 462 | ¹ýÁËÒ»»á¶ù£¬µµ°¸µÄÄÚÈݾͻá³öÏÖÔÚÓ©Ä»£¬È»ºóÄú¾Í¿ÉÒÔ±à¼ËüµÄÄÚÈÝ¡£µ±ÄúÏë | 442 | Õ£ÑÛ¼äÎļþ¾Í»áÏÔʾÔÚÆÁÄ»ÉÏ£¬Äã¿ÉÒÔ¿ªÊ¼±à¼ÁË¡£´æÅÌÓÃÕâ¸öÃüÁ |
| 463 | ÒªÄúµÄ¸Ä±äÓÀ¾Ã±£´æÊ±£¬¼üÈëÕâ¸öÖ¸Á | ||
| 464 | 443 | ||
| 465 | C-x C-s ´¢´æÕâ¸öµµ°¸ | 444 | C-x C-s ´¢´æÕâ¸öÎļþ |
| 466 | 445 | ||
| 467 | Õâ»á°ÑÔÚ Emacs ÖеÄÎÄ×Ö¸´ÖƵ½µµ°¸ÖС£µ±ÄúµÚÒ»´Î×öÕâ¸ö¶¯×÷ʱ£¬Emacs »á | 446 | Õâ¸öÃüÁî°Ñ Emacs ÖеÄÎÄ×Ö´æ´¢µ½ÎļþÖС£µÚÒ»´Î´æÅ̵Äʱºò Emacs »á½«ÔÎÄ |
| 468 | ½«ÔʼµÄµµ°¸ÖØÐÂÃüÃû³ÉÒ»¸öеÄÃû×Ö£¬ÕâÑùËü²Å²»»áÏûʧ¡£ÐµÄÃû×Öͨ³£»á¼Ó | 447 | ¼þÖØÃüÃûÒÔ±£ÁôÔÎÄ¡£ÖØÃüÃûµÄ¹æÔòͨ³£ÊÇÔÚÔÎļþÃûÖ®ºóÌí¼ÓÒ»¸ö¡°~¡±×Ö·û¡£ |
| 469 | È롸~¡¹µ½Ôʼµµ°¸µÄÃû×ÖºóÃæ¡£ | ||
| 470 | 448 | ||
| 471 | µ±´¢´æ½áÊøÊ±£¬Emacs »á°ÑдÈëµµ°¸µÄÃû×ÖÁгöÀ´¡£ÄúÓ¦¸Ã¾³£µØ½øÐд¢´æ£¬Õâ | 449 | ´æÅ̽áÊøºó£¬Emacs »áÏÔʾдÈëÎļþµÄÎļþÃû¡£Äã×îºÃÑø³É¾³£´æÅ̵Äϰ¹ß£¬Õâ |
| 472 | Ñù×ÓÈç¹ûϵͳµ±»úʱ£¬Äú¾Í²»»áËðʧ̫¶à¹¤×÷¡£ | 450 | ÑùÔÚϵͳ±ÀÀ£»òÕßËÀ»úµÄʱºòÄã²»»áËðʧ̫¶à¡£ |
| 473 | 451 | ||
| 474 | >> ¼üÈë C-x C-s ÒÔ´¢´æ±¾¿ìËÙÖ¸ÄϵÄÄúµÄ¿½±´¡£ | 452 | >> ÊäÈë C-x C-s °Ñ±¾¿ìËÙÖ¸ÄÏ´æÏÂÀ´¡£ |
| 475 | Õâ»á°Ñ¡¸Wrote ...TUTORIAL.cn¡¹Õâ¸öѶϢÏÔʾÔÚÓ©Ä»µÄÏ·½¡£ | 453 | Äã»á¿´µ½¡°Wrote ...TUTORIAL.cn¡±ÕâÑùµÄÏûÏ¢ÏÔʾÔÚÆÁÄ»µÄÏ·½¡£ |
| 476 | 454 | ||
| 477 | ×¢Ò⣺ÔÚijЩϵͳÖУ¬¼üÈë C-x C-s ½«»á°ÑÓ©Ä»¶³½á£¬Äú½«¿´²»µ½´Ó Emacs À´ | 455 | ×¢Ò⣺ʹÓÃijЩÖն˵Äʱºò£¬ÊäÈë C-x C-s »á¶³½áÆÁÄ»¡¾ÆÁĻûÓÐÈκÎÊä³ö¡¿£¬ |
| 478 | µÄÈκÎÊä³ö¡£Õâ±íʾ²Ù×÷ϵͳһ¸ö³ÆÎª¡¸Á÷³Ì¿ØÖÆ¡¹µÄ¡¸¹¦ÄÜ¡¹½« C-s Ö¸ÁîÀ¹ | 456 | ÕâÑùÄã¾Í¿´²»µ½ Emacs µÄÈκα仯¡£ÆäÔÒòÊDzÙ×÷ϵͳµÄ¡°Á÷Á¿¿ØÖÆ¡±¹¦ÄÜ°Ñ |
| 479 | ½Ø×¡£¬²¢ÇÒ²»ÈÃËü´«µ½ Emacs¡£ÒªÈ¡ÏûÓ©Ä»µÄ¶³½á£¬Çë¼üÈë C-q¡£È»ºóµ½ Emacs | 457 | C-s À¹½ØÁË£¬²¢ÇÒ¶³½áÁËÆÁÄ»£¬Emacs ×ÔȻҲ¾Í¿´²»µ½Õâ¸öÊäÈëÁË¡£Óà C-q ¿ÉÒÔ |
| 480 | ʹÓÃÊÖ²áÖп´¿´¶Ôì¶¡¸½¥½øÊ½ËÑѰµÄͬʱ½øÈ루 Spontaneous Entry to | 458 | ½â³ýÆÁÄ»¶³½á¡£Òª½â¾öÕâ¸öÎÊÌ⣬Çë²Î¿¼ Emacs ÊÖ²áÀïµÄ¡°Spontaneous Entry |
| 481 | Incremental Search £©¡¹Õâ¸öÖ÷Ì⣬ÒÔÈ¡µÃ´¦ÀíÕâ¸ö¡¸¹¦ÄÜ¡¹µÄ½¨Òé¡£ | 459 | to Incremental Search¡±Ò»½Ú¡¾Emacs ÊÖ²á¿ÉÄÜ»¹Ã»ÓÐÖÐÎÄ·Òë¡¿£¬ÄÇÀï¿ÉÄÜÓÐ |
| 460 | һЩÓÐÓõĽ¨Òé¡£ | ||
| 482 | 461 | ||
| 483 | Äú¿ÉÒÔÕÒ³öÒ»¸öÒѾ´æÔڵĵµ°¸£¬È»ºó¹Û¿´Ëü»ò±à¼Ëü¡£ÄúÒ²¿ÉÒÔÕÒÒ»¸ö»¹Ã»ÓÐ | 462 | Äã¿ÉÒÔѰÕÒÒ»¸öÒÑÓеÄÎļþÈ»ºó²é¿´»òÕ߱༣¬Ä㻹¿ÉÒÔѰÕÒÒ»¸ö²»´æÔÚµÄÎļþ¡£ |
| 484 | ´æÔÚ¹ýµÄµµ°¸¡£ÕâÊÇÒÔ Emacs ½¨Á¢Ò»¸öµµ°¸µÄ·½·¨£ºÕÒÕâ¸öµµ°¸£¬¾Í´ÓÁ㿪ʼ£¬ | 463 | ʵ¼ÊÉÏÕâÕýÊÇÓà Emacs ´´½¨ÐÂÎļþµÄ·½·¨£ºÕÒµ½²»´æÔÚµÄÐÂÎļþ£¬È»ºó´ÓÁ㿪ʼ¡£ |
| 485 | È»ºó¿ªÊ¼²åÈëÎÄ×Öµ½Õâ¸öµµ°¸ÖС£µ±ÄúÒªÇ󡸴¢´æ¡¹Õâ¸öµµ°¸£¬Emacs »áÕæµÄ½¨ | 464 | ÔÚ´æÅ̵Äʱºò£¬Emacs ²ÅÕæÕý´´½¨Õâ¸öÎļþÈ»ºóÔÙ´æÅÌ¡£ÔÚÕâÖ®ºóÒ»Çо͸úÄã±à |
| 486 | Á¢Ò»¸öµµ°¸£¬²¢°ÑÄúËù²åÈëµÄÎÄ×Ö°Úµ½µµ°¸ÖС£´ÓÄÇʱºò¿ªÊ¼£¬Äú¾Í¿ÉÒÔµ±×Ô¼º | 465 | ¼Ò»¸öÒÑÓÐÎļþÒ»ÑùÁË¡£ |
| 487 | ÊÇÔÚ±à¼Ò»¸öÒѾ´æÔڵĵµ°¸ÁË¡£ | ||
| 488 | 466 | ||
| 489 | 467 | ||
| 490 | * »º³åÇø£¨ BUFFER £© | 468 | * »º³åÇø£¨BUFFER£© |
| 491 | -------------------- | 469 | ------------------ |
| 492 | 470 | ||
| 493 | Èç¹ûÄúÒÔ C-x C-f¡¸ÕÒ¡¹µÚ¶þ¸öµµ°¸£¬µÚÒ»¸öµµ°¸ÈÔÈ»´æÔÚ Emacs ÄÚ¡£ÒªÇл» | 471 | Èç¹ûÄãÓà C-x C-f ÕÒµ½µÚ¶þ¸öÎļþ£¬µÚÒ»¸öÎļþÈÔÈ»»áÔÚ Emacs Àï¡£ÒªÇÐ»ØµÚ |
| 494 | »ØËü£¬Äú¿ÉÒÔ C-x C-f ÔÙÕÒËüÒ»´Î¡£ÒÀ´Ë·½Ê½£¬Äú¿ÉÒÔÔÚ Emacs ÄÚ¿ªÆô²»ÉÙµµ | 472 | Ò»¸öÎļþ£¬Äã¿ÉÒÔ C-x C-f ÔÙ´ÎѰÕÒËü¡£ÕâÑù£¬Äã¿ÉÒÔÔÚ Emacs Àïͬʱ´ò¿ªºÜ |
| 495 | °¸¡£ | 473 | ¶àÎļþ¡£ |
| 496 | 474 | ||
| 497 | >> ÒÔ¼üÈë C-x C-f foo <Return> µÄ·½Ê½½¨Á¢Ò»¸öÃûΪ¡¸foo¡¹µÄµµ°¸¡£ | 475 | >> Óà C-x C-f foo <Return> µÄ·½Ê½½¨Á¢Ò»¸öÃûΪ¡°foo¡±µÄÎļþ¡£ |
| 498 | È»ºó²åÈëһЩÎÄ×Ö£¬±à¼Ëü£¬È»ºóÔÙÒÔ C-x C-s ´¢´æ¡¸foo¡¹¡£ | 476 | È»ºóÇÃÈëһЩÎÄ×Ö£¬ÔÙÓà C-x C-s ±£´æÎļþ¡°foo¡±¡£ |
| 499 | ×îºó£¬¼üÈë C-x C-f TUTORIAL.cn <Return> »Øµ½±¾¿ìËÙÖ¸ÄÏ¡£ | 477 | ×îºó£¬ÊäÈë C-x C-f TUTORIAL.cn <Return> »Øµ½ÕâÀï¡£ |
| 500 | 478 | ||
| 501 | Emacs ´¢´æÃ¿¸öµµ°¸µÄÎÄ×ÖÔÚÒ»¸ö³ÆÎª¡¸»º³åÇø£¨ buffer £©¡¹µÄÎï¼þÖС£ÕÒÒ» | 479 | Emacs °Ñÿ¸ö±à¼ÖеÄÎļþ¶¼·ÅÔÚÒ»¸ö³ÆÎª¡°»º³åÇø£¨buffer£©¡±µÄµØ·½¡£Ã¿Ñ° |
| 502 | ¸öµµ°¸»áÔÚ Emacs ÄÚ²¿½¨Á¢Ò»¸ö»º³åÇø¡£ÏëÒª¿´Ä¿Ç°´æÔÚÄúµÄ Emacs µÄ¹¤×÷ÖÐ | 480 | ÕÒµ½Ò»¸öÎļþ£¬Emacs ¾ÍÔÚÆäÄÚ²¿¿ª±ÙÒ»¸ö»º³åÇø¡£ÓÃÏÂÃæµÄÃüÁî¿ÉÒÔÁгöµ±Ç° |
| 503 | »º³åÇøÁÐ±í£¬¼üÈë | 481 | ËùÓеĻº³åÇø£º |
| 504 | 482 | ||
| 505 | C-x C-b Áгö»º³åÇø | 483 | C-x C-b Áгö»º³åÇø |
| 506 | 484 | ||
| 507 | >> ÏÖÔÚ¾ÍÊÔһϠC-x C-b | 485 | >> ÏÖÔÚ¾ÍÊÔһϠC-x C-b |
| 508 | 486 | ||
| 509 | ¿´¿´Ã¿Ò»¸ö»º³åÇøÊÇÈçºÎÃüÃûµÄ£¬ËüÒ²¿ÉÄÜͬʱӵÓÐÒ»¸ö¡¸´¢´æÆäÄÚÈݵĵµ°¸¡¹ | 487 | ¹Û²ìһϻº³åÇøÊÇÈçºÎÃüÃûµÄ£¬ËüºÜ¿ÉÄܸúÆä¶ÔÓ¦µÄÎļþͬÃû¡£ÊÂʵÉÏ£¬ÄãÔÚÒ» |
| 510 | µÄÃû³Æ¡£ÄúÔÚÒ»¸ö Emacs ´°¸ñËù¼ûµ½µÄ¡¸ÈκΡ¹ÎÄ×Ö¶¼ÊÇij¸ö»º³åÇøµÄÒ»²¿·Ý¡£ | 488 | ¸ö Emacs ´°¸ñÀï¿´µ½µÄÈκÎÎÄ×Ö¶¼ÊÇij¸ö»º³åÇøµÄÒ»²¿·Ö¡£ |
| 511 | 489 | ||
| 512 | >> ¼üÈë C-x 1 ÒÔÀ뿪»º³åÁбí | 490 | >> ÊäÈë C-x 1 À뿪»º³åÇøÁбí |
| 513 | 491 | ||
| 514 | µ±ÄúÓÐÊý¸ö»º³åÇøÊ±£¬ÔÚÈκÎʱºòÆäÖÐÖ»ÓÐÒ»¸öÊÇ¡¸Ä¿Ç°×÷Óõġ¹¡£¶øÄǸö¾ÍÊÇ | 492 | ²»¹Ü´æÔÚ¶àÉÙ»º³åÇø£¬ÈκÎʱºò¶¼Ö»ÄÜÓÐÒ»¸öÊÇ¡°µ±Ç°¡±»º³åÇø£¬Ò²¾ÍÊÇÄãÕýÔÚ |
| 515 | ÄúÔڱ༵Ļº³åÇø¡£Èç¹ûÄúÏëÒª±à¼ÁíÒ»¸ö»º³åÇø£¬ÄÇôÄú±ØÐ롸Çл»¡¹µ½Ëü¡£ | 493 | ±à¼µÄÕâ¸ö¡£Èç¹ûÄãÏë±à¼ÁíÍâÒ»¸ö»º³åÇø£¬ÄÇôÄã±ØÐë¡°Çл»¡±¹ýÈ¥¡£ÉÏÃæ½² |
| 516 | Èç¹ûÄúÏëÒªÇл»µ½Á¬½Óµ½Ä³¸öµµ°¸µÄ»º³åÇø£¬Äú¿ÉÒÔÓà C-x C-f ÔٴΰݷÃÄǸö | 494 | ¹ý£¬Óà C-x C-f ¿ÉÒÔÇл»µ½Ä³¸öÎļþ¶ÔÓ¦µÄ»º³åÇø¡£²»¹ý»¹ÓÐÒ»¸ö¸ü¼òµ¥µãµÄ°ì |
| 517 | µµ°¸¡£µ«ÊÇÓиö±È½Ï¼òµ¥µÄ·½Ê½£ºÊ¹Óà C-x b £»ÔÚÕâ¸öÖ¸ÁîÖУ¬Äú±ØÐë¼üÈ뻺 | 495 | ·¨£¬ÄǾÍÊÇÓà C-x b¡£ÓÃÕâ¸öÃüÁÄã±ØÐëÊäÈ뻺³åÇøµÄÃû³Æ¡£ |
| 518 | ³åÇøµÄÃû³Æ¡£ | ||
| 519 | 496 | ||
| 520 | >> ¼üÈë C-x b foo <Return> ÒԻص½º¬Óеµ°¸¡¸foo¡¹µÄÎÄ×ֵĻº³åÇø¡£ | 497 | >> ÊäÈë C-x b foo <Return> ÒԻص½Îļþ¡°foo¡±µÄ»º³åÇø¡£ |
| 521 | È»ºó½¨Èë C-x b TUTORIAL <Return> ÒԻص½±¾¿ìËÙÖ¸ÄÏ¡£ | 498 | È»ºóÊäÈë C-x b TUTORIAL.cn <Return> »Øµ½ÕâÀï¡£ |
| 522 | 499 | ||
| 523 | ¾Í´ó²¿·ÝµÄÇé¿öÀ´Ëµ£¬»º³åÇøµÄÃû³ÆÓëµµ°¸µÄÃû³ÆÊÇÏàͬµÄ£¨³ýÈ¥Á˵µÃûÖеÄÄ¿ | 500 | ´ó¶àÊýÇé¿öÏ£¬»º³åÇøºÍÓëÆä¶ÔÓ¦µÄÎļþÊÇͬÃûµÄ£¨²»°üÀ¨Ä¿Â¼Ãû£©£¬²»¹ýÕâÒ² |
| 524 | ¼²¿·Ý£©¡£È»¶ø²¢²»×ÜÊÇÈç´Ë¡£ÄúÒÔ C-x C-b ËùÖÆ×÷³öµÄ»º³åÇøÁбí×ÜÊÇ»áÏÔ | 501 | ²»ÊǾø¶ÔµÄ¡£Óà C-x C-b µÃµ½µÄ»º³åÇøÁбíÖÐÏÔʾµÄ×ÜÊÇ»º³åÇøµÄÃû³Æ¡£ |
| 525 | ʾ¸øÄúÿһ¸ö»º³åÇøµÄÃû³Æ¡£ | ||
| 526 | 502 | ||
| 527 | ÄúÔÚÒ»¸ö Emacs ´°¸ñÖÐËù¼ûµ½µÄ¡¸ÈκΡ¹ÎÄ×Ö×ÜÊÇij¸ö»º³åÇøµÄÒ»²¿·Ý¡£ÓÐÒ» | 503 | ÄãÔÚ Emacs ´°¸ñÀï¿´µ½µÄ¡°ÈκΡ±ÎÄ×Ö¶¼Ò»¶¨ÊÇÊôÓÚij¸ö»º³åÇøµÄ¡£Ò²ÓÐЩ»º³å |
| 528 | Щ»º³åÇø²¢Ã»ÓÐÁ¬½Óµ½µµ°¸¡£¾ÙÀýÀ´Ëµ£¬ÃüÃûΪ¡¸*Buffer List*¡¹µÄ»º³åÇø²¢ | 504 | Çø²¢Ã»ÓжÔÓ¦Îļþ£º±ÈÈçÏÔʾ»º³åÇøÁбíµÄ»º³åÇø¾ÍÊÇÕâÑù£¬ÔÙ±ÈÈçÒ»¸öÃû½Ð |
| 529 | ûÓÐÈκεµ°¸¡£ËüÊǰüº¬ÓÐÄúÒÔ C-x C-b Ö¸ÁîËùÖÆ×÷³öÀ´µÄ»º³åÇøÁбíµÄ»º³å | 505 | ¡°*Messages*¡±µÄ»º³åÇøÒ²Ã»ÓжÔÓ¦µÄÎļþ£¬Õâ¸ö»º³åÇøÀï´æ·ÅµÄ¶¼ÊÇÔÚ Emacs |
| 530 | Çø¡£ÃüÃûΪ¡¸*Messages*¡¹µÄ»º³åÇøÒ²Ã»ÓÐÁ¬½Óµ½Èκεµ°¸£»ËüÔÚÄúµÄ Emacs | 506 | µ×²¿³öÏÖµÄÏûÏ¢¡£ |
| 531 | ²Ù×÷½×¶ÎÖаüº¬³öÏÖÔÚµ×ÐеÄѶϢ¡£ | ||
| 532 | 507 | ||
| 533 | >> ¼üÈë C-x b *Messages* <Return> À´¿´¿´Ñ¶Ï¢µÄ»º³åÇø¡£ | 508 | >> ÊäÈë C-x b *Messages* <Return> ³ò³òÏûÏ¢»º³åÇøÀï¶¼ÓÐʲô¶«Î÷¡£ |
| 534 | È»ºó¼üÈë C-x b TUTORIAL <Return> »Øµ½±¾¿ìËÙÖ¸ÄÏ¡£ | 509 | È»ºóÔÙÊäÈë C-x b TUTORIAL.cn <Return> »Øµ½ÕâÀï¡£ |
| 535 | 510 | ||
| 536 | Èç¹ûÄú¶Ôµµ°¸ÖеÄÎÄ×Ö×öÁËÐ޸ģ¬È»ºóÕÒÁíÒ»µµ°¸£¬Õâ¸ö¶¯×÷²¢²»»á´¢´æµÚÒ»¸ö | 511 | Èç¹ûÄã¶ÔÎļþ×öÁËÐ޸ģ¬È»ºóÇл»µ½ÁíÒ»¸öÎļþ£¬Õâ¸ö¶¯×÷²¢²»»á°ïÄã°ÑµÚÒ»¸ö |
| 537 | µµ°¸¡£ËüµÄÐÞ¸ÄÈԾɴæÔÚ Emacs ÖУ¬Ò²¾ÍÊÇÔÚÄǸöµµ°¸µÄ»º³åÇøÖС£¶Ôì¶µÚ¶þ | 512 | Îļþ´æÅÌ£¬¶ÔµÚÒ»¸öÎļþµÄÐÞ¸ÄÈÔÈ»½öÏÞÓÚ Emacs ÖУ¬Ò²¾ÍÊÇÔÚËü¶ÔÓ¦µÄ»º³åÇø |
| 538 | ¸öµµ°¸µÄ½¨Á¢»ò±à¼²¢²»»áÓ°Ïìµ½µÚÒ»¸öµµ°¸µÄ»º³åÇø¡£ÕâÑù×ӷdz£ÓÐÓ㬵«Õâ | 513 | Àͬʱ¶ÔµÚ¶þ¸öÎļþµÄÐÞ¸ÄÒ²²»»áÓ°Ïìµ½µÚÒ»¸öÎļþ¡£ÕâºÜÓÐÓ㬵«ÊÇҲͦÂé |
| 539 | ¸öÇéÐÎÒ²±íÃ÷ÁËÄúÐèÒª¡¸Ò»¸ö·½±ãµÄ·½·¨¡¹À´´¢´æµÚÒ»¸öµµ°¸µÄ»º³åÇø¡£Ö»ÊÇΪ | 514 | ·³£¬ÒòΪÈç¹ûÄãÓÖÏëÒª´æ´¢µÚÒ»¸öÎļþ£¬Ä㻹ÐèÒªÏÈÓà C-x C-f Çл»»ØÈ¥£¬È»ºó |
| 540 | ´¢´æµÚÒ»¸öµµ°¸¾Í±ØÐëÒÔ C-x C-f Çл»»º³åÇø£¬²ÅÄÜÒÔ C-x C-s ½«Ëü´¢´æ£¬×Ü | 515 | ÔÙÓà C-x C-s ´æÅÌ£¬ÕâÏÔȻ̫Âé·³ÁË¡£ÄãÐèÒªÒ»¸ö¸ü¼ò±ãµÄ·½·¨£¬¶ø Emacs µ± |
| 541 | ÊǸöÈÃÈËÌÖÑáµÄ¹ý³Ì¡£Òò´ËÎÒÃÇÓÐ | 516 | È»ÒÑ¾ÌæÄãÏëµ½ÁË£º |
| 542 | 517 | ||
| 543 | C-x s ´¢´æÒ»Ð©»º³åÇø | 518 | C-x s ±£´æ¶à¸ö»º³åÇø |
| 544 | 519 | ||
| 545 | C-x s »áѯÎÊÄú¹Øì¶ÄúÒÑ×ö³öÐ޸ĵ«»¹Ã»´¢´æµÄÿһ¸ö»º³åÇø¡£Ëü»áÎÊÄú£¬¶Ôì¶ | 520 | C-x s »áÕÒµ½ËùÓÐÒѱ»Ð޸ĵ«ÉÐδ´æÅ̵Ļº³åÇø£¬È»ºóÏòÄãÖð¸öѯÎÊ£¬ÊÇ·ñÐèÒª |
| 546 | ÿһ¸öÕâÑùµÄ»º³åÇø£¬ÊÇ·ñÒª´¢´æ£¿ | 521 | ´æÅÌ£¿ |
| 547 | 522 | ||
| 548 | >> ²åÈëÒ»ÐÐÎÄ×Ö£¬È»ºó¼üÈë C-x s¡£ | 523 | >> ²åÈëÒ»ÐÐÎÄ×Ö£¬È»ºóÊäÈë C-x s¡£ |
| 549 | ËüÓ¦¸Ã»áÎÊÄúÊÇ·ñÒª´¢´æÃûΪ TUTORIAL.cn µÄ»º³åÇø¡£ | 524 | ËüÓ¦¸Ã»áÎÊÄ㣬ÊÇ·ñÒª´¢´æÃûΪ TUTORIAL.cn µÄ»º³åÇø£¿ |
| 550 | ¼üÈ롺y¡»ÒԻشðÒª´¢´æ¡£ | 525 | °´¡°y¡±¸æËßËüÄãÏë´æÅÌ¡£ |
| 551 | 526 | ||
| 552 | 527 | ||
| 553 | * À©³äÖ¸Á£¨ EXTENDING THE COMMAND SET £© | 528 | * ÃüÁÀ©Õ¹£¨EXTENDING THE COMMAND SET£© |
| 554 | ------------------------------------------- | 529 | ----------------------------------------- |
| 555 | 530 | ||
| 556 | ÓÉì¶ Emacs ÓµÓÐÌ«¶àÖ¸Á¼´±ãʹÓÃÉÏËùÓÐµÄ CONTROL ºÍ META ×ÖÔª£¬Ò²Ã»°ì | 531 | Emacs µÄÃüÁî¾ÍÏñÌìÉϵÄÐÇÐÇ£¬ÊýÒ²Êý²»Çå¡£°ÑËüÃǶ¼¶ÔÓ¦µ½ CONTROL ºÍ META |
| 557 | ·¨ÍêÈ«°ÚÉÏ¡£Emacs ÒÔ X£¨À©³ä¡ºeXtend¡»£©Ö¸ÁîÀ´½â¾öÕâ¸öÎÊÌâ¡£À©³äÖ¸ÁîÓÐ | 532 | ×éºÏ¼üÉÏÏÔÈ»ÊDz»¿ÉÄܵÄÊÂÇé¡£Emacs ÓÃÀ©Õ¹£¨eXtend£©ÃüÁîÀ´½â¾öÕâ¸öÎÊÌ⣬ |
| 558 | Á½ÖÖÐÍʽ£º | 533 | À©Õ¹ÃüÁîÓÐÁ½ÖÖ·ç¸ñ£º |
| 559 | 534 | ||
| 560 | C-x ×ÖÔªÀ©³ä¡£ºóÃæ¸úÖøÒ»¸ö×ÖÔª¡£ | 535 | C-x ×Ö·ûÀ©Õ¹¡£ C-x Ö®ºóÊäÈëÁíÒ»¸ö×Ö·û»òÕß×éºÏ¼ü¡£ |
| 561 | M-x ÓÐÃû³ÆµÄÖ¸ÁîÀ©³ä¡£ºóÃæ¸úÖøÒ»¸ö³¤µÄÃû³Æ¡£ | 536 | M-x ÃüÁîÃûÀ©Õ¹¡£M-x Ö®ºóÊäÈëÒ»¸öÃüÁîÃû¡£ |
| 562 | 537 | ||
| 563 | »¹ÓÐһЩָÁîͨ³£À´ËµÊǺÜÓÐÓõ쬵«ÊDZÈÄúÒѾѧµ½µÄÖ¸Áî½ÏÉÙʹÓá£ÄúÒѾ | 538 | ºÜ¶àÀ©Õ¹ÃüÁî¶¼ºÜÓÐÓã¬ËäÈ»ÓëÄãÒѾѧ¹ýµÄÃüÁî±ÈÆðÀ´£¬ËûÃÇ¿ÉÄܲ»ÄÇô³£Óᣠ|
| 564 | ¿´¹ýÆäÖÐÁ½¸ö£ºµµ°¸Ö¸ÁîÖÐµÄ C-x C-f ȥѰÕÒ£¬ÒÔ¼° C-x C-s È¥´¢´æ¡£ÆäËûµÄ | 539 | ÄãÓ¦¸ÃÒѾ¼û¹ýһЩÀ©Õ¹ÃüÁîÁË£¬±ÈÈçÓà C-x C-f ѰÕÒÎļþºÍÓà C-x C-s ±£´æ |
| 565 | Àý×ÓÔòÓнáÊø Emacs ½×¶ÎµÄÖ¸Áî -- Õâ¸öÖ¸ÁîÊÇ C-x C-c¡££¨²»Òªµ£ÐÄÄú»áʧ | 540 | Îļþ¡£Í˳ö Emacs ÓÃµÄ C-x C-c Ò²ÊÇÀ©Õ¹ÃüÁî¡££¨²»Óõ£ÐÄÍ˳ö Emacs »á¸øÄã |
| 566 | È¥ÒѾ×ö³öµÄ¸Ä±ä£¬C-x C-c ÔÚËüɱµô Emacs ֮ǰ»áÌṩ´¢´æÃ¿Ò»¸ö±ä¶¯µÄµµ | 541 | ´øÀ´Ê²Ã´Ëðʧ£¬Emacs »áÔÚÍ˳ö֮ǰÌáÐÑÄã±£´æÎļþµÄ£© |
| 567 | °¸µÄ»ú»á¡££© | ||
| 568 | 542 | ||
| 569 | C-z ÊÇ *ÔÝʱ* À뿪 Emacs µÄÖ¸Áî -- Òò´ËÄúÉÔºó¿ÉÒԻص½Í¬ÑùµÄ Emacs ½×¶Î¡£ | 543 | ÔÚ¿ØÖÆÌ¨Ï£¬C-z ¿ÉÒÔÔÝʱÀ뿪 Emacs¡ª¡ªµ±È»£¬Ä㻹¿ÉÒÔÔÙ»ØÀ´¡£ |
| 570 | 544 | ||
| 571 | ÔÚijЩÔÊÐíËüµÄ×÷ÓõÄϵͳÖУ¬ C-z »á¡¸ÔÝͣס£¨ suspends £©¡¹Emacs£¬Ò²¾Í | 545 | ÔÚÔÊÐí C-z µÄϵͳÖУ¬C-z »á°Ñ Emacs¡°¹ÒÆð¡±£¬Ò²¾ÍÊÇ˵£¬Ëü»á»Øµ½ shell |
| 572 | ÊÇ˵£¬Ëü»á»Øµ½ shell µ«²»»á°Ñ Emacs »Ùµô¡£ÔÚ×î³£ÓÃµÄ shell ÖУ¬Äú¿ÉÒÔ | 546 | µ«²»Í˳ö Emacs¡£ÔÚÄÇЩ×î³£ÓÃµÄ shell ÖУ¬Í¨³£¿ÉÒÔÓá°fg¡±»òÕß¡°%emacs¡± |
| 573 | Óáºfg¡»»ò¡º%emacs¡»Á½ÖÖÖ¸Áî»Ö¸´ Emacs¡£ | 547 | ÃüÁîÔٴλص½ Emacs ÖС£ |
| 574 | 548 | ||
| 575 | ÔÚûÓÐÌṩÔÝÍ£¹¦ÄܵÄϵͳÖУ¬C-z »áÔÚ Emacs µ×Ͻ¨Á¢Ò»¸ö subshell ÒÔÈà | 549 | ÔÚûÓÐÌṩ¹ÒÆð¹¦ÄܵÄϵͳÖУ¬C-z »áÔÚ Emacs ֮ϴ´½¨Ò»¸ö×Ó shell À´ÈÃÄã |
| 576 | ÄúÓлú»áÖ´ÐÐÆäËûµÄ³Ìʽ£¬²¢ÇÒÔÚÉÔºó»Øµ½ Emacs£¬Ëü²¢Ã»ÓÐÕæµÄÀ뿪 Emacs¡£ | 550 | ÔËÐÐÆäËü³ÌÐò£¬²¢ÇÒÔٴΡ°»Øµ½¡± Emacs ÖСª¡ªËäÈ»ÎÒÃDz¢Ã»ÓÐÕæÕýÀ뿪¹ý¡£Õâ |
| 577 | ÔÚÕâ¸öÀý×ÓÖУ¬shell Ö¸Áexit¡»ÊÇ´Ósubshell »Øµ½ Emacs µÄͨ³£·½Ê½¡£ | 551 | ÖÖÇé¿öÏ£¬Í¨³£ÓÃshell ÃüÁî¡°exit¡±´Ó×Ó shell »Øµ½ Emacs¡£ |
| 578 | 552 | ||
| 579 | ʹÓà C-x C-c µÄʱ»úÊǵ±Äú´òËãÒªµÇ³öʱ¡£ËüÒ²·Ç³£ÊʺÏÓÃÀ´À뿪±»ÆäËûÓʼþ | 553 | C-x C-c ×îºÃÔÚÄã´òËãÍ˳öµÇ½µÄʱºòÔÙÓá£ÔÚ Emacs ±»ÖîÈçÓʼþ´¦Àí³ÌÐòÖ®Àà |
| 580 | ´¦Àí³Ìʽ£¬ÒÔ¼°Ðí¶à²»Í¬µÄÓ¦ÓóÌʽËùÆô¶¯µÄ Emacs¡£È»¶øÔÚÒ»°ãµÄ×´¿öÏ£¬Èç | 554 | µÄÍⲿ³ÌÐòµ÷ÓÃÖ®ºó£¬Ò²¿ÉÒÔÓà C-x C-c Í˳ö¡£²»¹ýÒ»°ãÀ´½²£¬Èç¹ûÄã²»ÏëÍ˳ö |
| 581 | ¹ûÄú²»´òËãµÇ³ö£¬×îºÃÊÇ°Ñ Emacs ÔÝÍ£¶ø²»ÊÇÀ뿪Ëü¡£ | 555 | µÇ¼£¬×îºÃ»¹ÊÇ°Ñ Emacs ¹ÒÆð¶ø²»ÊÇÍ˳ö¡£ |
| 582 | 556 | ||
| 583 | ÓÐÐí¶à C-x µÄÖ¸Áî¡£ÕâÀïÊÇÒ»·ÝÄúÒѾѧ¹ýµÄÁÐ±í£º | 557 | C-x µÄÀ©Õ¹ÃüÁîÓкܶ࣬ÏÂÃæÁгöµÄÊÇÄãÒѾѧ¹ýµÄ£º |
| 584 | 558 | ||
| 585 | C-x C-f ÕÒµµ°¸¡£ | 559 | C-x C-f ѰÕÒÎļþ¡£ |
| 586 | C-x C-s ´¢´æµµ°¸¡£ | 560 | C-x C-s ±£´æÎļþ¡£ |
| 587 | C-x C-b Áгö»º³åÇø¡£ | 561 | C-x C-b Áгö»º³åÇø¡£ |
| 588 | C-x C-c À뿪 Emacs¡£ | 562 | C-x C-c À뿪 Emacs¡£ |
| 589 | C-x 1 ³ýÁËÒ»¸öÍ⣬ɾȥÆäËûËùÓеĴ°¸ñ¡£ | 563 | C-x 1 ¹ØµôÆäËüËùÓд°¸ñ£¬Ö»±£ÁôÒ»¸ö¡£ |
| 590 | C-x u È¡Ïû¶¯×÷¡£ | 564 | C-x u ³·Ïú¡£ |
| 591 | 565 | ||
| 592 | ÒÔÀ©³äÀ´ÃüÃûµÄÖ¸Áîͨ³£ÊDz»Ì«³£Ê¹ÓõÄÖ¸Á»òÊÇÖ»ÔÚÌØ¶¨µÄģʽϲŻáʹÓà | 566 | ÓÃÃüÁîÃûÀ©Õ¹µÄÃüÁîÒ»°ã¶¼²»Ì«³£Ó㬻òÕßÖ»ÔÚ²¿·Öģʽϱ»Óõ½¡£±ÈÈç |
| 593 | µÄÖ¸Áî¡£Ò»¸öÀý×ÓÊÇÈ¡´ú×Ö´®Ö¸ÁËü»áÈ«ÓòµØ½«Ò»¸ö×Ö´®ÒÔÁíÒ»¸öÀ´È¡´ú¡£µ± | 567 | replace-string£¨×Ö·û´®Ìæ»»£©Õâ¸öÃüÁËü»áÔÚÈ«ÎÄ·¶Î§ÄÚ°ÑÒ»¸ö×Ö·û´®Ìæ»» |
| 594 | Äú¼üÈë M-x ʱ£¬Emacs »áÔÚÓ©Ä»µÄµ×¶ËѯÎÊÄú£¬È»ºóÄúÒ²Ó¦¸Ã¼üÈëÕâ¸öÖ¸ÁîµÄ | 568 | ³ÉÁíÒ»¸ö¡£ÔÚÄãÊäÈë M-x µÄʱºò£¬Emacs »áÔÚÆÁÄ»µ×¶ËÏòÄãѯÎÊ£¬È»ºóÄãÓ¦¸ÃÊä |
| 595 | Ãû³Æ¡£ÔÚÕâ¸öÀý×ÓÖÐÊÇ¡ºreplace-string¡»Ö»Òª¼üÈ롺repl s<TAB>¡»£¬È»ºó | 569 | ÈëÃüÁîÃû¡£Èç¹ûÄãÏëÊäÈë¡°replace-string¡±£¬ÆäʵֻÐèÒªÇá°repl s<TAB>¡±¾Í |
| 596 | Emacs ½«»á²¹ÆëÕâ¸öÃû³Æ¡£ÒÔ <Return> À´½áÊøÕâ¸öÖ¸ÁîÃû³Æ¡£ | 570 | ÐÐÁË£¬Emacs »á°ïÄã×Ô¶¯²¹ÆëµÄ¡£ÊäÈëÍêÖ®ºó°´ <Return> ¡£ |
| 597 | 571 | ||
| 598 | È¡´ú×Ö´®Ö¸ÁîÐèÒªÁ½¸ö²ÎÊý -- ±»È¡´úµÄ×Ö´®ÒÔ¼°ÓÃÀ´È¡´úËüµÄ×Ö´®¡£Äú±ØÐëÒÔ | 572 | ×Ö·û´®Ìæ»»ÃüÁîÐèÒªÁ½¸ö²ÎÊý¡ª¡ª±»Ìæ»»µÄ×Ö·û´®ºÍÓÃÀ´Ìæ»»ËüµÄ×Ö·û´®¡£Ã¿¸ö |
| 599 | Newline ×ÖÔªÀ´½áÊøÃ¿Ò»¸ö²ÎÊý¡£ | 573 | ²ÎÊýµÄÊäÈëÓû»ÐзûÀ´½áÊø¡£ |
| 600 | 574 | ||
| 601 | >> ½«ÓαêÒÆµ½±¾ÐеÄÏÂÁ½Ðпհף¬È»ºó¼üÈë | 575 | >> ½«¹â±êÒÆµ½±¾ÐеÄÏÂÁ½Ðпհף¬È»ºóÊäÈë |
| 602 | M-x repl s<Return>changed<Return>altered<Return>¡£ | 576 | M-x repl s<Return>changed<Return>altered<Return>¡£ |
| 603 | 577 | ||
| 604 | ¡¾ÎªÁË˵Ã÷µÄÄ¿µÄ£¬ì¶Ï±£ÁôÒ»ÐÐÔÎÄ¡£ | 578 | ¡¾ÎªÁ˼ÌÐøÁ·Ï°£¬±£ÁôÒ»ÐÐÔÎÄÈçÏ£º |
| 605 | Notice how this line has changed: you've replaced... ¡¿ | 579 | Notice how this line has changed: you've replaced... ¡¿ |
| 606 | 580 | ||
| 607 | Çë×¢ÒâÕâÒ»ÐÐÊÇÔõô¸Ä±äµÄ£ºÔÚÓαêµÄÆðʼλÖÃÖ®ºó£¬ÄúÒѾ½« c-h-a-n-g-e-d | 581 | Çë×¢ÒâÕâÒ»ÐÐÊÇÔõô¸Ä±äµÄ£ºÔÚ¹â±êÖ®ºóµÄ·¶Î§ÄÚ£¬ÄãÒѾ½«¡°changed¡±Õâ¸ö |
| 608 | Õâ¸ö×Ö -- ²»¹ÜËüÔÚÄÄÀï³öÏÖ -- ÒÔ¡¸altered¡¹Õâ¸ö×ÖÀ´È¡´úÁË¡£ | 582 | ´Ê¡ª¡ª²»¹ÜËüÔÚÄÄÀï³öÏÖ¡ª¡ªÈ«²¿Óá°altered¡±Ìæ»»µôÁË¡£ |
| 609 | 583 | ||
| 610 | 584 | ||
| 611 | * ×Ô¶¯´æµµ£¨ AUTO SAVE £© | 585 | * ×Ô¶¯±£´æ£¨AUTO SAVE£© |
| 612 | ------------------------- | 586 | ----------------------- |
| 613 | 587 | ||
| 614 | µ±ÄúÔÚÒ»¸öµµ°¸ÖÐ×öÁËÐ޸쬵«ÊÇ»¹Ã»Óн«ËüÃÇ´¢´æÆðÀ´£¬ÄÇôÈç¹ûÄúµÄµçÄÔµ± | 588 | Èç¹ûÄãÐÞ¸ÄÁËÒ»¸öÎļþµ«ÊÇ»¹Ã»À´µÃ¼°´æÅÌ£¬È»ºóÄãµÄ¼ÆËã»ú°Õ¹¤ÁË£¬ÄÇôÄã±à |
| 615 | »ú£¬ËüÃǽ«ÓпÉÄÜÒÅʧ¡£ÎªÁ˱ÜÃâÕâÖÖÇéÐη¢ÉúÔÚÄúµÄÉíÉÏ£¬Emacs »á¶¨ÆÚµØ½« | 589 | ¼µÄ¶«Î÷ºÜ¿ÉÄܾÍÕÒ²»»ØÀ´ÁË¡£ÎªÁ˱ÜÃâÕâÑùµÄ²»ÐÒÒ»ÔÙ·¢Éú£¬Emacs »á¶¨ÆÚ½« |
| 616 | ÄúÕýÔڱ༵ĵµ°¸Ð´È롸×Ô¶¯´¢´æ¡¹µµ°¸ÖС£×Ô¶¯´¢´æµµ°¸ÔÚµµÃûµÄǰºó»á¸÷ÓÐ | 590 | ÄãÕýÔڱ༵ÄÎļþ´æÈëÒ»¸ö¡°×Ô¶¯±£´æ¡±ÎļþÖС£×Ô¶¯±£´æµÄÎļþÃûµÄͷβ¸÷ÓÐ |
| 617 | Ò»¸ö # ·ûºÅ£»¾ÙÀýÀ´Ëµ£¬Èç¹ûÄúµÄµµ°¸ÃûΪ¡¸hello.c¡¹£¬ÄÇôËüµÄ×Ô¶¯´¢´æµµ | 591 | Ò»¸ö¡°#¡±×Ö·û£¬±ÈÈçÄãÕýÔڱ༡°hello.c¡±£¬ÄÇôËüµÄ×Ô¶¯±£´æÎļþ¾Í½Ð |
| 618 | °¸µÄµµÃû¾ÍÊÇ¡¸#hello.c#¡¹¡£µ±ÄúÒÔÆ½³£µÄ·½Ê½´¢´æµµ°¸Ê±£¬Emacs ¾Í»á°ÑËü | 592 | ¡°#hello.c#¡±¡£ÔÚÄãÕý³£´æÅÌÖ®ºó£¬Emacs »áɾ³ý×Ô¶¯±£´æÎļþ¡£ |
| 619 | µÄ×Ô¶¯´¢´æµµÉ¾³ý¡£ | ||
| 620 | 593 | ||
| 621 | Èç¹ûµ±»ú£¬Äú¿ÉÒÔ¾ÓÉÕý³£µØÑ°ÕÒµµ°¸£¬£¨Ö¸µÄÊÇÄúÔڱ༵ĵµ°¸¶ø²»ÊÇ×Ô¶¯´¢ | 594 | ¼ÙÈç²»ÐÒÕæµÄ·¢ÉúÁË£¬Äã´ó¿ÉÒÔ´ÓÈݵĴò¿ªÔÀ´µÄÎļþ£¨×¢Òâ²»ÊÇ×Ô¶¯±£´æÎļþ£© |
| 622 | ´æµµ£©È»ºó¼üÈë M-x recover file<Return> À´»Ø¸´ÄúµÄ×Ô¶¯´¢´æµµ¡£µ±ËüÒªÇó | 595 | È»ºóÊäÈë M-x recover file<Return> À´»Ö¸´ÄãµÄ×Ô¶¯±£´æÎļþ¡£ÔÚÌáʾȷÈ쵀 |
| 623 | È·ÈÏʱ£¬¼üÈë yes<Return> ÒÔ¼ÌÐø²¢»Ø¸´×Ô¶¯´¢´æµÄ×ÊÁÏ¡£ | 596 | ʱºò£¬ÊäÈë yes<Return> ¾ÍÐÐÁË¡£ |
| 624 | 597 | ||
| 625 | 598 | ||
| 626 | * »ØÓ¦Çø£¨ ECHO AREA £© | 599 | * »ØÏÔÇø£¨ECHO AREA£© |
| 627 | ----------------------- | 600 | --------------------- |
| 628 | 601 | ||
| 629 | Èç¹û Emacs ¼ûµ½ÄúºÜÂýµØ¼üÈë¶à×ÖÔªÖ¸ÁËü»á½«ËüÃÇÏÔʾÔÚλ춴°¸ñÏ·½£¬ | 602 | Èç¹û Emacs ·¢ÏÖÄãÊäÈë¶à×Ö·ûÃüÁîµÄ½Ú×àºÜÂý£¬Ëü»áÔÚ´°¸ñµÄÏ·½³ÆÎª¡°»ØÏÔÇø¡± |
| 630 | ³ÆÎª¡¸»ØÓ¦Çø¡¹µÄÇøÓò¸øÄú²ÎÔÄ¡£»ØÓ¦ÇøÎ»ÔÚ´°¸ñµÄ×îºóÒ»ÐС£ | 603 | µÄµØ·½¸øÄãÌáʾ¡£»ØÏÔÇøÎ»ÓÚÆÁÄ»µÄ×îºóÒ»ÐС£ |
| 631 | 604 | ||
| 632 | 605 | ||
| 633 | * ״̬ÐУ¨ MODE LINE £© | 606 | * ״̬À¸£¨MODE LINE£© |
| 634 | ----------------------- | 607 | --------------------- |
| 635 | |||
| 636 | λÔÚ»ØÓ¦ÇøµÄÕýÉÏÃæÊdzÆÎª¡¸×´Ì¬ÐС¹µÄÒ»ÐС£×´Ì¬ÐÐÏÔʾ³öһЩÐÅÏ¢£¬È磺 | ||
| 637 | 608 | ||
| 638 | --:** TUTORIAL.cn (Fundamental)--L670--58%---------------- | 609 | λÓÚ»ØÏÔÇøµÄÕýÉÏ·½µÄÒ»Ðб»³ÆÎª¡°×´Ì¬À¸¡±¡£×´Ì¬À¸ÉÏ»áÏÔʾһЩÐÅÏ¢£¬±ÈÈ磺 |
| 639 | 610 | ||
| 640 | ±¾ÐÐÌṩһЩ¹Øì¶¡¸Emacs µÄ״̬¡¹ÒÔ¼°¡¸ÄúÕýÔڱ༵ÄÎÄ×Ö¡¹µÄÓÐÓÃÐÅÏ¢¡£ | 611 | --:** TUTORIAL.cn (Fundamental)--L670--54%---------------- |
| 641 | 612 | ||
| 642 | ÄúÒѾ֪µÀµµÃûµÄÒâÒåÊÇʲôÁË -- ¾ÍÊÇÄúÕҵĵµ°¸¡£-NN%-- Ö¸³öĿǰÄúÔÚÎÄ | 613 | ״̬À¸ÏÔʾÁË Emacs µÄ״̬ºÍÄãÕýÔڱ༵ÄÎÄ×ÖµÄһЩÐÅÏ¢¡£ |
| 643 | ×ÖµµÖеÄλÖã»ËüµÄÒâ˼ÊÇ˵£ºÓÐ NN °Ù·Ö±ÈµÄÎÄ×ÖλÔÚ´°¸ñµÄÉÏÃæ¡£Èç¹ûµµ°¸ | ||
| 644 | µÄ¶¥¶Ë¾ÍλÔÚ´°¸ñÖУ¬ÄÇôËü¾Í»áÏÔʾ --Top-- ¶ø²»ÊÇ --00%--¡£Èç¹ûµµ°¸µÄ | ||
| 645 | µ×²¿¾ÍλÔÚ´°¸ñÖУ¬ÄÇôËüÊÇÏÔʾ --Bot--¡£Èç¹ûÄúÕýÔÚ¿´µÄÎÄ×ÖµµºÜС£¬ÔÚ´° | ||
| 646 | ¸ñÖоÍ×ãÒÔ¿´µ½È«²¿µÄÄÚÈÝ£¬ÄÇô״̬ÐоͻáÏÔʾ --All--¡£ | ||
| 647 | 614 | ||
| 648 | L ºÍÊý×ÖÒÔÁíÒ»ÖÖ·½Ê½À´±íʾ³öλÖãºËüÃǸø³öÁËĿǰËùÔÚµÄÐÐÊý£¨ Line £©¡£ | 615 | ÄãÓ¦¸ÃÖªµÀÎļþÃûµÄÒâ˼°É£¿¾ÍÊÇÄãÕÒµ½µÄÄǸöÎļþÂï¡£-NN%-- ÏÔʾµÄÊǹâ±êÔÚ |
| 616 | È«ÎÄÖеÄλÖá£Èç¹ûλÓÚÎļþµÄ¿ªÍ·£¬ÄÇô¾ÍÏÔʾ --Top-- ¶ø²»ÊÇ --00%--£»Èç | ||
| 617 | ¹ûλÓÚÎļþµÄĩ⣬¾ÍÏÔʾ --Bot--¡£Èç¹ûÎļþºÜС£¬Ò»ÆÁ¾Í×ãÒÔÏÔʾȫ²¿ÄÚÈÝ£¬ | ||
| 618 | ÄÇô״̬À¸»áÏÔʾ --All--¡£ | ||
| 649 | 619 | ||
| 650 | ÔÚ¿¿½üÇ°ÃæµÄÐǺűíʾÄúÒѾ¶ÔÕâЩÎÄ×Ö×öÁ˸ı䡣ÔÚÄú¸Õ°Ý·Ã»ò´¢´æÒ»¸öµµ°¸ | 620 | L ºÍÆäºóµÄÊý×Ö¸ø³öÁ˹â±êËùÔÚÐеÄÐкš£ |
| 651 | Ö®ºó£¬×´Ì¬ÐеÄÄǸö²¿·Ö»áûÓÐÐǺţ¬Ö»ÓÐÆÆÕۺš£ | ||
| 652 | 621 | ||
| 653 | ״̬ÐÐÖÐλì¶Ð¡À¨»¡ÀïÃæµÄ²¿·Ö£¬ÊÇÓÃÀ´¸æËßÄúÕýÔÚʹÓÃʲô±à¼Ä£Ê½¡£Ô¤ÉèµÄ | 622 | ×ͷµÄÐǺţ¨*£©±íʾÄãÒѾ¶ÔÎÄ×Ö×ö¹ý¸Ä¶¯¡£¸Õ¸Õ´ò¿ªµÄÎļþ¿Ï¶¨Ã»Óб»¸Ä¶¯ |
| 654 | ģʽÊÇ Fundamental£¬Ò²¾ÍÊÇÄúÏÖÔÚʹÓõġ£ËüÊÇ¡¸Ö÷ģʽ¡¹µÄÒ»¸öÀý×Ó¡£ | 623 | ¹ý£¬ËùÒÔ״̬À¸ÉÏÏÔʾµÄ²»ÊÇÐǺŶøÊǶÌÏߣ¨-£©¡£ |
| 655 | 624 | ||
| 656 | Emacs ÓÐÐí¶à²»Í¬µÄÖ÷ģʽ¡£ËüÃÇÖ®ÖÐÓÐһЩÊÇÓÃÀ´±à¼²»Í¬µÄÓïÑÔÒÔ¼°£¯»ò²» | 625 | ״̬À¸ÉÏСÀ¨ºÅÀïµÄÄÚÈݸæËßÄ㵱ǰÕýÔÚʹÓõıà¼Ä£Ê½¡£È±Ê¡µÄģʽÊÇ |
| 657 | ͬÖÖÀàµÄÎÄ×Ö£¬ÏñÊÇ Lisp ģʽ¡¢ Text ģʽµÈµÈ¡£ÔÚÈκεÄʱ¼äÖ»ÓÐÒ»¸öÖ÷Ä£ | 626 | Fundamental£¬¾ÍÊÇÄãÏÖÔÚÕýÔÚʹÓõÄÕâ¸ö¡£ËüÊÇÒ»ÖÖ¡°Ö÷ģʽ¡±¡£ |
| 658 | ʽ¿ÉÒÔ×÷Ó㬲¢ÇÒËüµÄÃû³Æ×Ü¿ÉÒÔÔÚ״̬ÐÐÖб»ÕÒµ½£¬¾ÍÔÚÏÖÔÚµÄ | ||
| 659 | ¡¸Fundamental¡¹ÖеÄλÖᣠ| ||
| 660 | 627 | ||
| 661 | ÿһ¸öÖ÷ģʽ¶¼Ê¹µÃһЩָÁîµÄÐÐΪ±íÏֵò»Ì«Ò»Ñù¡£¾ÙÀýÀ´Ëµ£¬ÔÚÒ»¸ö³ÌʽÖÐ | 628 | Emacs µÄÖ÷ģʽÁÖÁÖ×Ü×Ü¡£ÓÐÓÃÀ´±à¼³ÌÐò´úÂëµÄ¡ª¡ª±ÈÈç Lisp ģʽ£»Ò²ÓÐÓà |
| 662 | ÓÐһЩָÁîÓÃÀ´ÖÆ×÷³ö×¢½â£¬¶øÓÉì¶Ã¿Ò»ÖÖ³ÌʽÓïÑÔ¶Ôì¶Ò»¸ö×¢½âÓ¦¸Ã³¤µÃÏñʲ | 629 | À´±à¼¸÷ÖÖ×ÔÈ»ÓïÑÔÎı¾µÄ¡ª¡ª±ÈÈç Text ģʽ¡£ÈκÎÇé¿öÏÂÖ»ÄÜÓ¦ÓÃÒ»¸öÖ÷Ä£ |
| 663 | ô£¬¶¼ÓÐÖø²»Í¬µÄÏë·¨£¬Òò´Ëÿһ¸öÖ÷ģʽ¶¼±ØÐëÒÔ²»Í¬µÄ·½Ê½À´²åÈë×¢½â¡£Ã¿ | 630 | ʽ£¬ÆäÃû³Æ»áÏÔʾÔÚ״̬À¸ÉÏ£¬¾ÍÔÚÏÖÔÚÏÔʾ¡°Fundamental¡±µÄµØ·½¡£ |
| 664 | Ò»¸öÖ÷ģʽÊÇÒ»¸öÑÓÉìÖ¸ÁîµÄÃû³Æ£¬Ê¹µÃÄú¿ÉÒÔÓÃÀ´Çл»ÖÁÄǸöģʽ¡£¾ÙÀýÀ´Ëµ£¬ | ||
| 665 | M-x fundamental-mode ¾ÍÊÇÇл»µ½ Fundamental ģʽµÄÒ»¸öÖ¸Áî¡£ | ||
| 666 | 631 | ||
| 667 | Èç¹ûÄúÏëÒª±à¼ÈËÀàÓïÑÔµÄÎÄ×Öµµ°¸ -- ÏñÊÇÏÖÔÚµÄÕâÒ»¸ö£¬ÄúÓ¦¸ÃʹÓà Text | 632 | Ö÷ģʽÓÐʱ»á¸Ä±äһЩÃüÁîµÄÐÐΪ¡£±ÈÈç˵£¬²»¹Ü±à¼Ê²Ã´ÑùµÄ³ÌÐò´úÂ룬Äã¶¼ |
| 633 | ¿ÉÒÔÓÃÒ»¸öͳһµÄÃüÁîÀ´Ìí¼Ó×¢ÊÍ£¬µ«ÊÇÔÚ²»Í¬µÄÓïÑÔÖÐ×¢Ê͵ÄÓï·¨ÍùÍùÊDz»Í¬ | ||
| 634 | µÄ£¬ÕâʱÏàÓ¦µÄÖ÷ģʽ¾Í»á·Ö±ðÓø÷×ÔµÄÓï·¨¹æÔòÀ´Ìí¼Ó×¢ÊÍ¡£Ö÷ģʽ¶¼ÊÇ¿ÉÒÔ | ||
| 635 | Óà M-x Æô¶¯µÄÃüÁËùÒÔ M-x fundamental-mode ¾Í¿ÉÒÔÇл»µ½ Fundamental | ||
| 668 | ģʽ¡£ | 636 | ģʽ¡£ |
| 669 | 637 | ||
| 670 | >> ¼üÈë M-x text mode<Return>¡£ | 638 | Èç¹ûÄãÒª±à¼×ÔÈ»ÓïÑÔÎı¾¡ª¡ª±ÈÈçÏÖÔÚ¡ª¡ªÄãÓ¦¸ÃÓà Text ģʽ¡£ |
| 671 | 639 | ||
| 672 | ²»Òªµ£ÐÄ£¬Ã»ÓÐÈκÎÒ»¸öÄúÒѾѧ¹ýµÄ Emacs Ö¸Á»á±»¸Ä±ä³ÉÈκηdz£²»Í¬ | 640 | >> ÊäÈë M-x text mode<Return>¡£ |
| 673 | µÄÐÎʽ¡£µ«ÊÇÄú¿ÉÒÔ·¢ÏÖµ½ M-f ºÍ M-b ÏÖÔÚ°ÑÆ²ºÅ£¨'£©ÊÓΪ×ÖµÄÒ»²¿·Ö¡£ÏÈ | ||
| 674 | ǰ£¬ÔÚ Fundamental ģʽÖУ¬M-f ºÍ M-b ½«Æ²ºÅÊÓΪ×ֵķָô·ûºÅ¡£ | ||
| 675 | 641 | ||
| 676 | Ö÷ģʽͨ³£»áÏñÉÏÊöÄǸöÀý×ÓÒ»Ñù£¬×ö³öһЩ¾«Çɵĸı䣺´ó²¿·ÖµÄÖ¸ÁîÔÚÿһ | 642 | ±ðº¦Å£¬Ã»ÓÐʲôÃüÁî»á¸Ä±ä¹¦ÄÜ¡£²»¹ýÄã¿ÉÒÔ·¢ÏÖ£¬M-f ºÍ M-b ÏÖÔڰѵ¥ÒýºÅ |
| 677 | ¸öÖ÷ģʽÖС¸×öͬÑùµÄÊ¡¹£¬µ«ÊÇËüÃÇÒÔÒ»µãµã²»Í¬µÄ·½Ê½À´¹¤×÷¡£¡¾ÔپٸöÀý | 643 | £¨'£©ÊÓΪ´ÊµÄÒ»²¿·ÖÁË¡£¶øÔÚÏÈǰ£¬ÔÚ Fundamental ģʽÖУ¬M-f ºÍ M-b ¶¼½« |
| 678 | ×Ó£¬½ÓÐøÉÏÃæËù¿ªµÄÍ·£¬ÒÔ³ÌʽÓïÑÔµÄ×¢½âÀ´Ëµ¡£Í¬ÑùÒ»¸ö²åÈë×¢½âµÄ¶¯×÷£¬Òò | 644 | µ¥ÒýºÅÊÓΪ·Ö¸ôµ¥´ÊµÄ·ûºÅ¡£ |
| 679 | ΪÄúʹÓõijÌʽÓïÑÔ£¯Ö÷ģʽµÄ²»Í¬¶ø²»Í¬¡£ÈôÄúʹÓà C ÓïÑÔ£¬Emacs ²åÈë | ||
| 680 | ¡º/* ½éì¶ÖмäµÄΪע½âÇø¿é */¡»£»ÈôÄúʹÓõÄÊÇ Fortran ÓïÑÔ£¬Emacs ²åÈë | ||
| 681 | ¡ºc ÒÔ×ÖÔª c ΪÊ×µÄΪע½âÐС»£»ÈôÄúʹÓõÄÊÇ Basic ÓïÑÔ£¬Emacs Ôò²åÈ롺' | ||
| 682 | ƲºÅÒÔºóµÄΪע½âÎÄ×Ö¡»¡£±à¼Æ÷µÄµ¯ÐÔÈç´Ë£¬ÊµÔÚûÓбØÒªÎªÁ˲»Í¬µÄÓïÑÔ¡¢ | ||
| 683 | Ä¿µÄ»òÍâ¹Û£¬Éè¼ÆÌØÊ⻯µÄ±à¼Æ÷¡£¡¸Çó´óͬ£¬´æÐ¡Ò졹ÔÚÕâÀïÒ²ÊdzÉÁ¢µÄ¡£¡¿ | ||
| 684 | 645 | ||
| 685 | Òªä¯ÀÀÄúÏÖÔÚËù´¦µÄÖ÷ģʽµÄÎĵµ£¬¼üÈë C-h m¡£ | 646 | Ö÷ģʽͨ³£¶¼»á¸ãһЩÀàËÆµÄС¶¯×÷£¬ÒòΪºÜ¶àÃüÁîÆäʵÍê³ÉµÄÊÇ¡°ÏàͬµÄ¹¤ |
| 647 | ×÷¡±£¬Ö»ÊÇÔÚ²»Í¬Çé¿öÏ»áÓв»Í¬µÄ¹¤×÷·½Ê½¶øÒÑ¡£¡¾Ëùν¡°Çóͬ´æÒ족£¬ÔÚ | ||
| 648 | Emacs ÀïµÃµ½Á˺ܺõÄÌåÏÖ¡¿ | ||
| 686 | 649 | ||
| 687 | >> ʹÓà C-u C-v Ò»»òÊý´Î£¬½«±¾Ðдøµ½¿¿½üÓ©Ä»µÄÉÏ·½¡£ | 650 | Óà C-h m ¿ÉÒԲ鿴µ±Ç°Ö÷ģʽµÄÎĵµ¡£ |
| 688 | >> ¼üÈë C-h m£¬¿´¿´ Text ģʽÓë Fundamental ģʽÊÇÄÄÀﲻͬ¡£ | ||
| 689 | >> ¼üÈë C-x 1 ½«Îĵµ´ÓÓ©Ä»ÒÆ³ýµô¡£ | ||
| 690 | 651 | ||
| 691 | Ö÷ģʽ֮ËùÒÔ³ÆÎª¡¸Ö÷Òª£¨ major £©¡¹µÄÔÒòÊÇÒòΪËüÃÇÒ²ÓдÎģʽ£¨ minor | 652 | >> Óà C-u C-v ½«±¾Ðдøµ½¿¿½üÆÁÄ»µÄÉÏ·½¡£ |
| 692 | mode £©¡£´ÎÒªµÄģʽ²¢²»ÊÇÖ÷ģʽµÄÆäËûÑ¡Ôñ£¬¶øÖ»ÊÇ´ÎÒªµÄ¸ü¸Ä¡£Ã¿Ò»¸ö´Î | 653 | >> ÊäÈë C-h m£¬¿´¿´ Text ģʽÓë Fundamental ģʽÓÐÄÄЩ²»Í¬¡£ |
| 693 | ģʽ¿ÉÒÔ±»Ëü±¾ÉíÆôÓûòÍ£Ö¹£¬ºÍËùÓÐÆäËûµÄ´ÎģʽÎ޹أ¬²¢ÇÒÒ²ºÍÄúµÄÖ÷ģʽ | 654 | >> ÊäÈë C-x 1 ¹ØµôÎĵµ´°¸ñ¡£ |
| 694 | Î޹ء£ËùÒÔÄú¿ÉÒÔ²»Ê¹ÓôÎģʽ£¬»òÒ»¸ö£¬»òÈκÎÊýÁ¿µÄ´ÎģʽµÄ×éºÏ¡£ | ||
| 695 | 655 | ||
| 696 | ÓÐÒ»¸ö½Ð×ö Auto Fill ģʽµÄ´Îģʽ·Ç³£ÓÐÓã¬ÌرðÊÇÔÚ±à¼ÈËÀàÓïÑÔµÄÎÄ×Ö | 656 | Ö÷ģʽ֮ËùÒÔ³ÆÖ®Îª¡°Ö÷£¨major£©¡±Ä£Ê½£¬ÊÇÒòΪͬʱ»¹ÓС°¸¨Ä£Ê½¡±£¨minor |
| 697 | ʱ¡£µ±Õâ¸öģʽÆôÓÃʱ£¬ Emacs ÔÚµ±Äú²åÈëÎÄ×Ö²¢ÇÒʹһÐÐÌ«¿íʱ£¬»á½«ÄÇÒ» | 657 | mode£©´æÔÚ¡£¸¨Ä£Ê½²¢²»ÄÜÌæ´úÖ÷ģʽ£¬¶øÊÇÔÚÖ÷ģʽ֮ÍâÔÙ×öһЩ¸¨ÖúµÄÐ޸ġ£ |
| 698 | ÐУ¬ÔÚ×ÖÓë×ÖÖ®¼ä×Ô¶¯µØ·Ö¸ô¿ª¡£ | 658 | ÿ¸ö¸¨Ä£Ê½¶¼¿ÉÒÔ¶ÀÁ¢µØ¿ªÆôºÍ¹Ø±Õ£¬¸úÆäËü¸¨Ä£Ê½Î޹أ¬¸úÖ÷ģʽҲÎ޹ء£Ëù |
| 659 | ÒÔÄã¿ÉÒÔ²»Óø¨Ä£Ê½£¬Ò²¿ÉÒÔÓÃÒ»¸ö»òÕß¶à¸ö¸¨Ä£Ê½¡£ | ||
| 699 | 660 | ||
| 700 | Äú¿ÉÒÔ M-x auto fill mode<Return> À´½« Auto Fill ģʽÆôÓᣵ±Õâ¸öģʽ | 661 | ÓÐÒ»¸ö½Ð×ö×Ô¶¯ÕÛÐУ¨Auto Fill£©µÄ¸¨Ä£Ê½Óô¦ºÜ´ó£¬ÌرðÊÇÔÚ±à¼×ÔÈ»ÓïÑÔÎÄ |
| 701 | ÆôÓÃʱ£¬Äú¿ÉÒÔʹÓà M-x auto fill mode<Return> À´½«ËüÈ¡Ïû¡£µ±Õâ¸öģʽ²» | 662 | ±¾µÄʱºò¡£Õâ¸ö¸¨Ä£Ê½Æô¶¯ºó£¬Emacs »áÔÚÄã´ò×Ö³¬³öÒ»Ðб߽çʱ×Ô¶¯ÌæÄã»»ÐС£ |
| 702 | ÓÃʱ£¬ÔòÕâ¸öÖ¸Áî»á½«ËüÆô¶¯£¬¶øµ±Õâ¸öģʽÆôÓÃʱ£¬Õâ¸öÖ¸Áî»á½«Ëü¹Ø±Õ¡£ÎÒ | ||
| 703 | ÃÇ˵Õâ¸öÖ¸ÁîÓÃÀ´¡¸Çл»£¨ toggle £©¡¹Ä£Ê½¡£ | ||
| 704 | 663 | ||
| 705 | >> ÏÖÔÚ¼üÈë M-x auto fill mode<Return>¡£È»ºóÒ»ÔٵزåÈë×Ö´® | 664 | Óà M-x auto fill mode<Return> Æô¶¯×Ô¶¯ÕÛÐÐģʽ¡£Æô¶¯Ö®ºó£¬Èç¹ûÎÒÃÇÔÙÓà |
| 706 | ¡¸ asdf ¡¹£¬Ö±µ½Äú¿´µ½Ëü·Ö³ÉÁ½ÐС£Äú±ØÐëÔÚËüÃÇÖ®¼ä°ÚÉϿհף¬ | 665 | Ò»´Î M-x auto fill mode<Return>£¬×Ô¶¯ÕÛÐÐģʽ¾Í±»¹Ø±ÕÁË¡£Ò²¾ÍÊÇ˵£¬Èç¹û |
| 707 | ÒòΪ Auto Fill Ö»ÔÚ¿Õ°×´¦¶ÏÐС£ | 666 | ×Ô¶¯ÕÛÐÐģʽûÓпªÆô£¬Õâ¸öÃüÁî»á¿ªÆôËü£»¶øÈç¹ûÒѾ¿ªÆôÁË£¬Õâ¸öÃüÁî»á¹Ø |
| 667 | ±ÕËü¡£ÎÒÃÇ˵Õâ¸öÃüÁîÓÃÀ´¡°¿ª¹Ø£¨toggle£©¡±Ä£Ê½¡£ | ||
| 708 | 668 | ||
| 709 | ±ß½çͨ³£±»É趨Ϊ 70 ¸ö×ÖÔª£¬µ«ÊÇÄú¿ÉÒÔÓà C-x f Ö¸ÁîÀ´¸Ä±äËü¡£ÄúÓ¦¸ÃÒÔ | 669 | >> ÏÖÔÚÊäÈë M-x auto fill mode<Return>¡£È»ºóËæ±ãÇõãʲô£¬Ö±µ½Äã¿´µ½Ëü |
| 710 | Ò»¸öÊý×Ö²ÎÊýµÄ·½Ê½À´¸ø¶¨ÄúËùÏ£ÍûµÄ±ß½çÉ趨¡£ | 670 | ·Ö³ÉÁ½ÐС£±ØÐëÇÃһЩ¿Õ¸ñ£¬ÒòΪ Auto Fill Ö»ÔÚ¿Õ°×´¦½øÐжÏÐС£¡¾¿Õ¸ñ |
| 671 | ¶ÔÓ¢ÎÄÀ´ËµÊDZØÐëµÄ£¬¶ø¶ÔÖÐÎÄÔò²»±Ø¡£¡¿ | ||
| 711 | 672 | ||
| 712 | >> ¼üÈë C-x f ²¢¸½ÉÏÒýÊý 20£º¡ºC-u 2 0 C-x f¡»¡£ | 673 | Ðб߽çͨ³£±»É趨Ϊ 70 ¸ö×Ö·û¡¾ÕâÀïÖ¸Ó¢ÎÄ×Ö·û¡¿£¬Äã¿ÉÒÔÓà C-x f ÃüÁîÀ´ÖØ |
| 713 | È»ºó¼üÈëһЩÎÄ×Ö£¬¿´¿´ Emacs ÒÔ 20 ¸ö×ÖÔª£¬ | 674 | ÐÂÉ趨֮¡£Ö¸¶¨ÐÂÐб߽ç¿ÉÒÔÓÃÊý×Ö²ÎÊýÀ´½øÐд«µÝ¡£ |
| 714 | ÔÚÐÐÓëÐÐÖ®¼ä½øÐÐ fill ¶¯×÷¡£È»ºóÔÙÓÃÒ»´Î C-x f ½«±ß½çÉè»Ø 70¡£ | ||
| 715 | 675 | ||
| 716 | Èç¹ûÄúÔÚÒ»¸ö¶ÎÂäµÄÖмä×ö³ö¸Ä±ä£¬Auto Fill ģʽ²¢²»»áΪÄúÖØÐ½øÐÐ fill | 676 | >> ÊäÈë C-x f ²¢´«µÝ²ÎÊý 20£º C-u 2 0 C-x f¡£ |
| 717 | µÄ¶¯×÷£¨ re-fill £©¡£Òª re-fill Õâ¸ö¶ÎÂ䣬¼üÈë M-q (META-q)£¬¶øÓÎ±ê±Ø | 677 | È»ºóÊäÈëһЩÎÄ×Ö£¬¹Û²ì Emacs µÄ×Ô¶¯ÕÛÐж¯×÷ |
| 718 | Ðë´¦ÔÚÆäÖС£ | 678 | ×îºóÔÙÓà C-x f ½«±ß½çÉè»Ø 70¡£ |
| 719 | 679 | ||
| 720 | >> ÒÆ¶¯Óα굽ǰһ¶ÎÖУ¬È»ºó¼üÈë M-q¡£ | 680 | Èç¹ûÄãÔÚ¶ÎÂäµÄÖмä×öÁËһЩÐ޸ģ¬ÄÇô×Ô¶¯ÕÛÐÐģʽ²»»áÌæÄã°ÑÕû¸ö¶ÎÂäÖØÐ |
| 681 | ÕÛÐС£ÖØÐÂ×Ô¶¯ÕÛÐÐÓà M-q£¬×¢ÒâʹÓõÄʱºò¹â±ê±ØÐëλÓÚÄãÏëÕÛÐеÄÄÇÒ»¶ÎÀï¡£ | ||
| 721 | 682 | ||
| 683 | >> ÒÆ¶¯¹â±êµ½Ç°Ò»¶ÎÖУ¬È»ºóÊäÈë M-q¡£ | ||
| 722 | 684 | ||
| 723 | * ËÑѰ£¨ SEARCHING £© | ||
| 724 | --------------------- | ||
| 725 | 685 | ||
| 726 | Emacs ¿ÉÒÔËÑѰ×Ö´®£¨×Ö´®¿ÉÒÔÊÇһȺÁ¬ÐøµÄ×ÖÔª»ò×Ö£©¡¾¾ÍÖÐÎÄÀ´Ëµ£¬×ÖÔªºÍ | 686 | * ËÑË÷£¨SEARCHING£© |
| 727 | ×Ö»ù±¾ÉÏÒâÒåÏàͬ£»´Ë´¦ËùÖ¸µÄ¡º×Ö¡»£¬ÊÇÓ¢ÎÄÖÐûÓб»¿Õ°×¸ô¿ªµÄ×ÖÔª¼¯ | 687 | ------------------- |
| 728 | ºÏ¡£¡¿£¬Íùǰ»òÍùºóËÑѰ¶¼¿ÉÒÔ¡£ËÑѰһ¸ö×Ö´®ÊÇÒ»ÖÖÓαêÒÆ¶¯Ö¸ÁËü»á½«ÓÎ | 688 | |
| 729 | ±êÒÆ¶¯µ½×Ö´®³öÏÖµÄÏÂÒ»¸öµØ·½¡£ | 689 | Emacs ¿ÉÒÔÏòǰ»òÕßÏòºóËÑË÷×Ö·û´®¡£ËÑË÷ÃüÁîÊÇÒ»¸öÒÆ¶¯¹â±êµÄÃüÁËÑË÷³É |
| 690 | ¹¦ºó£¬¹â±ê»áÍ£ÁôÔÚËÑË÷Ä¿±ê³öÏֵĵط½¡£ | ||
| 730 | 691 | ||
| 731 | Emacs ËÑѰָÁîÓë´ó²¿·Ö±à¼Æ÷µÄËÑѰָÁͬµÄµØ·½ÔÚì¶£¬ËüÊÇ¡¸½¥½øµÄ | 692 | Emacs µÄËÑË÷ÃüÁîµÄ¶ÀÌØÖ®´¦ÔÚÓÚ£¬ËüÊÇ¡°½¥½øµÄ£¨incremental£©¡±£¬Òâ˼ÊÇËÑ |
| 732 | £¨ incremental £©¡¹¡£Õâ±íʾËÑѰ·¢ÉúÔÚÄú¼üÈëÏëÒªËÑѰµÄÎÄ×Ö´®ºó¡£ | 693 | Ë÷ÓëÊäÈëͬʱ½øÐУºÄãÔÚÕâ±ßÒ»¸ö×ÖÒ»¸ö×ÖµØÊäÈëÄãÏëËÑË÷µÄ¶«Î÷£¬Í¬Ê± Emacs |
| 694 | ÔÚÄDZ߾ÍÌæÄãËÑË÷ÁË¡£ | ||
| 733 | 695 | ||
| 734 | Òª¿ªÊ¼ËÑѰµÄÖ¸ÁîÊÇ£ºC-s ÍùǰËÑѰ£¬C-r ÍùºóËÑѰ¡£µ«ÏȵÈһϣ¡ÏÖÔÚÏȲ»Òª | 696 | C-s ÊÇÏòǰËÑË÷£¬C-r ÊÇÏòºóËÑË÷¡£²»¹ýÊÖ±ðÕâô¿ì£¡Ïȵȵȱð׿±ÊÔ¡£ |
| 735 | ÊÔ¡£ | ||
| 736 | 697 | ||
| 737 | µ±Äú¼üÈë C-s ʱ£¬»á·¢ÏÖµ½ÓÐÒ»¸ö×Ö´®¡¸I-search¡¹³öÏÖÔÚ»ØÓ¦ÇøÖÐ×÷ΪÌáʾ¡£ | 698 | ÔÚÄã°´Ï C-s Ö®ºó£¬Äã»á·¢ÏÖ»ØÏÔÇøÀïÓС°I-search¡±×ÖÑù³öÏÖ£¬ÕâÊÇÔÚÌáʾ |
| 738 | Ëü¸æËßÄú Emacs ÏÖÔÚÕý´¦ì¶³ÆÎª¡¸½¥½øÊ½ËÑѰ¡¹µÄ״̬ÖУ¬µÈ´ýÄú¼üÈëÄúÏëÒª | 699 | ÄãĿǰ Emacs Õý´¦ÓÚ¡°½¥½øËÑË÷¡±×´Ì¬£¬ÕýÔڵȴýÄãÊäÈëËÑË÷×Ö´®¡£<Return> |
| 739 | ËÑѰµÄ×Ö´®¡£<Return> »á½áÊøÒ»¸öËÑѰ¡£ | 700 | »á½áÊøËÑË÷¡£ |
| 740 | 701 | ||
| 741 | >> ÏÖÔÚ¼üÈë C-s ¿ªÊ¼Ò»¸öËÑѰ¡£ÂýÒ»µã£¬Ò»´Î¼üÈëÒ»¸ö×ÖÔª£¬ | 702 | >> ÊäÈë C-s ¿ªÊ¼Ò»¸öËÑË÷¡£×¢ÒâÇÃÂýÒ»µã£¬Ò»´ÎÊäÈëÒ»¸ö×Ö·û¡£ |
| 742 | ¼üÈ롺cursor¡»Õâ¸ö×Ö£¬Ã¿¼üÈëÒ»¸ö×ÖԪʱ£¬ÉÔ΢ͣһÏ£¬ | 703 | ÂýÂýÊäÈë¡°cursor¡±Õû¸ö´Ê£¬Ã¿ÇÃÒ»¸ö×Ö¾ÍÔÝͣһϣ¬×¢Òâ¹Û²ì¹â±ê¡£ |
| 743 | ×¢Òâ¿´¿´Óα귢ÉúÁËʲôÊ¡£ÏÖÔÚÄúÒÑÔø¾ËÑѰ¹ý¡¸cursor¡¹Õâ¸ö×ÖÁË¡£ | 704 | ÏÖÔÚÄãÓ¦¸ÃÒÑÔø¾ÕÒµ½¡°cursor¡±Õâ¸ö´ÊÁË¡£ |
| 744 | >> ÔٴμüÈë C-s À´ËÑѰ¡¸cursor¡¹µÄÏÂÒ»¸ö³öÏÖλÖᣠ| 705 | >> ÔÙ°´Ò»´Î C-s£¬ËÑË÷ÏÂÒ»¸ö¡°cursor¡±³öÏÖµÄλÖᣠ|
| 745 | >> ÏÖÔÚ¼üÈë <Delback> ËĴΣ¬¿´¿´ÓαêÊÇÈçºÎÒÆ¶¯µÄ¡£ | 706 | >> ÏÖÔÚ°´ËÄ´ÎÍ˸ñ¼ü£¬¿´¿´¹â±êÊÇÈçºÎÒÆ¶¯µÄ¡£ |
| 746 | >> ¼üÈë <Return> ½áÊøËÑѰ¡£ | 707 | >> Çà <Return> ½áÊøËÑË÷¡£ |
| 747 | 708 | ||
| 748 | ÄúÓÐûÓп´µ½·¢ÉúÁËʲô£¿ÔÚÒ»¸ö½¥½øÊ½ËÑѰÖУ¬Emacs ÊÔÖøÒª×ßµ½Äú¼üÈëµÄ×Ö | 709 | ¸Õ²Å¿´×ÐϸÁËô£¿ÔÚÒ»¸ö½¥½øÊ½ËÑË÷ÖУ¬Emacs »á³¢ÊÔÌøµ½ÄãÊäÈëµÄ×Ö·û´®µÄ³ö |
| 749 | ´®µÄÏÂÒ»¸ö³öÏÖλÖá£ÒªÒƶ¯µ½ÓαêËùÔÚµÄÏÂÒ»¸ö³öÏÖλÖã¬Ö»ÒªÔÙ¼üÈë C-s | 710 | ÏÖλÖá£ÏëÌøµ½ÏÂÒ»¸öËÑË÷Ä¿±ê³öÏÖµÄλÖã¬Ö»ÒªÔÙ°´Ò»´Î C-s ¾ÍÐÐÁË¡£Èç¹ûÕÒ |
| 750 | Ò»´Î¡£Èç¹û²¢Ã»ÓÐÕâÑùµÄ³öÏÖλÖôæÔÚ£¬Emacs »áßÙÒ»Éù£¬²¢¸æËßÄúĿǰµÄËÑѰ | 711 | ²»µ½£¬Emacs »á·¢³ö¡°ßÙ¡±µÄÒ»Éù£¬¸æËßÄãËÑË÷ʧ°Ü¡£ÔÚÕû¸ö¹ý³ÌÖУ¬¶¼¿ÉÒÔÓà |
| 751 | ¡¸Ê§°Ü¡¹¡£ÁíÍâ C-g Ò²¿ÉÒÔÓÃÀ´½áÊøËÑѰ¡£ | 712 | C-g À´ÖÕÖ¹ËÑË÷¡£¡¾Äã»á·¢ÏÖ C-g Ö®ºó¹â±ê»Øµ½ÁËËÑË÷¿ªÊ¼Ç°µÄµØ·½£¬¶ø |
| 713 | <Return> »áÈùâ±êÁôÔÚËÑË÷½á¹ûÉÏ£¬ÕâÊǺÜÓÐÓõŦÄÜ¡£¡¿ | ||
| 752 | 714 | ||
| 753 | ×¢Ò⣺ÔÚijЩϵͳÖУ¬¼üÈë C-s ½«»á°ÑÓ©Ä»¶³½á£¬Äú½«¿´²»µ½´Ó Emacs À´µÄÈÎ | 715 | ×¢Ò⣺ʹÓÃijЩÖն˵Äʱºò£¬ÊäÈë C-x C-s »á¶³½áÆÁÄ»¡¾ÆÁĻûÓÐÈκÎÊä³ö¡¿£¬ |
| 754 | ºÎÊä³ö¡£Õâ±íʾ²Ù×÷ϵͳһ¸ö³ÆÎª¡¸Á÷³Ì¿ØÖÆ¡¹µÄ¡¸¹¦ÄÜ¡¹½« C-s Ö¸ÁîÀ¹½Ø×¡£¬ | 716 | ÕâÑùÄã¾Í¿´²»µ½ Emacs µÄÈκα仯¡£ÆäÔÒòÊDzÙ×÷ϵͳµÄ¡°Á÷Á¿¿ØÖÆ¡±¹¦ÄÜ°Ñ |
| 755 | ²¢ÇÒ²»ÈÃËü´«µ½ Emacs¡£ÒªÈ¡ÏûÓ©Ä»µÄ¶³½á£¬Çë¼üÈë C-q¡£È»ºóµ½ Emacs ʹÓà | 717 | C-s À¹½ØÁË£¬²¢ÇÒ¶³½áÁËÆÁÄ»£¬Emacs ×ÔȻҲ¾Í¿´²»µ½Õâ¸öÊäÈëÁË¡£Óà C-q ¿ÉÒÔ |
| 756 | ÊÖ²áÖп´¿´¶Ôì¶¡¸½¥½øÊ½ËÑѰµÄͬʱ½øÈ루 Spontaneous Entry to | 718 | ½â³ýÆÁÄ»¶³½á¡£Òª½â¾öÕâ¸öÎÊÌ⣬Çë²Î¿¼ Emacs ÊÖ²áÀïµÄ¡°Spontaneous Entry |
| 757 | Incremental Search £©¡¹Õâ¸öÖ÷Ì⣬ÒÔÈ¡µÃ´¦ÀíÕâ¸ö¡¸¹¦ÄÜ¡¹µÄ½¨Òé¡£ | 719 | to Incremental Search¡±Ò»½Ú¡¾Emacs ÊÖ²á¿ÉÄÜ»¹Ã»ÓÐÖÐÎÄ·Òë¡¿£¬ÄÇÀï¿ÉÄÜÓÐ |
| 720 | һЩÓÐÓõĽ¨Òé¡£ | ||
| 758 | 721 | ||
| 759 | Èç¹ûÄúÔÚÒ»¸ö½¥½øÊ½ËÑѰµÄÖм䣬²¢ÇÒ¼üÈë <Delback>£¬Äú¿ÉÒÔ·¢ÏÖÔÚËÑѰ×Ö´® | 722 | Èç¹ûÄãÕýÔÚ½¥½øÊ½ËÑË÷ÖУ¬°´Í˸ñ¼ü»áɾ³ýÄ¿±ê×Ö·û´®µÄ×îºóÒ»¸ö×Ö·û£¬²¢ÇÒ¹â |
| 760 | ÖеÄ×îºóÒ»¸ö×ÖÔª±»Ïû³ýÁË£¬²¢ÇÒËÑѰ»á»Øµ½Õâ¸öËÑѰµÄ×îºóÒ»¸öµØ·½¡£¾ÙÀýÀ´ | 723 | ±ê»á»Øµ½×î½üÒ»´ÎËÑË÷µÄÃüÖÐλÖᣱÈÈçÄãÒѾÊäÈëÁË¡°c¡±£¬¹â±ê¾ÍÍ£ÔÚ¡°c¡± |
| 761 | ˵£¬¼ÙÉèÄúÒѾ¼üÈëÁË¡ºc¡»£¬ÓÃÀ´Ñ°ÕÒ¡¸c¡¹µÄµÚÒ»´Î³öÏÖ¡£ÏÖÔÚÈç¹ûÄú¼üÈë | 724 | µÚÒ»´Î³öÏֵĵط½£¬ÔÙÊäÈë¡°u¡±£¬¹â±êÍ£ÔÚ¡°cu¡±µÚÒ»´Î³öÏֵĵط½£¬ÕâʱÔÙ°´ |
| 762 | ¡ºu¡»£¬Óαê»áÒÆ¶¯µ½¡¸cu¡¹µÄµÚÒ»´Î³öÏÖλÖá£ÏÖÔÚ¼üÈë <Delback> £¬Õâ»á½« | 725 | Í˸ñ¼ü£¬¡°u¡±¾Í´ÓËÑË÷×Ö´®ÖÐÏûʧÁË£¬È»ºó¹â±ê»á»Øµ½¡°c¡±µÚÒ»´Î³öÏֵĵط½¡£ |
| 763 | ¡¸u¡¹´ÓËÑѰ×Ö´®ÖÐÏû³ý£¬²¢ÇÒÓαê»áÒÆ»Øµ½¡¸c¡¹µÄµÚÒ»´Î³öÏÖλÖᣠ| ||
| 764 | 726 | ||
| 765 | Èç¹ûÄúÔÚÒ»¸öËÑѰµÄÖм䣬²¢ÇÒ¼üÈëÒ»¸ö CONTROL »ò META ×ÖÔªµÄ»°£¬£¨µ«ÓÐ | 727 | ÁíÍâÈç¹ûÄãÔÚËÑË÷µÄʱºòÊäÈëÁË CONTROL »òÕß META ×éºÏ¼üµÄ»°£¬ËÑË÷¿ÉÄÜ»á |
| 766 | һЩÀýÍâ -- ¶ÔËÑѰ¶øÑÔÌØ±ðµÄ×ÖÔª£¬ÏñÊÇ C-s ºÍ C-r £©£¬ËÑѰ»á±»½áÊø¡£ | 728 | ½áÊø¡££¨Ò²ÓÐÀýÍ⣬±ÈÈç C-s ºÍ M-r ÕâЩ¶ÔËÑË÷ÓÐÌØ±ðÒâÒåµÄ×éºÏ¼ü¡££© |
| 767 | 729 | ||
| 768 | C-s »á¿ªÊ¼Ò»¸öËÑѰ£¬Ëü»áѰÕÒËÑѰ×Ö´®ÔÚĿǰÓαêλÖá¸Ö®ºó¡¹£¬µÄÈκγöÏÖ | 730 | Ç°ÃæËµµÄ¶¼ÊÇ¡°ÏòÏ¡±ËÑË÷£¬Èç¹ûÏë¡°ÏòÉÏ¡±ËÑË÷£¬¿ÉÒÔÓà C-r¡£C-r Óë C-s |
| 769 | λÖá£Èç¹ûÄúÏëÒªÔÚÏÈǰÎÄ×ÖÖÐËÑѰ£¬¼üÈë C-r ×÷ÎªÌæ´ú¡£³ýÁËËÑѰµÄ·½ÏòÏà | 731 | Ïà±È³ýÁËËÑË÷·½ÏòÏà·´Ö®Í⣬ÆäËüµÄ²Ù×÷¶¼Ò»Ñù¡£ |
| 770 | ·´Ö®Í⣬ÎÒÃÇËù˵µÄÓÐ¹Ø C-s µÄËùÓÐÊÂÇ飬ͬÑùµØ¿ÉÒÔÓ¦Óõ½ C-r ÉÏ¡£ | ||
| 771 | 732 | ||
| 772 | 733 | ||
| 773 | * ¶àÖØ´°¸ñ£¨ MULTIPLE WINDOWS £© | 734 | * ¶à´°¸ñ£¨MULTIPLE WINDOWS£© |
| 774 | -------------------------------- | 735 | ---------------------------- |
| 775 | 736 | ||
| 776 | Emacs Ðí¶àºÃ¹¦ÄܵįäÖÐÖ®Ò»ÊÇ£¬Äú¿ÉÒÔÔÚÓ©Ä»ÖÐͬʱչʾ³¬¹ýÒ»¸ö´°¸ñ¡£ | 737 | Emacs µÄÃÔÈËÖ®´¦ºÜ¶à£¬Äܹ»ÔÚÆÁÄ»ÉÏͬʱÏÔʾ¶à¸ö´°¸ñ¾ÍÊÇÆäÖÐÖ®Ò»¡£ |
| 777 | 738 | ||
| 778 | >> ÒÆ¶¯Óα굽ÕâÒ»Ðв¢ÇÒ¼üÈë C-u 0 C-l¡£ | 739 | >> ÒÆ¶¯¹â±êµ½ÕâÒ»ÐУ¬È»ºóÊäÈë C-u 0 C-l¡£ |
| 779 | 740 | ||
| 780 | >> ÏÖÔÚ¼üÈë C-x 2£¬Ëü»á½«Ó©Ä»Æ½·Ö³ÉÁ½¸ö´°¸ñ¡£ | 741 | >> ÏÖÔÚÊäÈë C-x 2£¬Ëü»á½«ÆÁÄ»»®·Ö³ÉÁ½¸ö´°¸ñ¡£ |
| 781 | ÕâÁ½¸ö´°¸ñ¶¼ÏÔÊ¾ÖøÕâ¸ö¿ìËÙÖ¸ÄÏ¡£ÓαêÔòÍ£ÁôÔÚÉÏ·½µÄ´°¸ñ¡£ | 742 | ÕâÁ½¸ö´°¸ñÀïÏÔʾµÄ¶¼ÊDZ¾Æª¿ìËÙÖ¸ÄÏ£¬¶ø¹â±êÔòÍ£ÁôÔÚÉÏ·½µÄ´°¸ñÀï¡£ |
| 782 | 743 | ||
| 783 | >> ¼üÈë C-M-v ÒÔ¾í¶¯Ï·½µÄ´°¸ñ¡£ | 744 | >> ÊÔÊÔÓà C-M-v ¹ö¶¯Ï·½µÄ´°¸ñ¡£ |
| 784 | £¨Èç¹ûÄú²¢Ã»ÓÐÒ»¸öÕæµÄ META ¼ü£¬Ôò¼üÈë ESC C-v Òà¿É¡££© | 745 | £¨Èç¹ûÄ㲢ûÓÐ META ¼ü£¬Óà ESC C-v Ò²¿ÉÒÔ¡££© |
| 746 | ¡¾ÏòÉϹö¶¯ÊÇ C-M-S-v£¬Ò²¾ÍÊÇͬʱ°´×¡ CONTROL¡¢META ºÍ SHIFT ÔÙ°´ v¡¿ | ||
| 785 | 747 | ||
| 786 | >> ¼üÈë C-x o£¨¡ºo¡»Ö¸µÄÊÇÆäËû¡ºother¡»µÄÒâ˼£©£¬ | 748 | >> ÊäÈë C-x o£¨¡°o¡±Ö¸µÄÊÇ¡°ÆäËü£¨other£©¡±£©£¬ |
| 787 | ½«ÓαêÒÆ¶¯µ½Ï·½µÄ´°¸ñ¡£ | 749 | ½«¹â±ê×ªÒÆµ½Ï·½µÄ´°¸ñ¡£ |
| 788 | 750 | ||
| 789 | >> ÔÚÏ·½µÄ´°¸ñÖУ¬Ê¹Óà C-v ºÍ M-v À´¾í¶¯Ëü¡£ | 751 | >> ÔÚÏ·½µÄ´°¸ñÖУ¬Óà C-v ºÍ M-v À´¹ö¶¯¡£ |
| 790 | ¼ÌÐøÎ¬³ÖÔÚÉÏ·½µÄ´°¸ñÖÐÔĶÁÕâЩָÒý¡£ | 752 | ͬʱ¼ÌÐøÔÚÉÏ·½µÄ´°¸ñÀïÔĶÁÕâЩָµ¼¡£ |
| 791 | 753 | ||
| 792 | >> ÔÙÒ»´Î¼üÈë C-x o ½«ÓαêÒÆ»Øµ½ÉÏ·½µÄ´°¸ñ¡£ | 754 | >> ÔÙÊäÈë C-x o ½«¹â±êÒÆ»Øµ½ÉÏ·½µÄ´°¸ñÀï¡£ |
| 793 | Óαê»á»Øµ½ËüÔÚÉÏ·½´°¸ñÖУ¬Ô±¾ËùÔÚµÄλÖᣠ| 755 | ¹â±ê»á»Øµ½ËüÔÚÉÏ·½´°¸ñÖÐÔ±¾ËùÔÚµÄλÖᣠ|
| 794 | 756 | ||
| 795 | Äú¿ÉÒÔ³ÖÐøÊ¹Óà C-x o ÔÚ´°¸ñÖ®¼äÇл»¡£Ã¿Ò»¸ö´°¸ñÓÐËü×Ô¼ºµÄÓαêλÖ㬵« | 757 | Á¬ÐøÊ¹Óà C-x o ¿ÉÒÔ±éÀúËùÓд°¸ñ¡£Ã¿Ò»¸ö´°¸ñ¶¼ÓÐËü×Ô¼ºµÄ¹â±êλÖ㬵«ÊÇÖ» |
| 796 | ÊÇÖ»ÓÐÒ»¸ö´°¸ñ»áÕæµÄÏÔʾ³öÓαꡣËùÓÐͨ³£µÄ±à¼Ö¸ÁîÖ»»áÓ¦Óõ½ÄǸöÓαêËù | 758 | ÓÐÒ»¸ö´°¸ñ»áÕæÕýÏÔʾÕâ¸ö¹â±ê¡£¡¾ÆäËü´°¸ñÔÚ¿ØÖÆÌ¨Ï²»»áÏÔʾ¹â±ê£¬ÔÚͼÐÎ |
| 797 | ÔڵĴ°¸ñ¡£ÎÒÃdzÆÕâ¸öΪ¡¸±»Ñ¡ÔñµÄ´°¸ñ¡¹¡£ | 759 | ´°¿ÚÏÂȱʡÏÔʾΪïοչâ±ê¡£¡¿Ò»°ãËùÓеıà¼ÃüÁî¶¼×÷ÓÃÓÚÕâ¸ö¹â±êËùÔڵĴ° |
| 760 | ¸ñ£¬ÎÒÃdzÆÕâ¸ö´°¸ñΪ¡°±»Ñ¡ÖеĴ°¸ñ¡±¡£ | ||
| 798 | 761 | ||
| 799 | Ö¸Áî C-M-v ÔÚµ±Äúì¶Ò»¸ö´°¸ñÖбà¼ÎÄ×Ö£¬²¢Ê¹ÓÃÆäËûµÄ´°¸ñ×÷Ϊ²Î¿¼Ö®ÓÃʱ£¬ | 762 | µ±ÄãÔÚÒ»¸ö´°¸ñÖб༣¬µ«ÊÇÏëÓÃÁíÒ»¸ö´°¸ñ×÷²Î¿¼µÄʱºò£¬C-M-v ÊǺÜÓÐÓÃµÄ |
| 800 | ÊǷdz£ÓÐÓõġ£Äú¿ÉÒÔ½«ÓαêÒ»Ö±±£³ÖÔÚÄúÕýÔڱ༵Ĵ°¸ñÖУ¬²¢ÒÔ C-M-v Ö¸ | 763 | ÃüÁî¡£Äã¿ÉÒÔ±£³Ö¹â±êʼÖÕ´¦Óڱ༴°¸ñÖУ¬È»ºóÓà C-M-v ÃüÁîÔÚÁíÍâÒ»¸ö´°¸ñ |
| 801 | ÁîÔÚÆäËûµÄ´°¸ñÑÐòµØÇ°½ø¡£¡¾ÑéÖ¤¹¤×÷ÌØ±ðÊʺÏÒÔÕâÖÖ·½Ê½À´½øÐУ¬Èç GNU | 764 | Àï¹ö¶¯¡£¡¾·ÒëºÍУ¶Ô¾ÍºÜÊʺÏÓÃÕâÖÖ·½Ê½½øÐС£¡¿ |
| 802 | ÖÐÒëС×飺ÕÒÒ»¸öÔʼӢÎĵµ°¸£»ÔÙÕÒËü·ÒëºÃµÄÖÐÎĵµ°¸£¬±à¼Õâ¸ö¡¸±»Ñ¡Ôñ | ||
| 803 | µÄ´°¸ñ¡¹£¬ÒÔ C-M-v Ö¸Áî¸úÉÏÑéÖ¤ÖеĶÎÂä¡¡¡£¡¿ | ||
| 804 | 765 | ||
| 805 | C-M-v ÊÇ CONTROL-META ×ÖÔªµÄÒ»¸öÀý×Ó¡£Èç¹ûÄúÓÐÒ»¸öÕæµÄ META ¼ü£¬Äú¿ÉÒÔ | 766 | C-M-v ÊÇÒ»¸ö CONTROL-META ×éºÏ¼ü¡£Èç¹ûÄãÓÐ META ¼ü£¬Äã¿ÉÒÔͬʱ°´×¡ |
| 806 | ͬʱ°´×¡ CONTROL ºÍ META ÔÙ¼üÈë v À´¼üÈë C-M-v¡£CONTROL »ò META ¡¸ËÏÈ | 767 | CONTROL ºÍ META ¼üÈ»ºóÊäÈë v¡£CONTROL ºÍ META ¼üÄĸöÏȰ´Ã»ÓйØÏµ£¬ÒòΪ |
| 807 | ±»°´×¡¡¹²¢Ã»ÓÐÓ°Ï죬ÒòΪÕâÁ½¸ö¼ü¶¼ÊÇÓÃÀ´ÐÞÊÎÄúËù¼üÈëµÄ×ÖÔª¡£ | 768 | ËüÃÇÖ»ÊÇÓÃÀ´¡°ÐÞÊΣ¨modify£©¡±ÄãÊäÈëµÄ×Ö·ûµÄ¡£ |
| 808 | 769 | ||
| 809 | Èç¹ûÄú²¢Ã»ÓÐÒ»¸öÕæµÄ META ¼ü£¬Äú¿ÉÒÔʹÓà ESC À´×÷ÎªÌæ´ú£¬ÕâÑù×Ó˳Ðò¾Í | 770 | Èç¹ûÄ㲢ûÓÐ META ¼ü£¬ÄãÒ²¿ÉÒÔÓà ESC À´´úÌæ£¬²»¹ýÕâÑù×Ó°´¼ü˳Ðò¾ÍÓйØÏµ |
| 810 | ÓйØÏµÁË£ºÄú±ØÐë¼üÈë ESC £¬¸úÖø¼üÈë CONTROL-v£¬CONTROL-ESC v ²¢²»»á×÷ | 771 | ÁË£ºÄã±ØÐëÊäÈë ESC £¬È»ºóÔÙÊäÈë CONTROL-v¡£CONTROL-ESC v ÊÇûÓõģ¬ÒòΪ |
| 811 | Óá£ÕâÊÇÒòΪ ESC ÊÇÒ»¸ö¾ßÓб¾Éí×÷ÓõÄ×ÖÔª£¬¶ø²»ÊÇÒ»¸öÐÞÊμü¡£ | 772 | ESC ±¾ÉíÊÇÒ»¸ö×Ö·û¼ü£¬¶ø²»ÊÇÒ»¸öÐÞÊμü£¨modifier key£©¡£ |
| 812 | 773 | ||
| 813 | >> £¨ÔÚÉÏ·½´°¸ñ£©¼üÈë C-x 1 ÒÔ³ýȥϷ½´°¸ñ¡£ | 774 | >> £¨ÔÚÉÏ·½´°¸ñÀÊäÈë C-x 1 ¹ØµôÏ·½´°¸ñ¡£ |
| 814 | 775 | ||
| 815 | £¨Èç¹ûÄúÒѾÔڵ׶˵Ĵ°¸ñ¼üÈë C-x 1£¬ÄÇô½«»á°ÑÉÏÃæµÄ´°¸ñÒþ²Ø×¡¡£½«Õâ¸ö | 776 | £¨Èç¹ûÄãÔÚÏ·½µÄ´°¸ñÀïÊäÈë C-x 1£¬ÄÇô¾Í»á¹ØµôÉÏ·½µÄ´°¸ñ¡£Äã¿ÉÒÔ°ÑÕâ¸ö |
| 816 | Ö¸ÁîÏëÏñ³É¡¸Ö»±£ÁôÒ»¸ö´°¸ñ -- ÎÒÕýÔڱ༵ÄÕâ¸ö¡£¡¹£© | 777 | ÃüÁî¿´³ÉÊÇ¡°Ö»±£ÁôÒ»¸ö´°¸ñ¡±¡ª¡ª¾ÍÊÇÎÒÕýÔڱ༵ÄÕâ¸ö¡££© |
| 817 | 778 | ||
| 818 | Äú²»ÐèÒªÔÚÁ½¸ö²»Í¬µÄ´°¸ñÖÐÏÔʾÏàͬµÄ»º³åÇø¡£Èç¹ûÄúʹÓà C-x C-f ÔÚÒ»¸ö | 779 | ²»Í¬µÄ´°¸ñÀï¿ÉÒÔÏÔʾ²»Í¬µÄ»º³åÇø¡£Èç¹ûÄãÔÚÒ»¸ö´°¸ñÀïÓà C-x C-f ´ò¿ªÁË |
| 819 | ´°¸ñÖÐÕÒµµ°¸£¬ÁíÒ»¸ö´°¸ñ²¢²»Òò¶ø¸Ä±ä¡£Äú¿ÉÒÔÔÚ¶ÀÁ¢µÄÈÎÒ»¸ö´°¸ñÖÐÕÒ¡²Ëü | 780 | Ò»¸öÎļþ£¬ÁíÒ»¸ö´°¸ñ²¢²»»áÓÐʲô±ä»¯¡£ÔÚÈκÎÒ»¸ö´°¸ñÀï¶¼¿ÉÒÔ´ò¿ªÎļþ¡£ |
| 820 | ×Ô¼ºµÄ¡³Ò»¸öµµ°¸¡£ | ||
| 821 | 781 | ||
| 822 | ÕâÀïÓÐÁíÍâÒ»¸ö·½Ê½¿ÉÒÔÓÃÀ´£¬Ê¹ÓÃÁ½¸ö´°¸ñÏÔʾÁ½¸ö²»Í¬µÄ¶«Î÷£º | 782 | ÓÐÒ»ÖÖ·½Ê½¿ÉÒÔÈÃÄãÔÚÁíÒ»¸ö´°¸ñÀï´ò¿ªÎļþ£º |
| 823 | 783 | ||
| 824 | >> ¼üÈë C-x 4 C-f£¬ºóÃæ¸úÖøÄúµÄÆäÖÐÒ»¸öµµ°¸µÄÃû³Æ¡£ | 784 | >> ÊäÈë C-x 4 C-f£¬ºóÃæ½ô¸ú×ÅÊäÈëÒ»¸öÎļþÃû£¬Óà <Return> ½áÊø¡£ |
| 825 | ÒÔ <Return> ×÷Ϊ½áÊø¡£¿´¿´Ö¸¶¨µÄµµ°¸³öÏÖÔÚÏ·½µÄ´°¸ñ¡£ | 785 | ¿ÉÒÔ¿´µ½ÄãÖ¸¶¨µÄÎļþ³öÏÖÔÚÏ·½µÄ´°¸ñÖУ¬Í¬Ê±¹â±êÒ²Ìøµ½ÁËÄÇÀï¡£ |
| 826 | ÓαêÒ²Åܵ½ÄÇÀï¡£ | ||
| 827 | 786 | ||
| 828 | >> ¼üÈë C-x o ÒԻص½ÉÏ·½µÄ´°¸ñ£¬È»ºóÒÔ C-x 1 ɾ³ýµôÏ·½´°¸ñ¡£ | 787 | >> ÊäÈë C-x o »Øµ½ÉÏ·½µÄ´°¸ñ£¬È»ºóÔÙÓà C-x 1 ¹ØµôÏ·½´°¸ñ¡£ |
| 829 | 788 | ||
| 830 | 789 | ||
| 831 | * µÝ¹é±à¼½×²ã£¨ RECURSIVE EDITING LEVELS £© | 790 | * µÝ¹é±à¼£¨RECURSIVE EDITING LEVELS£© |
| 832 | -------------------------------------------- | 791 | -------------------------------------- |
| 833 | 792 | ||
| 834 | ÓÐʱºòÄú»á½øÈëËùνµÄ¡¸µÝ¹é±à¼½×²ã¡¹¡£ËüÊÇÓÉλÔÚ״̬Ðеķ½À¨»¡ËùÖ¸Ã÷£¬ | 793 | ÓÐʱºòÄã»á½øÈëËùνµÄ¡°µÝ¹é±à¼¡±¡£µÝ¹é±à¼×´Ì¬ÓÉλÓÚ״̬À¸µÄ·½À¨ºÅËùÖ¸ |
| 835 | ²¢ÇÒ°üº¬×¡ÒÔСÀ¨»¡À´Ö¸Ã÷µÄģʽÃû³Æ¡£¾ÙÀýÀ´Ëµ£¬Äú¿ÉÄܻῴµ½ | 794 | ʾ£¬ÆäÖаüº¬ÁËÓÃСÀ¨ºÅÀ´Ö¸Ã÷µÄģʽÃû³Æ¡£±ÈÈç˵£¬ÄãÓÐʱ¿ÉÄܻῴµ½ |
| 836 | [(Fundamental)]£¬¶ø²»ÊÇ (Fundamental)¡£ | 795 | [(Fundamental)]£¬¶ø²»ÊÇ (Fundamental)¡£¡¾±ÈÈçÔÚÓà M-% ½øÐн»»¥Ê½Ìæ»»µÄ |
| 796 | ʱºòÄãÓÖÓÃÁË C-s ½øÐÐËÑË÷£¬ÕâÊ±Ìæ»»Ä£Ê½²¢Ã»ÓнáÊø£¬µ«ÄãÓÖ½øÈëÁËËÑË÷ģʽ£¬ | ||
| 797 | Õâ¾ÍÊÇËùνµÄµÝ¹é±à¼¡£¡¿ | ||
| 837 | 798 | ||
| 838 | ÒªÀ뿪µÝ¹é±à¼½×²ã£¬Çë¼üÈë ESC ESC ESC¡£ÕâÊǸöÈ«¹¦Äܵġ¸À뿪¡¹Ö¸Áî¡£Äú | 799 | À뿪µÝ¹é±à¼¿ÉÒÔÓà ESC ESC ESC¡£ÕâÊÇÒ»¸ö×îͨÓõġ°À뿪¡±ÃüÁÄãÉõÖÁ¿É |
| 839 | Ò²¿ÉÒÔʹÓÃËüÀ´³ýÈ¥¶àÓàµÄ´°¸ñ£¬²¢ÇÒÀ뿪С»º³åÇø¡£ | 800 | ÒÔʹÓÃËüÀ´¹Øµô¶àÓàµÄ´°¸ñ£¬»òÕßÀ뿪С»º³å¡£ |
| 840 | 801 | ||
| 841 | >> ¼üÈë M-x ÒÔ½øÈëС»º³åÇø£»È»ºó¼üÈë ESC ESC ESC À뿪¡£ | 802 | >> ÊäÈë M-x ½øÈëС»º³å£»È»ºóÊäÈë ESC ESC ESC À뿪¡£ |
| 842 | 803 | ||
| 843 | ÄúÎÞ·¨Ê¹Óà C-g À´À뿪µÝ¹é±à¼½×²ã¡£ÕâÊÇÒòΪ C-g ÊÇÓÃÀ´È¡ÏûÖ¸ÁîÒÔ¼°¡¸Î» | 804 | Äã²»ÄÜÓà C-g À´À뿪µÝ¹é±à¼£¬ÒòΪ C-g µÄ×÷ÓÃÊÇÈ¡ÏûÃüÁîºÍ¡°²ÎÊý |
| 844 | ì¶¡¹µÝ¹é±à¼½×²ãÖеġ¸ÒýÊý£¨ arguments £©¡¹Ö®¹Ê¡£ | 805 | £¨arguments£©¡±£¬¶øÕâЩ¶«Î÷¶¼Î»ÓÚ±¾²ãµÝ¹é±à¼¡°Ö®ÄÚ¡±¡£ |
| 845 | 806 | ||
| 846 | 807 | ||
| 847 | * È¡µÃ¸ü¶àµÄ°ïÖú£¨ GETTING MORE HELP £© | 808 | * »ñµÃ¸ü¶à°ïÖú£¨GETTING MORE HELP£© |
| 848 | --------------------------------------- | 809 | ----------------------------------- |
| 849 | 810 | ||
| 850 | ÔÚ±¾¿ìËÙÖ¸ÄÏÖУ¬ÎÒÃÇÊÔÖø½öÌṩ¸Õ¸ÕºÃµÄÐÅÏ¢ÈÃÄú¿ÉÒÔ¿ªÊ¼Ê¹Óà Emacs¡£ÔÚ | 811 | ±¾¿ìËÙÖ¸ÄϵÄÄ¿µÄ½ö½öÊǰïÖúÄãѧ»áÔÚ Emacs µÄ´óº£ÀïÓÎÓ¾£¬²»ÖÁÓÚÒ»ÉÏÀ´¾ÍÑÍ |
| 851 | Emacs ÖÐÓÐÌ«¶à¿ÉÈ¡µÃµÄÐÅÏ¢£¬ÏëÒªÔÚÕâÀïÈ«²¿½âÊÍÊDz»¿ÉÄܵġ£È»¶ø£¬ÄúÒ²Ðí | 812 | ËÀ¡£ÓÐ¹Ø Emacs µÄ»°ÌâÈýÌìÈýÒ¹Ò²½²²»Í꣬ÕâÀï×ÔÈ»ÊÇд²»ÏÂÁË¡£Emacs ºÜÀí½â |
| 852 | »áÏëҪѧϰ¸ü¶à Emacs Ïà¹ØµÄÐÅÏ¢£¬ÒòΪËüÓÐÐí¶àÆäËûÓÐÓõŦÄÜ¡£Emacs Ìá | 813 | ÄãÇóÖªÈô¿ÊµÄÐÄÇ飬ÒòΪËüÌṩµÄÇ¿¾¢¹¦ÄÜʵÔÚÊÇÌ«¶àÁË¡£Emacs ÌṩÁËһЩÃü |
| 853 | ¹©ÁË¡¸ÔĶÁÓÐ¹Ø Emacs Ö¸ÁµÄÖ¸Áî¡£ÕâЩ¡¸help¡¹Ö¸Áî¶¼ÒÔ CONTROL-h Õâ¸ö | 814 | ÁîÀ´²é¿´ Emacs ÃüÁîµÄÎĵµ£¬ÕâЩÃüÁî¶¼ÒÔ CONTROL-h ¿ªÍ·£¬Õâ¸ö×Ö·ûÒ²Òò´Ë |
| 854 | ×ÖÔª×÷Ϊ¿ªÍ·£¬³Æ×÷Ϊ¡¸Help ×ÖÔª¡¹¡£ | 815 | ±»³ÆÎª¡°Help£¨°ïÖú£©×Ö·û¡±¡£ |
| 855 | 816 | ||
| 856 | ҪʹÓà Help ¹¦ÄÜ£¬¼üÈë C-h ×ÖÔª£¬È»ºóÔÙ¼üÈëÒ»¸ö˵Ã÷ÄúËùÐèÒªµÄ°ïÖúµÄ×Ö | 817 | ҪʹÓðïÖú£¨Help£©¹¦ÄÜ£¬ÇëÏÈÊäÈë C-h£¬È»ºóÔÙÊäÈëÒ»¸ö˵Ã÷ÄãÐèÇóµÄ×Ö·û¡£ |
| 857 | Ôª¡£Èç¹ûÄúÕæµÄ²»ÖªµÀÒªÎÊʲô£¬ÄÇôÇë¼üÈ롺C-h ?¡»£¬´Ëʱ Emacs ½«»á¸æËß | 818 | Èç¹ûÄãÔε½Á¬ÐèҪʲô°ïÖú¶¼²»ÖªµÀ£¬ÄÇô¾ÍÊäÈë C-h ?£¬Emacs »á¸æËßÄãËüÄÜ |
| 858 | ÄúËüÄܹ»ÌṩµÄ°ïÖú¡£Èç¹ûÄúÒѾ¼üÈë C-h£¬µ«·¢ÏÖÄú²¢²»ÐèÒªÈκΰïÖú£¬¼üÈë | 819 | ÌṩÄÄЩ°ïÖú¡£Èç¹ûÄãÒѾ°´ÁË C-h ÓÖÏë·´»Ú£¬ÄÇôÓà C-g È¡ÏûËü¾ÍÊÇÁË¡£ |
| 859 | C-g À´È¡ÏûµôËü¾ÍÊÇÁË¡£ | ||
| 860 | 820 | ||
| 861 | £¨ÓÐÐ©ÍøÕ¾½« C-h Õâ¸ö×ÖÔªµÄÒâÒå¸Ä±äÁË¡£ËûÃÇÕæµÄ²»Ó¦¸Ã°ÑËüÉèΪ¶ÔËùÓÐʹ | 821 | £¨ÓÐЩվµã¸Ä±äÁË C-h µÄÒâ˼£¬ËûÃÇÕâÖÖÒÔ¼º¶ÈÈËÍâ¼ÓÒ»µ¶ÇеÄ×ö·¨Èõ¹ÊÇÈÃÄã |
| 862 | ÓÃÕßÈ«²¿¶¼ÊÊÓõķ½·¨£¬ËùÒÔÄúÏÖÔÚ¾ÍÓÐÁ˸öÀíÓÉÀ´±§Ô¹ÏµÍ³¹ÜÀíÕßÁË¡£ÔÚ´Ëͬ | 822 | ¿ÉÒÔÒåÕý´ÇÑϵı§Ô¹ÏµÍ³¹ÜÀíÔ±£¬ÕæµÄ²»ÊÇÌ«ºÃ¡£»°Ëµ»ØÀ´£¬Èç¹ûÄã°´ C-h Ö®ºó |
| 863 | ʱ£¬Èç¹û C-h ²¢Ã»ÓÐÔÚ´°¸ñµÄµ×²¿ÏÔʾÈκÎÓйذïÖúµÄѶϢ£¬ÊÔÖø¼üÈë F1 ¼ü£¬ | 823 | ûÓÐÈκΰïÖúÐÅÏ¢ÏÔʾ³öÀ´£¬ÄÇôÊÔÊÔ F1 ¼ü»òÕß M-x help <Return>¡££© |
| 864 | »òÊÇ M-x help <Return>¡££© | ||
| 865 | 824 | ||
| 866 | ×î»ù±¾µÄ HELP ¹¦ÄÜÊÇ C-h c¡£¼üÈë C-h£¬×ÖÔª c£¬ÒÔ¼°Ò»¸ö»òÒ»´®×ÖÔª£»È»ºó | 825 | ×î»ù±¾µÄ°ïÖú¹¦ÄÜÊÇ C-h c¡£ÊäÈë C-h c Ö®ºóÔÚÊäÈëÒ»¸ö×éºÏ¼ü£¬Emacs »áºÜ¼ò |
| 867 | Emacs »áÏÔʾһ¸ö·Ç³£¼ò¶ÌµÄÓйØÕâ¸öÖ¸ÁîµÄ½âÊÍ¡£ | 826 | ÒªµØ¸ø³öÕâ¸öÃüÁîµÄ˵Ã÷¡£ |
| 868 | 827 | ||
| 869 | >> ¼üÈë C-h c C-p¡£ | 828 | >> ÊäÈë C-h c C-p¡£ |
| 870 | 829 | ||
| 871 | ѶϢӦ¸Ã»áÏñÊÇÕâÑù£º | 830 | ÏÔʾµÄÏûÏ¢Ó¦¸Ã»áÊÇÕâÑù£º |
| 872 | 831 | ||
| 873 | C-p runs the command previous-line | 832 | C-p runs the command previous-line |
| 874 | 833 | ||
| 875 | Õâ¸æËßÁËÄú¡¸º¯ÊýµÄÃû³Æ¡¹¡£º¯ÊýÃû³ÆÖ÷ÒªÊÇÓÃÀ´×Ô¶©ÒÔ¼°À©³ä Emacs¡£µ«ÊÇÓÉ | 834 | ÕâÌõÏûÏ¢ÏÔʾÁË C-p ÃüÁî¶ÔÓ¦µÄº¯ÊýÃû£¬º¯ÊýÃûÖ÷ÒªÓÃÀ´¶¨ÖƺÍÀ©Õ¹ Emacs¡£Ãü |
| 876 | 춺¯ÊýÃû³ÆÊÇÓÉ¡¸ÓÃÀ´Ö¸³öÕâÖ¸ÁîÔÚ×öЩʲô¡¹¶ø±»Ñ¡¶¨£¬ËüÃÇÒò´ËÒ²¿ÉÒÔ×÷Ϊ | 835 | ÁîµÄ¹¦ÄÜÓɺ¯ÊýÍê³É£¬ËùÒÔº¯ÊýÃû±¾ÉíÒ²¿ÉÒÔ±»¿´³ÉÊÇ×î¼òµ¥µÄÎĵµ¡ª¡ªÖÁÉÙ¶Ô |
| 877 | ·Ç³£¼ò¶ÌµÄÎĵµ -- ×ã¹»ÌáÐÑÄúÒѾѧ¹ýµÄÖ¸Áî¡£ | 836 | ÓÚÄãÒѾѧ¹ýµÄÃüÁîÀ´Ëµ£¬ËüÃǵĺ¯ÊýÃû×ãÒÔ½âÊÍËüÃÇËùÍê³ÉµÄ¹¤×÷ÁË¡£ |
| 878 | 837 | ||
| 879 | ¶à×ÖÔªÖ¸ÁîÏñÊÇ C-x C-s ºÍ £¨Èç¹ûÄúûÓÐ META »ò EDIT »ò ALT ¼ü£©<ESC>v | 838 | ¶à×Ö·ûÃüÁîÒ»Ñù¿ÉÒÔÓà C-h c À´²é¿´¡£ |
| 880 | Ò²¿ÉÒÔÔÚ C-h c ºóÃæ³öÏÖ¡£ | ||
| 881 | 839 | ||
| 882 | ҪȡµÃ¸ü¶àÓйØÒ»¸öÖ¸ÁîµÄÐÅÏ¢£¬Óà C-h k À´È¡´úʹÓà C-h c ¡£ | 840 | ÏëµÃµ½¸ü¶àµÄÐÅÏ¢£¬Çë°Ñ C-h c »»³É C-h k ÊÔÊÔ¿´¡£ |
| 883 | 841 | ||
| 884 | >> ¼üÈë C-h k C-p¡£ | 842 | >> ÊäÈë C-h k C-p¡£ |
| 885 | 843 | ||
| 886 | Õâ»áÔÚÒ»¸ö Emacs ´°¸ñÏÔʾÕâ¸öº¯ÊýµÄ˵Ã÷ÎĵµÒÔ¼°ËüµÄÃû³Æ¡£µ±ÄúÔĶÁÍêºó£¬ | 844 | ÉÏÃæµÄÃüÁî»áдò¿ªÒ»¸ö Emacs ´°¸ñ£¬²¢ÔÚÆäÖÐÏÔʾº¯ÊýµÄÃû³Æ¼°ÆäÎĵµ¡£Äã¶Á |
| 887 | ¼üÈë C-x 1 ÒÔÌøÀëÕâЩ°ïÖúÎÄ×Ö¡£Äú²¢²»ÐèÒªÂíÉϸúÖø×ö¡£Äú¿ÉÒÔ×öЩ±à¼£¬ | 845 | ÍêÖ®ºó£¬¿ÉÒÔÓà C-x 1 ¹ØµôÕâ¸ö°ïÖú´°¸ñ¡£µ±È»Äã²¢²»ÐèÒªÔÚ C-h k Ö®ºóÁ¢¼´ |
| 888 | µ±²Î¿¼µ½°ïÖúÎÄ×ÖʱÔÙ¼üÈë C-x 1¡£ | 846 | ÕâÑù×ö£¬ÄãÍêÈ«¿ÉÒÔÏÈÔڱ༴°¸ñÀï×öµã±ðµÄÊÂÇ飬ȻºóÔÙÓà C-x 1 ¹Øµô°ïÖú¡£ |
| 889 | 847 | ||
| 890 | ÕâÀïÓÐһЩÆäËûÓÐÓÃµÄ C-h Ñ¡Ï | 848 | »¹ÓÐһЩÆäËûÓÐÓÃµÄ C-h ÃüÁ |
| 891 | 849 | ||
| 892 | C-h f ½âÊÍÒ»¸öº¯Êý¡£ÄúÒª¼üÈë´Ëº¯ÊýµÄÃû³Æ¡£ | 850 | C-h f ½âÊÍÒ»¸öº¯Êý¡£ÄãÒªÊäÈ뺯ÊýÃû¡£ |
| 893 | 851 | ||
| 894 | >> ÊÔÖø¼üÈë C-h f previous-line<Return>¡£ | 852 | >> ÊÔÊÔ¿´£¬ÊäÈë C-h f previous-line<Return>¡£ |
| 895 | Õâ»áÓ¡³ö Emacs ËùÓеÄÓйء¸Êµ×÷³ö C-p Õâ¸öÖ¸ÁîµÄº¯Êý¡¹µÄÐÅÏ¢ | 853 | Emacs »á¸ø³öËüËùÖªµÀµÄËùÓÐÓйء°ÊµÏÖ C-p ÃüÁÄܵĺ¯Êý¡±µÄÐÅÏ¢¡£ |
| 896 | 854 | ||
| 897 | C-h v Õâ¸öÀàËÆµÄÖ¸Áî»áÏÔʾ³ö¡¸Äú¿ÉÒÔÓÃÀ´×Ô¶© Emacs ÐÐΪµÄ±äÊý¡¹µÄÎĵµ¡£ | 855 | C-h v ÓÃÀ´ÏÔʾ Emacs ±äÁ¿µÄÎĵµ£¬Emacs ±äÁ¿¿ÉÒÔ±»ÓÃÀ´¡°¶¨ÖÆ Emacs µÄÐÐ |
| 898 | µ± Emacs ÒªÇóʱ£¬ÄúÐèÒª¼üÈëÕâ±äÊýµÄÃû³Æ¡£ | 856 | Ϊ¡±¡£Í¬Ñù£¬ÄãÐèÒªÊäÈë±äÁ¿µÄÃû³Æ¡£ |
| 899 | 857 | ||
| 900 | C-h a Ö¸ÁîÏà¹Ø²éÕÒ£¨ Command Apropos £©¡£ | 858 | C-h a Ïà¹ØÃüÁîËÑË÷£¨Command Apropos£©¡£ |
| 901 | ¼üÈëÒ»¸ö¹Ø¼ü×ÖÈ»ºó Emacs »áÁгöËùÓÐ | 859 | ÊäÈëÒ»¸ö¹Ø¼ü´ÊÈ»ºó Emacs »áÁгöËùÓÐÃüÁîÃûÖаüº¬´Ë¹Ø¼ü´Ê |
| 902 | ¡¸ÔÚÆäÃû³ÆÖк¬Óд˹ؼü×Ö¡¹µÄÈ«²¿Ö¸Áî¡£ | 860 | µÄÃüÁî¡£ÕâЩÃüÁîÈ«¶¼¿ÉÒÔÓà M-x À´Æô¶¯¡£¶ÔÓÚijЩÃüÁîÀ´Ëµ£¬ |
| 903 | ÕâЩָÁîÈ«²¿¶¼¿ÉÒÔ¾ÓÉ META-x À´Æô¶¯¡£ | 861 | Ïà¹ØÃüÁîËÑË÷»¹»áÁгöÒ»Á½¸ö×éºÏ¼ü¡£ |
| 904 | ¶Ôì¶Ò»Ð©Ö¸Áî¶øÑÔ£¬Ö¸ÁîÏà¹Ø²éÕÒÒ²»áÁгö | ||
| 905 | ¡¸¿ÉÒÔÖ´ÐÐÏàָͬÁµÄÒ»¸ö»òÁ½¸ö×ÖÔªµÄ´®ÁС£ | ||
| 906 | 862 | ||
| 907 | >> ¼üÈë C-h a file<Return>¡£ | 863 | >> ÊäÈë C-h a file<Return>¡£ |
| 908 | 864 | ||
| 909 | Õâ»áÔÚÁíÒ»¸ö´°¸ñÏÔʾһ¸ö¡¸ÔÚÆäÃû³ÆÖк¬ÓСºfile¡»µÄÈ«²¿ M-x Ö¸ÁµÄÁÐ | 865 | Emacs »áÔÚÁíÒ»¸ö´°¸ñÀïÏÔʾһ¸ö M-x ÃüÁîÁÐ±í£¬Õâ¸öÁбí°üº¬ÁËËùÓÐÃû³ÆÖк¬ |
| 910 | ±í¡£Äú½«»á¿´µ½ÏñÊÇ C-x C-f µÄ¡¸×ÖÔª-Ö¸ÁÁÐÔÚÆäÏà¶ÔÓ¦Ö¸ÁîÃû³Æ£¨È磺 | 866 | ÓС°file¡±µÄÃüÁî¡£Äã¿ÉÒÔ¿´µ½Ïñ¡°C-x C-f¡±ÕâÑùµÄ×éºÏ¼üÏÔʾÔÚ¡°find-file¡± |
| 911 | find-file £©µÄÅԱߡ£ | 867 | ÕâÑùµÄÃüÁîÃûµÄÅԱߡ£ |
| 912 | 868 | ||
| 913 | >> ¼üÈë C-M-v ÉÏÏÂÒÆ¶¯ help ´°¸ñ¡£ÊÔ¸ö¼¸´Î¡£ | 869 | >> Óà C-M-v À´»Ø¹ö¶¯ help ´°¸ñ£¬¶àÊÔ¼¸´Î¡£ |
| 914 | 870 | ||
| 915 | >> ¼üÈë C-x 1 À´É¾³ý help ´°¸ñ¡£ | 871 | >> ÊäÈë C-x 1 À´É¾³ý help ´°¸ñ¡£ |
| 916 | 872 | ||
| 917 | C-h i ÔĶÁÏßÉÏʹÓÃÊֲᣨ a.k.a. Info £©¡£ | 873 | C-h i ÔĶÁÁª»úÊֲᣨҲ¾ÍÊÇͨ³£½²µÄ Info£©¡£ |
| 918 | Õâ¸öÖ¸ÁÄú´øµ½Á˳ÆÎª¡¸*info*¡¹µÄÌØÊ⻺³åÇø£¬ÔÚÄÇ£¬ | 874 | Õâ¸öÃüÁî»á´ò¿ªÒ»¸ö³ÆÎª¡°*info*¡±µÄÌØÊ⻺³åÇø£¬ÔÚÄÇÀ |
| 919 | Äú¿ÉÒÔÔĶÁ°²×°ÔÚÄúµÄϵͳÀïµÄÈí¼þ°üµÄÏßÉÏʹÓÃÊֲᡣ | 875 | Äã¿ÉÒÔÔĶÁ°²×°ÔÚϵͳÀïµÄÈí¼þ°üʹÓÃÊֲᡣҪ¶Á Emacs µÄʹ |
| 920 | ¼üÈë m emacs <Return> ÒÔÔĶÁ Emacs ʹÓÃÊֲᡣ | 876 | ÓÃÊֲᣬ°´ m emacs <Return> ¾Í¿ÉÒÔÁË¡£Èç¹ûÄã֮ǰ´ÓûÓà |
| 921 | Èç¹ûÄúÔÚ´ËÖ®Ç°Î´ÔøÊ¹Óùý Info ϵͳ£¬Çë¼üÈ롺?¡»¡£ | 877 | ¹ý Info ϵͳ£¬ÄÇôÇë°´¡°?¡±£¬Emacs »á´øÄã½øÈë Info µÄʹ |
| 922 | Emacs ½«»á´øÄú½øÈë Info ģʽ¹¦Äܵĵ¼ÀÀÖ¸ÄÏ¡£ | 878 | ÓÃÖ¸ÄÏ¡£ÔÚ¿´Íê±¾¿ìËÙÖ¸ÄÏÖ®ºó£¬Emacs Info »á³ÉΪÄãµÄÖ÷Òª |
| 923 | Ò»µ©Íê³ÉÁ˱¾¿ìËÙÖ¸ÄϵÄÑжÁ£¬ÄúÓ¦¸Ã²éÔÄ Emacs Info | 879 | ²Î¿¼Îĵµ¡£ |
| 924 | ʹÓÃÊֲᣬÒÔ×÷ΪÖ÷ÒªµÄ²Î¿¼Îĵµ¡£ | ||
| 925 | 880 | ||
| 926 | 881 | ||
| 927 | * ¸ü¶à¹¦ÄÜÌØÉ«£¨ MORE FEATURES £© | 882 | * ¸ü¶à¾«²Ê£¨MORE FEATURES£© |
| 928 | --------------------------------- | 883 | --------------------------- |
| 929 | 884 | ||
| 930 | Äú¿ÉÒÔ¾ÓÉÔĶÁ Emacs ʹÓÃÊֲᡴ²»ÂÛÊÇÒ»±¾Êé»òÊÇÔÚ Info ÖеÄÏßÉϰ汾 | 885 | ÏëÁ˽â¸ü¶àʹÓà Emacs µÄ֪ʶ£¬Ó¦¸ÃÈ¥¶ÁÒ»¶Á Emacs ʹÓÃÊֲᡪ¡ª¿ÉÒÔÊÇÖ½°æ |
| 931 | £¨Ê¹Óà Help Ñ¡µ¥»òÊǼüÈë F10 h r £©¡µÀ´Ñ§µ½¸ü¶àÓйØËüµÄ֪ʶ¡£ÓÐÁ½¸öÄú | 886 | µÄÊ飬Ҳ¿ÉÒÔÊǵç×Ó°æµÄÁª»ú°ïÖú£¨¿ÉÒÔ´Ó Help ²Ëµ¥½øÈë»òÕß°´ F10 h r£©¡£ |
| 932 | ¿ÉÄÜ»áÌØ±ðϲ»¶µÄ¹¦ÄÜÌØÉ«ÊÇ¿ÉÒÔ½ÚÊ¡´ò×ÖÁ¿µÄ completion »¹Óмò»¯µµ°¸´¦Àí | 887 | ÌáÁ½¸öÄã¿ÉÄÜ»áºÜ¸ÐÐËȤµÄ¹¦Äܰɣ¬Ò»¸öÊÇ¿ÉÒÔ°ïÄãÉÙÇüüÅÌµÄ completion£¨×Ô |
| 933 | µÄ dired ¡£ | 888 | ¶¯²¹È«£©£¬Ò»¸öÊÇ·½±ãÎļþ´¦ÀíµÄ dired£¨Ä¿Â¼±à¼£©¡£ |
| 934 | 889 | ||
| 935 | Completion ÊÇÒ»ÖÖ±ÜÃâ²»±ØÒªµÄ´ò×ֵķ½Ê½¡£¾ÙÀýÀ´Ëµ£¬Èç¹ûÄúÏëÒªÇл» | 890 | Completion ¿ÉÒÔÌæÄã½ÚÊ¡²»±ØÒªµÄ¼üÅÌÊäÈë¡£±ÈÈç˵ÄãÏëÇл»µ½ *Message* »º |
| 936 | *Messages* »º³åÇø£¬Äú¿ÉÒÔ¼üÈë C-x b *M<Tab> £¬Ö»Òª¿ÉÒÔ´ÓÄúÒѾ¼üÈëµÄÎÄ | 891 | ³åÇø£¬Äã¾Í¿ÉÒÔÓà C-x b *M<Tab> À´Íê³É£¬Ö»Òª Emacs Äܹ»´ÓÄãÒѾÊäÈëµÄÎÄ |
| 937 | ×ÖÖÐÈ·¶¨£¬ Emacs ¾Í»á½«Ê£ÏµĻº³åÇøÃû³Æ²¹Æë¡£ Completion ÊÇÔÚ Emacs ʹ | 892 | ×ÖÖÐÅжϳöÄãÏëÒªÊäÈëµÄ¶«Î÷£¬Ëü»á×Ô¶¯°ïÄã²¹ÆëÓàϵġ£ÓÐ¹Ø Completion µÄ |
| 938 | ÓÃÊÖ²áµÄ Info ÖУ¬³ÆÎª¡¸Completion¡¹µÄ½ÚµãÖÐËù½âÊ͵ġ£ | 893 | Ïêϸ½âÊÍ¿ÉÒÔÔÚ Emacs Info Öеġ°Completion¡±Ò»½ÚÀïÕÒµ½¡£ |
| 939 | 894 | ||
| 940 | Dired ʹÄú¿ÉÒÔÔÚÒ»¸öĿ¼ÖÐÁгöµµ°¸£¨´ÎĿ¼ÔòÊÇ¿ÉÑ¡µÄ£©¡¢ÔÚÁбíÖе½´¦ÒÆ | 895 | Dired ¿ÉÒÔÔÚÒ»¸ö»º³åÇøÀïÁгöÒ»¸öĿ¼ÀïµÄËùÓÐÎļþ£¨¿ÉÒÔÑ¡ÔñÊÇ·ñÒ²Áгö×Ó |
| 941 | ¶¯¡¢°Ý·Ã¡¢ÖØÐÂÃüÃû¡¢É¾³ýÒÔ¼°¶Ôµµ°¸×÷²Ù×÷¡£ Dired ÊÇÔÚ Emacs ʹÓÃÊÖ²áµÄ | 896 | Ŀ¼£©£¬È»ºóÄã¿ÉÒÔÔÚÕâ¸öÎļþÁбíÉÏÍê³É¶ÔÎļþµÄÒÆ¶¯¡¢·ÃÎÊ¡¢¸ÄÃû»òÕßɾ³ý |
| 942 | Info ÖУ¬³ÆÎª¡¸Dired¡¹µÄ½ÚµãÖÐËù½âÊ͵ġ£ | 897 | µÈµÈ²Ù×÷¡£Dired Ò²ÔÚ Emacs Info ÖÐÓÐÏêϸ˵Ã÷£¬¾ÍÔÚ¡°Dired¡±Ò»½Ú¡£ |
| 943 | 898 | ||
| 944 | ʹÓÃÊÖ²áÒ²½âÊÍÁËÐí¶àÆäËü Emacs µÄ¹¦ÄÜÌØÉ«¡£ | 899 | Emacs ʹÓÃÊÖ²áÀﻹÓкܶàºÜ¶àµÄ¾«²Ê¹¦ÄܵÈ×ÅÄãÀ´Á˽⡣ |
| 945 | 900 | ||
| 946 | 901 | ||
| 947 | * ½áÂÛ£¨ CONCLUSION £© | 902 | * ×ܽᣨCONCLUSION£© |
| 948 | ---------------------- | 903 | -------------------- |
| 949 | 904 | ||
| 950 | ¼Çס£¬ÒªÍêÈ«À뿪 Emacs ÇëʹÓà C-x C-c ¡£ÒªÔÝʱÀ뿪µ½ shell£¬ÉÔºóÔٻص½ | 905 | ¼Çס£¬ÒªÍ˳ö Emacs ÇëÓà C-x C-c¡£ÒªÔÝʱÇл»µ½ shell ²¢ÇÒÉÔºóÔٻص½ |
| 951 | Emacs£¬ÇëʹÓà C-z ¡£ | 906 | Emacs ÀïÀ´£¬ÇëÓà C-z¡£¡¾Çл»µ½ shell ½ö¶Ô¿ØÖÆÌ¨Ï嵀 Emacs ÓÐЧ¡¿ |
| 952 | 907 | ||
| 953 | ±¾¿ìËÙÖ¸Ä϶Ôì¶ËùÓеÄÐÂÊÖÓ¦¸Ã¶¼ÊÇÒ×ì¶Àí½âµÄ£¬ËùÒÔÈç¹ûÄú·¢ÏÖÁËʲôµØ·½²» | 908 | ±¾ÎÄÍêÈ«ÊÇΪÁãÆðµãÐÂÊÖдµÄɵ¹Ï½Ì³Ì¡£Èç¹ûÄã¾õµÃÄÄÀﻹ¿´²»Ã÷°×£¬Ç§Íò²»Òª |
| 954 | Çå³þ£¬²»ÒªÖ»ÊÇ×øÖø¹Ö×Ô¼º -- £¨Ïò±¾ÎÄ×÷ÕߺͷÒ룩·¢µãÀÎɧ°É£¡ | 909 | ¾õµÃ²»ºÃÒâ˼£¬ÄÇÒ»¶¨ÊÇÎÒÃÇûÓÐдºÃ¡£ÎÒÃÇÓÀÔ¶»¶ÓÄãµÄ²»ÂúºÍ±§Ô¹¡£ |
| 955 | 910 | ||
| 956 | 911 | ||
| 957 | * ·Ò루 TRANSLATION £© | 912 | * ·Ò루TRANSLATION£© |
| 958 | ----------------------- | 913 | --------------------- |
| 959 | 914 | ||
| 960 | ±¾¿ìËÙÖ¸ÄϵķÒëÈËÔ±ÁбíÈçÏ£¬Èç¹ûÄúÔÚÔĶÁ±¾ÎÄ֮ǰ£¬¡¸ÍêÈ«¡¹¶Ô Emacs | 915 | ·Ò룺Ëï Ò»½ <sunyijiang@gmail.com> |
| 961 | ûÓиÅÄÇë¸æËßÎÒÃÇÄúµÄÒâ¼ûÒÔ×÷Ϊ±¾ÎĺóÐøµÄ¸Ä½øÒÀ¾Ý¡£·ÒëÒ²ÌṩÁËÒ»·Ý | 916 | У¶Ô£ºË®Ä¾ÉçÇø£¨www.newsmth.net£©Emacs °åÖÚ¶àÍøÓÑ |
| 962 | ¡¶GNU Emacs ÖÐÎÄ´¦Àí˵Ã÷¡·ÔÚ | 917 | |
| 963 | http://www.gnu.org/software/chinese/guide/emacs-chinese.cn.html ¡´²¿·Ý | 918 | Emacs ¿ìËÙÖ¸ÄÏ£¨Tutorial£©ÔçÓÐÁ½¸öÁõÕѺêµÄÖÐÎÄÒë±¾£¬·±¼ò¸÷Ò»¡£Æä¼òÌå°æ±¾ |
| 964 | ÄÚÈÝÒѾÕûÀíµ½±¾¿ìËÙÖ¸ÄÏ¡µ£¬Ò²ÇëÄú×ÔÐвÎÔÄ¡£ | 919 | £¨TUTORIAL.cn£©»ù±¾ÓÉ·±Ìå°æ±¾£¨TUTORIAL.zh£©¾´ÊÓïÌæ»»¶øµÃ¡£È»¶ø·±¼òÖÐÎÄ |
| 965 | 920 | ²»½öÔÚÓôÊϰ¹ßÉÏÓÐËù²»Í¬£¬¸üÓÐÖî¶à±í´ï·½Ê½ºÍ¾ä·¨·½ÃæµÄ²îÒì¡£Òò´ËÒ»Ö±ÒÔÀ´ | |
| 966 | ±à¼Æ÷ÊǵçÄÔʹÓÃÕß×î³£½Ó´¥µ½µÄÓ¦ÓóÌʽ£¬Òò´Ë²»Ó¦¸ÃÈóõѧÕ߸е½¹ýì¶À§ÄÑ£¬ | 921 | ÔĶÁ TUTORIAL.cn ¶¼ÂÔ¾õ»ÞɬºÍÉúÓ²¡£Õâ´ÎÖØÐ·Òë TUTORIAL.cn µÄ¶¯»úÕýÊÇÔ´ |
| 967 | ¾ÍÒ»°ãµÄÆÀÂÛÀ´Ëµ£¬ Emacs ÊDz»ÄÑѧ»áʹÓÃµÄ±à¼Æ÷£¬µ«ÄúµÄÒâ¼û¿ÉÒÔʹËü¸ü | 922 | ÓÚÕâÖÖÌåÑ飬ϣÍûÎÒÃǵŤ×÷Äܹ»Èñ¾ÎĸüºÃµÄ·¢»ÓÆäÓ¦ÓеÄ×÷Óá£TUTORIAL.zh |
| 968 | ΪÌù½üÒ»°ãµÄʹÓÃÕߣ¬²¢Ê¹µçÄÔ×÷Ϊ¹¤¾ßµÄ½ÇÉ«µÃÒÔ³ä·Ö·¢»Ó¡£Èç¹ûÄúÔ¸ÒâÌṩ | 923 | µÄÒëÎÄÖÊÁ¿ºÜ¸ß£¬ÔÚ·Òë¹ý³ÌÖиøÓè¹ýÎÒÃǺܶà½è¼øºÍ²Î¿¼£¬Ôڴ˶ÔÁõÕѺêµÄ¹¤×÷ |
| 969 | ¸Ä½øµÄÒâ¼û£¬Çë¼Ä email µ½<chinese-translators@gnu.org> ¡£Çë²»Òªº¦Ðߣ¬ | 924 | ±íʾ¸Ðл¡£ |
| 970 | ÎÒÃÇ»¶ÓÈκÎÓйصÄÌÖÂÛ£»Èç¹ûÄú²»Ïë¼Äµ½ÓʼþÇåµ¥£¬ÇëÖ±½Ó email ¸ø±¾ÎÄ· | 925 | |
| 971 | Òë <chliu@gnu.org> ¡£ÇëÔÚ Title ÐÐÖаüº¬´Ë×Ö´®¡¸Emacs TUTORIAL: <your | 926 | ·Òë¹ý³ÌÖÐ×î´óµÄÌôսιýÓÚÊõÓïÒë´ÊµÄÑ¡ÔñÁË¡£¾¹ýˮľÉçÇø Emacs °åÈÈÐÄÍø |
| 972 | issue here>¡¹¡£ | 927 | ÓÑС·¶Î§ÄÚµÄÌÖÂÛ£¬ÎÒÃÇÑ¡ÔñÁËÏÖÔÚµÄÒë·¨¡£Óû§µÄ¹ã·º²ÎÓëÊÇ×ÔÓÉÈí¼þÉúÃüÁ¦µÄ |
| 973 | 928 | ԴȪ£¬ËùÒÔÈç¹ûÄãÓÐÈκν¨Òé¡¢¿±Îó»ò¸üºÃµÄÏë·¨£¬ÇëÓÃÄãϲ»¶µÄ·½Ê½ÏòÎÒÃÇÌá³ö | |
| 974 | Èç¹ûÄúÊÇ Emacs ÀÏÊÖ£¬GNU Chinese Translators Team (GNU/CTT) | 929 | ¡£Äã¿ÉÒÔÖ±½Ó¸øÎÒ·¢µç×ÓÓʼþ£¬Ò²¿ÉÒԷŵ½ GNU Emacs µÄ¿ª·¢ÓʼþÁбí»òÕßˮľ |
| 975 | <http://www.gnu.org/software/chinese/> »¶ÓÄúµÄ¼ÓÈ룬ÎÒÃÇÏÖÔÚÕýÐèÒªÔ¸ | 930 | ÉçÇøµÄ Emacs °åÉϽøÐÐÌÖÂÛ¡£ÏÂÃæÁгöÖ÷ÒªÊõÓïµÄÒë´Ê¶ÔÕÕ£¬²¢¸ø³ö×¢ÊÍ˵Ã÷£º |
| 976 | ÒâͶÈë·Òë Emacs ʹÓÃÊÖ²áµÄÈËÔ±¡£ | 931 | |
| 977 | 932 | command ÃüÁî | |
| 978 | ±¾¿ìËÙÖ¸Äϲ¢Ã»ÓвÉÓÃϰ¹ßÉÏ±à¼Æ÷ËùʹÓõķÒëÊõÓһ·½ÃæÒòΪËüµÄʵ¼ÊÒâ | 933 | cursor ¹â±ê |
| 979 | ÒåÓëÒ»°ãµÄ±à¼Æ÷²»Í¬£¬ÔÎı¾¾Í²»Í¬£»ÁíÒ»·½ÃæÒ²ÒòΪ Emacs Ëù²ÉÓõÄÊÓ¾õ | 934 | scrolling ¹ö¶¯ |
| 980 | Éè¼Æ¸ÅÄÔçÔÚ´°¿Ú»¯ÏµÍ³Ö®Ç°¾ÍÒѾ´æÔÚ£¬±¾ÖÊÒ²²»Ïàͬ¡£×ÜÖ®£¬·ÒëÒÔΪÕâ | 935 | numeric argument Êý×Ö²ÎÊý |
| 981 | Ñù¿ÉÒÔ°ïÖú¶Ôì¶ Emacs Õû¸öÉè¼ÆÕÜѧµÄÀí½â¡£Èç¹ûÊÕµ½µÄ»Ø¸²ÖУ¬´ó²¿·ÝÒªÇó | 936 | window ´°¸ñ [1] |
| 982 | Ìá³öÐ޸ģ¬ÎÒÃÇ»¹ÊÇ´ÓÉÆÈçÁ÷¡£ | 937 | insert ²åÈë |
| 983 | 938 | delete ɾ³ý [2] | |
| 984 | (0) ΪÁ˱ÜÃ⡸ÓαêÒÆ¶¯Ö¸ÁÂÛÊöÉϵĻìÏý£¬±¾ÎIJÉÓõÄÊõÓïΪ£º | 939 | kill ÒÆ³ý [2] |
| 985 | Íù¡¸Ç°¡¹ÒÆ£¨ move Forward £©£»Íù¡¸ºó¡¹ÒÆ£¨ move Backware £© | 940 | yank ÕÙ»Ø [2] |
| 986 | ¡²»òÊÇÍù¡¸»Ø¡¹ÒÆ¡³£» | 941 | undo ³·Ïú |
| 987 | Íù¡¸ÉÏ¡¹ÒÆ£¨ Previous line £©£»Íù¡¸Ï¡¹ÒÆ£¨ Next line £©¡£ | 942 | file Îļþ |
| 988 | (1) ÔÚ±¾ÎÄÖУ¬¡¸ÐС¹Ö¸µÄÊÇ row£¬ÕâÊDzÉÓÃÒ»°ãµÄϰ¹ßÓ÷¨¡£ | 943 | buffer »º³åÇø |
| 989 | ΪÁ˱ÜÃâÎóµ¼ÖÐÎĶÁÕߣ¬ÌرðÔÚ´Ë˵Ã÷¡£ÔÚÕýʽµÄÓ÷¨ÖУº | 944 | minibuffer С»º³å |
| 990 | ¡¸column¡¹·ÒëΪ¡¸ÐС¹£¬ÒÔ¡¸×Ý¡¹ÎªÐУ¨Ö±ÐУ©£¬Ò²ÒëΪ¡¸À¸¡¹£» | 945 | echo area »ØÏÔÇø |
| 991 | ¡¸row¡¹·ÒëΪ¡¸ÁС¹£¬ÒÔ¡¸ºá¡¹ÎªÁУ¨ºáÁУ©¡£ | 946 | mode line ״̬À¸ |
| 992 | ¶ÁÕß˼Ë÷һϡ¸ºÏ×ÝÁ¬ºá¡¹Ó¦¸Ã¿ÉÒÔÀí½â¡£ | 947 | search ËÑË÷ |
| 993 | ´óÔ¼ÊÇÒòΪÖÐÎÄÔ±¾ÊÇÖ±ÊéµÄ£¬ÎÒÃÇ˵¡¸Ò»ÐÐ×Ö¡¹ÊÇûÎÊÌ⣻ | 948 | incremental search ½¥½øÊ½ËÑË÷ [3] |
| 994 | µ«ÏÖÔڴ󲿷ݵÄÇéÐÎÖÐÎÄÊǺáÊéµÄ£¬ÓÉì¶Ï°¹ßʹȻҲ³ÆÎªÒ»ÐÐ×ÖÁË¡£ | 949 | |
| 995 | (2) ÓйØì¶¡¸ÎÄ×Ö¡¹¼°Æä¼¯ºÏµÄÏà¹ØÒëÎÄ£¬·ÒëËù²ÉÓõÄÓУº | 950 | [1] ¡°window¡±Ò»´ÊÔÚ¼ÆËã»úÏà¹ØµÄÁìÓòÒ»°ã¶¼±»ÒëΪ¡°´°¿Ú¡±¡£µ«ÊÇÔÚ Emacs |
| 996 | ±à¼µÄ¡¸ÎÄ×Ö¡¹£º¡¸È»ºó¼üÈëһЩÎÄ×Ö¡¹£» | 951 | ÖУ¬»¹ÓÐÒ»¸ö¡°frame¡±µÄ¸ÅÄî¡£ÔÚ±»¹ã·ºÊ¹ÓÃµÄ X ´°¿ÚϵͳºÍ΢ÈíµÄÊÓ´° |
| 997 | ÓÃÀ´×÷Ϊ˵Ã÷¹¦Äܵġ¸Îĵµ¡¹£º¡¸Õâ¸öº¯ÊýµÄ˵Ã÷Îĵµ¡¹£» | 952 | £¨Windows£©ÏµÁвÙ×÷ϵͳÖУ¬Emacs µÄÒ»¸ö¡°frame¡±¾ÍÊÇÒ»¸ö¡°´°¿Ú¡±£¬Òò |
| 998 | ÌØÖ¸ÆäËù˵Ã÷µÄÄÚÈݵġ¸Îı¾¡¹£º¡¸Êµ¼ÊЧÁ¦ÒÔÓ¢Îı¾Îª×¼¡¹¡£ | 953 | ´Ë°Ñ Emacs Öеġ°frame¡±Òë³É¡°´°¿Ú¡±¸ü¼Ó·ûºÏͨ³£µÄϰ¹ß¡£ÕâÑù£¬Emacs |
| 999 | ¼´Ê¹Ö»ÊÇ¡¸Ò»ÐÐ×Ö¡¹£¬Ö»ÒªËüÊÇÓÃÀ´×÷Ϊ˵Ã÷Ö®Ó㬠| 954 | Öеġ°window¡±¾ÍÖ»ÄÜÒë³É¡°´°¸ñ¡±ÁË¡£ÎÒÃÇÈÏΪ Emacs ÖÐ window ºÍ |
| 1000 | ·Ò뻹Êǽ«ËüÊÓΪ¡¸Îĵµ¡¹¡£ | 955 | frame µÄ¹ØÏµÓô°¸ñºÍ´°¿ÚÀ´Àà±ÈÊÇÊ®·ÖÐÎÏóµÄ¡£ |
| 1001 | (3) ¡¸cut¡¹µÄ¶¯×÷ÔÚ Emacs ÖзÖΪ¡¸É±µô¡¹ºÍ¡¸É¾³ý¡¹£¬Ö®¼äµÄ²îÒìÈçÏ£º | 956 | |
| 1002 | Ò»°ã±à¼Æ÷Öеġ¸cut¡¹£ºÖ»ÓÐ×î½ü±» cut µÄÎÄ×Ö°Úµ½ clipboard ÖУ» | 957 | [2] ¶ÔÓÚ¡°delete¡±ºÍ¡°kill¡±µÄÇø±ð£¬ÕýÎÄÒѾ¸ø³öÁËÏêϸµÄ˵Ã÷¡£¡°É¾³ý¡±ºÍ |
| 1003 | ¡¸É±µô£¨ killing £©¡¹£º±»É±µôµÄÎÄ×Ö£¬È«²¿±»¼ÓÈëµ½ kill ring ÖУ» | 958 | ¡°ÒƳý¡±Ïà±È½ÏÆðÀ´£¬Ç°Õ߸ü¶àµØÒþº¬×Å¡°ÆÆ»µ¡±ºÍ¡°²»¿É»Ö¸´¡±µÄÒâ˼£¬¶ø |
| 1004 | ¡¸É¾³ý£¨ deleting £©¡¹£º±»É¾³ýµÄÎÄ×Ö£¬¾ÍÊDZ»É¾³ýÁË¡£ | 959 | ºóÕ߸ü¶àµØÒþº¬×Å¡°±»×ªÒÆ¡±ºÍ¡°¿É»Ö¸´¡±µÄÒâ˼¡£Òò´Ë·Ö±ðÑ¡ÔñËüÃÇ×÷ΪÉÏ |
| 1005 | Òò´ËÔÚÒ»°ã±à¼Æ÷ÖУ¬ÄúÖ»ÄÜ paste¡¸×î½ü¡¹±» cut µÄÎÄ×Ö£» | 960 | ÊöÁ½´ÊµÄÒë´Ê£¬Ï£ÍûÄܹ»ÌåÏÖ³öÇø±ð¡£¡°yank¡±ÔÚÖÐÎÄÎĵµÖÐÏÊÓжÔÓ¦Òë´Ê³ö |
| 1006 | ¶øÔÚ Emacs ÖУ¬Äú¿ÉÒÔ¡¸À»Ø¡¹ÈκÎÏÈǰ±»É±µôµÄÎÄ×Ö£¬Í¬Ê±£¬ | 961 | ÏÖ£¬·ÒëµÄÀ§Äѽϴ󡣾¿Æä±¾ÒâÊÇ£º¡°a strong sudden pull¡±£¨²Î¼ûΤÊÏ´Ê |
| 1007 | ËüµÄ×÷·¨ºÜÈÝÒס£ÖÁì¶±»É¾³ýµÄ£¬ÒòΪÓÃÀ´×÷Ϊ¡¸É¾³ý¡¹¹¦ÄܵÄÖ¸Á | 962 | µä£©£¬¼´¡°ÃÍÈ»À»Ø¡±¡£ÔÚÔÎĵµÖÐ yank ±»ÒýÉêΪ¡°½«ÏÈÇ°ÒÆ³ýµÄ¶«Î÷ÔÙÒÆ |
| 1008 | ËùÄÜÒÆÈ¥µÄÎÄ×ÖÊýÁ¿¶¼ºÜÉÙ£¬Òò´ËҲûʲôºÃÀ»ØµÄ£» | 963 | »ØÀ´¡±Õâ¸öÒâ˼£¬ËùÒÔÎÒÃÇÑ¡ÔñÁË¡°Õٻء±Ò»´ÊÓëÆä¶ÔÓ¦¡£ |
| 1009 | Èç¹ûÕæµÄÏë»Ø¸´ÕâЩÎÄ×Ö£¬undo ÄúµÄ¶¯×÷¾ÍÊÇÁË¡£ | 964 | |
| 1010 | (4) ¡¸window¡¹Í¬Ê±·ÒëΪ¡¸´°¿Ú¡¹ºÍ¡¸´°¸ñ¡¹£¬ | 965 | [3] ¡°incremental¡±Ò»´ÊÔÚ¼ÆËã»úÖø×÷Öй㷺³öÏÖ£¬±»¹ã·º½ÓÊܵÄÖÐÎÄÒë´ÊÓÐÁ½ |
| 1011 | ǰÕß±íʾÏÖÔÚÒ»°ã¸ÅÄîÖеĴ°¿Úϵͳ£¬È硸X ´°¿Ú¡¹£» | 966 | ¸ö£º¡°ÔöÁ¿µÄ¡±ºÍ¡°½¥½øµÄ¡±¡£¡°incremental search¡±·Òë³É¡°ÔöÁ¿Ê½ËÑË÷ |
| 1012 | ºóÕß±íʾ Emacs ÖеĴ°¿Ú£¬·ÒëÔÚ´Ëͨ³ÆÎª¡¸´°¸ñ¡¹¡£ | 967 | ¡±»òÕß¡°½¥½øÊ½ËÑË÷¡±¶¼½²µÄͨ£¬ÇÒ¶¼Óи÷×ÔµÄÐÎÏóÖ®´¦¡£»¹ÊDzο¼ÔÎÄ¶ÔÆä |
| 1013 | Emacs µÄ¡¸´°¸ñ¡¹¼´Ê¹ÔÚÃüÁîÁÐÌáʾÏÂÒ²¿ÉÒÔÕý³£¹¤×÷£¬ | 968 | µÄ½âÊÍ£º¡°... means that the search happens while you type in the |
| 1014 | ´ËÒ»»ù±¾ÌØÐÔÏÔȻֵµÃÎÒÃÇÒÔÁíÒ»¸öרÓÃÊõÓïÀ´ÃèÊöËü¡£ | 969 | string to search for¡±¡£Òâ˼ÊÇÖ®ËùÒÔ³ÆÆäΪ¡°incremental search¡±£¬ÊÇ |
| 1015 | (5) ¹Øì¶µµ°¸µÄÊõÓ¡¸ÕÒ¡¹Ò»¸öµµ°¸ÔÚ Emacs ÖÐÓÐÁ½ÖÖ×÷Ó㺠| 970 | ÒòΪ¡°ÔÚÄãÊäÈëËÑË÷×Ö·û´®µÄ¹ý³ÌÖУ¬ËÑË÷¾ÍÒѾÔÚ½øÐÐÁË¡±¡£ÎÒÃÇÈÏΪ¡°Ôö |
| 1016 | ÕÒÒ»¸ö¡¸²¢²»´æÔÚ¡¹µÄµµ°¸£¬¶ÁÕßÓ¦ÈÏ֪Ϊ¡¸¿ªÐµµ°¸¡¹£» | 971 | Á¿µÄ¡±¸ü¼ÓÇ¿µ÷ÔÚÏÖÓлù´¡Éϵı仯£¨±ÈÈç¡°ÔöÁ¿±¸·Ý¡±£¬¡°ÔöÁ¿±àÒ롱£©£» |
| 1017 | ÕÒÒ»¸ö¡¸ÒѾ´æÔÚ¡¹µÄµµ°¸£¬ÔòÊÇ¡¸¿ªÆô¾Éµµ¡¹¡£ | 972 | ¶ø¡°½¥½øµÄ¡±¸ü¼ÓÇ¿µ÷¹ý³ÌµÄÖð½¥·¢Õ¹£¬Ò²¸ü¼Ó·ûºÏÔÎĵÄÒâ˼¡£Òò´ËÎÒÃÇÑ¡ |
| 1018 | Emacs Ö»ÒÔÒ»¸ö¡¸ÕÒ¡¹µÄ¶¯×÷À´½â¾ö£¬Ö÷ÒªµÄÔÒòÊÇ¡¸Êµ¼ÊÉÏ¡¹ | 973 | Ôñ½«¡°incremental search¡±Òë×÷¡°½¥½øÊ½ËÑË÷¡±¡£ |
| 1019 | µÄÈí¼þ¹¤×÷Èç´Ë¡£ºÚ¿ÍÃÇÓ¦¸Ã»á·¢ÏÖÕâÑù±È½Ï×ÔÈ»£¬ | 974 | |
| 1020 | ÒòΪËü·´Ó¦Á˵çÄԵŤ×÷·½Ê½£¬Í¬Ê±²Ù×÷ÆðÀ´Ò²½ÏÉÙ·Ï»°¡£ | 975 | |
| 1021 | (6) ÔÚ¡¾¡¿ÖеÄÎÄ×ÖΪ·ÒëµÄ×¢½â¡£ | 976 | * °æÈ¨ÉùÃ÷£¨COPYING£© |
| 1022 | (7) ¹Øì¶Ê¹ÖÐÎÄÎĵµ½á¹¹»¯µÄÒéÌ⣬ÎÊÌâÒѾ»ñµÃ½â¾ö¡£ | 977 | --------------------- |
| 1023 | (8) ±¾·ÒëÎı¾Ëù²ÉÓõļò·±ÓÃÓï²îÒìÁбíÈçÏ£º | ||
| 1024 | zh cn | ||
| 1025 | Îļþ Îĵµ | ||
| 1026 | ÈíÌå Èí¼þ | ||
| 1027 | ×÷Òµ ²Ù×÷ | ||
| 1028 | Ì×¼þ °ü | ||
| 1029 | ÊÓ´° ´°¿Ú | ||
| 1030 | µÝ»Ø µÝ¹é | ||
| 1031 | º§¿Í ºÚ¿Í | ||
| 1032 | ×ÊѶ ÐÅÏ¢ | ||
| 1033 | |||
| 1034 | ÁíÍ⣬ÎÒÃÇҲʮ·Ö»¶Ó¶ÁÕß¿ÉÒÔÖ±½ÓÐ޸ı¾¿ìËÙÖ¸ÄÏ£¬×ö³ö×Ô¼ºµÄ°æ±¾£¬ÒÔ×Ô¼º | ||
| 1035 | ÈÏΪ×îΪºÏÊʵķ½Ê½À´½éÉÜ Emacs ¡£Èç¹ûÄú×ö³öÁËÕâÑù¸öÈË»¯µÄ°æ±¾£¬²¢ÇÒÈÏ | ||
| 1036 | Ϊ×㹩´ó¼Ò²Î¿¼Ê¹Óã¬Çë¼Ä¸ø <chinese-coordinators@gnu.org> £¬ÎÒÃǻὫÄú | ||
| 1037 | µÄ°æ±¾¹«¿ªÔÚ GNU/CTT µÄÍøÒ³ÖÐÌṩ¸øÖÐÎÄʹÓÃÕßÏÂÔØ¡£ | ||
| 1038 | |||
| 1039 | ·Ò룺Áõ ÕѺê <chliu@gnu.org> | ||
| 1040 | ÑéÖ¤£ºÂí ѩƼ | ||
| 1041 | |||
| 1042 | |||
| 1043 | * ¸´ÖÆ£¨ COPYING £© | ||
| 1044 | ------------------- | ||
| 1045 | 978 | ||
| 1046 | ±¾¿ìËÙÖ¸ÄÏÑØÏ®×Ô¾ßÓÐÓÆ¾ÃÀúÊ·µÄ Emacs ¿ìËÙÖ¸ÄÏ£¬ÓÉ Stuart Cracraft ΪÁË | 979 | This tutorial descends from a long line of Emacs tutorials |
| 1047 | ÔʼµÄ Emacs Ëù׫дµÄ°æ±¾¿ªÊ¼¡£ | 980 | starting with the one written by Stuart Cracraft for the original Emacs. |
| 1048 | 981 | ||
| 1049 | Õâ¸ö°æ±¾µÄ¿ìËÙÖ¸ÄÏºÍ GNU Emacs Ò»Ñù¶¼ÊǰæÈ¨»¯µÄ£¬²¢ÇÒÔÊÐíÔÚijЩÌõ¼þÏ | 982 | This version of the tutorial, like GNU Emacs, is copyrighted, and |
| 1050 | É¢²¼Æä¿½±´£º | 983 | comes with permission to distribute copies on certain conditions: |
| 1051 | 984 | ||
| 1052 | Copyright (C) 1985, 1996, 1998, 2001, 2002, 2003, 2004, | 985 | Copyright (C) 1985, 1996, 1998, 2001, 2002, 2003, 2004, |
| 1053 | 2005, 2006 Free Software Foundation, Inc. | 986 | 2005, 2006 Free Software Foundation, Inc. |
| 1054 | Chinese Translation by Chao-Hong Liu (2002, 2003) | ||
| 1055 | 987 | ||
| 1056 | Permission is granted to anyone to make or distribute verbatim copies | 988 | Permission is granted to anyone to make or distribute verbatim copies |
| 1057 | of this document as received, in any medium, provided that the | 989 | of this document as received, in any medium, provided that the |
| @@ -1059,27 +991,37 @@ Chinese Translation by Chao-Hong Liu (2002, 2003) | |||
| 1059 | and that the distributor grants the recipient permission | 991 | and that the distributor grants the recipient permission |
| 1060 | for further redistribution as permitted by this notice. | 992 | for further redistribution as permitted by this notice. |
| 1061 | 993 | ||
| 1062 | ±¾ÎÄÔÊÐíÔÚ²»±ä¸üÎĵµÄÚÈݵÄǰÌáÏ¿¯µÇÔÚÈκÎÐÎʽµÄýÌåÖУ¬ | ||
| 1063 | µ«Ðè±£Áô°æÈ¨ÉùÃ÷ÒÔ¼°Ðí¿ÉÉùÃ÷£¬ | ||
| 1064 | É¢²¼ÕßÒ²±ØÐë¸øÓè½ÓÊÜÕßÈçͬ´ËÉùÃ÷ËùÔÊÐíµÄ£¬½øÒ»²½É¢²¼µÄÐí¿É¡£ | ||
| 1065 | ¡¾±¾¶ÎÒëÎÄÌṩ¶ÁÕß×÷Ϊ²Î¿¼ÒÔ°ïÖúÀí½â£¬Êµ¼ÊЧÁ¦ÒÔÓ¢Îı¾Îª×¼¡£¡¿ | ||
| 1066 | |||
| 1067 | Permission is granted to distribute modified versions | 994 | Permission is granted to distribute modified versions |
| 1068 | of this document, or of portions of it, | 995 | of this document, or of portions of it, |
| 1069 | under the above conditions, provided also that they | 996 | under the above conditions, provided also that they |
| 1070 | carry prominent notices stating who last altered them. | 997 | carry prominent notices stating who last altered them. |
| 1071 | 998 | ||
| 1072 | ±¾ÎÄÔÊÐíÔÚÓëÉÏÊöÏàͬµÄÌõ¼þÏ£¬É¢²¼Ð޸ĺóµÄ°æ±¾£¬»òÊÇÆäÖеÄÒ»²¿·Ý£¬ | 999 | The conditions for copying Emacs itself are more complex, but in the |
| 1073 | µ«ËüÃÇÒ²±ØÐë´øÓÐÏÔÖøµÄ£¬ËµÃ÷ÓÉË×îºó¸ü¶¯ÁËËüµÄÉùÃ÷¡£ | 1000 | same spirit. Please read the file COPYING and then do give copies of |
| 1074 | ¡¾Copyleft °æÈ¨³ýÁËÌṩʹÓÃÕß×ÔÓÉÍ⣬Ҳά»¤Ôʼ×÷Õߣ¬ | 1001 | GNU Emacs to your friends. Help stamp out software obstructionism |
| 1075 | ÒÔ¼°ºóÀ´µÄÐÞ¸Ä×÷ÕßµÄÃûÓþȨ£¨ credit £©¡£ | 1002 | ("ownership") by using, writing, and sharing free software! |
| 1076 | ±¾¶ÎÒëÎÄÌṩ¶ÁÕß×÷Ϊ²Î¿¼ÒÔ°ïÖúÀí½â£¬Êµ¼ÊЧÁ¦ÒÔÓ¢Îı¾Îª×¼¡£¡¿ | 1003 | |
| 1004 | ¡¾ÏÂÃæÎª°æÈ¨ÉùÃ÷µÄÒëÎÄ£¬½ö¹©²Î¿¼¡£Êµ¼Ê·¨ÂÉЧÁ¦ÒÔÓ¢ÎÄÔÎÄΪ׼¡£¡¿ | ||
| 1005 | |||
| 1006 | ±¾¿ìËÙÖ¸ÄÏÑØÏ®×ÔÀúÊ·ÓÆ¾ÃµÄ Emacs ¿ìËÙÖ¸ÄÏ£¬¿ÉÉÏËÝÖÁ Stuart Cracraft Ϊ×î | ||
| 1007 | ³õµÄ Emacs Ëù×÷µÄ°æ±¾¡£ | ||
| 1008 | |||
| 1009 | ±¾ÆªÎĵµÓë GNU Emacs Ò»ÑùÓµÓаæÈ¨£¬²¢ÔÊÐíÔÚÏÂÁÐÌõ¼þµÄÔ¼ÊøÏ·¢ÐÐÆä¿½±´£º | ||
| 1010 | |||
| 1011 | Copyright (C) 1985, 1996, 1998, 2001, 2002, 2003, 2004, 2005 | ||
| 1012 | Free Software Foundation, Inc. | ||
| 1013 | |||
| 1014 | ±¾ÎĵµÔÊÐíÔÚ²»±ä¸üÎĵµÄÚÈݵÄÇé¿öÏÂÓÉÈκÎÈË·¢²¼ÔÚÈκÎýÌåÉÏ£¬Í¬Ê±±ØÐë | ||
| 1015 | ÍêÕû±£Áô°æÈ¨ºÍÐí¿ÉÉùÃ÷£¬ÇÒÐè¸øÓèÊÜÖÚÓë·¢ÐÐÕßÍêÈ«ÏàͬµÄ¡¢Èç±¾ÉùÃ÷ËùÔÊ | ||
| 1016 | ÐíµÄÔٴη¢Ðб¾ÎĵµµÄȨÀû¡£ | ||
| 1017 | |||
| 1018 | ±¾ÉùÃ÷ÔÊÐíÔÚÓëÉÏÊöÌõ¼þÏàͬµÄÇé¿öÏ·¢²¼¾¹ýÐ޸ĵÄÈ«²¿»ò²¿·ÖÎĵµ£¬Í¬Ê± | ||
| 1019 | ±ØÐ븽´øÏÔÒªµÄÎÄ×ÖÒÔÉêÃ÷ÎĵµµÄ×îºóÐÞ¸ÄÕß¡£ | ||
| 1077 | 1020 | ||
| 1078 | ¸´ÖÆ Emacs ±¾ÉíµÄÌõ¼þ½ÏΪ¸´ÔÓ£¬µ«ÊǾßÓÐÏàͬµÄ¾«Éñ¡£ÇëÔĶÁ COPYING Õâ¸ö | 1021 | Emacs ×ÔÉíµÄ°æÈ¨ÎÊÌâËä±È±¾ÎĵµÒª¸´ÔÓһЩ£¬µ«Ò²»ùÓÚÏàͬµÄ¾«Éñ¡£¾´ÇëÔĶÁÎÄ |
| 1079 | µµ°¸£¬²¢ÇÒȷʵ¸øÓèÄúµÄÅóÓÑ GNU Emacs µÄ¿½±´¡£Çë¾ÓÉ¡¸Ê¹Óá¢×«Ð´¡¢ÒÔ¼° | 1022 | ¼þ¡°COPYING¡±£¬È»ºóÏòÄãµÄÅóÓÑÃÇ·Ö·¢ GNU Emacs ¿½±´¡£ÈÃÎÒÃÇÒÔʹÓᢱàдºÍ |
| 1080 | ·ÖÏí×ÔÓÉÈí¼þ¡¹À´°ïÖúÏû³ýÈí¼þÕϰÖ÷Ò壨ӵÓÐȨ£©£¡ | 1023 | ·ÖÏí×ÔÓÉÈí¼þµÄʵ¼ÊÐж¯À´¹²Í¬ìî³ýÈí¼þÕϰÖ÷Ò壨ËùνµÄ¡°ËùÓÐȨ¡±£©£¡ |
| 1081 | 1024 | ||
| 1082 | ;;; DO NOT PUT THIS ON ZHS OR ZHT FILE... | ||
| 1083 | ;;; Local Variables: | 1025 | ;;; Local Variables: |
| 1084 | ;;; coding: chinese-iso-8bit | 1026 | ;;; coding: chinese-iso-8bit |
| 1085 | ;;; End: | 1027 | ;;; End: |
diff --git a/etc/TUTORIAL.translators b/etc/TUTORIAL.translators index dfda17bedb7..bf89921e59e 100644 --- a/etc/TUTORIAL.translators +++ b/etc/TUTORIAL.translators | |||
| @@ -6,8 +6,8 @@ Author: Ognyan Kulev <ogi@fmi.uni-sofia.bg> | |||
| 6 | Maintainer: Ognyan Kulev <ogi@fmi.uni-sofia.bg> | 6 | Maintainer: Ognyan Kulev <ogi@fmi.uni-sofia.bg> |
| 7 | 7 | ||
| 8 | * TUTORIAL.cn: | 8 | * TUTORIAL.cn: |
| 9 | Author: Chao-Hong Liu <chliu@gnu.org> | 9 | Author: Sun Yijiang <sunyijiang@gmail.com> |
| 10 | Maintainer: Chao-Hong Liu <chliu@gnu.org> | 10 | Maintainer: Sun Yijiang <sunyijiang@gmail.com> |
| 11 | 11 | ||
| 12 | * TUTORIAL.cs: | 12 | * TUTORIAL.cs: |
| 13 | Author: Milan Zamazal <pdm@zamazal.org> | 13 | Author: Milan Zamazal <pdm@zamazal.org> |
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b0b7945e007..6b91115cd67 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,8 +1,388 @@ | |||
| 1 | 2006-02-21 Richard M. Stallman <rms@gnu.org> | ||
| 2 | |||
| 3 | * progmodes/sh-script.el (sh-mode): Set shell type based on file name | ||
| 4 | if there's no other specific basis. | ||
| 5 | |||
| 6 | * emacs-lisp/unsafep.el (unsafep): Don't treat &rest or &optional | ||
| 7 | as variables at all. | ||
| 8 | (unsafep-variable): Rename arg; doc fix. | ||
| 9 | |||
| 10 | * abbrevlist.el (list-one-abbrev-table): Add autoload. | ||
| 11 | |||
| 12 | * calendar/appt.el (diary-selective-display): Add defvar. | ||
| 13 | |||
| 14 | * sort.el (sort-columns): Use Posix arg syntax for `sort'. | ||
| 15 | |||
| 16 | * isearch.el (search-whitespace-regexp): Fix custom type. | ||
| 17 | |||
| 18 | * help.el (describe-key-briefly): Compute interactive args | ||
| 19 | in same was as before previous change. | ||
| 20 | |||
| 21 | * files.el (enable-local-variables): Doc fix. | ||
| 22 | |||
| 23 | 2006-02-21 Kim F. Storm <storm@cua.dk> | ||
| 24 | |||
| 25 | * fringe.el: Cleanup as file is now pre-loaded. | ||
| 26 | (fringe-bitmaps): Initialize unconditionally. | ||
| 27 | (fringe-mode, set-fringe-style): Remove autoload cookies. | ||
| 28 | |||
| 29 | 2006-02-21 Giorgos Keramidas <keramida@ceid.upatras.gr> (tiny change) | ||
| 30 | |||
| 31 | * fringe.el (fringe-bitmaps): Rename `horisontal-bar' to | ||
| 32 | `horizontal-bar'. | ||
| 33 | (fringe-cursor-alist): Use `horizontal-bar'. | ||
| 34 | |||
| 35 | 2006-02-20 Kim F. Storm <storm@cua.dk> | ||
| 36 | |||
| 37 | * fringe.el (fringe-bitmaps): Update to new bitmap names. | ||
| 38 | (fringe-indicator-alist, fringe-cursor-alist): Initialize. | ||
| 39 | |||
| 40 | * loadup.el: Load "fringe" on window systems. | ||
| 41 | |||
| 42 | 2006-02-20 Nick Roberts <nickrob@snap.net.nz> | ||
| 43 | |||
| 44 | * progmodes/gud.el (gud-speedbar-buttons): Use shadow face for all | ||
| 45 | out of scope components. | ||
| 46 | |||
| 47 | * progmodes/gdb-ui.el (gdb-speedbar-auto-raise): Don't enable by | ||
| 48 | default. | ||
| 49 | |||
| 50 | 2006-02-20 Chong Yidong <cyd@stupidchicken.com> | ||
| 51 | |||
| 52 | * custom.el (customize-mark-to-save, customize-mark-as-set): Load | ||
| 53 | the symbol first. | ||
| 54 | |||
| 55 | 2006-02-20 Juanma Barranquero <lekktu@gmail.com> | ||
| 56 | |||
| 57 | * buff-menu.el (list-buffers-noselect): Turn also "\n" into a | ||
| 58 | strech spec so it doesn't display as "^J" on the header line | ||
| 59 | when `Buffer-menu-use-header-line' is t. | ||
| 60 | |||
| 61 | 2006-02-20 Nick Roberts <nickrob@snap.net.nz> | ||
| 62 | |||
| 63 | * speedbar.el (speedbar-make-button): Keep text properties | ||
| 64 | of string arguments if desired. | ||
| 65 | |||
| 66 | * progmodes/gud.el (gud-speedbar-buttons): Fontify watch | ||
| 67 | expessions. | ||
| 68 | |||
| 69 | * progmodes/gdb-ui.el (gdb-speedbar-expand-node): Force update | ||
| 70 | of speedbar. | ||
| 71 | |||
| 72 | 2006-02-19 Ryan Yeske <rcyeske@gmail.com> | ||
| 73 | |||
| 74 | * ffap.el (ffap-read-file-or-url): Bind `completion-ignore-case' | ||
| 75 | to value of `read-file-name-completion-ignore-case'. | ||
| 76 | |||
| 77 | 2006-02-19 Chong Yidong <cyd@stupidchicken.com> | ||
| 78 | |||
| 79 | * custom.el (customize-mark-as-set): Push to `user' theme. | ||
| 80 | |||
| 81 | * cus-edit.el (custom-save-variables): Allow unthemed values. | ||
| 82 | (customize-set-variable): Push setting to `user' theme. | ||
| 83 | |||
| 84 | 2006-02-19 Nick Roberts <nickrob@snap.net.nz> | ||
| 85 | |||
| 86 | * progmodes/gud.el: Don't require font-lock as it's now | ||
| 87 | automatically loaded. | ||
| 88 | (gud-speedbar-buttons): Replace gdb-var-changed with | ||
| 89 | gdb-force-update. | ||
| 90 | |||
| 91 | * progmodes/gdb-ui.el (gdb-force-update): Rename from | ||
| 92 | gdb-var-changed. | ||
| 93 | (gdb-post-prompt): Use it. | ||
| 94 | (gdb-var-create-handler, gdb-var-evaluate-expression-handler) | ||
| 95 | (gdb-var-update-handler, gdb-var-delete) | ||
| 96 | (gdb-speedbar-expand-node, gdb-var-list-children-handler-1) | ||
| 97 | (gdb-var-update-handler-1): Don't set gdb-var-changed, just set | ||
| 98 | gdb-force-update in gdb-post-prompt. | ||
| 99 | (gdb-reset): Clear watch expressions from speedbar when quitting. | ||
| 100 | |||
| 101 | 2006-02-19 Michael Kifer <kifer@cs.stonybrook.edu> | ||
| 102 | |||
| 103 | * viper-cmd.el (viper-insert-state-post-command-sentinel) | ||
| 104 | (viper-change-state-to-vi, viper-change-state-to-emacs): | ||
| 105 | Make aware of cursor coloring in the Emacs state. | ||
| 106 | (viper-special-read-and-insert-char): Use read-char-exclusive. | ||
| 107 | (viper-minibuffer-trim-tail): Workaround for fields in minibuffer. | ||
| 108 | |||
| 109 | * viper-init.el (viper-emacs-state-cursor-color): New variable. | ||
| 110 | |||
| 111 | * viper-util.el (viper-save-cursor-color) | ||
| 112 | (viper-get-saved-cursor-color-in-replace-mode) | ||
| 113 | (viper-get-saved-cursor-color-in-insert-mode) | ||
| 114 | (viper-restore-cursor-color): Make aware of the cursor color in Emacs | ||
| 115 | state. | ||
| 116 | (viper-get-saved-cursor-color-in-emacs-mode): New function. | ||
| 117 | |||
| 118 | * ediff-diff.el (ediff-ignore-case, ediff-ignore-case-option) | ||
| 119 | (ediff-ignore-case-option3, ediff-actual-diff-options) | ||
| 120 | (ediff-actual-diff3-options): New variables to control case sensitivity. | ||
| 121 | (ediff-make-diff2-buffer, ediff-setup-fine-diff-regions) | ||
| 122 | (ediff-setup-diff-regions3): Make aware of case-sensitivity. | ||
| 123 | (ediff-toggle-ignore-case): New function. | ||
| 124 | (ediff-extract-diffs, ediff-extract-diffs3): Preserve point in buffers. | ||
| 125 | |||
| 126 | * ediff-help.el (ediff-long-help-message-narrow2) | ||
| 127 | (ediff-long-help-message-compare2, ediff-long-help-message-compare3) | ||
| 128 | (ediff-long-help-message-word-mode): Add ignore-case command. | ||
| 129 | (ediff-help-for-quick-help): Add ignore-case command. | ||
| 130 | |||
| 131 | * ediff-merg.el: Move provide to the end. | ||
| 132 | |||
| 133 | * ediff-ptch.el: Move provide to the end. | ||
| 134 | |||
| 135 | * ediff-wind.el: Move provide to the end. | ||
| 136 | |||
| 137 | * ediff-mult.el: Move provide to the end. | ||
| 138 | (ediff-set-meta-overlay): Enable follow-link. | ||
| 139 | |||
| 140 | * ediff.el: Move provide to the end. | ||
| 141 | Break recursive load cycle in eval-when-compile. | ||
| 142 | (ediff-patch-buffer): Better heuristics. | ||
| 143 | |||
| 144 | * ediff-util.el: Move provide to the end. | ||
| 145 | Break recursive load cycle in eval-when-compile. | ||
| 146 | (ediff-setup-keymap): Add binding for #c. Replace some defsubsts with | ||
| 147 | defuns. | ||
| 148 | (ediff-submit-report): Pass the values of ediff-diff3-program, | ||
| 149 | ediff-diff3-options. | ||
| 150 | |||
| 151 | 2006-02-19 Juanma Barranquero <lekktu@gmail.com> | ||
| 152 | |||
| 153 | * help-fns.el (help-do-arg-highlight): Recognize also ARG- followed by | ||
| 154 | the opening bracket of the following bracketing pairs: {}, [], (), <>, | ||
| 155 | `' (for example, in the docstring of `windmove-default-keybindings'). | ||
| 156 | |||
| 157 | 2006-02-19 Nick Roberts <nickrob@snap.net.nz> | ||
| 158 | |||
| 159 | * progmodes/gud.el (gud-speedbar-buttons): Update properly for | ||
| 160 | shadow face. Don't provide binding to edit variable when it is | ||
| 161 | out of scope. | ||
| 162 | |||
| 163 | * progmodes/gdb-ui.el (gdb-var-evaluate-expression-handler) | ||
| 164 | (gdb-var-update-handler): Detect out of scope variables with pre | ||
| 165 | GDB 6.4 too. | ||
| 166 | (gdb-post-prompt): Revert changet 2006-02-17 (force update). | ||
| 167 | Reset status of variable objects to nil in update handlers. | ||
| 168 | (gdb-var-update-handler-1): Detect when a variable object comes | ||
| 169 | in scope. setcar on var changes gdb-var-list directly. | ||
| 170 | |||
| 171 | 2006-02-17 Juri Linkov <juri@jurta.org> | ||
| 172 | |||
| 173 | * ffap.el (ffap) <defface>: Add explicit face declaration. | ||
| 174 | (ffap-highlight): Use face `ffap' directly instead of checking | ||
| 175 | for its existence. | ||
| 176 | |||
| 177 | * icomplete.el (icomplete-get-keys): Use `t' for the second arg | ||
| 178 | `visible-ok' of `other-buffer' to find the right original buffer. | ||
| 179 | |||
| 180 | * info.el (Info-search): Skip `Local Variables' node. | ||
| 181 | |||
| 182 | 2006-02-17 Juri Linkov <juri@jurta.org> | ||
| 183 | |||
| 184 | * info.el (Info-find-file): Check for symbols `apropos', `history', | ||
| 185 | `toc' in the input filename, and return these symbols as is. | ||
| 186 | (Info-find-node-2): Set Info-current-file to symbols `apropos', | ||
| 187 | `history', `toc' instead of strings. | ||
| 188 | (Info-set-mode-line): For non-string Info-current-file use the | ||
| 189 | symbol's name inside **. | ||
| 190 | (Info-isearch-push-state): Add quote before Info-current-file and | ||
| 191 | Info-current-node. | ||
| 192 | (Info-isearch-pop-state): Use `equal' instead of `string='. | ||
| 193 | (Info-extract-pointer, Info-following-node-name): Use | ||
| 194 | `match-string-no-properties' instead of `match-string'. | ||
| 195 | (Info-up): Check `old-file' for `stringp'. | ||
| 196 | (Info-history): Use `equal' instead of `string-equal'. | ||
| 197 | Check `file' for `stringp'. | ||
| 198 | (Info-history): Use symbol `history' instead of string as first arg | ||
| 199 | of `Info-find-node'. | ||
| 200 | (Info-toc): Check `Info-current-file' for `stringp'. Use symbol | ||
| 201 | `toc' instead of string. | ||
| 202 | (Info-extract-menu-node-name): Use `buffer-substring-no-properties' | ||
| 203 | instead of `buffer-substring', and `match-string-no-properties' | ||
| 204 | instead of `match-string'. | ||
| 205 | (Info-index-nodes): Check for symbols `apropos', `history', `toc' | ||
| 206 | instead of strings. | ||
| 207 | (info-apropos): Use `Info-find-node' instead of `Info-goto-node'. | ||
| 208 | Use symbol `apropos' instead of string. | ||
| 209 | (Info-copy-current-node-name): Check `Info-current-file' for | ||
| 210 | `stringp' and construct a command with `Info-find-node' from it. | ||
| 211 | (Info-fontify-node): Use `match-string-no-properties' instead of | ||
| 212 | `match-string' and check file names for `stringp'. | ||
| 213 | (Info-desktop-buffer-misc-data): Check for symbols `apropos', | ||
| 214 | `history', `toc' instead of strings. | ||
| 215 | |||
| 216 | 2006-02-17 Chong Yidong <cyd@stupidchicken.com> | ||
| 217 | |||
| 218 | * files.el: Rearrange functions and variables in the file local | ||
| 219 | variables section. | ||
| 220 | |||
| 221 | 2006-02-17 Reiner Steib <Reiner.Steib@gmx.de> | ||
| 222 | |||
| 223 | * files.el: Add truncate-lines, ispell-check-comments and | ||
| 224 | ispell-local-dictionary as safe local variables. | ||
| 225 | |||
| 226 | 2006-02-18 Nick Roberts <nickrob@snap.net.nz> | ||
| 227 | |||
| 228 | * progmodes/gud.el (gud-speedbar-buttons): Use shadow face for | ||
| 229 | out of scope variables. | ||
| 230 | (gud-speedbar-buttons): Use unless. | ||
| 231 | |||
| 232 | * progmodes/gdb-ui.el (gdb-var-list): Update doc string. | ||
| 233 | (gdb-init-1, gdb-var-changed): Set gdb-var-changed to t initially. | ||
| 234 | (gdb-show-changed-values): Also use for out of scope variables. | ||
| 235 | (gdb-var-update-handler-1): Note if variable goes out of scope. | ||
| 236 | |||
| 237 | 2006-02-17 Ryan Yeske <rcyeske@gmail.com> | ||
| 238 | |||
| 239 | * net/rcirc.el (rcirc-connect): Make all arguments optional, and | ||
| 240 | default to global variable values for unsupplied args. | ||
| 241 | (rcirc-get-buffer-create): Fix bug with setting the target. | ||
| 242 | (rcirc-any-buffer): Rename from rcirc-get-any-buffer, and include | ||
| 243 | test for rcirc-always-use-server-buffer-flag here. | ||
| 244 | (rcirc-response-formats): Add %N, which is a facified nick. %n | ||
| 245 | uses the default face. Change the ACTION format string. If the | ||
| 246 | "nick" is the server, don't print anything for that field. | ||
| 247 | Comment fixes. | ||
| 248 | (rcirc-target-buffer): Don't test | ||
| 249 | rcirc-always-use-server-buffer-flag here. | ||
| 250 | (rcirc-print): Squeeze extra spaces out of the text before message. | ||
| 251 | (rcirc-put-nick-channel): Strip potential "@" char from nick | ||
| 252 | before adding them to nick table. | ||
| 253 | (rcirc-url-regexp): Improve to match address like "foo.com". | ||
| 254 | |||
| 255 | 2006-02-17 Eli Zaretskii <eliz@gnu.org> | ||
| 256 | |||
| 257 | * allout.el (allout-hidden-p): Move this defsubst before | ||
| 258 | allout-overlay-interior-modification-handler, where it is first | ||
| 259 | used. | ||
| 260 | |||
| 261 | 2006-02-17 Ken Manheimer <ken.manheimer@gmail.com> | ||
| 262 | |||
| 263 | * allout.el: Use allout invisible-text overlays instead of | ||
| 264 | selective display for concealed text. Also, lots of general | ||
| 265 | cleanup, and improved compatibility code. | ||
| 266 | |||
| 267 | (allout-version) Incremented, corrected, revised, and refined | ||
| 268 | module commentary. | ||
| 269 | |||
| 270 | (provide 'allout): Moved to the bottom, added a require of overlay. | ||
| 271 | |||
| 272 | (allout-encrypt-unencrypted-on-saves): Defaults to t instead of | ||
| 273 | `except-current'. | ||
| 274 | (allout-write-file-hook-handler): Minimize delay. | ||
| 275 | (count-trailing-whitespace-region): New function so | ||
| 276 | auto-encryption of current topic can resituate cursor exactly. | ||
| 277 | PGP/GPG encryption trims trailing whitespace from lines, which | ||
| 278 | must be accounted for across encryption then decryption. | ||
| 279 | |||
| 280 | (allout-command-prefix): Now defaults to "\C-c<space>" rather than | ||
| 281 | just plain "\C-c", to avoid intruding on user's keybinding space. | ||
| 282 | |||
| 283 | (allout-toggle-current-subtree-encryption): Pass along fetch-pass | ||
| 284 | parameter, so user request to provide a new password is done. | ||
| 285 | |||
| 286 | (allout-outside-normal-auto-fill-function, allout-auto-fill): | ||
| 287 | Refined mechanism for auto-filling behavior while in allout mode. | ||
| 288 | |||
| 289 | (allout-mode): Explicitly specify the mode map in the docstring. | ||
| 290 | Clarify provision for various write-file hook var names. | ||
| 291 | Adjusted for invisible-text overlays instead of selective-display. | ||
| 292 | |||
| 293 | (allout-depth): Really return 0 if not within any topic. This | ||
| 294 | rectifies `allout-beginning-of-level' and sequence numbering | ||
| 295 | errors that occur when cutting and pasting numbered topics. | ||
| 296 | Changed from a in-line subst to a regular function, as well. | ||
| 297 | |||
| 298 | (allout-pre-next-prefix): Renamed from allout-pre-next-preface. | ||
| 299 | |||
| 300 | (allout-end-of-subtree, allout-end-of-subtree) | ||
| 301 | (allout-end-of-entry, allout-end-of-current-heading) | ||
| 302 | (allout-next-visible-heading, allout-open-topic, allout-show-entry) | ||
| 303 | (allout-show-children, allout-show-to-offshoot) | ||
| 304 | (allout-hide-current-entry, allout-show-current-entry): Rectified | ||
| 305 | handling of trailing blank lines between items. | ||
| 306 | |||
| 307 | (allout-line-boundary-regexp, set-allout-regexp, allout-depth) | ||
| 308 | (allout-current-depth, allout-unprotected, allout-hidden-p) | ||
| 309 | (allout-on-current-heading-p, allout-listify-exposed) | ||
| 310 | (allout-chart-subtree, allout-goto-prefix) | ||
| 311 | (allout-back-to-current-heading, allout-get-body-text) | ||
| 312 | (allout-snug-back, allout-flag-current-subtree, allout-show-all) | ||
| 313 | (allout-hide-region-body, allout-toggle-subtree-encryption) | ||
| 314 | (allout-encrypt-string, allout-encrypted-key-info) | ||
| 315 | (allout-next-topic-pending-encryption, allout-encrypt-decrypted) | ||
| 316 | (allout-file-vars-section-data): Adjusted for use with | ||
| 317 | invisible-text overlays instead of selective-display. | ||
| 318 | |||
| 319 | (allout-kill-line, allout-kill-topic, allout-yank-processing): | ||
| 320 | Reworked for use with invisible text overlays. | ||
| 321 | |||
| 322 | (allout-current-topic-collapsed-p): New function. | ||
| 323 | |||
| 324 | (allout-hide-current-subtree): Use allout-current-topic-collapsed-p | ||
| 325 | to know when to close the containing topic. | ||
| 326 | |||
| 327 | (allout-pre-command-business, allout-post-command-business): | ||
| 328 | Simplify undo-batching and dynamic isearch exposure. | ||
| 329 | |||
| 330 | (allout-set-overlay-category): New for invisible-text overlays. | ||
| 331 | Sets properties of allout-overlay-category, used by | ||
| 332 | allout-flag-region to set invisible-text overlay properties. | ||
| 333 | (allout-get-invisibility-overlay): Get the first qualifying | ||
| 334 | invisibility overlay, so we can find the extent of it. | ||
| 335 | (allout-back-to-visible-text): Get to just before the beginnining | ||
| 336 | of the current invisibility overlay, if any. | ||
| 337 | |||
| 338 | (allout-overlay-insert-in-front-handler) | ||
| 339 | (allout-overlay-interior-modification-handler) | ||
| 340 | (allout-before-change-handler, allout-isearch-end-handler): New | ||
| 341 | functions to handle extraordinary actions affecting concealed | ||
| 342 | text. | ||
| 343 | |||
| 344 | (allout-flag-region): Use overlays instead of selective-display | ||
| 345 | for invisible text - by inheritence from the properties of | ||
| 346 | allout-overlay-category in mainline Emacs, and applied | ||
| 347 | property-by-property in XEmacs, some recent versions of which | ||
| 348 | don't inherit the properties from the category. Provisions to | ||
| 349 | respond to concealed-text edits simplified drastically. | ||
| 350 | |||
| 351 | (allout-isearch-rectification, allout-isearch-was-font-lock) | ||
| 352 | (allout-isearch-expose, allout-enwrap-isearch) | ||
| 353 | (allout-isearch-abort, allout-pre-was-isearching) | ||
| 354 | (allout-isearch-prior-pos, allout-isearch-did-quit) | ||
| 355 | (allout-isearch-dynamic-expose) | ||
| 356 | (allout-hide-current-entry-completely): Functions deleted. | ||
| 357 | |||
| 358 | (allout-undo-aggregation): Explicit undo aggregation no longer | ||
| 359 | necessary due to transition away from selective-display. | ||
| 360 | |||
| 361 | (set-allout-regexp, allout-up-current-level) | ||
| 362 | (allout-next-visible-heading, allout-forward-current-level) | ||
| 363 | (allout-open-topic, allout-reindent-body, allout-rebullet-topic) | ||
| 364 | (allout-kill-line, allout-yank-processing, allout-show-children) | ||
| 365 | (allout-expose-topic, allout-old-expose-topic) | ||
| 366 | (allout-listify-exposed, allout-insert-latex-header) | ||
| 367 | (allout-toggle-subtree-encryption, allout-encrypt-string) | ||
| 368 | (remove-from-invisibility-spec, allout-hide-current-subtree): | ||
| 369 | Ditched unused variables. | ||
| 370 | |||
| 371 | 2006-02-17 Agustin Martin <agustin.martin@hispalinux.es> | ||
| 372 | |||
| 373 | * textmodes/ispell.el (ispell-change-dictionary): Call | ||
| 374 | ispell-buffer-local-dict instead of | ||
| 375 | ispell-accept-buffer-local-defs. | ||
| 376 | (ispell-local-dictionary-alist): Accept as valid any coding-system | ||
| 377 | supported by Emacs. | ||
| 378 | (ispell-dictionary-alist-3): Esperanto dictionary's coding system | ||
| 379 | changed to iso-8859-3. | ||
| 380 | |||
| 1 | 2006-02-17 Nick Roberts <nickrob@snap.net.nz> | 381 | 2006-02-17 Nick Roberts <nickrob@snap.net.nz> |
| 2 | 382 | ||
| 3 | * speedbar.el (speedbar-frame-width): Make an inline function | 383 | * speedbar.el (speedbar-frame-width): Make an inline function |
| 4 | instead of a macro. Use frame-width. | 384 | instead of a macro. Use frame-width. |
| 5 | (speedbar-try-completion, speedbar-update-contents) | 385 | (speedbar-try-completion, speedbar-update-contents) |
| 6 | (speedbar-timer-fn): Use consp. | 386 | (speedbar-timer-fn): Use consp. |
| 7 | (speedbar-update-localized-contents): Try to preserve point. | 387 | (speedbar-update-localized-contents): Try to preserve point. |
| 8 | 388 | ||
diff --git a/lisp/abbrevlist.el b/lisp/abbrevlist.el index bd3482f974b..d52ccffeb3c 100644 --- a/lisp/abbrevlist.el +++ b/lisp/abbrevlist.el | |||
| @@ -28,6 +28,7 @@ | |||
| 28 | 28 | ||
| 29 | ;;; Code: | 29 | ;;; Code: |
| 30 | 30 | ||
| 31 | ;;;###autoload | ||
| 31 | (defun list-one-abbrev-table (abbrev-table output-buffer) | 32 | (defun list-one-abbrev-table (abbrev-table output-buffer) |
| 32 | "Display alphabetical listing of ABBREV-TABLE in buffer OUTPUT-BUFFER." | 33 | "Display alphabetical listing of ABBREV-TABLE in buffer OUTPUT-BUFFER." |
| 33 | (with-output-to-temp-buffer output-buffer | 34 | (with-output-to-temp-buffer output-buffer |
diff --git a/lisp/allout.el b/lisp/allout.el index 78e61dacde2..69d72506fce 100644 --- a/lisp/allout.el +++ b/lisp/allout.el | |||
| @@ -1,12 +1,12 @@ | |||
| 1 | ;;; allout.el --- extensive outline mode for use alone and with other modes | 1 | ;;; allout.el --- extensive outline mode for use alone and with other modes |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1992, 1993, 1994, 2001, 2002, 2003, 2004, | 3 | ;; Copyright (C) 1992, 1993, 1994, 2001, 2002, 2003, 2004, |
| 4 | ;; 2005, 2006 Free Software Foundation, Inc. | 4 | ;; 2005 Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Author: Ken Manheimer <ken dot manheimer at gmail dot com> | 6 | ;; Author: Ken Manheimer <ken dot manheimer at gmail dot com> |
| 7 | ;; Maintainer: Ken Manheimer <ken dot manheimer at gmail dot com> | 7 | ;; Maintainer: Ken Manheimer <ken dot manheimer at gmail dot com> |
| 8 | ;; Created: Dec 1991 - first release to usenet | 8 | ;; Created: Dec 1991 - first release to usenet |
| 9 | ;; Version: 2.1 | 9 | ;; Version: 2.2 |
| 10 | ;; Keywords: outlines wp languages | 10 | ;; Keywords: outlines wp languages |
| 11 | 11 | ||
| 12 | ;; This file is part of GNU Emacs. | 12 | ;; This file is part of GNU Emacs. |
| @@ -28,36 +28,39 @@ | |||
| 28 | 28 | ||
| 29 | ;;; Commentary: | 29 | ;;; Commentary: |
| 30 | 30 | ||
| 31 | ;; Allout outline mode provides extensive outline formatting and | 31 | ;; Allout outline minor mode provides extensive outline formatting and |
| 32 | ;; and manipulation beyond standard emacs outline mode. It provides | 32 | ;; and manipulation beyond standard emacs outline mode. Some features: |
| 33 | ;; for structured editing of outlines, as well as navigation and | ||
| 34 | ;; exposure. It also provides for syntax-sensitive text like | ||
| 35 | ;; programming languages. (For an example, see the allout code | ||
| 36 | ;; itself, which is organized in ;; an outline framework.) | ||
| 37 | ;; | 33 | ;; |
| 38 | ;; Some features: | 34 | ;; - Classic outline-mode topic-oriented navigation and exposure adjustment |
| 39 | ;; | 35 | ;; - Topic-oriented editing including coherent topic and subtopic |
| 40 | ;; - classic outline-mode topic-oriented navigation and exposure adjustment | 36 | ;; creation, promotion, demotion, cut/paste across depths, etc. |
| 41 | ;; - topic-oriented editing including coherent topic and subtopic | 37 | ;; - Incremental search with dynamic exposure and reconcealment of text |
| 42 | ;; creation, promotion, demotion, cut/paste across depths, etc | 38 | ;; - Customizable bullet format - enables programming-language specific |
| 43 | ;; - incremental search with dynamic exposure and reconcealment of text | 39 | ;; outlining, for code-folding editing. (Allout code itself is to try it; |
| 44 | ;; - customizable bullet format enbles programming-language specific | 40 | ;; formatted as an outline - do ESC-x eval-current-buffer in allout.el; but |
| 45 | ;; outlining, for ultimate code-folding editing. (allout code itself is | 41 | ;; emacs local file variables need to be enabled when the |
| 46 | ;; formatted as an outline - do ESC-x eval-current-buffer in allout.el | 42 | ;; file was visited - see `enable-local-variables'.) |
| 47 | ;; to try it out.) | 43 | ;; - Configurable per-file initial exposure settings |
| 48 | ;; - configurable per-file initial exposure settings | 44 | ;; - Symmetric-key and key-pair topic encryption, plus symmetric passphrase |
| 49 | ;; - symmetric-key and key-pair topic encryption, plus symmetric passphrase | ||
| 50 | ;; mnemonic support, with verification against an established passphrase | 45 | ;; mnemonic support, with verification against an established passphrase |
| 51 | ;; (using a stashed encrypted dummy string) and user-supplied hint | 46 | ;; (using a stashed encrypted dummy string) and user-supplied hint |
| 52 | ;; maintenance. (see allout-toggle-current-subtree-encryption docstring.) | 47 | ;; maintenance. (See allout-toggle-current-subtree-encryption docstring.) |
| 53 | ;; - automatic topic-number maintenance | 48 | ;; - Automatic topic-number maintenance |
| 54 | ;; - "hot-spot" operation, for single-keystroke maneuvering and | 49 | ;; - "Hot-spot" operation, for single-keystroke maneuvering and |
| 55 | ;; exposure control (see the allout-mode docstring) | 50 | ;; exposure control (see the allout-mode docstring) |
| 56 | ;; - easy rendering of exposed portions into numbered, latex, indented, etc | 51 | ;; - Easy rendering of exposed portions into numbered, latex, indented, etc |
| 57 | ;; outline styles | 52 | ;; outline styles |
| 53 | ;; - Careful attention to whitespace - enabling blank lines between items | ||
| 54 | ;; and maintenance of hanging indentation (in paragraph auto-fill and | ||
| 55 | ;; across topic promotion and demotion) of topic bodies consistent with | ||
| 56 | ;; indentation of their topic header. | ||
| 58 | ;; | 57 | ;; |
| 59 | ;; and more. | 58 | ;; and more. |
| 60 | ;; | 59 | ;; |
| 60 | ;; See the `allout-mode' function's docstring for an introduction to the | ||
| 61 | ;; mode. The development version and helpful notes are available at | ||
| 62 | ;; http://myriadicity.net/Sundry/EmacsAllout . | ||
| 63 | ;; | ||
| 61 | ;; The outline menubar additions provide quick reference to many of | 64 | ;; The outline menubar additions provide quick reference to many of |
| 62 | ;; the features, and see the docstring of the variable `allout-init' | 65 | ;; the features, and see the docstring of the variable `allout-init' |
| 63 | ;; for instructions on priming your emacs session for automatic | 66 | ;; for instructions on priming your emacs session for automatic |
| @@ -75,20 +78,18 @@ | |||
| 75 | 78 | ||
| 76 | ;;; Code: | 79 | ;;; Code: |
| 77 | 80 | ||
| 78 | ;;;_* Provide | ||
| 79 | ;(provide 'outline) | ||
| 80 | (provide 'allout) | ||
| 81 | |||
| 82 | ;;;_* Dependency autoloads | 81 | ;;;_* Dependency autoloads |
| 82 | (require 'overlay) | ||
| 83 | (eval-when-compile (progn (require 'pgg) | 83 | (eval-when-compile (progn (require 'pgg) |
| 84 | (require 'pgg-gpg) | 84 | (require 'pgg-gpg) |
| 85 | (fset 'allout-real-isearch-abort | 85 | (require 'overlay) |
| 86 | (symbol-function 'isearch-abort)) | ||
| 87 | )) | 86 | )) |
| 88 | (autoload 'pgg-gpg-symmetric-key-p "pgg-gpg" | 87 | (autoload 'pgg-gpg-symmetric-key-p "pgg-gpg" |
| 89 | "True if decoded armor MESSAGE-KEYS has symmetric encryption indicator.") | 88 | "True if decoded armor MESSAGE-KEYS has symmetric encryption indicator.") |
| 90 | 89 | ||
| 91 | ;;;_* USER CUSTOMIZATION VARIABLES: | 90 | ;;;_* USER CUSTOMIZATION VARIABLES: |
| 91 | |||
| 92 | ;;;_ > defgroup allout | ||
| 92 | (defgroup allout nil | 93 | (defgroup allout nil |
| 93 | "Extensive outline mode for use alone and with other modes." | 94 | "Extensive outline mode for use alone and with other modes." |
| 94 | :prefix "allout-" | 95 | :prefix "allout-" |
| @@ -151,7 +152,7 @@ lines at the bottom of an Emacs Lisp file: | |||
| 151 | will, modulo the above-mentioned conditions, cause the mode to be | 152 | will, modulo the above-mentioned conditions, cause the mode to be |
| 152 | activated when the file is visited, followed by the equivalent of | 153 | activated when the file is visited, followed by the equivalent of |
| 153 | `\(allout-expose-topic 0 : -1 -1 0)'. \(This is the layout used for | 154 | `\(allout-expose-topic 0 : -1 -1 0)'. \(This is the layout used for |
| 154 | the allout.el, itself.) | 155 | the allout.el source file.) |
| 155 | 156 | ||
| 156 | Also, allout's mode-specific provisions will make topic prefixes default | 157 | Also, allout's mode-specific provisions will make topic prefixes default |
| 157 | to the comment-start string, if any, of the language of the file. This | 158 | to the comment-start string, if any, of the language of the file. This |
| @@ -450,7 +451,7 @@ variable for details about allout ajustment of file variables." | |||
| 450 | :group 'allout) | 451 | :group 'allout) |
| 451 | (make-variable-buffer-local 'allout-passphrase-hint-handling) | 452 | (make-variable-buffer-local 'allout-passphrase-hint-handling) |
| 452 | ;;;_ = allout-encrypt-unencrypted-on-saves | 453 | ;;;_ = allout-encrypt-unencrypted-on-saves |
| 453 | (defcustom allout-encrypt-unencrypted-on-saves 'except-current | 454 | (defcustom allout-encrypt-unencrypted-on-saves t |
| 454 | "*When saving, should topics pending encryption be encrypted? | 455 | "*When saving, should topics pending encryption be encrypted? |
| 455 | 456 | ||
| 456 | The idea is to prevent file-system exposure of any un-encrypted stuff, and | 457 | The idea is to prevent file-system exposure of any un-encrypted stuff, and |
| @@ -485,8 +486,11 @@ disable auto-saves for that file." | |||
| 485 | ;;;_ + Miscellaneous customization | 486 | ;;;_ + Miscellaneous customization |
| 486 | 487 | ||
| 487 | ;;;_ = allout-command-prefix | 488 | ;;;_ = allout-command-prefix |
| 488 | (defcustom allout-command-prefix "\C-c" | 489 | (defcustom allout-command-prefix "\C-c " |
| 489 | "*Key sequence to be used as prefix for outline mode command key bindings." | 490 | "*Key sequence to be used as prefix for outline mode command key bindings. |
| 491 | |||
| 492 | Default is '\C-c<space>'; just '\C-c' is more short-and-sweet, if you're | ||
| 493 | willing to let allout use a bunch of \C-c keybindings." | ||
| 490 | :type 'string | 494 | :type 'string |
| 491 | :group 'allout) | 495 | :group 'allout) |
| 492 | 496 | ||
| @@ -538,23 +542,12 @@ unless optional third, non-nil element is present.") | |||
| 538 | ("=t" allout-latexify-exposed) | 542 | ("=t" allout-latexify-exposed) |
| 539 | ("=p" allout-flatten-exposed-to-buffer))) | 543 | ("=p" allout-flatten-exposed-to-buffer))) |
| 540 | 544 | ||
| 541 | ;;;_ = allout-isearch-dynamic-expose | ||
| 542 | (defcustom allout-isearch-dynamic-expose t | ||
| 543 | "*Non-nil enable dynamic exposure of hidden incremental-search | ||
| 544 | targets as they're encountered." | ||
| 545 | :type 'boolean | ||
| 546 | :group 'allout) | ||
| 547 | (make-variable-buffer-local 'allout-isearch-dynamic-expose) | ||
| 548 | |||
| 549 | ;;;_ = allout-use-hanging-indents | 545 | ;;;_ = allout-use-hanging-indents |
| 550 | (defcustom allout-use-hanging-indents t | 546 | (defcustom allout-use-hanging-indents t |
| 551 | "*If non-nil, topic body text auto-indent defaults to indent of the header. | 547 | "*If non-nil, topic body text auto-indent defaults to indent of the header. |
| 552 | Ie, it is indented to be just past the header prefix. This is | 548 | Ie, it is indented to be just past the header prefix. This is |
| 553 | relevant mostly for use with indented-text-mode, or other situations | 549 | relevant mostly for use with indented-text-mode, or other situations |
| 554 | where auto-fill occurs. | 550 | where auto-fill occurs." |
| 555 | |||
| 556 | \[This feature no longer depends in any way on the `filladapt.el' | ||
| 557 | lisp-archive package.\]" | ||
| 558 | :type 'boolean | 551 | :type 'boolean |
| 559 | :group 'allout) | 552 | :group 'allout) |
| 560 | (make-variable-buffer-local 'allout-use-hanging-indents) | 553 | (make-variable-buffer-local 'allout-use-hanging-indents) |
| @@ -597,7 +590,7 @@ For details, see `allout-toggle-current-subtree-encryption's docstring." | |||
| 597 | ;;;_ #1 Internal Outline Formatting and Configuration | 590 | ;;;_ #1 Internal Outline Formatting and Configuration |
| 598 | ;;;_ : Version | 591 | ;;;_ : Version |
| 599 | ;;;_ = allout-version | 592 | ;;;_ = allout-version |
| 600 | (defvar allout-version "2.1" | 593 | (defvar allout-version "2.2" |
| 601 | "Version of currently loaded outline package. \(allout.el)") | 594 | "Version of currently loaded outline package. \(allout.el)") |
| 602 | ;;;_ > allout-version | 595 | ;;;_ > allout-version |
| 603 | (defun allout-version (&optional here) | 596 | (defun allout-version (&optional here) |
| @@ -636,9 +629,9 @@ and `allout-distinctive-bullets-string'.") | |||
| 636 | (defvar allout-line-boundary-regexp () | 629 | (defvar allout-line-boundary-regexp () |
| 637 | "`allout-regexp' with outline style beginning-of-line anchor. | 630 | "`allout-regexp' with outline style beginning-of-line anchor. |
| 638 | 631 | ||
| 639 | \(Ie, C-j, *or* C-m, for prefixes of hidden topics). This is properly | 632 | This is properly set when `allout-regexp' is produced by |
| 640 | set when `allout-regexp' is produced by `set-allout-regexp', so | 633 | `set-allout-regexp', so that (match-beginning 2) and (match-end |
| 641 | that (match-beginning 2) and (match-end 2) delimit the prefix.") | 634 | 2) delimit the prefix.") |
| 642 | (make-variable-buffer-local 'allout-line-boundary-regexp) | 635 | (make-variable-buffer-local 'allout-line-boundary-regexp) |
| 643 | ;;;_ = allout-bob-regexp | 636 | ;;;_ = allout-bob-regexp |
| 644 | (defvar allout-bob-regexp () | 637 | (defvar allout-bob-regexp () |
| @@ -753,11 +746,9 @@ Works with respect to `allout-plain-bullets-string' and | |||
| 753 | cur-string | 746 | cur-string |
| 754 | cur-len | 747 | cur-len |
| 755 | cur-char | 748 | cur-char |
| 756 | cur-char-string | 749 | index) |
| 757 | index | ||
| 758 | new-string) | ||
| 759 | (while strings | 750 | (while strings |
| 760 | (setq new-string "") (setq index 0) | 751 | (setq index 0) |
| 761 | (setq cur-len (length (setq cur-string (symbol-value (car strings))))) | 752 | (setq cur-len (length (setq cur-string (symbol-value (car strings))))) |
| 762 | (while (< index cur-len) | 753 | (while (< index cur-len) |
| 763 | (setq cur-char (aref cur-string index)) | 754 | (setq cur-char (aref cur-string index)) |
| @@ -788,7 +779,7 @@ Works with respect to `allout-plain-bullets-string' and | |||
| 788 | allout-primary-bullet | 779 | allout-primary-bullet |
| 789 | "+\\|\^l")) | 780 | "+\\|\^l")) |
| 790 | (setq allout-line-boundary-regexp | 781 | (setq allout-line-boundary-regexp |
| 791 | (concat "\\([\n\r]\\)\\(" allout-regexp "\\)")) | 782 | (concat "\\(\n\\)\\(" allout-regexp "\\)")) |
| 792 | (setq allout-bob-regexp | 783 | (setq allout-bob-regexp |
| 793 | (concat "\\(\\`\\)\\(" allout-regexp "\\)")) | 784 | (concat "\\(\\`\\)\\(" allout-regexp "\\)")) |
| 794 | ) | 785 | ) |
| @@ -955,42 +946,28 @@ from the list." | |||
| 955 | (setq allout-mode-prior-settings rebuild))))) | 946 | (setq allout-mode-prior-settings rebuild))))) |
| 956 | ) | 947 | ) |
| 957 | ;;;_ : Mode-specific incidentals | 948 | ;;;_ : Mode-specific incidentals |
| 958 | ;;;_ = allout-pre-was-isearching nil | ||
| 959 | (defvar allout-pre-was-isearching nil | ||
| 960 | "Cue for isearch-dynamic-exposure mechanism, implemented in | ||
| 961 | allout-pre- and -post-command-hooks.") | ||
| 962 | (make-variable-buffer-local 'allout-pre-was-isearching) | ||
| 963 | ;;;_ = allout-isearch-prior-pos nil | ||
| 964 | (defvar allout-isearch-prior-pos nil | ||
| 965 | "Cue for isearch-dynamic-exposure tracking, used by | ||
| 966 | `allout-isearch-expose'.") | ||
| 967 | (make-variable-buffer-local 'allout-isearch-prior-pos) | ||
| 968 | ;;;_ = allout-isearch-did-quit | ||
| 969 | (defvar allout-isearch-did-quit nil | ||
| 970 | "Distinguishes isearch conclusion and cancellation. | ||
| 971 | |||
| 972 | Maintained by allout-isearch-abort \(which is wrapped around the real | ||
| 973 | isearch-abort), and monitored by allout-isearch-expose for action.") | ||
| 974 | (make-variable-buffer-local 'allout-isearch-did-quit) | ||
| 975 | ;;;_ > allout-unprotected (expr) | 949 | ;;;_ > allout-unprotected (expr) |
| 976 | (defmacro allout-unprotected (expr) | 950 | (defmacro allout-unprotected (expr) |
| 977 | "Enable internal outline operations to alter read-only text." | 951 | "Enable internal outline operations to alter invisible text." |
| 978 | `(let ((was-inhibit-r-o inhibit-read-only)) | 952 | `(let ((inhibit-read-only t)) |
| 979 | (unwind-protect | 953 | ,expr)) |
| 980 | (progn | 954 | ;;;_ = allout-mode-hook |
| 981 | (setq inhibit-read-only t) | 955 | (defvar allout-mode-hook nil |
| 982 | ,expr) | 956 | "*Hook that's run when allout mode starts.") |
| 983 | (setq inhibit-read-only was-inhibit-r-o) | 957 | ;;;_ = allout-overlay-category |
| 984 | ) | 958 | (defvar allout-overlay-category nil |
| 985 | ) | 959 | "Symbol for use in allout invisible-text overlays as the category.") |
| 986 | ) | 960 | ;;;_ = allout-view-change-hook |
| 987 | ;;;_ = allout-undo-aggregation | 961 | (defvar allout-view-change-hook nil |
| 988 | (defvar allout-undo-aggregation 30 | 962 | "*Hook that's run after allout outline visibility changes.") |
| 989 | "Amount of successive self-insert actions to bunch together per undo. | 963 | |
| 990 | 964 | ;;;_ = allout-outside-normal-auto-fill-function | |
| 991 | This is purely a kludge variable, regulating the compensation for a bug in | 965 | (defvar allout-outside-normal-auto-fill-function nil |
| 992 | the way that `before-change-functions' and undo interact.") | 966 | "Value of normal-auto-fill-function outside of allout mode. |
| 993 | (make-variable-buffer-local 'allout-undo-aggregation) | 967 | |
| 968 | Used by allout-auto-fill to do the mandated normal-auto-fill-function | ||
| 969 | wrapped within allout's automatic fill-prefix setting.") | ||
| 970 | (make-variable-buffer-local 'allout-outside-normal-auto-fill-function) | ||
| 994 | ;;;_ = file-var-bug hack | 971 | ;;;_ = file-var-bug hack |
| 995 | (defvar allout-v18/19-file-var-hack nil | 972 | (defvar allout-v18/19-file-var-hack nil |
| 996 | "Horrible hack used to prevent invalid multiple triggering of outline | 973 | "Horrible hack used to prevent invalid multiple triggering of outline |
| @@ -1059,7 +1036,7 @@ was encrypted automatically as part of a file write or autosave.") | |||
| 1059 | (allout-next-topic-pending-encryption except-mark)) | 1036 | (allout-next-topic-pending-encryption except-mark)) |
| 1060 | (progn | 1037 | (progn |
| 1061 | (message "auto-encrypting pending topics") | 1038 | (message "auto-encrypting pending topics") |
| 1062 | (sit-for 2) | 1039 | (sit-for 0) |
| 1063 | (condition-case failure | 1040 | (condition-case failure |
| 1064 | (setq allout-after-save-decrypt | 1041 | (setq allout-after-save-decrypt |
| 1065 | (allout-encrypt-decrypted except-mark)) | 1042 | (allout-encrypt-decrypted except-mark)) |
| @@ -1184,7 +1161,6 @@ the following two lines in your Emacs init file: | |||
| 1184 | ((message | 1161 | ((message |
| 1185 | "Outline mode auto-activation and -layout enabled.") | 1162 | "Outline mode auto-activation and -layout enabled.") |
| 1186 | 'full))))))) | 1163 | 'full))))))) |
| 1187 | |||
| 1188 | ;;;_ > allout-setup-menubar () | 1164 | ;;;_ > allout-setup-menubar () |
| 1189 | (defun allout-setup-menubar () | 1165 | (defun allout-setup-menubar () |
| 1190 | "Populate the current buffer's menubar with `allout-mode' stuff." | 1166 | "Populate the current buffer's menubar with `allout-mode' stuff." |
| @@ -1197,12 +1173,37 @@ the following two lines in your Emacs init file: | |||
| 1197 | (setq cur (car menus) | 1173 | (setq cur (car menus) |
| 1198 | menus (cdr menus)) | 1174 | menus (cdr menus)) |
| 1199 | (easy-menu-add cur)))) | 1175 | (easy-menu-add cur)))) |
| 1176 | ;;;_ > allout-set-overlay-category | ||
| 1177 | (defun allout-set-overlay-category () | ||
| 1178 | "Set the properties of the allout invisible-text overlay." | ||
| 1179 | (setplist 'allout-overlay-category nil) | ||
| 1180 | (put 'allout-overlay-category 'invisible 'allout) | ||
| 1181 | (put 'allout-overlay-category 'evaporate t) | ||
| 1182 | ;; XXX We use isearch-open-invisible *and* isearch-mode-end-hook. The | ||
| 1183 | ;; latter would be sufficient, but it seems that a separate behavior - | ||
| 1184 | ;; the _transient_ opening of invisible text during isearch - is keyed to | ||
| 1185 | ;; presence of the isearch-open-invisible property - even though this | ||
| 1186 | ;; property controls the isearch _arrival_ behavior. This is the case at | ||
| 1187 | ;; least in emacs 21, 22.0, and xemacs 21.4. | ||
| 1188 | (put 'allout-overlay-category 'isearch-open-invisible | ||
| 1189 | 'allout-isearch-end-handler) | ||
| 1190 | (if (featurep 'xemacs) | ||
| 1191 | (put 'allout-overlay-category 'start-open t) | ||
| 1192 | (put 'allout-overlay-category 'insert-in-front-hooks | ||
| 1193 | '(allout-overlay-insert-in-front-handler))) | ||
| 1194 | (if (featurep 'xemacs) | ||
| 1195 | (progn (make-variable-buffer-local 'before-change-functions) | ||
| 1196 | (add-hook 'before-change-functions | ||
| 1197 | 'allout-before-change-handler)) | ||
| 1198 | (put 'allout-overlay-category 'modification-hooks | ||
| 1199 | '(allout-overlay-interior-modification-handler)))) | ||
| 1200 | ;;;_ > allout-mode (&optional toggle) | 1200 | ;;;_ > allout-mode (&optional toggle) |
| 1201 | ;;;_ : Defun: | 1201 | ;;;_ : Defun: |
| 1202 | ;;;###autoload | 1202 | ;;;###autoload |
| 1203 | (defun allout-mode (&optional toggle) | 1203 | (defun allout-mode (&optional toggle) |
| 1204 | ;;;_ . Doc string: | 1204 | ;;;_ . Doc string: |
| 1205 | "Toggle minor mode for controlling exposure and editing of text outlines. | 1205 | "Toggle minor mode for controlling exposure and editing of text outlines. |
| 1206 | \\<allout-mode-map> | ||
| 1206 | 1207 | ||
| 1207 | Optional arg forces mode to re-initialize iff arg is positive num or | 1208 | Optional arg forces mode to re-initialize iff arg is positive num or |
| 1208 | symbol. Allout outline mode always runs as a minor mode. | 1209 | symbol. Allout outline mode always runs as a minor mode. |
| @@ -1244,62 +1245,69 @@ The bindings are dictated by the `allout-keybindings-list' and | |||
| 1244 | \\[allout-forward-current-level] allout-forward-current-level | \\[allout-show-current-entry] allout-show-current-entry | 1245 | \\[allout-forward-current-level] allout-forward-current-level | \\[allout-show-current-entry] allout-show-current-entry |
| 1245 | \\[allout-backward-current-level] allout-backward-current-level | \\[allout-show-all] allout-show-all | 1246 | \\[allout-backward-current-level] allout-backward-current-level | \\[allout-show-all] allout-show-all |
| 1246 | \\[allout-end-of-entry] allout-end-of-entry | 1247 | \\[allout-end-of-entry] allout-end-of-entry |
| 1247 | \\[allout-beginning-of-current-entry,] allout-beginning-of-current-entry, alternately, goes to hot-spot | 1248 | \\[allout-beginning-of-current-entry] allout-beginning-of-current-entry, alternately, goes to hot-spot |
| 1248 | 1249 | ||
| 1249 | Topic Header Production: | 1250 | Topic Header Production: |
| 1250 | ----------------------- | 1251 | ----------------------- |
| 1251 | \\[allout-open-sibtopic] allout-open-sibtopic Create a new sibling after current topic. | 1252 | \\[allout-open-sibtopic] allout-open-sibtopic Create a new sibling after current topic. |
| 1252 | \\[allout-open-subtopic] allout-open-subtopic ... an offspring of current topic. | 1253 | \\[allout-open-subtopic] allout-open-subtopic ... an offspring of current topic. |
| 1253 | \\[allout-open-supertopic] allout-open-supertopic ... a sibling of the current topic's parent. | 1254 | \\[allout-open-supertopic] allout-open-supertopic ... a sibling of the current topic's parent. |
| 1254 | 1255 | ||
| 1255 | Topic Level and Prefix Adjustment: | 1256 | Topic Level and Prefix Adjustment: |
| 1256 | --------------------------------- | 1257 | --------------------------------- |
| 1257 | \\[allout-shift-in] allout-shift-in Shift current topic and all offspring deeper. | 1258 | \\[allout-shift-in] allout-shift-in Shift current topic and all offspring deeper. |
| 1258 | \\[allout-shift-out] allout-shift-out ... less deep. | 1259 | \\[allout-shift-out] allout-shift-out ... less deep. |
| 1259 | \\[allout-rebullet-current-heading] allout-rebullet-current-heading Prompt for alternate bullet for | 1260 | \\[allout-rebullet-current-heading] allout-rebullet-current-heading Prompt for alternate bullet for |
| 1260 | current topic. | 1261 | current topic. |
| 1261 | \\[allout-rebullet-topic] allout-rebullet-topic Reconcile bullets of topic and its offspring | 1262 | \\[allout-rebullet-topic] allout-rebullet-topic Reconcile bullets of topic and its offspring |
| 1262 | - distinctive bullets are not changed, others | 1263 | - distinctive bullets are not changed, others |
| 1263 | alternated according to nesting depth. | 1264 | alternated according to nesting depth. |
| 1264 | \\[allout-number-siblings] allout-number-siblings Number bullets of topic and siblings - the | 1265 | \\[allout-number-siblings] allout-number-siblings Number bullets of topic and siblings - the |
| 1265 | offspring are not affected. With repeat | 1266 | offspring are not affected. With repeat |
| 1266 | count, revoke numbering. | 1267 | count, revoke numbering. |
| 1267 | 1268 | ||
| 1268 | Topic-oriented Killing and Yanking: | 1269 | Topic-oriented Killing and Yanking: |
| 1269 | ---------------------------------- | 1270 | ---------------------------------- |
| 1270 | \\[allout-kill-topic] allout-kill-topic Kill current topic, including offspring. | 1271 | \\[allout-kill-topic] allout-kill-topic Kill current topic, including offspring. |
| 1271 | \\[allout-kill-line] allout-kill-line Like kill-line, but reconciles numbering, etc. | 1272 | \\[allout-kill-line] allout-kill-line Like kill-line, but reconciles numbering, etc. |
| 1272 | \\[allout-yank] allout-yank Yank, adjusting depth of yanked topic to | 1273 | \\[allout-yank] allout-yank Yank, adjusting depth of yanked topic to |
| 1273 | depth of heading if yanking into bare topic | 1274 | depth of heading if yanking into bare topic |
| 1274 | heading (ie, prefix sans text). | 1275 | heading (ie, prefix sans text). |
| 1275 | \\[allout-yank-pop] allout-yank-pop Is to allout-yank as yank-pop is to yank | 1276 | \\[allout-yank-pop] allout-yank-pop Is to allout-yank as yank-pop is to yank |
| 1277 | |||
| 1278 | Topic-oriented Encryption: | ||
| 1279 | ------------------------- | ||
| 1280 | \\[allout-toggle-current-subtree-encryption] allout-toggle-current-subtree-encryption Encrypt/Decrypt topic content | ||
| 1276 | 1281 | ||
| 1277 | Misc commands: | 1282 | Misc commands: |
| 1278 | ------------- | 1283 | ------------- |
| 1279 | M-x outlineify-sticky Activate outline mode for current buffer, | 1284 | M-x outlineify-sticky Activate outline mode for current buffer, |
| 1280 | and establish a default file-var setting | 1285 | and establish a default file-var setting |
| 1281 | for `allout-layout'. | 1286 | for `allout-layout'. |
| 1282 | \\[allout-mark-topic] allout-mark-topic | 1287 | \\[allout-mark-topic] allout-mark-topic |
| 1283 | \\[allout-copy-exposed-to-buffer] allout-copy-exposed-to-buffer | 1288 | \\[allout-copy-exposed-to-buffer] allout-copy-exposed-to-buffer |
| 1284 | Duplicate outline, sans concealed text, to | 1289 | Duplicate outline, sans concealed text, to |
| 1285 | buffer with name derived from derived from that | 1290 | buffer with name derived from derived from that |
| 1286 | of current buffer - \"*BUFFERNAME exposed*\". | 1291 | of current buffer - \"*BUFFERNAME exposed*\". |
| 1287 | \\[allout-flatten-exposed-to-buffer] allout-flatten-exposed-to-buffer | 1292 | \\[allout-flatten-exposed-to-buffer] allout-flatten-exposed-to-buffer |
| 1288 | Like above 'copy-exposed', but convert topic | 1293 | Like above 'copy-exposed', but convert topic |
| 1289 | prefixes to section.subsection... numeric | 1294 | prefixes to section.subsection... numeric |
| 1290 | format. | 1295 | format. |
| 1291 | ESC ESC (allout-init t) Setup Emacs session for outline mode | 1296 | \\[eval-expression] (allout-init t) Setup Emacs session for outline mode |
| 1292 | auto-activation. | 1297 | auto-activation. |
| 1293 | 1298 | ||
| 1294 | Encrypted Entries | 1299 | Topic Encryption |
| 1295 | 1300 | ||
| 1296 | Outline mode supports easily togglable gpg encryption of topics, with | 1301 | Outline mode supports gpg encryption of topics, with support for |
| 1297 | niceties like support for symmetric and key-pair modes, passphrase timeout, | 1302 | symmetric and key-pair modes, passphrase timeout, passphrase |
| 1298 | passphrase consistency checking, user-provided hinting for symmetric key | 1303 | consistency checking, user-provided hinting for symmetric key |
| 1299 | mode, and auto-encryption of topics pending encryption on save. The aim is | 1304 | mode, and auto-encryption of topics pending encryption on save. |
| 1300 | to enable reliable topic privacy while preventing accidents like neglected | 1305 | \(Topics pending encryption are, by default, automatically |
| 1301 | encryption, encryption with a mistaken passphrase, forgetting which | 1306 | encrypted during file saves; if you're editing the contents of |
| 1302 | passphrase was used, and other practical pitfalls. | 1307 | such a topic, it is automatically decrypted for continued |
| 1308 | editing.) The aim is reliable topic privacy while preventing | ||
| 1309 | accidents like neglected encryption before saves, forgetting | ||
| 1310 | which passphrase was used, and other practical pitfalls. | ||
| 1303 | 1311 | ||
| 1304 | See `allout-toggle-current-subtree-encryption' function docstring and | 1312 | See `allout-toggle-current-subtree-encryption' function docstring and |
| 1305 | `allout-encrypt-unencrypted-on-saves' customization variable for details. | 1313 | `allout-encrypt-unencrypted-on-saves' customization variable for details. |
| @@ -1309,22 +1317,21 @@ See `allout-toggle-current-subtree-encryption' function docstring and | |||
| 1309 | Hot-spot operation provides a means for easy, single-keystroke outline | 1317 | Hot-spot operation provides a means for easy, single-keystroke outline |
| 1310 | navigation and exposure control. | 1318 | navigation and exposure control. |
| 1311 | 1319 | ||
| 1312 | \\<allout-mode-map> | ||
| 1313 | When the text cursor is positioned directly on the bullet character of | 1320 | When the text cursor is positioned directly on the bullet character of |
| 1314 | a topic, regular characters (a to z) invoke the commands of the | 1321 | a topic, regular characters (a to z) invoke the commands of the |
| 1315 | corresponding allout-mode keymap control chars. For example, \"f\" | 1322 | corresponding allout-mode keymap control chars. For example, \"f\" |
| 1316 | would invoke the command typically bound to \"C-c C-f\" | 1323 | would invoke the command typically bound to \"C-c<space>C-f\" |
| 1317 | \(\\[allout-forward-current-level] `allout-forward-current-level'). | 1324 | \(\\[allout-forward-current-level] `allout-forward-current-level'). |
| 1318 | 1325 | ||
| 1319 | Thus, by positioning the cursor on a topic bullet, you can execute | 1326 | Thus, by positioning the cursor on a topic bullet, you can |
| 1320 | the outline navigation and manipulation commands with a single | 1327 | execute the outline navigation and manipulation commands with a |
| 1321 | keystroke. Non-literal chars never get this special translation, so | 1328 | single keystroke. Regular navigation keys (eg, \\[forward-char], \\[next-line]) never get |
| 1322 | you can use them to get away from the hot-spot, and back to normal | 1329 | this special translation, so you can use them to get out of the |
| 1323 | operation. | 1330 | hot-spot and back to normal operation. |
| 1324 | 1331 | ||
| 1325 | Note that the command `allout-beginning-of-current-entry' \(\\[allout-beginning-of-current-entry]\) | 1332 | Note that the command `allout-beginning-of-current-entry' \(\\[allout-beginning-of-current-entry]\) |
| 1326 | will move to the hot-spot when the cursor is already located at the | 1333 | will move to the hot-spot when the cursor is already located at the |
| 1327 | beginning of the current entry, so you can simply hit \\[allout-beginning-of-current-entry] | 1334 | beginning of the current entry, so you usually can hit \\[allout-beginning-of-current-entry] |
| 1328 | twice in a row to get to the hot-spot. | 1335 | twice in a row to get to the hot-spot. |
| 1329 | 1336 | ||
| 1330 | Terminology | 1337 | Terminology |
| @@ -1332,7 +1339,7 @@ twice in a row to get to the hot-spot. | |||
| 1332 | Topic hierarchy constituents - TOPICS and SUBTOPICS: | 1339 | Topic hierarchy constituents - TOPICS and SUBTOPICS: |
| 1333 | 1340 | ||
| 1334 | TOPIC: A basic, coherent component of an Emacs outline. It can | 1341 | TOPIC: A basic, coherent component of an Emacs outline. It can |
| 1335 | contain other topics, and it can be subsumed by other topics, | 1342 | contain and be contained by other topics. |
| 1336 | CURRENT topic: | 1343 | CURRENT topic: |
| 1337 | The visible topic most immediately containing the cursor. | 1344 | The visible topic most immediately containing the cursor. |
| 1338 | DEPTH: The degree of nesting of a topic; it increases with | 1345 | DEPTH: The degree of nesting of a topic; it increases with |
| @@ -1376,13 +1383,13 @@ PREFIX-LEAD: | |||
| 1376 | docstring for more detail. | 1383 | docstring for more detail. |
| 1377 | PREFIX-PADDING: | 1384 | PREFIX-PADDING: |
| 1378 | Spaces or asterisks which separate the prefix-lead and the | 1385 | Spaces or asterisks which separate the prefix-lead and the |
| 1379 | bullet, according to the depth of the topic. | 1386 | bullet, determining the depth of the topic. |
| 1380 | BULLET: A character at the end of the topic prefix, it must be one of | 1387 | BULLET: A character at the end of the topic prefix, it must be one of |
| 1381 | the characters listed on `allout-plain-bullets-string' or | 1388 | the characters listed on `allout-plain-bullets-string' or |
| 1382 | `allout-distinctive-bullets-string'. (See the documentation | 1389 | `allout-distinctive-bullets-string'. (See the documentation |
| 1383 | for these variables for more details.) The default choice of | 1390 | for these variables for more details.) The default choice of |
| 1384 | bullet when generating varies in a cycle with the depth of the | 1391 | bullet when generating topics varies in a cycle with the depth of |
| 1385 | topic. | 1392 | the topic. |
| 1386 | ENTRY: The text contained in a topic before any offspring. | 1393 | ENTRY: The text contained in a topic before any offspring. |
| 1387 | BODY: Same as ENTRY. | 1394 | BODY: Same as ENTRY. |
| 1388 | 1395 | ||
| @@ -1393,7 +1400,6 @@ EXPOSURE: | |||
| 1393 | CONCEALED: | 1400 | CONCEALED: |
| 1394 | Topics and entry text whose display is inhibited. Contiguous | 1401 | Topics and entry text whose display is inhibited. Contiguous |
| 1395 | units of concealed text is represented by `...' ellipses. | 1402 | units of concealed text is represented by `...' ellipses. |
| 1396 | (Ref the `selective-display' var.) | ||
| 1397 | 1403 | ||
| 1398 | Concealed topics are effectively collapsed within an ancestor. | 1404 | Concealed topics are effectively collapsed within an ancestor. |
| 1399 | CLOSED: A topic whose immediate offspring and body-text is concealed. | 1405 | CLOSED: A topic whose immediate offspring and body-text is concealed. |
| @@ -1415,9 +1421,11 @@ OPEN: A topic that is not closed, though its offspring or body may be." | |||
| 1415 | ;; allout-mode already called once during this complex command? | 1421 | ;; allout-mode already called once during this complex command? |
| 1416 | (same-complex-command (eq allout-v18/19-file-var-hack | 1422 | (same-complex-command (eq allout-v18/19-file-var-hack |
| 1417 | (car command-history))) | 1423 | (car command-history))) |
| 1418 | (write-file-hook-var-name (if (boundp 'write-file-functions) | 1424 | (write-file-hook-var-name (cond ((boundp 'write-file-functions) |
| 1419 | 'write-file-functions | 1425 | 'write-file-functions) |
| 1420 | 'local-write-file-hooks)) | 1426 | ((boundp 'write-file-hooks) |
| 1427 | 'write-file-hooks) | ||
| 1428 | (t 'local-write-file-hooks))) | ||
| 1421 | do-layout | 1429 | do-layout |
| 1422 | ) | 1430 | ) |
| 1423 | 1431 | ||
| @@ -1465,9 +1473,8 @@ OPEN: A topic that is not closed, though its offspring or body may be." | |||
| 1465 | (progn | 1473 | (progn |
| 1466 | (allout-resumptions 'allout-primary-bullet) | 1474 | (allout-resumptions 'allout-primary-bullet) |
| 1467 | (allout-resumptions 'allout-old-style-prefixes))) | 1475 | (allout-resumptions 'allout-old-style-prefixes))) |
| 1468 | (allout-resumptions 'selective-display) | 1476 | ;;(allout-resumptions 'selective-display) |
| 1469 | (if (and (boundp 'before-change-functions) before-change-functions) | 1477 | (remove-from-invisibility-spec '(allout . t)) |
| 1470 | (allout-resumptions 'before-change-functions)) | ||
| 1471 | (set write-file-hook-var-name | 1478 | (set write-file-hook-var-name |
| 1472 | (delq 'allout-write-file-hook-handler | 1479 | (delq 'allout-write-file-hook-handler |
| 1473 | (symbol-value write-file-hook-var-name))) | 1480 | (symbol-value write-file-hook-var-name))) |
| @@ -1476,9 +1483,8 @@ OPEN: A topic that is not closed, though its offspring or body may be." | |||
| 1476 | auto-save-hook)) | 1483 | auto-save-hook)) |
| 1477 | (allout-resumptions 'paragraph-start) | 1484 | (allout-resumptions 'paragraph-start) |
| 1478 | (allout-resumptions 'paragraph-separate) | 1485 | (allout-resumptions 'paragraph-separate) |
| 1479 | (allout-resumptions (if (string-match "^18" emacs-version) | 1486 | (allout-resumptions 'auto-fill-function) |
| 1480 | 'auto-fill-hook | 1487 | (allout-resumptions 'normal-auto-fill-function) |
| 1481 | 'auto-fill-function)) | ||
| 1482 | (allout-resumptions 'allout-former-auto-filler) | 1488 | (allout-resumptions 'allout-former-auto-filler) |
| 1483 | (setq allout-mode nil)) | 1489 | (setq allout-mode nil)) |
| 1484 | 1490 | ||
| @@ -1490,6 +1496,8 @@ OPEN: A topic that is not closed, though its offspring or body may be." | |||
| 1490 | (allout-resumptions 'allout-primary-bullet '("*")) | 1496 | (allout-resumptions 'allout-primary-bullet '("*")) |
| 1491 | (allout-resumptions 'allout-old-style-prefixes '(())))) | 1497 | (allout-resumptions 'allout-old-style-prefixes '(())))) |
| 1492 | 1498 | ||
| 1499 | (allout-set-overlay-category) ; Doesn't hurt to redo this. | ||
| 1500 | |||
| 1493 | (allout-infer-header-lead) | 1501 | (allout-infer-header-lead) |
| 1494 | (allout-infer-body-reindent) | 1502 | (allout-infer-body-reindent) |
| 1495 | 1503 | ||
| @@ -1525,25 +1533,24 @@ OPEN: A topic that is not closed, though its offspring or body may be." | |||
| 1525 | (current-local-map))) | 1533 | (current-local-map))) |
| 1526 | ) | 1534 | ) |
| 1527 | 1535 | ||
| 1528 | ; selective-display is the | 1536 | (add-to-invisibility-spec '(allout . t)) |
| 1529 | ; emacs conditional exposure | 1537 | (make-local-variable 'line-move-ignore-invisible) |
| 1530 | ; mechanism: | 1538 | (setq line-move-ignore-invisible t) |
| 1531 | (allout-resumptions 'selective-display '(t)) | ||
| 1532 | (add-hook 'pre-command-hook 'allout-pre-command-business) | 1539 | (add-hook 'pre-command-hook 'allout-pre-command-business) |
| 1533 | (add-hook 'post-command-hook 'allout-post-command-business) | 1540 | (add-hook 'post-command-hook 'allout-post-command-business) |
| 1541 | (add-hook 'isearch-mode-end-hook 'allout-isearch-end-handler) | ||
| 1534 | (add-hook write-file-hook-var-name 'allout-write-file-hook-handler) | 1542 | (add-hook write-file-hook-var-name 'allout-write-file-hook-handler) |
| 1535 | (add-hook 'auto-save-hook 'allout-auto-save-hook-handler) | 1543 | (add-hook 'auto-save-hook 'allout-auto-save-hook-handler) |
| 1536 | ; Custom auto-fill func, to support | 1544 | ; Custom auto-fill func, to support |
| 1537 | ; respect for topic headline, | 1545 | ; respect for topic headline, |
| 1538 | ; hanging-indents, etc: | 1546 | ; hanging-indents, etc: |
| 1539 | (let* ((fill-func-var (if (string-match "^18" emacs-version) | 1547 | ;; Register prevailing fill func for use by allout-auto-fill: |
| 1540 | 'auto-fill-hook | 1548 | (allout-resumptions 'allout-former-auto-filler (list auto-fill-function)) |
| 1541 | 'auto-fill-function)) | 1549 | ;; Register allout-auto-fill to be used if filling is active: |
| 1542 | (fill-func (symbol-value fill-func-var))) | 1550 | (allout-resumptions 'auto-fill-function '(allout-auto-fill)) |
| 1543 | ;; Register prevailing fill func for use by allout-auto-fill: | 1551 | (allout-resumptions 'allout-outside-normal-auto-fill-function |
| 1544 | (allout-resumptions 'allout-former-auto-filler (list fill-func)) | 1552 | (list normal-auto-fill-function)) |
| 1545 | ;; Register allout-auto-fill to be used if filling is active: | 1553 | (allout-resumptions 'normal-auto-fill-function '(allout-auto-fill)) |
| 1546 | (allout-resumptions fill-func-var '(allout-auto-fill))) | ||
| 1547 | ;; Paragraphs are broken by topic headlines. | 1554 | ;; Paragraphs are broken by topic headlines. |
| 1548 | (make-local-variable 'paragraph-start) | 1555 | (make-local-variable 'paragraph-start) |
| 1549 | (allout-resumptions 'paragraph-start | 1556 | (allout-resumptions 'paragraph-start |
| @@ -1563,10 +1570,6 @@ OPEN: A topic that is not closed, though its offspring or body may be." | |||
| 1563 | (if allout-layout | 1570 | (if allout-layout |
| 1564 | (setq do-layout t)) | 1571 | (setq do-layout t)) |
| 1565 | 1572 | ||
| 1566 | (if (and allout-isearch-dynamic-expose | ||
| 1567 | (not (fboundp 'allout-real-isearch-abort))) | ||
| 1568 | (allout-enwrap-isearch)) | ||
| 1569 | |||
| 1570 | (run-hooks 'allout-mode-hook) | 1573 | (run-hooks 'allout-mode-hook) |
| 1571 | (setq allout-mode t)) | 1574 | (setq allout-mode t)) |
| 1572 | 1575 | ||
| @@ -1602,9 +1605,92 @@ OPEN: A topic that is not closed, though its offspring or body may be." | |||
| 1602 | allout-mode | 1605 | allout-mode |
| 1603 | ) ; let* | 1606 | ) ; let* |
| 1604 | ) ; defun | 1607 | ) ; defun |
| 1608 | |||
| 1609 | ;;;_ - Position Assessment | ||
| 1610 | ;;;_ > allout-hidden-p (&optional pos) | ||
| 1611 | (defsubst allout-hidden-p (&optional pos) | ||
| 1612 | "Non-nil if the character after point is invisible." | ||
| 1613 | (get-char-property (or pos (point)) 'invisible)) | ||
| 1614 | |||
| 1605 | ;;;_ > allout-minor-mode | 1615 | ;;;_ > allout-minor-mode |
| 1606 | (defalias 'allout-minor-mode 'allout-mode) | 1616 | (defalias 'allout-minor-mode 'allout-mode) |
| 1607 | 1617 | ||
| 1618 | ;;;_ > allout-overlay-insert-in-front-handler (ol after beg end | ||
| 1619 | ;;; &optional prelen) | ||
| 1620 | (defun allout-overlay-insert-in-front-handler (ol after beg end | ||
| 1621 | &optional prelen) | ||
| 1622 | "Shift the overlay so stuff inserted in front of it are excluded." | ||
| 1623 | (if after | ||
| 1624 | (move-overlay ol (1+ beg) (overlay-end ol)))) | ||
| 1625 | ;;;_ > allout-overlay-interior-modification-handler (ol after beg end | ||
| 1626 | ;;; &optional prelen) | ||
| 1627 | (defun allout-overlay-interior-modification-handler (ol after beg end | ||
| 1628 | &optional prelen) | ||
| 1629 | "Get confirmation before making arbitrary changes to invisible text. | ||
| 1630 | |||
| 1631 | We expose the invisible text and ask for confirmation. Refusal or | ||
| 1632 | keyboard-quit abandons the changes, with keyboard-quit additionally | ||
| 1633 | reclosing the opened text. | ||
| 1634 | |||
| 1635 | No confirmation is necessary when inhibit-read-only is set - eg, allout | ||
| 1636 | internal functions use this feature cohesively bunch changes." | ||
| 1637 | |||
| 1638 | (when (and (not inhibit-read-only) (not after)) | ||
| 1639 | (let ((start (point)) | ||
| 1640 | (ol-start (overlay-start ol)) | ||
| 1641 | (ol-end (overlay-end ol)) | ||
| 1642 | (msg "Change within concealed text disallowed.") | ||
| 1643 | opened | ||
| 1644 | first) | ||
| 1645 | (goto-char beg) | ||
| 1646 | (while (< (point) end) | ||
| 1647 | (when (allout-hidden-p) | ||
| 1648 | (allout-show-to-offshoot) | ||
| 1649 | (if (allout-hidden-p) | ||
| 1650 | (save-excursion (forward-char 1) | ||
| 1651 | (allout-show-to-offshoot))) | ||
| 1652 | (when (not first) | ||
| 1653 | (setq opened t) | ||
| 1654 | (setq first (point)))) | ||
| 1655 | (goto-char (if (featurep 'xemacs) | ||
| 1656 | (next-property-change (1+ (point)) nil end) | ||
| 1657 | (next-char-property-change (1+ (point)) end)))) | ||
| 1658 | (when first | ||
| 1659 | (goto-char first) | ||
| 1660 | (condition-case nil | ||
| 1661 | (if (not | ||
| 1662 | (yes-or-no-p | ||
| 1663 | (substitute-command-keys | ||
| 1664 | (concat "Modify this concealed text? (\"no\" aborts," | ||
| 1665 | " \\[keyboard-quit] also reconceals) ")))) | ||
| 1666 | (progn (goto-char start) | ||
| 1667 | (error "Concealed-text change refused."))) | ||
| 1668 | (quit (allout-flag-region ol-start ol-end nil) | ||
| 1669 | (allout-flag-region ol-start ol-end t) | ||
| 1670 | (error "Concealed-text change abandoned, text reconcealed.")))) | ||
| 1671 | (goto-char start)))) | ||
| 1672 | ;;;_ > allout-before-change-handler (beg end) | ||
| 1673 | (defun allout-before-change-handler (beg end) | ||
| 1674 | "Protect against changes to invisible text. | ||
| 1675 | |||
| 1676 | See allout-overlay-interior-modification-handler for details. | ||
| 1677 | |||
| 1678 | This before-change handler is used only where modification-hooks | ||
| 1679 | overlay property is not supported." | ||
| 1680 | (if (not allout-mode) | ||
| 1681 | nil | ||
| 1682 | (allout-overlay-interior-modification-handler nil nil beg end nil))) | ||
| 1683 | ;;;_ > allout-isearch-end-handler (&optional overlay) | ||
| 1684 | (defun allout-isearch-end-handler (&optional overlay) | ||
| 1685 | "Reconcile allout outline exposure on arriving in hidden text after isearch. | ||
| 1686 | |||
| 1687 | Optional OVERLAY parameter is for when this function is used by | ||
| 1688 | `isearch-open-invisible' overlay property. It is otherwise unused, so this | ||
| 1689 | function can also be used as an `isearch-mode-end-hook'." | ||
| 1690 | |||
| 1691 | (if (and (allout-mode-p) (allout-hidden-p)) | ||
| 1692 | (allout-show-to-offshoot))) | ||
| 1693 | |||
| 1608 | ;;;_ #3 Internal Position State-Tracking - "allout-recent-*" funcs | 1694 | ;;;_ #3 Internal Position State-Tracking - "allout-recent-*" funcs |
| 1609 | ;;; All the basic outline functions that directly do string matches to | 1695 | ;;; All the basic outline functions that directly do string matches to |
| 1610 | ;;; evaluate heading prefix location set the variables | 1696 | ;;; evaluate heading prefix location set the variables |
| @@ -1667,7 +1753,6 @@ to return the current depth of the most recently matched topic." | |||
| 1667 | 1753 | ||
| 1668 | ;;;_ #4 Navigation | 1754 | ;;;_ #4 Navigation |
| 1669 | 1755 | ||
| 1670 | ;;;_ - Position Assessment | ||
| 1671 | ;;;_ : Location Predicates | 1756 | ;;;_ : Location Predicates |
| 1672 | ;;;_ > allout-on-current-heading-p () | 1757 | ;;;_ > allout-on-current-heading-p () |
| 1673 | (defun allout-on-current-heading-p () | 1758 | (defun allout-on-current-heading-p () |
| @@ -1675,7 +1760,7 @@ to return the current depth of the most recently matched topic." | |||
| 1675 | 1760 | ||
| 1676 | Actually, returns prefix beginning point." | 1761 | Actually, returns prefix beginning point." |
| 1677 | (save-excursion | 1762 | (save-excursion |
| 1678 | (beginning-of-line) | 1763 | (allout-beginning-of-current-line) |
| 1679 | (and (looking-at allout-regexp) | 1764 | (and (looking-at allout-regexp) |
| 1680 | (allout-prefix-data (match-beginning 0) (match-end 0))))) | 1765 | (allout-prefix-data (match-beginning 0) (match-end 0))))) |
| 1681 | ;;;_ > allout-on-heading-p () | 1766 | ;;;_ > allout-on-heading-p () |
| @@ -1686,39 +1771,36 @@ Actually, returns prefix beginning point." | |||
| 1686 | (and (save-excursion (beginning-of-line) | 1771 | (and (save-excursion (beginning-of-line) |
| 1687 | (looking-at allout-regexp)) | 1772 | (looking-at allout-regexp)) |
| 1688 | (= (point)(save-excursion (allout-end-of-prefix)(point))))) | 1773 | (= (point)(save-excursion (allout-end-of-prefix)(point))))) |
| 1689 | ;;;_ > allout-hidden-p () | ||
| 1690 | (defmacro allout-hidden-p () | ||
| 1691 | "True if point is in hidden text." | ||
| 1692 | '(save-excursion | ||
| 1693 | (and (re-search-backward "[\n\r]" () t) | ||
| 1694 | (= ?\r (following-char))))) | ||
| 1695 | ;;;_ > allout-visible-p () | ||
| 1696 | (defmacro allout-visible-p () | ||
| 1697 | "True if point is not in hidden text." | ||
| 1698 | (interactive) | ||
| 1699 | '(not (allout-hidden-p))) | ||
| 1700 | ;;;_ : Location attributes | 1774 | ;;;_ : Location attributes |
| 1701 | ;;;_ > allout-depth () | 1775 | ;;;_ > allout-depth () |
| 1702 | (defsubst allout-depth () | 1776 | (defun allout-depth () |
| 1703 | "Like `allout-current-depth', but respects hidden as well as visible topics." | 1777 | "Return depth of topic most immediately containing point. |
| 1778 | |||
| 1779 | Return zero if point is not within any topic. | ||
| 1780 | |||
| 1781 | Like `allout-current-depth', but respects hidden as well as visible topics." | ||
| 1704 | (save-excursion | 1782 | (save-excursion |
| 1705 | (if (allout-goto-prefix) | 1783 | (let ((start-point (point))) |
| 1706 | (allout-recent-depth) | 1784 | (if (and (allout-goto-prefix) |
| 1707 | (progn | 1785 | (not (< start-point (point)))) |
| 1708 | ;; Oops, no prefix, zero prefix data: | 1786 | (allout-recent-depth) |
| 1709 | (allout-prefix-data (point)(point)) | 1787 | (progn |
| 1710 | ;; ... and return 0: | 1788 | ;; Oops, no prefix, zero prefix data: |
| 1711 | 0)))) | 1789 | (allout-prefix-data (point)(point)) |
| 1790 | ;; ... and return 0: | ||
| 1791 | 0))))) | ||
| 1712 | ;;;_ > allout-current-depth () | 1792 | ;;;_ > allout-current-depth () |
| 1713 | (defmacro allout-current-depth () | 1793 | (defun allout-current-depth () |
| 1714 | "Return nesting depth of visible topic most immediately containing point." | 1794 | "Return depth of visible topic most immediately containing point. |
| 1715 | '(save-excursion | 1795 | |
| 1716 | (if (allout-back-to-current-heading) | 1796 | Return zero if point is not within any topic." |
| 1717 | (max 1 | 1797 | (save-excursion |
| 1718 | (- allout-recent-prefix-end | 1798 | (if (allout-back-to-current-heading) |
| 1719 | allout-recent-prefix-beginning | 1799 | (max 1 |
| 1720 | allout-header-subtraction)) | 1800 | (- allout-recent-prefix-end |
| 1721 | 0))) | 1801 | allout-recent-prefix-beginning |
| 1802 | allout-header-subtraction)) | ||
| 1803 | 0))) | ||
| 1722 | ;;;_ > allout-get-current-prefix () | 1804 | ;;;_ > allout-get-current-prefix () |
| 1723 | (defun allout-get-current-prefix () | 1805 | (defun allout-get-current-prefix () |
| 1724 | "Topic prefix of the current topic." | 1806 | "Topic prefix of the current topic." |
| @@ -1734,7 +1816,7 @@ Actually, returns prefix beginning point." | |||
| 1734 | ;;;_ > allout-current-bullet () | 1816 | ;;;_ > allout-current-bullet () |
| 1735 | (defun allout-current-bullet () | 1817 | (defun allout-current-bullet () |
| 1736 | "Return bullet of current (visible) topic heading, or none if none found." | 1818 | "Return bullet of current (visible) topic heading, or none if none found." |
| 1737 | (condition-case err | 1819 | (condition-case nil |
| 1738 | (save-excursion | 1820 | (save-excursion |
| 1739 | (allout-back-to-current-heading) | 1821 | (allout-back-to-current-heading) |
| 1740 | (buffer-substring (- allout-recent-prefix-end 1) | 1822 | (buffer-substring (- allout-recent-prefix-end 1) |
| @@ -1783,7 +1865,31 @@ Outermost is first." | |||
| 1783 | rev-sibls) | 1865 | rev-sibls) |
| 1784 | ) | 1866 | ) |
| 1785 | 1867 | ||
| 1786 | ;;;_ - Navigation macros | 1868 | ;;;_ - Navigation routines |
| 1869 | ;;;_ > allout-beginning-of-current-line () | ||
| 1870 | (defun allout-beginning-of-current-line () | ||
| 1871 | "Like beginning of line, but to visible text." | ||
| 1872 | |||
| 1873 | ;; XXX We would use `(move-beginning-of-line 1)', but it gets | ||
| 1874 | ;; stuck on some hidden newlines, eg at column 80, as of GNU Emacs 22.0.50. | ||
| 1875 | ;; Conversely, `beginning-of-line' can make no progress in other | ||
| 1876 | ;; situations. Both are necessary, in the order used below. | ||
| 1877 | (move-beginning-of-line 1) | ||
| 1878 | (beginning-of-line) | ||
| 1879 | (while (or (not (bolp)) (allout-hidden-p)) | ||
| 1880 | (beginning-of-line) | ||
| 1881 | (if (or (allout-hidden-p) (not (bolp))) | ||
| 1882 | (forward-char -1)))) | ||
| 1883 | ;;;_ > allout-end-of-current-line () | ||
| 1884 | (defun allout-end-of-current-line () | ||
| 1885 | "Move to the end of line, past concealed text if any." | ||
| 1886 | ;; XXX This is for symmetry with `allout-beginning-of-current-line' - | ||
| 1887 | ;; `move-end-of-line' doesn't suffer the same problem as | ||
| 1888 | ;; `move-beginning-of-line'. | ||
| 1889 | (end-of-line) | ||
| 1890 | (while (allout-hidden-p) | ||
| 1891 | (end-of-line) | ||
| 1892 | (if (allout-hidden-p) (forward-char 1)))) | ||
| 1787 | ;;;_ > allout-next-heading () | 1893 | ;;;_ > allout-next-heading () |
| 1788 | (defsubst allout-next-heading () | 1894 | (defsubst allout-next-heading () |
| 1789 | "Move to the heading for the topic \(possibly invisible) before this one. | 1895 | "Move to the heading for the topic \(possibly invisible) before this one. |
| @@ -1798,7 +1904,7 @@ Returns the location of the heading, or nil if none found." | |||
| 1798 | (goto-char (or (match-beginning 2) | 1904 | (goto-char (or (match-beginning 2) |
| 1799 | allout-recent-prefix-beginning)) | 1905 | allout-recent-prefix-beginning)) |
| 1800 | (or (match-end 2) allout-recent-prefix-end)))) | 1906 | (or (match-end 2) allout-recent-prefix-end)))) |
| 1801 | ;;;_ : allout-this-or-next-heading | 1907 | ;;;_ > allout-this-or-next-heading |
| 1802 | (defun allout-this-or-next-heading () | 1908 | (defun allout-this-or-next-heading () |
| 1803 | "Position cursor on current or next heading." | 1909 | "Position cursor on current or next heading." |
| 1804 | ;; A throwaway non-macro that is defined after allout-next-heading | 1910 | ;; A throwaway non-macro that is defined after allout-next-heading |
| @@ -1822,6 +1928,21 @@ Return the location of the beginning of the heading, or nil if not found." | |||
| 1822 | (goto-char (or (match-beginning 2) | 1928 | (goto-char (or (match-beginning 2) |
| 1823 | allout-recent-prefix-beginning)) | 1929 | allout-recent-prefix-beginning)) |
| 1824 | (or (match-end 2) allout-recent-prefix-end)))))) | 1930 | (or (match-end 2) allout-recent-prefix-end)))))) |
| 1931 | ;;;_ > allout-get-invisibility-overlay () | ||
| 1932 | (defun allout-get-invisibility-overlay () | ||
| 1933 | "Return the overlay at point that dictates allout invisibility." | ||
| 1934 | (let ((overlays (overlays-at (point))) | ||
| 1935 | got) | ||
| 1936 | (while (and overlays (not got)) | ||
| 1937 | (if (equal (overlay-get (car overlays) 'invisible) 'allout) | ||
| 1938 | (setq got (car overlays)))) | ||
| 1939 | got)) | ||
| 1940 | ;;;_ > allout-back-to-visible-text () | ||
| 1941 | (defun allout-back-to-visible-text () | ||
| 1942 | "Move to most recent prior character that is visible, and return point." | ||
| 1943 | (if (allout-hidden-p) | ||
| 1944 | (goto-char (overlay-start (allout-get-invisibility-overlay)))) | ||
| 1945 | (point)) | ||
| 1825 | 1946 | ||
| 1826 | ;;;_ - Subtree Charting | 1947 | ;;;_ - Subtree Charting |
| 1827 | ;;;_ " These routines either produce or assess charts, which are | 1948 | ;;;_ " These routines either produce or assess charts, which are |
| @@ -1912,11 +2033,11 @@ starting point, and PREV-DEPTH is depth of prior topic." | |||
| 1912 | ; the original level. Position | 2033 | ; the original level. Position |
| 1913 | ; to the end of it: | 2034 | ; to the end of it: |
| 1914 | (progn (and (not (eobp)) (forward-char -1)) | 2035 | (progn (and (not (eobp)) (forward-char -1)) |
| 1915 | (and (memq (preceding-char) '(?\n ?\r)) | 2036 | (and (= (preceding-char) ?\n) |
| 1916 | (memq (aref (buffer-substring (max 1 (- (point) 3)) | 2037 | (= (aref (buffer-substring (max 1 (- (point) 3)) |
| 1917 | (point)) | 2038 | (point)) |
| 1918 | 1) | 2039 | 1) |
| 1919 | '(?\n ?\r)) | 2040 | ?\n) |
| 1920 | (forward-char -1)) | 2041 | (forward-char -1)) |
| 1921 | (setq allout-recent-end-of-subtree (point)))) | 2042 | (setq allout-recent-end-of-subtree (point)))) |
| 1922 | 2043 | ||
| @@ -1954,7 +2075,7 @@ start point." | |||
| 1954 | (if further (setq result (append further result))) | 2075 | (if further (setq result (append further result))) |
| 1955 | (setq chart (cdr chart))) | 2076 | (setq chart (cdr chart))) |
| 1956 | (goto-char here) | 2077 | (goto-char here) |
| 1957 | (if (= (preceding-char) ?\r) | 2078 | (if (allout-hidden-p) |
| 1958 | (setq result (cons here result))) | 2079 | (setq result (cons here result))) |
| 1959 | (setq chart (cdr chart)))) | 2080 | (setq chart (cdr chart)))) |
| 1960 | result)) | 2081 | result)) |
| @@ -2003,7 +2124,7 @@ Returns the point at the beginning of the prefix, or nil if none." | |||
| 2003 | 2124 | ||
| 2004 | (let (done) | 2125 | (let (done) |
| 2005 | (while (and (not done) | 2126 | (while (and (not done) |
| 2006 | (re-search-backward "[\n\r]" nil 1)) | 2127 | (search-backward "\n" nil 1)) |
| 2007 | (forward-char 1) | 2128 | (forward-char 1) |
| 2008 | (if (looking-at allout-regexp) | 2129 | (if (looking-at allout-regexp) |
| 2009 | (setq done (allout-prefix-data (match-beginning 0) | 2130 | (setq done (allout-prefix-data (match-beginning 0) |
| @@ -2042,19 +2163,30 @@ otherwise skip white space between bullet and ensuing text." | |||
| 2042 | (1- (match-end 0)))) | 2163 | (1- (match-end 0)))) |
| 2043 | ;;;_ > allout-back-to-current-heading () | 2164 | ;;;_ > allout-back-to-current-heading () |
| 2044 | (defun allout-back-to-current-heading () | 2165 | (defun allout-back-to-current-heading () |
| 2045 | "Move to heading line of current topic, or beginning if already on the line." | 2166 | "Move to heading line of current topic, or beginning if already on the line. |
| 2046 | 2167 | ||
| 2047 | (beginning-of-line) | 2168 | Return value of point, unless we started outside of (before any) topics, |
| 2048 | (prog1 (or (allout-on-current-heading-p) | 2169 | in which case we return nil." |
| 2049 | (and (re-search-backward (concat "^\\(" allout-regexp "\\)") | 2170 | |
| 2050 | nil | 2171 | (allout-beginning-of-current-line) |
| 2051 | 'move) | 2172 | (if (or (allout-on-current-heading-p) |
| 2052 | (allout-prefix-data (match-beginning 1)(match-end 1)))) | 2173 | (and (re-search-backward (concat "^\\(" allout-regexp "\\)") |
| 2053 | (if (interactive-p) (allout-end-of-prefix)))) | 2174 | nil 'move) |
| 2175 | (progn (while (allout-hidden-p) | ||
| 2176 | (allout-beginning-of-current-line) | ||
| 2177 | (if (not (looking-at allout-regexp)) | ||
| 2178 | (re-search-backward (concat | ||
| 2179 | "^\\(" allout-regexp "\\)") | ||
| 2180 | nil 'move))) | ||
| 2181 | (allout-prefix-data (match-beginning 1) | ||
| 2182 | (match-end 1))))) | ||
| 2183 | (if (interactive-p) | ||
| 2184 | (allout-end-of-prefix) | ||
| 2185 | (point)))) | ||
| 2054 | ;;;_ > allout-back-to-heading () | 2186 | ;;;_ > allout-back-to-heading () |
| 2055 | (defalias 'allout-back-to-heading 'allout-back-to-current-heading) | 2187 | (defalias 'allout-back-to-heading 'allout-back-to-current-heading) |
| 2056 | ;;;_ > allout-pre-next-preface () | 2188 | ;;;_ > allout-pre-next-prefix () |
| 2057 | (defun allout-pre-next-preface () | 2189 | (defun allout-pre-next-prefix () |
| 2058 | "Skip forward to just before the next heading line. | 2190 | "Skip forward to just before the next heading line. |
| 2059 | 2191 | ||
| 2060 | Returns that character position." | 2192 | Returns that character position." |
| @@ -2062,12 +2194,16 @@ Returns that character position." | |||
| 2062 | (if (re-search-forward allout-line-boundary-regexp nil 'move) | 2194 | (if (re-search-forward allout-line-boundary-regexp nil 'move) |
| 2063 | (prog1 (goto-char (match-beginning 0)) | 2195 | (prog1 (goto-char (match-beginning 0)) |
| 2064 | (allout-prefix-data (match-beginning 2)(match-end 2))))) | 2196 | (allout-prefix-data (match-beginning 2)(match-end 2))))) |
| 2065 | ;;;_ > allout-end-of-subtree (&optional current) | 2197 | ;;;_ > allout-end-of-subtree (&optional current include-trailing-blank) |
| 2066 | (defun allout-end-of-subtree (&optional current) | 2198 | (defun allout-end-of-subtree (&optional current include-trailing-blank) |
| 2067 | "Put point at the end of the last leaf in the containing topic. | 2199 | "Put point at the end of the last leaf in the containing topic. |
| 2068 | 2200 | ||
| 2069 | If optional CURRENT is true (default false), then put point at the end of | 2201 | Optional CURRENT means put point at the end of the containing |
| 2070 | the containing visible topic. | 2202 | visible topic. |
| 2203 | |||
| 2204 | Optional INCLUDE-TRAILING-BLANK means include a trailing blank line, if | ||
| 2205 | any, as part of the subtree. Otherwise, that trailing blank will be | ||
| 2206 | excluded as delimiting whitespace between topics. | ||
| 2071 | 2207 | ||
| 2072 | Returns the value of point." | 2208 | Returns the value of point." |
| 2073 | (interactive "P") | 2209 | (interactive "P") |
| @@ -2080,18 +2216,21 @@ Returns the value of point." | |||
| 2080 | (> (allout-recent-depth) level)) | 2216 | (> (allout-recent-depth) level)) |
| 2081 | (allout-next-heading)) | 2217 | (allout-next-heading)) |
| 2082 | (and (not (eobp)) (forward-char -1)) | 2218 | (and (not (eobp)) (forward-char -1)) |
| 2083 | (and (memq (preceding-char) '(?\n ?\r)) | 2219 | (if (and (not include-trailing-blank) (= ?\n (preceding-char))) |
| 2084 | (memq (aref (buffer-substring (max 1 (- (point) 3)) (point)) 1) | ||
| 2085 | '(?\n ?\r)) | ||
| 2086 | (forward-char -1)) | 2220 | (forward-char -1)) |
| 2087 | (setq allout-recent-end-of-subtree (point)))) | 2221 | (setq allout-recent-end-of-subtree (point)))) |
| 2088 | ;;;_ > allout-end-of-current-subtree () | 2222 | ;;;_ > allout-end-of-current-subtree (&optional include-trailing-blank) |
| 2089 | (defun allout-end-of-current-subtree () | 2223 | (defun allout-end-of-current-subtree (&optional include-trailing-blank) |
| 2224 | |||
| 2090 | "Put point at end of last leaf in currently visible containing topic. | 2225 | "Put point at end of last leaf in currently visible containing topic. |
| 2091 | 2226 | ||
| 2227 | Optional INCLUDE-TRAILING-BLANK means include a trailing blank line, if | ||
| 2228 | any, as part of the subtree. Otherwise, that trailing blank will be | ||
| 2229 | excluded as delimiting whitespace between topics. | ||
| 2230 | |||
| 2092 | Returns the value of point." | 2231 | Returns the value of point." |
| 2093 | (interactive) | 2232 | (interactive) |
| 2094 | (allout-end-of-subtree t)) | 2233 | (allout-end-of-subtree t include-trailing-blank)) |
| 2095 | ;;;_ > allout-beginning-of-current-entry () | 2234 | ;;;_ > allout-beginning-of-current-entry () |
| 2096 | (defun allout-beginning-of-current-entry () | 2235 | (defun allout-beginning-of-current-entry () |
| 2097 | "When not already there, position point at beginning of current topic header. | 2236 | "When not already there, position point at beginning of current topic header. |
| @@ -2104,18 +2243,23 @@ If already there, move cursor to bullet for hot-spot operation. | |||
| 2104 | (if (and (interactive-p) | 2243 | (if (and (interactive-p) |
| 2105 | (= (point) start-point)) | 2244 | (= (point) start-point)) |
| 2106 | (goto-char (allout-current-bullet-pos))))) | 2245 | (goto-char (allout-current-bullet-pos))))) |
| 2107 | ;;;_ > allout-end-of-entry () | 2246 | ;;;_ > allout-end-of-entry (&optional inclusive) |
| 2108 | (defun allout-end-of-entry () | 2247 | (defun allout-end-of-entry (&optional inclusive) |
| 2109 | "Position the point at the end of the current topics' entry." | 2248 | "Position the point at the end of the current topics' entry. |
| 2249 | |||
| 2250 | Optional INCLUSIVE means also include trailing empty line, if any. When | ||
| 2251 | unset, whitespace between items separates them even when the items are | ||
| 2252 | collapsed." | ||
| 2110 | (interactive) | 2253 | (interactive) |
| 2111 | (prog1 (allout-pre-next-preface) | 2254 | (allout-pre-next-prefix) |
| 2112 | (if (and (not (bobp))(looking-at "^$")) | 2255 | (if (and (not inclusive) (not (bobp)) (= ?\n (preceding-char))) |
| 2113 | (forward-char -1)))) | 2256 | (forward-char -1)) |
| 2257 | (point)) | ||
| 2114 | ;;;_ > allout-end-of-current-heading () | 2258 | ;;;_ > allout-end-of-current-heading () |
| 2115 | (defun allout-end-of-current-heading () | 2259 | (defun allout-end-of-current-heading () |
| 2116 | (interactive) | 2260 | (interactive) |
| 2117 | (allout-beginning-of-current-entry) | 2261 | (allout-beginning-of-current-entry) |
| 2118 | (re-search-forward "[\n\r]" nil t) | 2262 | (search-forward "\n" nil t) |
| 2119 | (forward-char -1)) | 2263 | (forward-char -1)) |
| 2120 | (defalias 'allout-end-of-heading 'allout-end-of-current-heading) | 2264 | (defalias 'allout-end-of-heading 'allout-end-of-current-heading) |
| 2121 | ;;;_ > allout-get-body-text () | 2265 | ;;;_ > allout-get-body-text () |
| @@ -2123,13 +2267,13 @@ If already there, move cursor to bullet for hot-spot operation. | |||
| 2123 | "Return the unmangled body text of the topic immediately containing point." | 2267 | "Return the unmangled body text of the topic immediately containing point." |
| 2124 | (save-excursion | 2268 | (save-excursion |
| 2125 | (allout-end-of-prefix) | 2269 | (allout-end-of-prefix) |
| 2126 | (if (not (re-search-forward "[\n\r]" nil t)) | 2270 | (if (not (search-forward "\n" nil t)) |
| 2127 | nil | 2271 | nil |
| 2128 | (backward-char 1) | 2272 | (backward-char 1) |
| 2129 | (let ((pre-body (point))) | 2273 | (let ((pre-body (point))) |
| 2130 | (if (not pre-body) | 2274 | (if (not pre-body) |
| 2131 | nil | 2275 | nil |
| 2132 | (allout-end-of-entry) | 2276 | (allout-end-of-entry t) |
| 2133 | (if (not (= pre-body (point))) | 2277 | (if (not (= pre-body (point))) |
| 2134 | (buffer-substring-no-properties (1+ pre-body) (point)))) | 2278 | (buffer-substring-no-properties (1+ pre-body) (point)))) |
| 2135 | ) | 2279 | ) |
| @@ -2189,8 +2333,7 @@ DONT-COMPLAIN is non-nil." | |||
| 2189 | (allout-back-to-current-heading) | 2333 | (allout-back-to-current-heading) |
| 2190 | (let ((present-level (allout-recent-depth)) | 2334 | (let ((present-level (allout-recent-depth)) |
| 2191 | (last-good (point)) | 2335 | (last-good (point)) |
| 2192 | failed | 2336 | failed) |
| 2193 | return) | ||
| 2194 | ;; Loop for iterating arg: | 2337 | ;; Loop for iterating arg: |
| 2195 | (while (and (> (allout-recent-depth) 1) | 2338 | (while (and (> (allout-recent-depth) 1) |
| 2196 | (> arg 0) | 2339 | (> arg 0) |
| @@ -2260,11 +2403,9 @@ Presumes point is at the start of a topic prefix." | |||
| 2260 | (if (or (bobp) (eobp)) | 2403 | (if (or (bobp) (eobp)) |
| 2261 | nil | 2404 | nil |
| 2262 | (forward-char -1)) | 2405 | (forward-char -1)) |
| 2263 | (if (or (bobp) (not (memq (preceding-char) '(?\n ?\r)))) | 2406 | (if (or (bobp) (not (= ?\n (preceding-char)))) |
| 2264 | nil | 2407 | nil |
| 2265 | (forward-char -1) | 2408 | (forward-char -1)) |
| 2266 | (if (or (bobp) (not (memq (preceding-char) '(?\n ?\r)))) | ||
| 2267 | (forward-char -1))) | ||
| 2268 | (point)) | 2409 | (point)) |
| 2269 | ;;;_ > allout-beginning-of-level () | 2410 | ;;;_ > allout-beginning-of-level () |
| 2270 | (defun allout-beginning-of-level () | 2411 | (defun allout-beginning-of-level () |
| @@ -2282,19 +2423,19 @@ Presumes point is at the start of a topic prefix." | |||
| 2282 | (defun allout-next-visible-heading (arg) | 2423 | (defun allout-next-visible-heading (arg) |
| 2283 | "Move to the next ARG'th visible heading line, backward if arg is negative. | 2424 | "Move to the next ARG'th visible heading line, backward if arg is negative. |
| 2284 | 2425 | ||
| 2285 | Move as far as possible in indicated direction \(beginning or end of | 2426 | Move to buffer limit in indicated direction if headings are exhausted." |
| 2286 | buffer) if headings are exhausted." | ||
| 2287 | 2427 | ||
| 2288 | (interactive "p") | 2428 | (interactive "p") |
| 2289 | (let* ((backward (if (< arg 0) (setq arg (* -1 arg)))) | 2429 | (let* ((backward (if (< arg 0) (setq arg (* -1 arg)))) |
| 2290 | (step (if backward -1 1)) | 2430 | (step (if backward -1 1)) |
| 2291 | (start-point (point)) | ||
| 2292 | prev got) | 2431 | prev got) |
| 2293 | 2432 | ||
| 2294 | (while (> arg 0) ; limit condition | 2433 | (while (> arg 0) ; limit condition |
| 2295 | (while (and (not (if backward (bobp)(eobp))) ; boundary condition | 2434 | (while (and (not (if backward (bobp)(eobp))) ; boundary condition |
| 2296 | ;; Move, skipping over all those concealed lines: | 2435 | ;; Move, skipping over all those concealed lines: |
| 2297 | (< -1 (forward-line step)) | 2436 | (prog1 (condition-case nil (or (line-move step) t) |
| 2437 | (error nil)) | ||
| 2438 | (allout-beginning-of-current-line)) | ||
| 2298 | (not (setq got (looking-at allout-regexp))))) | 2439 | (not (setq got (looking-at allout-regexp))))) |
| 2299 | ;; Register this got, it may be the last: | 2440 | ;; Register this got, it may be the last: |
| 2300 | (if got (setq prev got)) | 2441 | (if got (setq prev got)) |
| @@ -2323,7 +2464,6 @@ Takes optional repeat-count, goes backward if count is negative. | |||
| 2323 | Returns resulting position, else nil if none found." | 2464 | Returns resulting position, else nil if none found." |
| 2324 | (interactive "p") | 2465 | (interactive "p") |
| 2325 | (let ((start-depth (allout-current-depth)) | 2466 | (let ((start-depth (allout-current-depth)) |
| 2326 | (start-point (point)) | ||
| 2327 | (start-arg arg) | 2467 | (start-arg arg) |
| 2328 | (backward (> 0 arg)) | 2468 | (backward (> 0 arg)) |
| 2329 | last-depth | 2469 | last-depth |
| @@ -2386,51 +2526,17 @@ are mapped to the command of the corresponding control-key on the | |||
| 2386 | - Implement (and clear) `allout-post-goto-bullet', for hot-spot | 2526 | - Implement (and clear) `allout-post-goto-bullet', for hot-spot |
| 2387 | outline commands. | 2527 | outline commands. |
| 2388 | 2528 | ||
| 2389 | - Decrypt topic currently being edited if it was encrypted for a save. | 2529 | - Decrypt topic currently being edited if it was encrypted for a save." |
| 2390 | |||
| 2391 | - Massage buffer-undo-list so successive, standard character self-inserts are | ||
| 2392 | aggregated. This kludge compensates for lack of undo bunching when | ||
| 2393 | before-change-functions is used." | ||
| 2394 | 2530 | ||
| 2395 | ; Apply any external change func: | 2531 | ; Apply any external change func: |
| 2396 | (if (not (allout-mode-p)) ; In allout-mode. | 2532 | (if (not (allout-mode-p)) ; In allout-mode. |
| 2397 | nil | 2533 | nil |
| 2398 | (if allout-isearch-dynamic-expose | ||
| 2399 | (allout-isearch-rectification)) | ||
| 2400 | ;; Undo bunching business: | ||
| 2401 | (if (and (listp buffer-undo-list) ; Undo history being kept. | ||
| 2402 | (equal this-command 'self-insert-command) | ||
| 2403 | (equal last-command 'self-insert-command)) | ||
| 2404 | (let* ((prev-stuff (cdr buffer-undo-list)) | ||
| 2405 | (before-prev-stuff (cdr (cdr prev-stuff))) | ||
| 2406 | cur-cell cur-from cur-to | ||
| 2407 | prev-cell prev-from prev-to) | ||
| 2408 | (if (and before-prev-stuff ; Goes back far enough to bother, | ||
| 2409 | (not (car prev-stuff)) ; and break before current, | ||
| 2410 | (not (car before-prev-stuff)) ; !and break before prev! | ||
| 2411 | (setq prev-cell (car (cdr prev-stuff))) ; contents now, | ||
| 2412 | (setq cur-cell (car buffer-undo-list)) ; contents prev. | ||
| 2413 | |||
| 2414 | ;; cur contents denote a single char insertion: | ||
| 2415 | (numberp (setq cur-from (car cur-cell))) | ||
| 2416 | (numberp (setq cur-to (cdr cur-cell))) | ||
| 2417 | (= 1 (- cur-to cur-from)) | ||
| 2418 | |||
| 2419 | ;; prev contents denote fewer than aggregate-limit | ||
| 2420 | ;; insertions: | ||
| 2421 | (numberp (setq prev-from (car prev-cell))) | ||
| 2422 | (numberp (setq prev-to (cdr prev-cell))) | ||
| 2423 | ; Below threshold: | ||
| 2424 | (> allout-undo-aggregation (- prev-to prev-from))) | ||
| 2425 | (setq buffer-undo-list | ||
| 2426 | (cons (cons prev-from cur-to) | ||
| 2427 | (cdr (cdr (cdr buffer-undo-list)))))))) | ||
| 2428 | 2534 | ||
| 2429 | (if (and (boundp 'allout-after-save-decrypt) | 2535 | (if (and (boundp 'allout-after-save-decrypt) |
| 2430 | allout-after-save-decrypt) | 2536 | allout-after-save-decrypt) |
| 2431 | (allout-after-saves-handler)) | 2537 | (allout-after-saves-handler)) |
| 2432 | 2538 | ||
| 2433 | ;; Implement -post-goto-bullet, if set: (must be after undo business) | 2539 | ;; Implement -post-goto-bullet, if set: |
| 2434 | (if (and allout-post-goto-bullet | 2540 | (if (and allout-post-goto-bullet |
| 2435 | (allout-current-bullet-pos)) | 2541 | (allout-current-bullet-pos)) |
| 2436 | (progn (goto-char (allout-current-bullet-pos)) | 2542 | (progn (goto-char (allout-current-bullet-pos)) |
| @@ -2456,10 +2562,6 @@ return to regular interpretation of self-insert characters." | |||
| 2456 | (if (not (allout-mode-p)) | 2562 | (if (not (allout-mode-p)) |
| 2457 | ;; Shouldn't be invoked if not in allout-mode, but just in case: | 2563 | ;; Shouldn't be invoked if not in allout-mode, but just in case: |
| 2458 | nil | 2564 | nil |
| 2459 | ;; Register isearch status: | ||
| 2460 | (if (and (boundp 'isearch-mode) isearch-mode) | ||
| 2461 | (setq allout-pre-was-isearching t) | ||
| 2462 | (setq allout-pre-was-isearching nil)) | ||
| 2463 | ;; Hot-spot navigation provisions: | 2565 | ;; Hot-spot navigation provisions: |
| 2464 | (if (and (eq this-command 'self-insert-command) | 2566 | (if (and (eq this-command 'self-insert-command) |
| 2465 | (eq (point)(allout-current-bullet-pos))) | 2567 | (eq (point)(allout-current-bullet-pos))) |
| @@ -2499,110 +2601,6 @@ See `allout-init' for setup instructions." | |||
| 2499 | (not (allout-mode-p)) | 2601 | (not (allout-mode-p)) |
| 2500 | allout-layout) | 2602 | allout-layout) |
| 2501 | (allout-mode t))) | 2603 | (allout-mode t))) |
| 2502 | ;;;_ > allout-isearch-rectification | ||
| 2503 | (defun allout-isearch-rectification () | ||
| 2504 | "Rectify outline exposure before, during, or after isearch. | ||
| 2505 | |||
| 2506 | Called as part of `allout-post-command-business'." | ||
| 2507 | |||
| 2508 | (let ((isearching (and (boundp 'isearch-mode) isearch-mode))) | ||
| 2509 | (cond ((and isearching (not allout-pre-was-isearching)) | ||
| 2510 | (allout-isearch-expose 'start)) | ||
| 2511 | ((and isearching allout-pre-was-isearching) | ||
| 2512 | (allout-isearch-expose 'continue)) | ||
| 2513 | ((and (not isearching) allout-pre-was-isearching) | ||
| 2514 | (allout-isearch-expose 'final)) | ||
| 2515 | ;; Not and wasn't isearching: | ||
| 2516 | (t (setq allout-isearch-prior-pos nil) | ||
| 2517 | (setq allout-isearch-did-quit nil))))) | ||
| 2518 | ;;;_ = allout-isearch-was-font-lock | ||
| 2519 | (defvar allout-isearch-was-font-lock | ||
| 2520 | (and (boundp 'font-lock-mode) font-lock-mode)) | ||
| 2521 | ;;;_ > allout-isearch-expose (mode) | ||
| 2522 | (defun allout-isearch-expose (mode) | ||
| 2523 | "MODE is either 'clear, 'start, 'continue, or 'final." | ||
| 2524 | ;; allout-isearch-prior-pos encodes exposure status of prior pos: | ||
| 2525 | ;; (pos was-vis header-pos end-pos) | ||
| 2526 | ;; pos - point of concern | ||
| 2527 | ;; was-vis - t, else 'topic if entire topic was exposed, 'entry otherwise | ||
| 2528 | ;; Do reclosure or prior pos, as necessary: | ||
| 2529 | (if (eq mode 'start) | ||
| 2530 | (setq allout-isearch-was-font-lock (and (boundp 'font-lock-mode) | ||
| 2531 | font-lock-mode) | ||
| 2532 | font-lock-mode nil) | ||
| 2533 | (if (eq mode 'final) | ||
| 2534 | (setq font-lock-mode allout-isearch-was-font-lock)) | ||
| 2535 | (if (and allout-isearch-prior-pos | ||
| 2536 | (listp allout-isearch-prior-pos)) | ||
| 2537 | ;; Conceal prior peek: | ||
| 2538 | (allout-flag-region (car (cdr allout-isearch-prior-pos)) | ||
| 2539 | (car (cdr (cdr allout-isearch-prior-pos))) | ||
| 2540 | ?\r))) | ||
| 2541 | (if (allout-visible-p) | ||
| 2542 | (setq allout-isearch-prior-pos nil) | ||
| 2543 | (if (not (eq mode 'final)) | ||
| 2544 | (setq allout-isearch-prior-pos (cons (point) (allout-show-entry))) | ||
| 2545 | (if allout-isearch-did-quit | ||
| 2546 | nil | ||
| 2547 | (setq allout-isearch-prior-pos nil) | ||
| 2548 | (allout-show-children)))) | ||
| 2549 | (setq allout-isearch-did-quit nil)) | ||
| 2550 | ;;;_ > allout-enwrap-isearch () | ||
| 2551 | (defun allout-enwrap-isearch () | ||
| 2552 | "Impose `allout-mode' isearch-abort wrapper for dynamic exposure in isearch. | ||
| 2553 | |||
| 2554 | The function checks to ensure that the rebinding is done only once." | ||
| 2555 | |||
| 2556 | (add-hook 'isearch-mode-end-hook 'allout-isearch-rectification) | ||
| 2557 | (if (fboundp 'allout-real-isearch-abort) | ||
| 2558 | ;; | ||
| 2559 | nil | ||
| 2560 | ; Ensure load of isearch-mode: | ||
| 2561 | (if (or (and (fboundp 'isearch-mode) | ||
| 2562 | (fboundp 'isearch-abort)) | ||
| 2563 | (condition-case error | ||
| 2564 | (load-library "isearch-mode") | ||
| 2565 | ('file-error (message | ||
| 2566 | "Skipping isearch-mode provisions - %s '%s'" | ||
| 2567 | (car (cdr error)) | ||
| 2568 | (car (cdr (cdr error)))) | ||
| 2569 | (sit-for 1) | ||
| 2570 | ;; Inhibit subsequent tries and return nil: | ||
| 2571 | (setq allout-isearch-dynamic-expose nil)))) | ||
| 2572 | ;; Isearch-mode loaded, encapsulate specific entry points for | ||
| 2573 | ;; outline dynamic-exposure business: | ||
| 2574 | (progn | ||
| 2575 | ;; stash crucial isearch-mode funcs under known, private | ||
| 2576 | ;; names, then register wrapper functions under the old | ||
| 2577 | ;; names, in their stead: | ||
| 2578 | (fset 'allout-real-isearch-abort (symbol-function 'isearch-abort)) | ||
| 2579 | (fset 'isearch-abort 'allout-isearch-abort))))) | ||
| 2580 | ;;;_ > allout-isearch-abort () | ||
| 2581 | (defun allout-isearch-abort () | ||
| 2582 | "Wrapper for allout-real-isearch-abort \(which see), to register | ||
| 2583 | actual quits." | ||
| 2584 | (interactive) | ||
| 2585 | (setq allout-isearch-did-quit nil) | ||
| 2586 | (condition-case what | ||
| 2587 | (allout-real-isearch-abort) | ||
| 2588 | ('quit (setq allout-isearch-did-quit t) | ||
| 2589 | (signal 'quit nil)))) | ||
| 2590 | |||
| 2591 | ;;; Prevent unnecessary font-lock while isearching! | ||
| 2592 | (defvar isearch-was-font-locking nil) | ||
| 2593 | (defun isearch-inhibit-font-lock () | ||
| 2594 | "Inhibit `font-lock' while isearching - for use on `isearch-mode-hook'." | ||
| 2595 | (if (and (allout-mode-p) (boundp 'font-lock-mode) font-lock-mode) | ||
| 2596 | (setq isearch-was-font-locking t | ||
| 2597 | font-lock-mode nil))) | ||
| 2598 | (add-hook 'isearch-mode-hook 'isearch-inhibit-font-lock) | ||
| 2599 | (defun isearch-reenable-font-lock () | ||
| 2600 | "Reenable font-lock after isearching - for use on `isearch-mode-end-hook'." | ||
| 2601 | (if (and (boundp 'font-lock-mode) font-lock-mode) | ||
| 2602 | (if (and (allout-mode-p) isearch-was-font-locking) | ||
| 2603 | (setq isearch-was-font-locking nil | ||
| 2604 | font-lock-mode t)))) | ||
| 2605 | (add-hook 'isearch-mode-end-hook 'isearch-reenable-font-lock) | ||
| 2606 | 2604 | ||
| 2607 | ;;;_ - Topic Format Assessment | 2605 | ;;;_ - Topic Format Assessment |
| 2608 | ;;;_ > allout-solicit-alternate-bullet (depth &optional current-bullet) | 2606 | ;;;_ > allout-solicit-alternate-bullet (depth &optional current-bullet) |
| @@ -2807,15 +2805,20 @@ index for each successive sibling)." | |||
| 2807 | ((allout-sibling-index)))))) | 2805 | ((allout-sibling-index)))))) |
| 2808 | ) | 2806 | ) |
| 2809 | ) | 2807 | ) |
| 2810 | ;;;_ > allout-open-topic (relative-depth &optional before use_recent_bullet) | 2808 | ;;;_ > allout-open-topic (relative-depth &optional before offer-recent-bullet) |
| 2811 | (defun allout-open-topic (relative-depth &optional before use_recent_bullet) | 2809 | (defun allout-open-topic (relative-depth &optional before offer-recent-bullet) |
| 2812 | "Open a new topic at depth DEPTH. | 2810 | "Open a new topic at depth DEPTH. |
| 2813 | 2811 | ||
| 2814 | New topic is situated after current one, unless optional flag BEFORE | 2812 | New topic is situated after current one, unless optional flag BEFORE |
| 2815 | is non-nil, or unless current line is complete empty (not even | 2813 | is non-nil, or unless current line is completely empty - lacking even |
| 2816 | whitespace), in which case open is done on current line. | 2814 | whitespace - in which case open is done on the current line. |
| 2817 | 2815 | ||
| 2818 | If USE_RECENT_BULLET is true, offer to use the bullet of the prior sibling. | 2816 | When adding an offspring, it will be added immediately after the parent if |
| 2817 | the other offspring are exposed, or after the last child if the offspring | ||
| 2818 | are hidden. \(The intervening offspring will be exposed in the latter | ||
| 2819 | case.) | ||
| 2820 | |||
| 2821 | If OFFER-RECENT-BULLET is true, offer to use the bullet of the prior sibling. | ||
| 2819 | 2822 | ||
| 2820 | Nuances: | 2823 | Nuances: |
| 2821 | 2824 | ||
| @@ -2839,12 +2842,12 @@ Nuances: | |||
| 2839 | having to go to its preceding sibling, and then open forward | 2842 | having to go to its preceding sibling, and then open forward |
| 2840 | from there." | 2843 | from there." |
| 2841 | 2844 | ||
| 2845 | (allout-beginning-of-current-line) | ||
| 2842 | (let* ((depth (+ (allout-current-depth) relative-depth)) | 2846 | (let* ((depth (+ (allout-current-depth) relative-depth)) |
| 2843 | (opening-on-blank (if (looking-at "^\$") | 2847 | (opening-on-blank (if (looking-at "^\$") |
| 2844 | (not (setq before nil)))) | 2848 | (not (setq before nil)))) |
| 2845 | ;; bunch o vars set while computing ref-topic | 2849 | ;; bunch o vars set while computing ref-topic |
| 2846 | opening-numbered | 2850 | opening-numbered |
| 2847 | opening-encrypted | ||
| 2848 | ref-depth | 2851 | ref-depth |
| 2849 | ref-bullet | 2852 | ref-bullet |
| 2850 | (ref-topic (save-excursion | 2853 | (ref-topic (save-excursion |
| @@ -2864,13 +2867,6 @@ Nuances: | |||
| 2864 | (allout-descend-to-depth depth)) | 2867 | (allout-descend-to-depth depth)) |
| 2865 | (if (allout-numbered-type-prefix) | 2868 | (if (allout-numbered-type-prefix) |
| 2866 | allout-numbered-bullet)))) | 2869 | allout-numbered-bullet)))) |
| 2867 | (setq opening-encrypted | ||
| 2868 | (save-excursion | ||
| 2869 | (and allout-topic-encryption-bullet | ||
| 2870 | (or (<= relative-depth 0) | ||
| 2871 | (allout-descend-to-depth depth)) | ||
| 2872 | (if (allout-numbered-type-prefix) | ||
| 2873 | allout-numbered-bullet)))) | ||
| 2874 | (point))) | 2870 | (point))) |
| 2875 | dbl-space | 2871 | dbl-space |
| 2876 | doing-beginning) | 2872 | doing-beginning) |
| @@ -2891,122 +2887,98 @@ Nuances: | |||
| 2891 | (save-excursion | 2887 | (save-excursion |
| 2892 | ;; succeeded by a blank line? | 2888 | ;; succeeded by a blank line? |
| 2893 | (allout-end-of-current-subtree) | 2889 | (allout-end-of-current-subtree) |
| 2894 | (bolp))) | 2890 | (looking-at "\n\n"))) |
| 2895 | (and (= ref-depth 1) | 2891 | (and (= ref-depth 1) |
| 2896 | (or before | 2892 | (or before |
| 2897 | (= depth 1) | 2893 | (= depth 1) |
| 2898 | (save-excursion | 2894 | (save-excursion |
| 2899 | ;; Don't already have following | 2895 | ;; Don't already have following |
| 2900 | ;; vertical padding: | 2896 | ;; vertical padding: |
| 2901 | (not (allout-pre-next-preface))))))) | 2897 | (not (allout-pre-next-prefix))))))) |
| 2902 | 2898 | ||
| 2903 | ; Position to prior heading, | 2899 | ;; Position to prior heading, if inserting backwards, and not |
| 2904 | ; if inserting backwards, and | 2900 | ;; going outwards: |
| 2905 | ; not going outwards: | ||
| 2906 | (if (and before (>= relative-depth 0)) | 2901 | (if (and before (>= relative-depth 0)) |
| 2907 | (progn (allout-back-to-current-heading) | 2902 | (progn (allout-back-to-current-heading) |
| 2908 | (setq doing-beginning (bobp)) | 2903 | (setq doing-beginning (bobp)) |
| 2909 | (if (not (bobp)) | 2904 | (if (not (bobp)) |
| 2910 | (allout-previous-heading))) | 2905 | (allout-previous-heading))) |
| 2911 | (if (and before (bobp)) | 2906 | (if (and before (bobp)) |
| 2912 | (allout-unprotected (allout-open-line-not-read-only)))) | 2907 | (open-line 1))) |
| 2913 | 2908 | ||
| 2914 | (if (<= relative-depth 0) | 2909 | (if (<= relative-depth 0) |
| 2915 | ;; Not going inwards, don't snug up: | 2910 | ;; Not going inwards, don't snug up: |
| 2916 | (if doing-beginning | 2911 | (if doing-beginning |
| 2917 | (allout-unprotected | 2912 | (if (not dbl-space) |
| 2918 | (if (not dbl-space) | 2913 | (open-line 1) |
| 2919 | (allout-open-line-not-read-only) | 2914 | (open-line 2)) |
| 2920 | (allout-open-line-not-read-only) | ||
| 2921 | (allout-open-line-not-read-only))) | ||
| 2922 | (if before | 2915 | (if before |
| 2923 | (progn (end-of-line) | 2916 | (progn (end-of-line) |
| 2924 | (allout-pre-next-preface) | 2917 | (allout-pre-next-prefix) |
| 2925 | (while (= ?\r (following-char)) | 2918 | (while (and (= ?\n (following-char)) |
| 2919 | (save-excursion | ||
| 2920 | (forward-char 1) | ||
| 2921 | (allout-hidden-p))) | ||
| 2926 | (forward-char 1)) | 2922 | (forward-char 1)) |
| 2927 | (if (not (looking-at "^$")) | 2923 | (if (not (looking-at "^$")) |
| 2928 | (allout-unprotected | 2924 | (open-line 1))) |
| 2929 | (allout-open-line-not-read-only)))) | 2925 | (allout-end-of-current-subtree) |
| 2930 | (allout-end-of-current-subtree))) | 2926 | (if (looking-at "\n\n") (forward-char 1)))) |
| 2931 | ;; Going inwards - double-space if first offspring is, | 2927 | ;; Going inwards - double-space if first offspring is |
| 2932 | ;; otherwise snug up. | 2928 | ;; double-spaced, otherwise snug up. |
| 2933 | (end-of-line) ; So we skip any concealed progeny. | 2929 | (allout-end-of-entry) |
| 2934 | (allout-pre-next-preface) | 2930 | (line-move 1) |
| 2931 | (allout-beginning-of-current-line) | ||
| 2932 | (backward-char 1) | ||
| 2935 | (if (bolp) | 2933 | (if (bolp) |
| 2936 | ;; Blank lines between current header body and next | 2934 | ;; Blank lines between current header body and next |
| 2937 | ;; header - get to last substantive (non-white-space) | 2935 | ;; header - get to last substantive (non-white-space) |
| 2938 | ;; line in body: | 2936 | ;; line in body: |
| 2939 | (re-search-backward "[^ \t\n]" nil t)) | 2937 | (progn (setq dbl-space t) |
| 2938 | (re-search-backward "[^ \t\n]" nil t))) | ||
| 2939 | (if (looking-at "\n\n") | ||
| 2940 | (setq dbl-space t)) | ||
| 2940 | (if (save-excursion | 2941 | (if (save-excursion |
| 2941 | (allout-next-heading) | 2942 | (allout-next-heading) |
| 2942 | (if (> (allout-recent-depth) ref-depth) | 2943 | (when (> (allout-recent-depth) ref-depth) |
| 2943 | ;; This is an offspring. | 2944 | ;; This is an offspring. |
| 2944 | (progn (forward-line -1) | 2945 | (forward-line -1) |
| 2945 | (looking-at "^\\s-*$")))) | 2946 | (looking-at "^\\s-*$"))) |
| 2946 | (progn (forward-line 1) | 2947 | (progn (forward-line 1) |
| 2947 | (allout-unprotected | 2948 | (open-line 1) |
| 2948 | (allout-open-line-not-read-only)) | ||
| 2949 | (forward-line 1))) | 2949 | (forward-line 1))) |
| 2950 | (end-of-line)) | 2950 | (allout-end-of-current-line)) |
| 2951 | |||
| 2951 | ;;(if doing-beginning (goto-char doing-beginning)) | 2952 | ;;(if doing-beginning (goto-char doing-beginning)) |
| 2952 | (if (not (bobp)) | 2953 | (if (not (bobp)) |
| 2953 | ;; We insert a newline char rather than using open-line to | 2954 | ;; We insert a newline char rather than using open-line to |
| 2954 | ;; avoid rear-stickiness inheritence of read-only property. | 2955 | ;; avoid rear-stickiness inheritence of read-only property. |
| 2955 | (progn (if (and (not (> depth ref-depth)) | 2956 | (progn (if (and (not (> depth ref-depth)) |
| 2956 | (not before)) | 2957 | (not before)) |
| 2957 | (allout-unprotected | 2958 | (open-line 1) |
| 2958 | (allout-open-line-not-read-only)) | 2959 | (if (and (not dbl-space) (> depth ref-depth)) |
| 2959 | (if (> depth ref-depth) | 2960 | (newline 1) |
| 2960 | (allout-unprotected | ||
| 2961 | (allout-open-line-not-read-only)) | ||
| 2962 | (if dbl-space | 2961 | (if dbl-space |
| 2963 | (allout-unprotected | 2962 | (open-line 1) |
| 2964 | (allout-open-line-not-read-only)) | ||
| 2965 | (if (not before) | 2963 | (if (not before) |
| 2966 | (allout-unprotected (newline 1)))))) | 2964 | (newline 1))))) |
| 2967 | (if dbl-space | 2965 | (if (and dbl-space (not (> relative-depth 0))) |
| 2968 | (allout-unprotected (newline 1))) | 2966 | (newline 1)) |
| 2969 | (if (and (not (eobp)) | 2967 | (if (and (not (eobp)) |
| 2970 | (not (bolp))) | 2968 | (not (bolp))) |
| 2971 | (forward-char 1)))) | 2969 | (forward-char 1)))) |
| 2972 | )) | 2970 | )) |
| 2973 | (insert (concat (allout-make-topic-prefix opening-numbered | 2971 | (insert (concat (allout-make-topic-prefix opening-numbered t depth) |
| 2974 | t | 2972 | " ")) |
| 2975 | depth) | 2973 | |
| 2976 | " ")) | 2974 | (allout-rebullet-heading (and offer-recent-bullet ref-bullet) |
| 2977 | 2975 | depth nil nil t) | |
| 2978 | ;;(if doing-beginning (save-excursion (newline (if dbl-space 2 1)))) | 2976 | (if (> relative-depth 0) |
| 2979 | 2977 | (save-excursion (goto-char ref-topic) | |
| 2980 | 2978 | (allout-show-children))) | |
| 2981 | (allout-rebullet-heading (and use_recent_bullet ;;; solicit | ||
| 2982 | ref-bullet) | ||
| 2983 | depth ;;; depth | ||
| 2984 | nil ;;; number-control | ||
| 2985 | nil ;;; index | ||
| 2986 | t) | ||
| 2987 | (end-of-line) | 2979 | (end-of-line) |
| 2988 | ) | 2980 | ) |
| 2989 | ) | 2981 | ) |
| 2990 | ;;;_ . open-topic contingencies | ||
| 2991 | ;;;_ ; base topic - one from which open was issued | ||
| 2992 | ;;;_ , beginning char | ||
| 2993 | ;;;_ , amount of space before will be used, unless opening in place | ||
| 2994 | ;;;_ , end char will be used, unless opening before (and it still may) | ||
| 2995 | ;;;_ ; absolute depth of new topic | ||
| 2996 | ;;;_ ! insert in place - overrides most stuff | ||
| 2997 | ;;;_ ; relative depth of new re base | ||
| 2998 | ;;;_ ; before or after base topic | ||
| 2999 | ;;;_ ; spacing around topic, if any, prior to new topic and at same depth | ||
| 3000 | ;;;_ ; buffer boundaries - special provisions for beginning and end ob | ||
| 3001 | ;;;_ ; level 1 topics have special provisions also - double space. | ||
| 3002 | ;;;_ ; location of new topic | ||
| 3003 | ;;;_ > allout-open-line-not-read-only () | ||
| 3004 | (defun allout-open-line-not-read-only () | ||
| 3005 | "Open line and remove inherited read-only text prop from new char, if any." | ||
| 3006 | (open-line 1) | ||
| 3007 | (if (plist-get (text-properties-at (point)) 'read-only) | ||
| 3008 | (allout-unprotected | ||
| 3009 | (remove-text-properties (point) (+ 1 (point)) '(read-only nil))))) | ||
| 3010 | ;;;_ > allout-open-subtopic (arg) | 2982 | ;;;_ > allout-open-subtopic (arg) |
| 3011 | (defun allout-open-subtopic (arg) | 2983 | (defun allout-open-subtopic (arg) |
| 3012 | "Open new topic header at deeper level than the current one. | 2984 | "Open new topic header at deeper level than the current one. |
| @@ -3055,9 +3027,12 @@ Maintains outline hanging topic indentation if | |||
| 3055 | ;; length of topic prefix: | 3027 | ;; length of topic prefix: |
| 3056 | (make-string (progn (allout-end-of-prefix) | 3028 | (make-string (progn (allout-end-of-prefix) |
| 3057 | (current-column)) | 3029 | (current-column)) |
| 3058 | ?\ )))))) | 3030 | ?\ ))))) |
| 3031 | (use-auto-fill-function (or allout-outside-normal-auto-fill-function | ||
| 3032 | auto-fill-function | ||
| 3033 | 'do-auto-fill))) | ||
| 3059 | (if (or allout-former-auto-filler allout-use-hanging-indents) | 3034 | (if (or allout-former-auto-filler allout-use-hanging-indents) |
| 3060 | (do-auto-fill)))) | 3035 | (funcall use-auto-fill-function)))) |
| 3061 | ;;;_ > allout-reindent-body (old-depth new-depth &optional number) | 3036 | ;;;_ > allout-reindent-body (old-depth new-depth &optional number) |
| 3062 | (defun allout-reindent-body (old-depth new-depth &optional number) | 3037 | (defun allout-reindent-body (old-depth new-depth &optional number) |
| 3063 | "Reindent body lines which were indented at OLD-DEPTH to NEW-DEPTH. | 3038 | "Reindent body lines which were indented at OLD-DEPTH to NEW-DEPTH. |
| @@ -3071,7 +3046,6 @@ Note that refill of indented paragraphs is not done." | |||
| 3071 | (allout-end-of-prefix) | 3046 | (allout-end-of-prefix) |
| 3072 | (let* ((new-margin (current-column)) | 3047 | (let* ((new-margin (current-column)) |
| 3073 | excess old-indent-begin old-indent-end | 3048 | excess old-indent-begin old-indent-end |
| 3074 | curr-ind | ||
| 3075 | ;; We want the column where the header-prefix text started | 3049 | ;; We want the column where the header-prefix text started |
| 3076 | ;; *before* the prefix was changed, so we infer it relative | 3050 | ;; *before* the prefix was changed, so we infer it relative |
| 3077 | ;; to the new margin and the shift in depth: | 3051 | ;; to the new margin and the shift in depth: |
| @@ -3081,7 +3055,7 @@ Note that refill of indented paragraphs is not done." | |||
| 3081 | (allout-unprotected | 3055 | (allout-unprotected |
| 3082 | (save-match-data | 3056 | (save-match-data |
| 3083 | (while | 3057 | (while |
| 3084 | (and (re-search-forward "[\n\r]\\(\\s-*\\)" | 3058 | (and (re-search-forward "\n\\(\\s-*\\)" |
| 3085 | nil | 3059 | nil |
| 3086 | t) | 3060 | t) |
| 3087 | ;; Register the indent data, before we reset the | 3061 | ;; Register the indent data, before we reset the |
| @@ -3231,8 +3205,7 @@ Descends into invisible as well as visible topics, however. | |||
| 3231 | 3205 | ||
| 3232 | With repeat count, shift topic depth by that amount." | 3206 | With repeat count, shift topic depth by that amount." |
| 3233 | (interactive "P") | 3207 | (interactive "P") |
| 3234 | (let ((start-col (current-column)) | 3208 | (let ((start-col (current-column))) |
| 3235 | (was-eol (eolp))) | ||
| 3236 | (save-excursion | 3209 | (save-excursion |
| 3237 | ;; Normalize arg: | 3210 | ;; Normalize arg: |
| 3238 | (cond ((null arg) (setq arg 0)) | 3211 | (cond ((null arg) (setq arg 0)) |
| @@ -3414,8 +3387,8 @@ depth, however." | |||
| 3414 | (if (and (> predecessor-depth 0) | 3387 | (if (and (> predecessor-depth 0) |
| 3415 | (> (+ current-depth arg) | 3388 | (> (+ current-depth arg) |
| 3416 | (1+ predecessor-depth))) | 3389 | (1+ predecessor-depth))) |
| 3417 | (error (concat "May not shift deeper than offspring depth" | 3390 | (error (concat "Disallowed shift deeper than" |
| 3418 | " of previous topic"))))))) | 3391 | " containing topic's children."))))))) |
| 3419 | (allout-rebullet-topic arg)) | 3392 | (allout-rebullet-topic arg)) |
| 3420 | ;;;_ > allout-shift-out (arg) | 3393 | ;;;_ > allout-shift-out (arg) |
| 3421 | (defun allout-shift-out (arg) | 3394 | (defun allout-shift-out (arg) |
| @@ -3436,84 +3409,72 @@ depth, however." | |||
| 3436 | 3409 | ||
| 3437 | (interactive "*P") | 3410 | (interactive "*P") |
| 3438 | 3411 | ||
| 3439 | (let ((start-point (point)) | 3412 | (if (or (not (allout-mode-p)) |
| 3440 | (leading-kill-ring-entry (car kill-ring)) | 3413 | (not (bolp)) |
| 3441 | binding) | 3414 | (not (looking-at allout-regexp))) |
| 3442 | 3415 | ;; Above conditions do not obtain - just do a regular kill: | |
| 3443 | (condition-case err | 3416 | (kill-line arg) |
| 3444 | 3417 | ;; Ah, have to watch out for adjustments: | |
| 3445 | (if (not (and (allout-mode-p) ; active outline mode, | 3418 | (let* ((beg (point)) |
| 3446 | allout-numbered-bullet ; numbers may need adjustment, | 3419 | (beg-hidden (allout-hidden-p)) |
| 3447 | (bolp) ; may be clipping topic head, | 3420 | (end-hidden (save-excursion (allout-end-of-current-line) |
| 3448 | (looking-at allout-regexp))) ; are clipping topic head. | 3421 | (allout-hidden-p))) |
| 3449 | ;; Above conditions do not obtain - just do a regular kill: | 3422 | (depth (allout-depth)) |
| 3450 | (kill-line arg) | 3423 | (collapsed (allout-current-topic-collapsed-p))) |
| 3451 | ;; Ah, have to watch out for adjustments: | 3424 | |
| 3452 | (let* ((depth (allout-depth)) | 3425 | (if collapsed |
| 3453 | (start-point (point)) | 3426 | (put-text-property beg (1+ beg) 'allout-was-collapsed t) |
| 3454 | binding) | 3427 | (remove-text-properties beg (1+ beg) '(allout-was-collapsed t))) |
| 3455 | ; Do the kill, presenting option | 3428 | |
| 3456 | ; for read-only text: | 3429 | (if (and (not beg-hidden) (not end-hidden)) |
| 3457 | (kill-line arg) | 3430 | (allout-unprotected (kill-line arg)) |
| 3431 | (kill-line arg)) | ||
| 3458 | ; Provide some feedback: | 3432 | ; Provide some feedback: |
| 3459 | (sit-for 0) | 3433 | (sit-for 0) |
| 3460 | (save-excursion | 3434 | (if allout-numbered-bullet |
| 3461 | ; Start with the topic | 3435 | (save-excursion ; Renumber subsequent topics if needed: |
| 3462 | ; following killed line: | ||
| 3463 | (if (not (looking-at allout-regexp)) | 3436 | (if (not (looking-at allout-regexp)) |
| 3464 | (allout-next-heading)) | 3437 | (allout-next-heading)) |
| 3465 | (allout-renumber-to-depth depth)))) | 3438 | (allout-renumber-to-depth depth)))))) |
| 3466 | ;; condition case handler: | ||
| 3467 | (text-read-only | ||
| 3468 | (goto-char start-point) | ||
| 3469 | (setq binding (where-is-internal 'allout-kill-topic nil t)) | ||
| 3470 | (cond ((not binding) (setq binding "")) | ||
| 3471 | ((arrayp binding) | ||
| 3472 | (setq binding (mapconcat 'key-description (list binding) ", "))) | ||
| 3473 | (t (setq binding (format "%s" binding)))) | ||
| 3474 | ;; ensure prior kill-ring leader is properly restored: | ||
| 3475 | (if (eq leading-kill-ring-entry (cadr kill-ring)) | ||
| 3476 | ;; Aborted kill got pushed on front - ditch it: | ||
| 3477 | (let ((got (car kill-ring))) | ||
| 3478 | (setq kill-ring (cdr kill-ring)) | ||
| 3479 | got) | ||
| 3480 | ;; Aborted kill got appended to prior - resurrect prior: | ||
| 3481 | (setcar kill-ring leading-kill-ring-entry)) | ||
| 3482 | ;; make last-command skip this failed command, so kill-appending | ||
| 3483 | ;; conditions track: | ||
| 3484 | (setq this-command last-command) | ||
| 3485 | (error (concat "read-only text hit - use %s allout-kill-topic to" | ||
| 3486 | " discard collapsed stuff") | ||
| 3487 | binding))) | ||
| 3488 | ) | ||
| 3489 | ) | ||
| 3490 | ;;;_ > allout-kill-topic () | 3439 | ;;;_ > allout-kill-topic () |
| 3491 | (defun allout-kill-topic () | 3440 | (defun allout-kill-topic () |
| 3492 | "Kill topic together with subtopics. | 3441 | "Kill topic together with subtopics. |
| 3493 | 3442 | ||
| 3494 | Leaves primary topic's trailing vertical whitespace, if any." | 3443 | Trailing whitespace is killed with a topic if that whitespace: |
| 3444 | |||
| 3445 | - would separate the topic from a subsequent sibling | ||
| 3446 | - would separate the topic from the end of buffer | ||
| 3447 | - would not be added to whitespace already separating the topic from the | ||
| 3448 | previous one. | ||
| 3449 | |||
| 3450 | Completely collapsed topics are marked as such, for re-collapse | ||
| 3451 | when yank with allout-yank into an outline as a heading." | ||
| 3495 | 3452 | ||
| 3496 | ;; Some finagling is done to make complex topic kills appear faster | 3453 | ;; Some finagling is done to make complex topic kills appear faster |
| 3497 | ;; than they actually are. A redisplay is performed immediately | 3454 | ;; than they actually are. A redisplay is performed immediately |
| 3498 | ;; after the region is disposed of, though the renumbering process | 3455 | ;; after the region is deleted, though the renumbering process |
| 3499 | ;; has yet to be performed. This means that there may appear to be | 3456 | ;; has yet to be performed. This means that there may appear to be |
| 3500 | ;; a lag *after* the kill has been performed. | 3457 | ;; a lag *after* a kill has been performed. |
| 3501 | 3458 | ||
| 3502 | (interactive) | 3459 | (interactive) |
| 3503 | (let* ((beg (prog1 (allout-back-to-current-heading)(beginning-of-line))) | 3460 | (let* ((collapsed (allout-current-topic-collapsed-p)) |
| 3461 | (beg (prog1 (allout-back-to-current-heading) (beginning-of-line))) | ||
| 3504 | (depth (allout-recent-depth))) | 3462 | (depth (allout-recent-depth))) |
| 3505 | (allout-end-of-current-subtree) | 3463 | (allout-end-of-current-subtree) |
| 3464 | (if (and (/= (current-column) 0) (not (eobp))) | ||
| 3465 | (forward-char 1)) | ||
| 3506 | (if (not (eobp)) | 3466 | (if (not (eobp)) |
| 3507 | (if (or (not (looking-at "^$")) | 3467 | (if (and (looking-at "\n") |
| 3508 | ;; A blank line - cut it with this topic *unless* this | 3468 | (or (save-excursion |
| 3509 | ;; is the last topic at this level, in which case | 3469 | (or (not (allout-next-heading)) |
| 3510 | ;; we'll leave the blank line as part of the | 3470 | (= depth (allout-recent-depth)))) |
| 3511 | ;; containing topic: | 3471 | (and (> (- beg (point-min)) 3) |
| 3512 | (save-excursion | 3472 | (string= (buffer-substring (- beg 2) beg) "\n\n")))) |
| 3513 | (and (allout-next-heading) | ||
| 3514 | (>= (allout-recent-depth) depth)))) | ||
| 3515 | (forward-char 1))) | 3473 | (forward-char 1))) |
| 3516 | 3474 | ||
| 3475 | (if collapsed | ||
| 3476 | (put-text-property beg (1+ beg) 'allout-was-collapsed t) | ||
| 3477 | (remove-text-properties beg (1+ beg) '(allout-was-collapsed t))) | ||
| 3517 | (allout-unprotected (kill-region beg (point))) | 3478 | (allout-unprotected (kill-region beg (point))) |
| 3518 | (sit-for 0) | 3479 | (sit-for 0) |
| 3519 | (save-excursion | 3480 | (save-excursion |
| @@ -3521,7 +3482,7 @@ Leaves primary topic's trailing vertical whitespace, if any." | |||
| 3521 | ;;;_ > allout-yank-processing () | 3482 | ;;;_ > allout-yank-processing () |
| 3522 | (defun allout-yank-processing (&optional arg) | 3483 | (defun allout-yank-processing (&optional arg) |
| 3523 | 3484 | ||
| 3524 | "Incidental outline-specific business to be done just after text yanks. | 3485 | "Incidental allout-specific business to be done just after text yanks. |
| 3525 | 3486 | ||
| 3526 | Does depth adjustment of yanked topics, when: | 3487 | Does depth adjustment of yanked topics, when: |
| 3527 | 3488 | ||
| @@ -3542,10 +3503,12 @@ however, are left exactly like normal, non-allout-specific yanks." | |||
| 3542 | (interactive "*P") | 3503 | (interactive "*P") |
| 3543 | ; Get to beginning, leaving | 3504 | ; Get to beginning, leaving |
| 3544 | ; region around subject: | 3505 | ; region around subject: |
| 3545 | (if (< (my-mark-marker t) (point)) | 3506 | (if (< (allout-mark-marker t) (point)) |
| 3546 | (exchange-point-and-mark)) | 3507 | (exchange-point-and-mark)) |
| 3547 | (let* ((subj-beg (point)) | 3508 | (let* ((subj-beg (point)) |
| 3548 | (subj-end (my-mark-marker t)) | 3509 | (into-bol (bolp)) |
| 3510 | (subj-end (allout-mark-marker t)) | ||
| 3511 | (was-collapsed (get-text-property subj-beg 'allout-was-collapsed)) | ||
| 3549 | ;; 'resituate' if yanking an entire topic into topic header: | 3512 | ;; 'resituate' if yanking an entire topic into topic header: |
| 3550 | (resituate (and (allout-e-o-prefix-p) | 3513 | (resituate (and (allout-e-o-prefix-p) |
| 3551 | (looking-at (concat "\\(" allout-regexp "\\)")) | 3514 | (looking-at (concat "\\(" allout-regexp "\\)")) |
| @@ -3554,7 +3517,7 @@ however, are left exactly like normal, non-allout-specific yanks." | |||
| 3554 | ;; `rectify-numbering' if resituating (where several topics may | 3517 | ;; `rectify-numbering' if resituating (where several topics may |
| 3555 | ;; be resituating) or yanking a topic into a topic slot (bol): | 3518 | ;; be resituating) or yanking a topic into a topic slot (bol): |
| 3556 | (rectify-numbering (or resituate | 3519 | (rectify-numbering (or resituate |
| 3557 | (and (bolp) (looking-at allout-regexp))))) | 3520 | (and into-bol (looking-at allout-regexp))))) |
| 3558 | (if resituate | 3521 | (if resituate |
| 3559 | ; The yanked stuff is a topic: | 3522 | ; The yanked stuff is a topic: |
| 3560 | (let* ((prefix-len (- (match-end 1) subj-beg)) | 3523 | (let* ((prefix-len (- (match-end 1) subj-beg)) |
| @@ -3575,7 +3538,6 @@ however, are left exactly like normal, non-allout-specific yanks." | |||
| 3575 | (allout-prefix-data (match-beginning 0) | 3538 | (allout-prefix-data (match-beginning 0) |
| 3576 | (match-end 0))) | 3539 | (match-end 0))) |
| 3577 | (allout-recent-depth)))) | 3540 | (allout-recent-depth)))) |
| 3578 | done | ||
| 3579 | (more t)) | 3541 | (more t)) |
| 3580 | (setq rectify-numbering allout-numbered-bullet) | 3542 | (setq rectify-numbering allout-numbered-bullet) |
| 3581 | (if adjust-to-depth | 3543 | (if adjust-to-depth |
| @@ -3616,7 +3578,7 @@ however, are left exactly like normal, non-allout-specific yanks." | |||
| 3616 | (progn | 3578 | (progn |
| 3617 | (beginning-of-line) | 3579 | (beginning-of-line) |
| 3618 | (delete-region (point) subj-beg) | 3580 | (delete-region (point) subj-beg) |
| 3619 | (set-marker (my-mark-marker t) subj-end) | 3581 | (set-marker (allout-mark-marker t) subj-end) |
| 3620 | (goto-char subj-beg) | 3582 | (goto-char subj-beg) |
| 3621 | (allout-end-of-prefix)) | 3583 | (allout-end-of-prefix)) |
| 3622 | ; Delete base subj prefix, | 3584 | ; Delete base subj prefix, |
| @@ -3643,6 +3605,9 @@ however, are left exactly like normal, non-allout-specific yanks." | |||
| 3643 | nil ;;; index | 3605 | nil ;;; index |
| 3644 | t)) | 3606 | t)) |
| 3645 | (message "")))) | 3607 | (message "")))) |
| 3608 | (when (and (or into-bol resituate) was-collapsed) | ||
| 3609 | (remove-text-properties subj-beg (1+ subj-beg) '(allout-was-collapsed)) | ||
| 3610 | (allout-hide-current-subtree)) | ||
| 3646 | (if (not resituate) | 3611 | (if (not resituate) |
| 3647 | (exchange-point-and-mark)))) | 3612 | (exchange-point-and-mark)))) |
| 3648 | ;;;_ > allout-yank (&optional arg) | 3613 | ;;;_ > allout-yank (&optional arg) |
| @@ -3678,7 +3643,8 @@ works with normal `yank' in non-outline buffers." | |||
| 3678 | (setq this-command 'yank) | 3643 | (setq this-command 'yank) |
| 3679 | (yank arg) | 3644 | (yank arg) |
| 3680 | (if (allout-mode-p) | 3645 | (if (allout-mode-p) |
| 3681 | (allout-yank-processing))) | 3646 | (allout-yank-processing)) |
| 3647 | ) | ||
| 3682 | ;;;_ > allout-yank-pop (&optional arg) | 3648 | ;;;_ > allout-yank-pop (&optional arg) |
| 3683 | (defun allout-yank-pop (&optional arg) | 3649 | (defun allout-yank-pop (&optional arg) |
| 3684 | "Yank-pop like `allout-yank' when popping to bare outline prefixes. | 3650 | "Yank-pop like `allout-yank' when popping to bare outline prefixes. |
| @@ -3736,93 +3702,51 @@ by pops to non-distinctive yanks. Bug..." | |||
| 3736 | ;;;_ - Fundamental | 3702 | ;;;_ - Fundamental |
| 3737 | ;;;_ > allout-flag-region (from to flag) | 3703 | ;;;_ > allout-flag-region (from to flag) |
| 3738 | (defun allout-flag-region (from to flag) | 3704 | (defun allout-flag-region (from to flag) |
| 3739 | "Hide or show lines from FROM to TO, via Emacs selective-display FLAG char. | 3705 | "Conceal text from FROM to TO if FLAG is non-nil, else reveal it. |
| 3740 | Ie, text following flag C-m \(carriage-return) is hidden until the | 3706 | |
| 3741 | next C-j (newline) char. | 3707 | Text is shown if flag is nil and hidden otherwise." |
| 3742 | 3708 | ;; We use outline invisibility spec. | |
| 3743 | Returns the endpoint of the region." | 3709 | (remove-overlays from to 'category 'allout-overlay-category) |
| 3744 | ;; "OFR-" prefixes to avoid collisions with vars in code calling the macro. | 3710 | (when flag |
| 3745 | ;; ie, elisp macro vars are not 'hygenic', so distinct names are necessary. | 3711 | (let ((o (make-overlay from to))) |
| 3746 | (let ((was-inhibit-r-o inhibit-read-only) | 3712 | (overlay-put o 'category 'allout-overlay-category) |
| 3747 | (was-undo-list buffer-undo-list) | 3713 | (when (featurep 'xemacs) |
| 3748 | (was-modified (buffer-modified-p)) | 3714 | (let ((props (symbol-plist 'allout-overlay-category))) |
| 3749 | trans) | 3715 | (while props |
| 3750 | (unwind-protect | 3716 | (overlay-put o (pop props) (pop props))))))) |
| 3751 | (save-excursion | 3717 | (run-hooks 'allout-view-change-hook)) |
| 3752 | (setq inhibit-read-only t) | ||
| 3753 | (setq buffer-undo-list t) | ||
| 3754 | (if (> from to) | ||
| 3755 | (setq trans from from to to trans)) | ||
| 3756 | (subst-char-in-region from to | ||
| 3757 | (if (= flag ?\n) ?\r ?\n) | ||
| 3758 | flag t) | ||
| 3759 | ;; adjust character read-protection on all the affected lines. | ||
| 3760 | ;; we handle the region line-by-line. | ||
| 3761 | (goto-char to) | ||
| 3762 | (end-of-line) | ||
| 3763 | (setq to (min (+ 2 (point)) (point-max))) | ||
| 3764 | (goto-char from) | ||
| 3765 | (beginning-of-line) | ||
| 3766 | (while (< (point) to) | ||
| 3767 | ;; handle from start of exposed to beginning of hidden, or eol: | ||
| 3768 | (remove-text-properties (point) | ||
| 3769 | (progn (if (re-search-forward "[\r\n]" | ||
| 3770 | nil t) | ||
| 3771 | (forward-char -1)) | ||
| 3772 | (point)) | ||
| 3773 | '(read-only nil)) | ||
| 3774 | ;; handle from start of hidden, if any, to eol: | ||
| 3775 | (if (and (not (eobp)) (= (char-after (point)) ?\r)) | ||
| 3776 | (put-text-property (point) (progn (end-of-line) (point)) | ||
| 3777 | 'read-only t)) | ||
| 3778 | ;; Handle the end-of-line to beginning of next line: | ||
| 3779 | (if (not (eobp)) | ||
| 3780 | (progn (forward-char 1) | ||
| 3781 | (remove-text-properties (1- (point)) (point) | ||
| 3782 | '(read-only nil))))) | ||
| 3783 | ) | ||
| 3784 | (if (not was-modified) | ||
| 3785 | (set-buffer-modified-p nil)) | ||
| 3786 | (setq inhibit-read-only was-inhibit-r-o) | ||
| 3787 | (setq buffer-undo-list was-undo-list) | ||
| 3788 | ) | ||
| 3789 | ) | ||
| 3790 | ) | ||
| 3791 | ;;;_ > allout-flag-current-subtree (flag) | 3718 | ;;;_ > allout-flag-current-subtree (flag) |
| 3792 | (defun allout-flag-current-subtree (flag) | 3719 | (defun allout-flag-current-subtree (flag) |
| 3793 | "Hide or show subtree of currently-visible topic. | 3720 | "Conceal currently-visible topic's subtree if FLAG non-nil, else reveal it." |
| 3794 | |||
| 3795 | See `allout-flag-region' for more details." | ||
| 3796 | 3721 | ||
| 3797 | (save-excursion | 3722 | (save-excursion |
| 3798 | (allout-back-to-current-heading) | 3723 | (allout-back-to-current-heading) |
| 3799 | (let ((from (point)) | 3724 | (end-of-line) |
| 3800 | (to (progn (allout-end-of-current-subtree) (1- (point))))) | 3725 | (allout-flag-region (point) |
| 3801 | (allout-flag-region from to flag)))) | 3726 | ;; Exposing must not leave trailing blanks hidden, |
| 3727 | ;; but can leave them exposed when hiding, so we | ||
| 3728 | ;; can use flag's inverse as the | ||
| 3729 | ;; include-trailing-blank cue: | ||
| 3730 | (allout-end-of-current-subtree (not flag)) | ||
| 3731 | flag))) | ||
| 3802 | 3732 | ||
| 3803 | ;;;_ - Topic-specific | 3733 | ;;;_ - Topic-specific |
| 3804 | ;;;_ > allout-show-entry () | 3734 | ;;;_ > allout-show-entry (&optional inclusive) |
| 3805 | (defun allout-show-entry () | 3735 | (defun allout-show-entry (&optional inclusive) |
| 3806 | "Like `allout-show-current-entry', reveals entries nested in hidden topics. | 3736 | "Like `allout-show-current-entry', reveals entries nested in hidden topics. |
| 3807 | 3737 | ||
| 3808 | This is a way to give restricted peek at a concealed locality without the | 3738 | This is a way to give restricted peek at a concealed locality without the |
| 3809 | expense of exposing its context, but can leave the outline with aberrant | 3739 | expense of exposing its context, but can leave the outline with aberrant |
| 3810 | exposure. `allout-hide-current-entry-completely' or `allout-show-offshoot' | 3740 | exposure. `allout-show-offshoot' should be used after the peek to rectify |
| 3811 | should be used after the peek to rectify the exposure." | 3741 | the exposure." |
| 3812 | 3742 | ||
| 3813 | (interactive) | 3743 | (interactive) |
| 3814 | (save-excursion | 3744 | (save-excursion |
| 3815 | (let ((at (point)) | 3745 | (let (beg end) |
| 3816 | beg end) | ||
| 3817 | (allout-goto-prefix) | 3746 | (allout-goto-prefix) |
| 3818 | (setq beg (if (= (preceding-char) ?\r) (1- (point)) (point))) | 3747 | (setq beg (if (allout-hidden-p) (1- (point)) (point))) |
| 3819 | (re-search-forward "[\n\r]" nil t) | 3748 | (setq end (allout-pre-next-prefix)) |
| 3820 | (setq end (1- (if (< at (point)) | 3749 | (allout-flag-region beg end nil) |
| 3821 | ;; We're on topic head line - show only it: | ||
| 3822 | (point) | ||
| 3823 | ;; or we're in body - include it: | ||
| 3824 | (max beg (or (allout-pre-next-preface) (point)))))) | ||
| 3825 | (allout-flag-region beg end ?\n) | ||
| 3826 | (list beg end)))) | 3750 | (list beg end)))) |
| 3827 | ;;;_ > allout-show-children (&optional level strict) | 3751 | ;;;_ > allout-show-children (&optional level strict) |
| 3828 | (defun allout-show-children (&optional level strict) | 3752 | (defun allout-show-children (&optional level strict) |
| @@ -3843,67 +3767,59 @@ Returns point at end of subtree that was opened, if any. (May get a | |||
| 3843 | point of non-opened subtree?)" | 3767 | point of non-opened subtree?)" |
| 3844 | 3768 | ||
| 3845 | (interactive "p") | 3769 | (interactive "p") |
| 3846 | (let (max-pos) | 3770 | (let ((start-point (point))) |
| 3847 | (if (and (not strict) | 3771 | (if (and (not strict) |
| 3848 | (allout-hidden-p)) | 3772 | (allout-hidden-p)) |
| 3849 | 3773 | ||
| 3850 | (progn (allout-show-to-offshoot) ; Point's concealed, open to | 3774 | (progn (allout-show-to-offshoot) ; Point's concealed, open to |
| 3851 | ; expose it. | 3775 | ; expose it. |
| 3852 | ;; Then recurse, but with "strict" set so we don't | 3776 | ;; Then recurse, but with "strict" set so we don't |
| 3853 | ;; infinite regress: | 3777 | ;; infinite regress: |
| 3854 | (setq max-pos (allout-show-children level t))) | 3778 | (allout-show-children level t)) |
| 3855 | 3779 | ||
| 3856 | (save-excursion | 3780 | (save-excursion |
| 3857 | (save-restriction | 3781 | (allout-beginning-of-current-line) |
| 3858 | (let* ((start-pt (point)) | 3782 | (save-restriction |
| 3859 | (chart (allout-chart-subtree (or level 1))) | 3783 | (let* ((chart (allout-chart-subtree (or level 1))) |
| 3860 | (to-reveal (allout-chart-to-reveal chart (or level 1)))) | 3784 | (to-reveal (allout-chart-to-reveal chart (or level 1)))) |
| 3861 | (goto-char start-pt) | 3785 | (goto-char start-point) |
| 3862 | (if (and strict (= (preceding-char) ?\r)) | 3786 | (when (and strict (allout-hidden-p)) |
| 3863 | ;; Concealed root would already have been taken care of, | 3787 | ;; Concealed root would already have been taken care of, |
| 3864 | ;; unless strict was set. | 3788 | ;; unless strict was set. |
| 3865 | (progn | 3789 | (allout-flag-region (point) (allout-snug-back) nil) |
| 3866 | (allout-flag-region (point) (allout-snug-back) ?\n) | 3790 | (when allout-show-bodies |
| 3867 | (if allout-show-bodies | 3791 | (goto-char (car to-reveal)) |
| 3868 | (progn (goto-char (car to-reveal)) | 3792 | (allout-show-current-entry))) |
| 3869 | (allout-show-current-entry))))) | 3793 | (while to-reveal |
| 3870 | (while to-reveal | 3794 | (goto-char (car to-reveal)) |
| 3871 | (goto-char (car to-reveal)) | 3795 | (allout-flag-region (save-excursion (allout-snug-back) (point)) |
| 3872 | (allout-flag-region (point) (allout-snug-back) ?\n) | 3796 | (progn (search-forward "\n" nil t) |
| 3873 | (if allout-show-bodies | 3797 | (1- (point))) |
| 3874 | (progn (goto-char (car to-reveal)) | 3798 | nil) |
| 3875 | (allout-show-current-entry))) | 3799 | (when allout-show-bodies |
| 3876 | (setq to-reveal (cdr to-reveal))))))))) | 3800 | (goto-char (car to-reveal)) |
| 3877 | ;;;_ > allout-hide-point-reconcile () | 3801 | (allout-show-current-entry)) |
| 3878 | (defun allout-hide-reconcile () | 3802 | (setq to-reveal (cdr to-reveal))))))) |
| 3879 | "Like `allout-hide-current-entry'; hides completely if within hidden region. | 3803 | ;; Compensate for `save-excursion's maintenance of point |
| 3880 | 3804 | ;; within invisible text: | |
| 3881 | Specifically intended for aberrant exposure states, like entries that were | 3805 | (goto-char start-point))) |
| 3882 | exposed by `allout-show-entry' but are within otherwise concealed regions." | ||
| 3883 | (interactive) | ||
| 3884 | (save-excursion | ||
| 3885 | (allout-goto-prefix) | ||
| 3886 | (allout-flag-region (if (not (bobp)) (1- (point)) (point)) | ||
| 3887 | (progn (allout-pre-next-preface) | ||
| 3888 | (if (= ?\r (following-char)) | ||
| 3889 | (point) | ||
| 3890 | (1- (point)))) | ||
| 3891 | ?\r))) | ||
| 3892 | ;;;_ > allout-show-to-offshoot () | 3806 | ;;;_ > allout-show-to-offshoot () |
| 3893 | (defun allout-show-to-offshoot () | 3807 | (defun allout-show-to-offshoot () |
| 3894 | "Like `allout-show-entry', but reveals all concealed ancestors, as well. | 3808 | "Like `allout-show-entry', but reveals all concealed ancestors, as well. |
| 3895 | 3809 | ||
| 3896 | As with `allout-hide-current-entry-completely', useful for rectifying | 3810 | Useful for coherently exposing to a random point in a hidden region." |
| 3897 | aberrant exposure states produced by `allout-show-entry'." | ||
| 3898 | |||
| 3899 | (interactive) | 3811 | (interactive) |
| 3900 | (save-excursion | 3812 | (save-excursion |
| 3901 | (let ((orig-pt (point)) | 3813 | (let ((orig-pt (point)) |
| 3902 | (orig-pref (allout-goto-prefix)) | 3814 | (orig-pref (allout-goto-prefix)) |
| 3903 | (last-at (point)) | 3815 | (last-at (point)) |
| 3904 | bag-it) | 3816 | bag-it) |
| 3905 | (while (or bag-it (= (preceding-char) ?\r)) | 3817 | (while (or bag-it (allout-hidden-p)) |
| 3906 | (beginning-of-line) | 3818 | (while (allout-hidden-p) |
| 3819 | ;; XXX We would use `(move-beginning-of-line 1)', but it gets | ||
| 3820 | ;; stuck on hidden newlines at column 80, as of GNU Emacs 22.0.50. | ||
| 3821 | (beginning-of-line) | ||
| 3822 | (if (allout-hidden-p) (forward-char -1))) | ||
| 3907 | (if (= last-at (setq last-at (point))) | 3823 | (if (= last-at (setq last-at (point))) |
| 3908 | ;; Oops, we're not making any progress! Show the current | 3824 | ;; Oops, we're not making any progress! Show the current |
| 3909 | ;; topic completely, and bag this try. | 3825 | ;; topic completely, and bag this try. |
| @@ -3926,38 +3842,24 @@ aberrant exposure states produced by `allout-show-entry'." | |||
| 3926 | (interactive) | 3842 | (interactive) |
| 3927 | (allout-back-to-current-heading) | 3843 | (allout-back-to-current-heading) |
| 3928 | (save-excursion | 3844 | (save-excursion |
| 3929 | (allout-flag-region (point) | 3845 | (end-of-line) |
| 3846 | (allout-flag-region (point) | ||
| 3930 | (progn (allout-end-of-entry) (point)) | 3847 | (progn (allout-end-of-entry) (point)) |
| 3931 | ?\r))) | 3848 | t))) |
| 3932 | ;;;_ > allout-show-current-entry (&optional arg) | 3849 | ;;;_ > allout-show-current-entry (&optional arg) |
| 3933 | (defun allout-show-current-entry (&optional arg) | 3850 | (defun allout-show-current-entry (&optional arg) |
| 3934 | 3851 | ||
| 3935 | "Show body following current heading, or hide the entry if repeat count." | 3852 | "Show body following current heading, or hide entry with universal argument." |
| 3936 | 3853 | ||
| 3937 | (interactive "P") | 3854 | (interactive "P") |
| 3938 | (if arg | 3855 | (if arg |
| 3939 | (allout-hide-current-entry) | 3856 | (allout-hide-current-entry) |
| 3857 | (save-excursion (allout-show-to-offshoot)) | ||
| 3940 | (save-excursion | 3858 | (save-excursion |
| 3941 | (allout-flag-region (point) | 3859 | (allout-flag-region (point) |
| 3942 | (progn (allout-end-of-entry) (point)) | 3860 | (progn (allout-end-of-entry t) (point)) |
| 3943 | ?\n) | 3861 | nil) |
| 3944 | ))) | 3862 | ))) |
| 3945 | ;;;_ > allout-hide-current-entry-completely () | ||
| 3946 | ; ... allout-hide-current-entry-completely also for isearch dynamic exposure: | ||
| 3947 | (defun allout-hide-current-entry-completely () | ||
| 3948 | "Like `allout-hide-current-entry', but conceal topic completely. | ||
| 3949 | |||
| 3950 | Specifically intended for aberrant exposure states, like entries that were | ||
| 3951 | exposed by `allout-show-entry' but are within otherwise concealed regions." | ||
| 3952 | (interactive) | ||
| 3953 | (save-excursion | ||
| 3954 | (allout-goto-prefix) | ||
| 3955 | (allout-flag-region (if (not (bobp)) (1- (point)) (point)) | ||
| 3956 | (progn (allout-pre-next-preface) | ||
| 3957 | (if (= ?\r (following-char)) | ||
| 3958 | (point) | ||
| 3959 | (1- (point)))) | ||
| 3960 | ?\r))) | ||
| 3961 | ;;;_ > allout-show-current-subtree (&optional arg) | 3863 | ;;;_ > allout-show-current-subtree (&optional arg) |
| 3962 | (defun allout-show-current-subtree (&optional arg) | 3864 | (defun allout-show-current-subtree (&optional arg) |
| 3963 | "Show everything within the current topic. With a repeat-count, | 3865 | "Show everything within the current topic. With a repeat-count, |
| @@ -3970,11 +3872,27 @@ expose this topic and its siblings." | |||
| 3970 | (error "No topics") | 3872 | (error "No topics") |
| 3971 | ;; got to first, outermost topic - set to expose it and siblings: | 3873 | ;; got to first, outermost topic - set to expose it and siblings: |
| 3972 | (message "Above outermost topic - exposing all.") | 3874 | (message "Above outermost topic - exposing all.") |
| 3973 | (allout-flag-region (point-min)(point-max) ?\n)) | 3875 | (allout-flag-region (point-min)(point-max) nil)) |
| 3876 | (allout-beginning-of-current-line) | ||
| 3974 | (if (not arg) | 3877 | (if (not arg) |
| 3975 | (allout-flag-current-subtree ?\n) | 3878 | (allout-flag-current-subtree nil) |
| 3976 | (allout-beginning-of-level) | 3879 | (allout-beginning-of-level) |
| 3977 | (allout-expose-topic '(* :)))))) | 3880 | (allout-expose-topic '(* :)))))) |
| 3881 | ;;;_ > allout-current-topic-collapsed-p (&optional include-single-liners) | ||
| 3882 | (defun allout-current-topic-collapsed-p (&optional include-single-liners) | ||
| 3883 | "True if the currently visible containing topic is already collapsed. | ||
| 3884 | |||
| 3885 | If optional INCLUDE-SINGLE-LINERS is true, then include single-line | ||
| 3886 | topics \(which intrinsically can be considered both collapsed and | ||
| 3887 | not\), as collapsed. Otherwise they are considered uncollapsed." | ||
| 3888 | (save-excursion | ||
| 3889 | (and | ||
| 3890 | (= (progn (allout-back-to-current-heading) | ||
| 3891 | (move-end-of-line 1) | ||
| 3892 | (point)) | ||
| 3893 | (allout-end-of-current-subtree)) | ||
| 3894 | (or include-single-liners | ||
| 3895 | (progn (backward-char 1) (allout-hidden-p)))))) | ||
| 3978 | ;;;_ > allout-hide-current-subtree (&optional just-close) | 3896 | ;;;_ > allout-hide-current-subtree (&optional just-close) |
| 3979 | (defun allout-hide-current-subtree (&optional just-close) | 3897 | (defun allout-hide-current-subtree (&optional just-close) |
| 3980 | "Close the current topic, or containing topic if this one is already closed. | 3898 | "Close the current topic, or containing topic if this one is already closed. |
| @@ -3982,35 +3900,21 @@ expose this topic and its siblings." | |||
| 3982 | If this topic is closed and it's a top level topic, close this topic | 3900 | If this topic is closed and it's a top level topic, close this topic |
| 3983 | and its siblings. | 3901 | and its siblings. |
| 3984 | 3902 | ||
| 3985 | If optional arg JUST-CLOSE is non-nil, do not treat the parent or | 3903 | If optional arg JUST-CLOSE is non-nil, do not close the parent or |
| 3986 | siblings, even if the target topic is already closed." | 3904 | siblings, even if the target topic is already closed." |
| 3987 | 3905 | ||
| 3988 | (interactive) | 3906 | (interactive) |
| 3989 | (let ((from (point)) | 3907 | (let* ((from (point)) |
| 3990 | (orig-eol (progn (end-of-line) | 3908 | (sibs-msg "Top-level topic already closed - closing siblings...") |
| 3991 | (if (not (allout-goto-prefix)) | 3909 | (current-exposed (not (allout-current-topic-collapsed-p t)))) |
| 3992 | (error "No topics found") | 3910 | (cond (current-exposed (allout-flag-current-subtree t)) |
| 3993 | (end-of-line)(point))))) | 3911 | (just-close nil) |
| 3994 | (allout-flag-current-subtree ?\r) | 3912 | ((allout-up-current-level 1 t) (allout-hide-current-subtree)) |
| 3995 | (goto-char from) | 3913 | (t (goto-char 0) |
| 3996 | (if (and (= orig-eol (progn (goto-char orig-eol) | 3914 | (message sibs-msg) |
| 3997 | (end-of-line) | 3915 | (allout-expose-topic '(0 :)) |
| 3998 | (point))) | 3916 | (message (concat sibs-msg " Done.")))) |
| 3999 | (not just-close) | 3917 | (goto-char from))) |
| 4000 | ;; Structure didn't change - try hiding current level: | ||
| 4001 | (goto-char from) | ||
| 4002 | (if (allout-up-current-level 1 t) | ||
| 4003 | t | ||
| 4004 | (goto-char 0) | ||
| 4005 | (let ((msg | ||
| 4006 | "Top-level topic already closed - closing siblings...")) | ||
| 4007 | (message msg) | ||
| 4008 | (allout-expose-topic '(0 :)) | ||
| 4009 | (message (concat msg " Done."))) | ||
| 4010 | nil) | ||
| 4011 | (/= (allout-recent-depth) 0)) | ||
| 4012 | (allout-hide-current-subtree)) | ||
| 4013 | (goto-char from))) | ||
| 4014 | ;;;_ > allout-show-current-branches () | 3918 | ;;;_ > allout-show-current-branches () |
| 4015 | (defun allout-show-current-branches () | 3919 | (defun allout-show-current-branches () |
| 4016 | "Show all subheadings of this heading, but not their bodies." | 3920 | "Show all subheadings of this heading, but not their bodies." |
| @@ -4031,7 +3935,7 @@ siblings, even if the target topic is already closed." | |||
| 4031 | "Show all of the text in the buffer." | 3935 | "Show all of the text in the buffer." |
| 4032 | (interactive) | 3936 | (interactive) |
| 4033 | (message "Exposing entire buffer...") | 3937 | (message "Exposing entire buffer...") |
| 4034 | (allout-flag-region (point-min) (point-max) ?\n) | 3938 | (allout-flag-region (point-min) (point-max) nil) |
| 4035 | (message "Exposing entire buffer... Done.")) | 3939 | (message "Exposing entire buffer... Done.")) |
| 4036 | ;;;_ > allout-hide-bodies () | 3940 | ;;;_ > allout-hide-bodies () |
| 4037 | (defun allout-hide-bodies () | 3941 | (defun allout-hide-bodies () |
| @@ -4046,11 +3950,11 @@ siblings, even if the target topic is already closed." | |||
| 4046 | (narrow-to-region start end) | 3950 | (narrow-to-region start end) |
| 4047 | (goto-char (point-min)) | 3951 | (goto-char (point-min)) |
| 4048 | (while (not (eobp)) | 3952 | (while (not (eobp)) |
| 4049 | (allout-flag-region (point) | 3953 | (end-of-line) |
| 4050 | (progn (allout-pre-next-preface) (point)) ?\r) | 3954 | (allout-flag-region (point) (allout-end-of-entry) t) |
| 4051 | (if (not (eobp)) | 3955 | (if (not (eobp)) |
| 4052 | (forward-char | 3956 | (forward-char |
| 4053 | (if (looking-at "[\n\r][\n\r]") | 3957 | (if (looking-at "\n\n") |
| 4054 | 2 1))))))) | 3958 | 2 1))))))) |
| 4055 | 3959 | ||
| 4056 | ;;;_ > allout-expose-topic (spec) | 3960 | ;;;_ > allout-expose-topic (spec) |
| @@ -4117,9 +4021,7 @@ Examples: | |||
| 4117 | (let ((depth (allout-depth)) | 4021 | (let ((depth (allout-depth)) |
| 4118 | (max-pos 0) | 4022 | (max-pos 0) |
| 4119 | prev-elem curr-elem | 4023 | prev-elem curr-elem |
| 4120 | stay done | 4024 | stay) |
| 4121 | snug-back | ||
| 4122 | ) | ||
| 4123 | (while spec | 4025 | (while spec |
| 4124 | (setq prev-elem curr-elem | 4026 | (setq prev-elem curr-elem |
| 4125 | curr-elem (car spec) | 4027 | curr-elem (car spec) |
| @@ -4147,7 +4049,7 @@ Examples: | |||
| 4147 | (setq spec (append (make-list residue prev-elem) | 4049 | (setq spec (append (make-list residue prev-elem) |
| 4148 | spec))))))) | 4050 | spec))))))) |
| 4149 | ((numberp curr-elem) | 4051 | ((numberp curr-elem) |
| 4150 | (if (and (>= 0 curr-elem) (allout-visible-p)) | 4052 | (if (and (>= 0 curr-elem) (not (allout-hidden-p))) |
| 4151 | (save-excursion (allout-hide-current-subtree t) | 4053 | (save-excursion (allout-hide-current-subtree t) |
| 4152 | (if (> 0 curr-elem) | 4054 | (if (> 0 curr-elem) |
| 4153 | nil | 4055 | nil |
| @@ -4207,7 +4109,6 @@ Optional FOLLOWERS arguments dictate exposure for succeeding siblings." | |||
| 4207 | 4109 | ||
| 4208 | (interactive "xExposure spec: ") | 4110 | (interactive "xExposure spec: ") |
| 4209 | (let ((depth (allout-current-depth)) | 4111 | (let ((depth (allout-current-depth)) |
| 4210 | done | ||
| 4211 | max-pos) | 4112 | max-pos) |
| 4212 | (cond ((null spec) nil) | 4113 | (cond ((null spec) nil) |
| 4213 | ((symbolp spec) | 4114 | ((symbolp spec) |
| @@ -4387,7 +4288,7 @@ header and body. The elements of that list are: | |||
| 4387 | (save-excursion | 4288 | (save-excursion |
| 4388 | (let* | 4289 | (let* |
| 4389 | ;; state vars: | 4290 | ;; state vars: |
| 4390 | (strings prefix pad result depth new-depth out gone-out bullet beg | 4291 | (strings prefix result depth new-depth out gone-out bullet beg |
| 4391 | next done) | 4292 | next done) |
| 4392 | 4293 | ||
| 4393 | (goto-char start) | 4294 | (goto-char start) |
| @@ -4419,16 +4320,11 @@ header and body. The elements of that list are: | |||
| 4419 | beg | 4320 | beg |
| 4420 | ;To hidden text or end of line: | 4321 | ;To hidden text or end of line: |
| 4421 | (progn | 4322 | (progn |
| 4422 | (search-forward "\r" | 4323 | (end-of-line) |
| 4423 | (save-excursion (end-of-line) | 4324 | (allout-back-to-visible-text))) |
| 4424 | (point)) | ||
| 4425 | 1) | ||
| 4426 | (if (= (preceding-char) ?\r) | ||
| 4427 | (1- (point)) | ||
| 4428 | (point)))) | ||
| 4429 | strings)) | 4325 | strings)) |
| 4430 | (if (< (point) next) ; Resume from after hid text, if any. | 4326 | (when (< (point) next) ; Resume from after hid text, if any. |
| 4431 | (forward-line 1)) | 4327 | (line-move 1)) |
| 4432 | (setq beg (point))) | 4328 | (setq beg (point))) |
| 4433 | ;; Accumulate list for this topic: | 4329 | ;; Accumulate list for this topic: |
| 4434 | (setq strings (nreverse strings)) | 4330 | (setq strings (nreverse strings)) |
| @@ -4488,7 +4384,7 @@ header and body. The elements of that list are: | |||
| 4488 | ;;;_ > allout-process-exposed (&optional func from to frombuf | 4384 | ;;;_ > allout-process-exposed (&optional func from to frombuf |
| 4489 | ;;; tobuf format) | 4385 | ;;; tobuf format) |
| 4490 | (defun allout-process-exposed (&optional func from to frombuf tobuf | 4386 | (defun allout-process-exposed (&optional func from to frombuf tobuf |
| 4491 | format &optional start-num) | 4387 | format start-num) |
| 4492 | "Map function on exposed parts of current topic; results to another buffer. | 4388 | "Map function on exposed parts of current topic; results to another buffer. |
| 4493 | 4389 | ||
| 4494 | All args are options; default values itemized below. | 4390 | All args are options; default values itemized below. |
| @@ -4694,13 +4590,6 @@ environment. Leaves point at the end of the line." | |||
| 4694 | (page-numbering (if allout-number-pages | 4590 | (page-numbering (if allout-number-pages |
| 4695 | "\\pagestyle{empty}\n" | 4591 | "\\pagestyle{empty}\n" |
| 4696 | "")) | 4592 | "")) |
| 4697 | (linesdef (concat "\\def\\beginlines{" | ||
| 4698 | "\\par\\begingroup\\nobreak\\medskip" | ||
| 4699 | "\\parindent=0pt\n" | ||
| 4700 | " \\kern1pt\\nobreak \\obeylines \\obeyspaces " | ||
| 4701 | "\\everypar{\\strut}}\n" | ||
| 4702 | "\\def\\endlines{" | ||
| 4703 | "\\kern1pt\\endgroup\\medbreak\\noindent}\n")) | ||
| 4704 | (titlecmd (format "\\newcommand{\\titlecmd}[1]{{%s #1}}\n" | 4593 | (titlecmd (format "\\newcommand{\\titlecmd}[1]{{%s #1}}\n" |
| 4705 | allout-title-style)) | 4594 | allout-title-style)) |
| 4706 | (labelcmd (format "\\newcommand{\\labelcmd}[1]{{%s #1}}\n" | 4595 | (labelcmd (format "\\newcommand{\\labelcmd}[1]{{%s #1}}\n" |
| @@ -4733,7 +4622,7 @@ environment. Leaves point at the end of the line." | |||
| 4733 | (title (format "%s%s%s%s" | 4622 | (title (format "%s%s%s%s" |
| 4734 | "\\titlecmd{" | 4623 | "\\titlecmd{" |
| 4735 | (allout-latex-verb-quote (if allout-title | 4624 | (allout-latex-verb-quote (if allout-title |
| 4736 | (condition-case err | 4625 | (condition-case nil |
| 4737 | (eval allout-title) | 4626 | (eval allout-title) |
| 4738 | ('error "<unnamed buffer>")) | 4627 | ('error "<unnamed buffer>")) |
| 4739 | "Unnamed Outline")) | 4628 | "Unnamed Outline")) |
| @@ -4913,7 +4802,7 @@ solicited whenever the passphrase is changed." | |||
| 4913 | (interactive "P") | 4802 | (interactive "P") |
| 4914 | (save-excursion | 4803 | (save-excursion |
| 4915 | (allout-back-to-current-heading) | 4804 | (allout-back-to-current-heading) |
| 4916 | (allout-toggle-subtree-encryption) | 4805 | (allout-toggle-subtree-encryption fetch-pass) |
| 4917 | ) | 4806 | ) |
| 4918 | ) | 4807 | ) |
| 4919 | ;;;_ > allout-toggle-subtree-encryption (&optional fetch-pass) | 4808 | ;;;_ > allout-toggle-subtree-encryption (&optional fetch-pass) |
| @@ -4948,20 +4837,23 @@ See `allout-toggle-current-subtree-encryption' for more details." | |||
| 4948 | (progn (if (= (point-max) after-bullet-pos) | 4837 | (progn (if (= (point-max) after-bullet-pos) |
| 4949 | (error "no body to encrypt")) | 4838 | (error "no body to encrypt")) |
| 4950 | (allout-encrypted-topic-p))) | 4839 | (allout-encrypted-topic-p))) |
| 4951 | (was-collapsed (if (not (re-search-forward "[\n\r]" nil t)) | 4840 | (was-collapsed (if (not (search-forward "\n" nil t)) |
| 4952 | nil | 4841 | nil |
| 4953 | (backward-char 1) | 4842 | (backward-char 1) |
| 4954 | (looking-at "\r"))) | 4843 | (allout-hidden-p))) |
| 4955 | (subtree-beg (1+ (point))) | 4844 | (subtree-beg (1+ (point))) |
| 4956 | (subtree-end (allout-end-of-subtree)) | 4845 | (subtree-end (allout-end-of-subtree)) |
| 4957 | (subject-text (buffer-substring-no-properties subtree-beg | 4846 | (subject-text (buffer-substring-no-properties subtree-beg |
| 4958 | subtree-end)) | 4847 | subtree-end)) |
| 4959 | (subtree-end-char (char-after (1- subtree-end))) | 4848 | (subtree-end-char (char-after (1- subtree-end))) |
| 4960 | (subtree-trailling-char (char-after subtree-end)) | 4849 | (subtree-trailing-char (char-after subtree-end)) |
| 4961 | (place-holder (if (or (string= "" subject-text) | 4850 | ;; kluge - result-text needs to be nil, but we also want to |
| 4962 | (string= "\n" subject-text)) | 4851 | ;; check for the error condition |
| 4963 | (error "No topic contents to %scrypt" | 4852 | (result-text (if (or (string= "" subject-text) |
| 4964 | (if was-encrypted "de" "en")))) | 4853 | (string= "\n" subject-text)) |
| 4854 | (error "No topic contents to %scrypt" | ||
| 4855 | (if was-encrypted "de" "en")) | ||
| 4856 | nil)) | ||
| 4965 | ;; Assess key parameters: | 4857 | ;; Assess key parameters: |
| 4966 | (key-info (or | 4858 | (key-info (or |
| 4967 | ;; detect the type by which it is already encrypted | 4859 | ;; detect the type by which it is already encrypted |
| @@ -4972,8 +4864,7 @@ See `allout-toggle-current-subtree-encryption' for more details." | |||
| 4972 | '(symmetric nil))) | 4864 | '(symmetric nil))) |
| 4973 | (for-key-type (car key-info)) | 4865 | (for-key-type (car key-info)) |
| 4974 | (for-key-identity (cadr key-info)) | 4866 | (for-key-identity (cadr key-info)) |
| 4975 | (fetch-pass (and fetch-pass (member fetch-pass '(16 (16))))) | 4867 | (fetch-pass (and fetch-pass (member fetch-pass '(16 (16)))))) |
| 4976 | result-text) | ||
| 4977 | 4868 | ||
| 4978 | (setq result-text | 4869 | (setq result-text |
| 4979 | (allout-encrypt-string subject-text was-encrypted | 4870 | (allout-encrypt-string subject-text was-encrypted |
| @@ -4987,12 +4878,12 @@ See `allout-toggle-current-subtree-encryption' for more details." | |||
| 4987 | (delete-region subtree-beg subtree-end) | 4878 | (delete-region subtree-beg subtree-end) |
| 4988 | (insert result-text) | 4879 | (insert result-text) |
| 4989 | (if was-collapsed | 4880 | (if was-collapsed |
| 4990 | (allout-flag-region subtree-beg (1- (point)) ?\r)) | 4881 | (allout-flag-region (1- subtree-beg) (point) t)) |
| 4991 | ;; adjust trailling-blank-lines to preserve topic spacing: | 4882 | ;; adjust trailing-blank-lines to preserve topic spacing: |
| 4992 | (if (not was-encrypted) | 4883 | (if (not was-encrypted) |
| 4993 | (if (and (member subtree-end-char '(?\r ?\n)) | 4884 | (if (and (= subtree-end-char ?\n) |
| 4994 | (member subtree-trailling-char '(?\r ?\n))) | 4885 | (= subtree-trailing-char ?\n)) |
| 4995 | (insert subtree-trailling-char))) | 4886 | (insert subtree-trailing-char))) |
| 4996 | ;; Ensure that the item has an encrypted-entry bullet: | 4887 | ;; Ensure that the item has an encrypted-entry bullet: |
| 4997 | (if (not (string= (buffer-substring-no-properties | 4888 | (if (not (string= (buffer-substring-no-properties |
| 4998 | (1- after-bullet-pos) after-bullet-pos) | 4889 | (1- after-bullet-pos) after-bullet-pos) |
| @@ -5060,8 +4951,7 @@ Returns the resulting string, or nil if the transformation fails." | |||
| 5060 | target-prompt-id | 4951 | target-prompt-id |
| 5061 | (or (buffer-file-name allout-buffer) | 4952 | (or (buffer-file-name allout-buffer) |
| 5062 | target-prompt-id)))) | 4953 | target-prompt-id)))) |
| 5063 | (comment "Processed by allout driving pgg") | 4954 | result-text status) |
| 5064 | work-buffer result result-text status) | ||
| 5065 | 4955 | ||
| 5066 | (if (and fetch-pass (not passphrase)) | 4956 | (if (and fetch-pass (not passphrase)) |
| 5067 | ;; Force later fetch by evicting passphrase from the cache. | 4957 | ;; Force later fetch by evicting passphrase from the cache. |
| @@ -5083,7 +4973,7 @@ Returns the resulting string, or nil if the transformation fails." | |||
| 5083 | retried fetch-pass))) | 4973 | retried fetch-pass))) |
| 5084 | (with-temp-buffer | 4974 | (with-temp-buffer |
| 5085 | 4975 | ||
| 5086 | (insert (subst-char-in-string ?\r ?\n text)) | 4976 | (insert text) |
| 5087 | 4977 | ||
| 5088 | (cond | 4978 | (cond |
| 5089 | 4979 | ||
| @@ -5319,7 +5209,7 @@ An error is raised if the text is not encrypted." | |||
| 5319 | (require 'pgg-parse) | 5209 | (require 'pgg-parse) |
| 5320 | (save-excursion | 5210 | (save-excursion |
| 5321 | (with-temp-buffer | 5211 | (with-temp-buffer |
| 5322 | (insert (subst-char-in-string ?\r ?\n text)) | 5212 | (insert text) |
| 5323 | (let* ((parsed-armor (pgg-parse-armor-region (point-min) (point-max))) | 5213 | (let* ((parsed-armor (pgg-parse-armor-region (point-min) (point-max))) |
| 5324 | (type (if (pgg-gpg-symmetric-key-p parsed-armor) | 5214 | (type (if (pgg-gpg-symmetric-key-p parsed-armor) |
| 5325 | 'symmetric | 5215 | 'symmetric |
| @@ -5442,21 +5332,21 @@ must also have content." | |||
| 5442 | (while (not done) | 5332 | (while (not done) |
| 5443 | 5333 | ||
| 5444 | (if (not (re-search-forward | 5334 | (if (not (re-search-forward |
| 5445 | (format "\\(\\`\\|[\n\r]\\)%s *%s[^*]" | 5335 | (format "\\(\\`\\|\n\\)%s *%s[^*]" |
| 5446 | (regexp-quote allout-header-prefix) | 5336 | (regexp-quote allout-header-prefix) |
| 5447 | (regexp-quote allout-topic-encryption-bullet)) | 5337 | (regexp-quote allout-topic-encryption-bullet)) |
| 5448 | nil t)) | 5338 | nil t)) |
| 5449 | (setq got nil | 5339 | (setq got nil |
| 5450 | done t) | 5340 | done t) |
| 5451 | (goto-char (setq got (match-beginning 0))) | 5341 | (goto-char (setq got (match-beginning 0))) |
| 5452 | (if (looking-at "[\n\r]") | 5342 | (if (looking-at "\n") |
| 5453 | (forward-char 1)) | 5343 | (forward-char 1)) |
| 5454 | (setq got (point))) | 5344 | (setq got (point))) |
| 5455 | 5345 | ||
| 5456 | (cond ((not got) | 5346 | (cond ((not got) |
| 5457 | (setq done t)) | 5347 | (setq done t)) |
| 5458 | 5348 | ||
| 5459 | ((not (re-search-forward "[\n\r]")) | 5349 | ((not (search-forward "\n")) |
| 5460 | (setq got nil | 5350 | (setq got nil |
| 5461 | done t)) | 5351 | done t)) |
| 5462 | 5352 | ||
| @@ -5498,26 +5388,28 @@ save. See `allout-encrypt-unencrypted-on-saves' for more info." | |||
| 5498 | 5388 | ||
| 5499 | (interactive "p") | 5389 | (interactive "p") |
| 5500 | (save-excursion | 5390 | (save-excursion |
| 5501 | (let ((current-mark (point-marker)) | 5391 | (let* ((current-mark (point-marker)) |
| 5502 | was-modified | 5392 | (current-mark-position (marker-position current-mark)) |
| 5503 | bo-subtree | 5393 | was-modified |
| 5504 | editing-topic editing-point) | 5394 | bo-subtree |
| 5395 | editing-topic editing-point) | ||
| 5505 | (goto-char (point-min)) | 5396 | (goto-char (point-min)) |
| 5506 | (while (allout-next-topic-pending-encryption except-mark) | 5397 | (while (allout-next-topic-pending-encryption except-mark) |
| 5507 | (setq was-modified (buffer-modified-p)) | 5398 | (setq was-modified (buffer-modified-p)) |
| 5508 | (if (save-excursion | 5399 | (when (save-excursion |
| 5509 | (and (boundp 'allout-encrypt-unencrypted-on-saves) | 5400 | (and (boundp 'allout-encrypt-unencrypted-on-saves) |
| 5510 | allout-encrypt-unencrypted-on-saves | 5401 | allout-encrypt-unencrypted-on-saves |
| 5511 | (setq bo-subtree (re-search-forward "[\n\r]")) | 5402 | (setq bo-subtree (re-search-forward "$")) |
| 5512 | ;; Not collapsed: | 5403 | (not (allout-hidden-p)) |
| 5513 | (string= (match-string 0) "\n") | 5404 | (>= current-mark (point)) |
| 5514 | (>= current-mark (point)) | 5405 | (allout-end-of-current-subtree) |
| 5515 | (allout-end-of-current-subtree) | 5406 | (<= current-mark (point)))) |
| 5516 | (<= current-mark (point)))) | ||
| 5517 | (setq editing-topic (point) | 5407 | (setq editing-topic (point) |
| 5518 | ;; we had to wait for this 'til now so prior topics are | 5408 | ;; we had to wait for this 'til now so prior topics are |
| 5519 | ;; encrypted, any relevant text shifts are in place: | 5409 | ;; encrypted, any relevant text shifts are in place: |
| 5520 | editing-point (marker-position current-mark))) | 5410 | editing-point (- current-mark-position |
| 5411 | (count-trailing-whitespace-region | ||
| 5412 | bo-subtree current-mark-position)))) | ||
| 5521 | (allout-toggle-subtree-encryption) | 5413 | (allout-toggle-subtree-encryption) |
| 5522 | (if (not was-modified) | 5414 | (if (not was-modified) |
| 5523 | (set-buffer-modified-p nil)) | 5415 | (set-buffer-modified-p nil)) |
| @@ -5579,11 +5471,11 @@ Returns list `(beginning-point prefix-string suffix-string)'." | |||
| 5579 | (setq beg (- (point) 16)) | 5471 | (setq beg (- (point) 16)) |
| 5580 | (setq suffix (buffer-substring-no-properties | 5472 | (setq suffix (buffer-substring-no-properties |
| 5581 | (point) | 5473 | (point) |
| 5582 | (progn (if (re-search-forward "[\n\r]" nil t) | 5474 | (progn (if (search-forward "\n" nil t) |
| 5583 | (forward-char -1)) | 5475 | (forward-char -1)) |
| 5584 | (point)))) | 5476 | (point)))) |
| 5585 | (setq prefix (buffer-substring-no-properties | 5477 | (setq prefix (buffer-substring-no-properties |
| 5586 | (progn (if (re-search-backward "[\n\r]" nil t) | 5478 | (progn (if (search-backward "\n" nil t) |
| 5587 | (forward-char 1)) | 5479 | (forward-char 1)) |
| 5588 | (point)) | 5480 | (point)) |
| 5589 | beg)) | 5481 | beg)) |
| @@ -5639,7 +5531,7 @@ enable-local-variables must be true for any of this to happen." | |||
| 5639 | (allout-show-to-offshoot) | 5531 | (allout-show-to-offshoot) |
| 5640 | (if (search-forward (concat "\n" prefix varname ":") nil t) | 5532 | (if (search-forward (concat "\n" prefix varname ":") nil t) |
| 5641 | (let* ((value-beg (point)) | 5533 | (let* ((value-beg (point)) |
| 5642 | (line-end (progn (if (re-search-forward "[\n\r]" nil t) | 5534 | (line-end (progn (if (search-forward "\n" nil t) |
| 5643 | (forward-char -1)) | 5535 | (forward-char -1)) |
| 5644 | (point))) | 5536 | (point))) |
| 5645 | (value-end (- line-end (length suffix)))) | 5537 | (value-end (- line-end (length suffix)))) |
| @@ -5710,26 +5602,29 @@ Optional arg SUCCESSIVE-BACKSLASHES is used internally for recursion." | |||
| 5710 | (regexp-sans-escapes (substring regexp 1))) | 5602 | (regexp-sans-escapes (substring regexp 1))) |
| 5711 | ;; Exclude first char, but maintain count: | 5603 | ;; Exclude first char, but maintain count: |
| 5712 | (regexp-sans-escapes (substring regexp 1) successive-backslashes)))) | 5604 | (regexp-sans-escapes (substring regexp 1) successive-backslashes)))) |
| 5713 | ;;;_ - add-hook definition for divergent emacsen | 5605 | ;;;_ > count-trailing-whitespace-region (beg end) |
| 5714 | ;;;_ > add-hook (hook function &optional append) | 5606 | (defun count-trailing-whitespace-region (beg end) |
| 5715 | (if (not (fboundp 'add-hook)) | 5607 | "Return number of trailing whitespace chars between BEG and END. |
| 5716 | (defun add-hook (hook function &optional append) | 5608 | |
| 5717 | "Add to the value of HOOK the function FUNCTION unless already present. | 5609 | If BEG is bigger than END we return 0." |
| 5718 | \(It becomes the first hook on the list unless optional APPEND is non-nil, in | 5610 | (if (> beg end) |
| 5719 | which case it becomes the last). HOOK should be a symbol, and FUNCTION may be | 5611 | 0 |
| 5720 | any valid function. HOOK's value should be a list of functions, not a single | 5612 | (save-excursion |
| 5721 | function. If HOOK is void, it is first set to nil." | 5613 | (goto-char beg) |
| 5722 | (or (boundp hook) (set hook nil)) | 5614 | (let ((count 0)) |
| 5723 | (or (if (consp function) | 5615 | (while (re-search-forward "[ ][ ]*$" end t) |
| 5724 | ;; Clever way to tell whether a given lambda-expression | 5616 | (goto-char (1+ (match-beginning 0))) |
| 5725 | ;; is equal to anything in the hook. | 5617 | (setq count (1+ count))) |
| 5726 | (let ((tail (assoc (cdr function) (symbol-value hook)))) | 5618 | count)))) |
| 5727 | (equal function tail)) | 5619 | ;;;_ > allout-mark-marker to accommodate divergent emacsen: |
| 5728 | (memq function (symbol-value hook))) | 5620 | (defun allout-mark-marker (&optional force buffer) |
| 5729 | (set hook | 5621 | "Accommodate the different signature for `mark-marker' across Emacsen. |
| 5730 | (if append | 5622 | |
| 5731 | (nconc (symbol-value hook) (list function)) | 5623 | XEmacs takes two optional args, while mainline GNU Emacs does not, |
| 5732 | (cons function (symbol-value hook))))))) | 5624 | so pass them along when appropriate." |
| 5625 | (if (featurep 'xemacs) | ||
| 5626 | (apply 'mark-marker force buffer) | ||
| 5627 | (mark-marker))) | ||
| 5733 | ;;;_ > subst-char-in-string if necessary | 5628 | ;;;_ > subst-char-in-string if necessary |
| 5734 | (if (not (fboundp 'subst-char-in-string)) | 5629 | (if (not (fboundp 'subst-char-in-string)) |
| 5735 | (defun subst-char-in-string (fromchar tochar string &optional inplace) | 5630 | (defun subst-char-in-string (fromchar tochar string &optional inplace) |
| @@ -5742,17 +5637,159 @@ Unless optional argument INPLACE is non-nil, return a new string." | |||
| 5742 | (if (eq (aref newstr i) fromchar) | 5637 | (if (eq (aref newstr i) fromchar) |
| 5743 | (aset newstr i tochar))) | 5638 | (aset newstr i tochar))) |
| 5744 | newstr))) | 5639 | newstr))) |
| 5745 | ;;;_ : my-mark-marker to accommodate divergent emacsen: | 5640 | ;;;_ > wholenump if necessary |
| 5746 | (defun my-mark-marker (&optional force buffer) | 5641 | (if (not (fboundp 'wholenump)) |
| 5747 | "Accommodate the different signature for `mark-marker' across Emacsen. | 5642 | (defalias 'wholenump 'natnump)) |
| 5748 | 5643 | ;;;_ > remove-overlays if necessary | |
| 5749 | XEmacs takes two optional args, while mainline GNU Emacs does not, | 5644 | (if (not (fboundp 'remove-overlays)) |
| 5750 | so pass them along when appropriate." | 5645 | (defun remove-overlays (&optional beg end name val) |
| 5751 | (if (featurep 'xemacs) | 5646 | "Clear BEG and END of overlays whose property NAME has value VAL. |
| 5752 | (apply 'mark-marker force buffer) | 5647 | Overlays might be moved and/or split. |
| 5753 | (mark-marker))) | 5648 | BEG and END default respectively to the beginning and end of buffer." |
| 5754 | 5649 | (unless beg (setq beg (point-min))) | |
| 5755 | ;;;_ #10 Under development | 5650 | (unless end (setq end (point-max))) |
| 5651 | (if (< end beg) | ||
| 5652 | (setq beg (prog1 end (setq end beg)))) | ||
| 5653 | (save-excursion | ||
| 5654 | (dolist (o (overlays-in beg end)) | ||
| 5655 | (when (eq (overlay-get o name) val) | ||
| 5656 | ;; Either push this overlay outside beg...end | ||
| 5657 | ;; or split it to exclude beg...end | ||
| 5658 | ;; or delete it entirely (if it is contained in beg...end). | ||
| 5659 | (if (< (overlay-start o) beg) | ||
| 5660 | (if (> (overlay-end o) end) | ||
| 5661 | (progn | ||
| 5662 | (move-overlay (copy-overlay o) | ||
| 5663 | (overlay-start o) beg) | ||
| 5664 | (move-overlay o end (overlay-end o))) | ||
| 5665 | (move-overlay o (overlay-start o) beg)) | ||
| 5666 | (if (> (overlay-end o) end) | ||
| 5667 | (move-overlay o end (overlay-end o)) | ||
| 5668 | (delete-overlay o))))))) | ||
| 5669 | ) | ||
| 5670 | ;;;_ > copy-overlay if necessary - xemacs ~ 21.4 | ||
| 5671 | (if (not (fboundp 'copy-overlay)) | ||
| 5672 | (defun copy-overlay (o) | ||
| 5673 | "Return a copy of overlay O." | ||
| 5674 | (let ((o1 (make-overlay (overlay-start o) (overlay-end o) | ||
| 5675 | ;; FIXME: there's no easy way to find the | ||
| 5676 | ;; insertion-type of the two markers. | ||
| 5677 | (overlay-buffer o))) | ||
| 5678 | (props (overlay-properties o))) | ||
| 5679 | (while props | ||
| 5680 | (overlay-put o1 (pop props) (pop props))) | ||
| 5681 | o1))) | ||
| 5682 | ;;;_ > add-to-invisibility-spec if necessary - xemacs ~ 21.4 | ||
| 5683 | (if (not (fboundp 'add-to-invisibility-spec)) | ||
| 5684 | (defun add-to-invisibility-spec (element) | ||
| 5685 | "Add ELEMENT to `buffer-invisibility-spec'. | ||
| 5686 | See documentation for `buffer-invisibility-spec' for the kind of elements | ||
| 5687 | that can be added." | ||
| 5688 | (if (eq buffer-invisibility-spec t) | ||
| 5689 | (setq buffer-invisibility-spec (list t))) | ||
| 5690 | (setq buffer-invisibility-spec | ||
| 5691 | (cons element buffer-invisibility-spec)))) | ||
| 5692 | ;;;_ > remove-from-invisibility-spec if necessary - xemacs ~ 21.4 | ||
| 5693 | (if (not (fboundp 'remove-from-invisibility-spec)) | ||
| 5694 | (defun remove-from-invisibility-spec (element) | ||
| 5695 | "Remove ELEMENT from `buffer-invisibility-spec'." | ||
| 5696 | (if (consp buffer-invisibility-spec) | ||
| 5697 | (setq buffer-invisibility-spec (delete element | ||
| 5698 | buffer-invisibility-spec))))) | ||
| 5699 | ;;;_ > move-beginning-of-line if necessary - older emacs, xemacs | ||
| 5700 | (if (not (fboundp 'move-beginning-of-line)) | ||
| 5701 | (defun move-beginning-of-line (arg) | ||
| 5702 | "Move point to beginning of current line as displayed. | ||
| 5703 | \(This disregards invisible newlines such as those | ||
| 5704 | which are part of the text that an image rests on.) | ||
| 5705 | |||
| 5706 | With argument ARG not nil or 1, move forward ARG - 1 lines first. | ||
| 5707 | If point reaches the beginning or end of buffer, it stops there. | ||
| 5708 | To ignore intangibility, bind `inhibit-point-motion-hooks' to t. | ||
| 5709 | |||
| 5710 | This function does not move point across a field boundary unless that | ||
| 5711 | would move point to a different line than the original, unconstrained | ||
| 5712 | result. If N is nil or 1, and a front-sticky field starts at point, | ||
| 5713 | the point does not move. To ignore field boundaries bind | ||
| 5714 | `inhibit-field-text-motion' to t." | ||
| 5715 | (interactive "p") | ||
| 5716 | (or arg (setq arg 1)) | ||
| 5717 | (if (/= arg 1) | ||
| 5718 | (condition-case nil (line-move (1- arg)) (error nil))) | ||
| 5719 | |||
| 5720 | (let ((orig (point))) | ||
| 5721 | ;; Move to beginning-of-line, ignoring fields and invisibles. | ||
| 5722 | (skip-chars-backward "^\n") | ||
| 5723 | (while (and (not (bobp)) (line-move-invisible-p (1- (point)))) | ||
| 5724 | (goto-char (if (featurep 'xemacs) | ||
| 5725 | (previous-property-change (point)) | ||
| 5726 | (previous-char-property-change (point)))) | ||
| 5727 | (skip-chars-backward "^\n")) | ||
| 5728 | (vertical-motion 0) | ||
| 5729 | (if (/= orig (point)) | ||
| 5730 | (goto-char (constrain-to-field (point) orig (/= arg 1) t nil))))) | ||
| 5731 | ) | ||
| 5732 | ;;;_ > move-end-of-line if necessary - older emacs, xemacs | ||
| 5733 | (if (not (fboundp 'move-end-of-line)) | ||
| 5734 | (defun move-end-of-line (arg) | ||
| 5735 | "Move point to end of current line as displayed. | ||
| 5736 | \(This disregards invisible newlines such as those | ||
| 5737 | which are part of the text that an image rests on.) | ||
| 5738 | |||
| 5739 | With argument ARG not nil or 1, move forward ARG - 1 lines first. | ||
| 5740 | If point reaches the beginning or end of buffer, it stops there. | ||
| 5741 | To ignore intangibility, bind `inhibit-point-motion-hooks' to t. | ||
| 5742 | |||
| 5743 | This function does not move point across a field boundary unless that | ||
| 5744 | would move point to a different line than the original, unconstrained | ||
| 5745 | result. If N is nil or 1, and a rear-sticky field ends at point, | ||
| 5746 | the point does not move. To ignore field boundaries bind | ||
| 5747 | `inhibit-field-text-motion' to t." | ||
| 5748 | (interactive "p") | ||
| 5749 | (or arg (setq arg 1)) | ||
| 5750 | (let ((orig (point)) | ||
| 5751 | done) | ||
| 5752 | (while (not done) | ||
| 5753 | (let ((newpos | ||
| 5754 | (save-excursion | ||
| 5755 | (let ((goal-column 0)) | ||
| 5756 | (and (condition-case nil | ||
| 5757 | (or (line-move arg) t) | ||
| 5758 | (error nil)) | ||
| 5759 | (not (bobp)) | ||
| 5760 | (progn | ||
| 5761 | (while (and (not (bobp)) (line-move-invisible-p (1- (point)))) | ||
| 5762 | (goto-char (previous-char-property-change (point)))) | ||
| 5763 | (backward-char 1))) | ||
| 5764 | (point))))) | ||
| 5765 | (goto-char newpos) | ||
| 5766 | (if (and (> (point) newpos) | ||
| 5767 | (eq (preceding-char) ?\n)) | ||
| 5768 | (backward-char 1) | ||
| 5769 | (if (and (> (point) newpos) (not (eobp)) | ||
| 5770 | (not (eq (following-char) ?\n))) | ||
| 5771 | ;; If we skipped something intangible | ||
| 5772 | ;; and now we're not really at eol, | ||
| 5773 | ;; keep going. | ||
| 5774 | (setq arg 1) | ||
| 5775 | (setq done t))))) | ||
| 5776 | (if (/= orig (point)) | ||
| 5777 | (goto-char (constrain-to-field (point) orig (/= arg 1) t | ||
| 5778 | nil))))) | ||
| 5779 | ) | ||
| 5780 | ;;;_ > line-move-invisible-p if necessary | ||
| 5781 | (if (not (fboundp 'line-move-invisible-p)) | ||
| 5782 | (defun line-move-invisible-p (pos) | ||
| 5783 | "Return non-nil if the character after POS is currently invisible." | ||
| 5784 | (let ((prop | ||
| 5785 | (get-char-property pos 'invisible))) | ||
| 5786 | (if (eq buffer-invisibility-spec t) | ||
| 5787 | prop | ||
| 5788 | (or (memq prop buffer-invisibility-spec) | ||
| 5789 | (assq prop buffer-invisibility-spec)))))) | ||
| 5790 | |||
| 5791 | |||
| 5792 | ;;;_ #10 Unfinished | ||
| 5756 | ;;;_ > allout-bullet-isearch (&optional bullet) | 5793 | ;;;_ > allout-bullet-isearch (&optional bullet) |
| 5757 | (defun allout-bullet-isearch (&optional bullet) | 5794 | (defun allout-bullet-isearch (&optional bullet) |
| 5758 | "Isearch \(regexp) for topic with bullet BULLET." | 5795 | "Isearch \(regexp) for topic with bullet BULLET." |
| @@ -5769,8 +5806,9 @@ so pass them along when appropriate." | |||
| 5769 | bullet))) | 5806 | bullet))) |
| 5770 | (isearch-repeat 'forward) | 5807 | (isearch-repeat 'forward) |
| 5771 | (isearch-mode t))) | 5808 | (isearch-mode t))) |
| 5772 | ;;;_ ? Re hooking up with isearch - use isearch-op-fun rather than | 5809 | |
| 5773 | ;;; wrapping the isearch functions. | 5810 | ;;;_ #11 Provide |
| 5811 | (provide 'allout) | ||
| 5774 | 5812 | ||
| 5775 | ;;;_* Local emacs vars. | 5813 | ;;;_* Local emacs vars. |
| 5776 | ;;; The following `allout-layout' local variable setting: | 5814 | ;;; The following `allout-layout' local variable setting: |
diff --git a/lisp/buff-menu.el b/lisp/buff-menu.el index 5388ff9863d..3094da3bfe8 100644 --- a/lisp/buff-menu.el +++ b/lisp/buff-menu.el | |||
| @@ -706,9 +706,9 @@ For more information, see the function `buffer-menu'." | |||
| 706 | list desired-point) | 706 | list desired-point) |
| 707 | (when Buffer-menu-use-header-line | 707 | (when Buffer-menu-use-header-line |
| 708 | (let ((pos 0)) | 708 | (let ((pos 0)) |
| 709 | ;; Turn spaces in the header into stretch specs so they work | 709 | ;; Turn whitespace chars in the header into stretch specs so |
| 710 | ;; regardless of the header-line face. | 710 | ;; they work regardless of the header-line face. |
| 711 | (while (string-match "[ \t]+" header pos) | 711 | (while (string-match "[ \t\n]+" header pos) |
| 712 | (setq pos (match-end 0)) | 712 | (setq pos (match-end 0)) |
| 713 | (put-text-property (match-beginning 0) pos 'display | 713 | (put-text-property (match-beginning 0) pos 'display |
| 714 | ;; Assume fixed-size chars in the buffer. | 714 | ;; Assume fixed-size chars in the buffer. |
| @@ -726,6 +726,7 @@ For more information, see the function `buffer-menu'." | |||
| 726 | (erase-buffer) | 726 | (erase-buffer) |
| 727 | (setq standard-output (current-buffer)) | 727 | (setq standard-output (current-buffer)) |
| 728 | (unless Buffer-menu-use-header-line | 728 | (unless Buffer-menu-use-header-line |
| 729 | ;; Use U+2014 (EM DASH) to underline if possible, else U+002D (HYPHEN-MINUS) | ||
| 729 | (let ((underline (if (char-displayable-p ?—) ?— ?-))) | 730 | (let ((underline (if (char-displayable-p ?—) ?— ?-))) |
| 730 | (insert header | 731 | (insert header |
| 731 | (apply 'string | 732 | (apply 'string |
diff --git a/lisp/calendar/appt.el b/lisp/calendar/appt.el index 571b4ec132a..bce30a1de20 100644 --- a/lisp/calendar/appt.el +++ b/lisp/calendar/appt.el | |||
| @@ -78,6 +78,7 @@ | |||
| 78 | ;; Make sure calendar is loaded when we compile this. | 78 | ;; Make sure calendar is loaded when we compile this. |
| 79 | (require 'calendar) | 79 | (require 'calendar) |
| 80 | 80 | ||
| 81 | (defvar diary-selective-display) | ||
| 81 | 82 | ||
| 82 | ;;;###autoload | 83 | ;;;###autoload |
| 83 | (defcustom appt-issue-message t | 84 | (defcustom appt-issue-message t |
diff --git a/lisp/cus-edit.el b/lisp/cus-edit.el index 3d06bd0fcae..feacc9adf0d 100644 --- a/lisp/cus-edit.el +++ b/lisp/cus-edit.el | |||
| @@ -932,6 +932,7 @@ If given a prefix (or a COMMENT argument), also prompt for a comment." | |||
| 932 | "Set customized value for %s to: " | 932 | "Set customized value for %s to: " |
| 933 | current-prefix-arg)) | 933 | current-prefix-arg)) |
| 934 | (custom-load-symbol variable) | 934 | (custom-load-symbol variable) |
| 935 | (custom-push-theme 'theme-value variable 'user 'set (custom-quote value)) | ||
| 935 | (funcall (or (get variable 'custom-set) 'set-default) variable value) | 936 | (funcall (or (get variable 'custom-set) 'set-default) variable value) |
| 936 | (put variable 'customized-value (list (custom-quote value))) | 937 | (put variable 'customized-value (list (custom-quote value))) |
| 937 | (cond ((string= comment "") | 938 | (cond ((string= comment "") |
| @@ -4166,7 +4167,9 @@ This function does not save the buffer." | |||
| 4166 | (mapatoms | 4167 | (mapatoms |
| 4167 | (lambda (symbol) | 4168 | (lambda (symbol) |
| 4168 | (if (and (get symbol 'saved-value) | 4169 | (if (and (get symbol 'saved-value) |
| 4169 | (eq 'user (car (car-safe (get symbol 'theme-value))))) | 4170 | ;; ignore theme values |
| 4171 | (or (null (get symbol 'theme-value)) | ||
| 4172 | (eq 'user (caar (get symbol 'theme-value))))) | ||
| 4170 | (nconc saved-list (list symbol))))) | 4173 | (nconc saved-list (list symbol))))) |
| 4171 | (setq saved-list (sort (cdr saved-list) 'string<)) | 4174 | (setq saved-list (sort (cdr saved-list) 'string<)) |
| 4172 | (unless (bolp) | 4175 | (unless (bolp) |
diff --git a/lisp/custom.el b/lisp/custom.el index 0f95e3bab73..15b5b4a815c 100644 --- a/lisp/custom.el +++ b/lisp/custom.el | |||
| @@ -653,6 +653,7 @@ default value. Otherwise, set it to nil. | |||
| 653 | To actually save the value, call `custom-save-all'. | 653 | To actually save the value, call `custom-save-all'. |
| 654 | 654 | ||
| 655 | Return non-nil iff the `saved-value' property actually changed." | 655 | Return non-nil iff the `saved-value' property actually changed." |
| 656 | (custom-load-symbol symbol) | ||
| 656 | (let* ((get (or (get symbol 'custom-get) 'default-value)) | 657 | (let* ((get (or (get symbol 'custom-get) 'default-value)) |
| 657 | (value (funcall get symbol)) | 658 | (value (funcall get symbol)) |
| 658 | (saved (get symbol 'saved-value)) | 659 | (saved (get symbol 'saved-value)) |
| @@ -681,6 +682,7 @@ or else if it is different from the standard value, set the | |||
| 681 | default value. Otherwise, set it to nil. | 682 | default value. Otherwise, set it to nil. |
| 682 | 683 | ||
| 683 | Return non-nil iff the `customized-value' property actually changed." | 684 | Return non-nil iff the `customized-value' property actually changed." |
| 685 | (custom-load-symbol symbol) | ||
| 684 | (let* ((get (or (get symbol 'custom-get) 'default-value)) | 686 | (let* ((get (or (get symbol 'custom-get) 'default-value)) |
| 685 | (value (funcall get symbol)) | 687 | (value (funcall get symbol)) |
| 686 | (customized (get symbol 'customized-value)) | 688 | (customized (get symbol 'customized-value)) |
| @@ -690,7 +692,9 @@ Return non-nil iff the `customized-value' property actually changed." | |||
| 690 | (not (equal value (condition-case nil | 692 | (not (equal value (condition-case nil |
| 691 | (eval (car old)) | 693 | (eval (car old)) |
| 692 | (error nil))))) | 694 | (error nil))))) |
| 693 | (put symbol 'customized-value (list (custom-quote value))) | 695 | (progn (put symbol 'customized-value (list (custom-quote value))) |
| 696 | (custom-push-theme 'theme-value symbol 'user 'set | ||
| 697 | (custom-quote value))) | ||
| 694 | (put symbol 'customized-value nil)) | 698 | (put symbol 'customized-value nil)) |
| 695 | ;; Changed? | 699 | ;; Changed? |
| 696 | (not (equal customized (get symbol 'customized-value))))) | 700 | (not (equal customized (get symbol 'customized-value))))) |
diff --git a/lisp/ediff-diff.el b/lisp/ediff-diff.el index 67da6eae25d..62a6386584e 100644 --- a/lisp/ediff-diff.el +++ b/lisp/ediff-diff.el | |||
| @@ -26,7 +26,6 @@ | |||
| 26 | 26 | ||
| 27 | ;;; Code: | 27 | ;;; Code: |
| 28 | 28 | ||
| 29 | (provide 'ediff-diff) | ||
| 30 | 29 | ||
| 31 | ;; compiler pacifier | 30 | ;; compiler pacifier |
| 32 | (defvar ediff-default-variant) | 31 | (defvar ediff-default-variant) |
| @@ -129,13 +128,33 @@ are `-I REGEXP', to ignore changes whose lines match the REGEXP." | |||
| 129 | 128 | ||
| 130 | (defcustom ediff-diff-options "" | 129 | (defcustom ediff-diff-options "" |
| 131 | "*Options to pass to `ediff-diff-program'. | 130 | "*Options to pass to `ediff-diff-program'. |
| 132 | If Unix diff is used as `ediff-diff-program', then the most useful options are | 131 | If Unix diff is used as `ediff-diff-program', then a useful option is |
| 133 | `-w', to ignore space, and `-i', to ignore case of letters. | 132 | `-w', to ignore space, and `-i', to ignore case of letters. |
| 134 | At present, the option `-c' is not allowed." | 133 | Options `-c' and `-i' are not allowed. Case sensitivity can be toggled |
| 134 | interactively using [ediff-toggle-ignore-case]" | ||
| 135 | :set 'ediff-reset-diff-options | 135 | :set 'ediff-reset-diff-options |
| 136 | :type 'string | 136 | :type 'string |
| 137 | :group 'ediff-diff) | 137 | :group 'ediff-diff) |
| 138 | 138 | ||
| 139 | (ediff-defvar-local ediff-ignore-case nil | ||
| 140 | "*If t, skip over difference regions that differ only in letter case. | ||
| 141 | This variable can be set either in .emacs or toggled interactively. | ||
| 142 | Use `setq-default' if setting it in .emacs") | ||
| 143 | |||
| 144 | (defcustom ediff-ignore-case-option "-i" | ||
| 145 | "*Option that causes the diff program to ignore case of letters." | ||
| 146 | :type 'string | ||
| 147 | :group 'ediff-diff) | ||
| 148 | |||
| 149 | (defcustom ediff-ignore-case-option3 "" | ||
| 150 | "*Option that causes the diff3 program to ignore case of letters. | ||
| 151 | GNU diff3 doesn't have such an option." | ||
| 152 | :type 'string | ||
| 153 | :group 'ediff-diff) | ||
| 154 | |||
| 155 | ;; the actual options used in comparison | ||
| 156 | (ediff-defvar-local ediff-actual-diff-options "" "") | ||
| 157 | |||
| 139 | (defcustom ediff-custom-diff-program ediff-diff-program | 158 | (defcustom ediff-custom-diff-program ediff-diff-program |
| 140 | "*Program to use for generating custom diff output for saving it in a file. | 159 | "*Program to use for generating custom diff output for saving it in a file. |
| 141 | This output is not used by Ediff internally." | 160 | This output is not used by Ediff internally." |
| @@ -155,6 +174,10 @@ This output is not used by Ediff internally." | |||
| 155 | :set 'ediff-reset-diff-options | 174 | :set 'ediff-reset-diff-options |
| 156 | :type 'string | 175 | :type 'string |
| 157 | :group 'ediff-diff) | 176 | :group 'ediff-diff) |
| 177 | |||
| 178 | ;; the actual options used in comparison | ||
| 179 | (ediff-defvar-local ediff-actual-diff3-options "" "") | ||
| 180 | |||
| 158 | (defcustom ediff-diff3-ok-lines-regexp | 181 | (defcustom ediff-diff3-ok-lines-regexp |
| 159 | "^\\([1-3]:\\|====\\| \\|.*Warning *:\\|.*No newline\\|.*missing newline\\|^\C-m$\\)" | 182 | "^\\([1-3]:\\|====\\| \\|.*Warning *:\\|.*No newline\\|.*missing newline\\|^\C-m$\\)" |
| 160 | "*Regexp that matches normal output lines from `ediff-diff3-program'. | 183 | "*Regexp that matches normal output lines from `ediff-diff3-program'. |
| @@ -182,7 +205,7 @@ Use `setq-default' if setting it in .emacs") | |||
| 182 | This variable can be set either in .emacs or toggled interactively. | 205 | This variable can be set either in .emacs or toggled interactively. |
| 183 | Use `setq-default' if setting it in .emacs") | 206 | Use `setq-default' if setting it in .emacs") |
| 184 | 207 | ||
| 185 | (ediff-defvar-local ediff-auto-refine-limit 1400 | 208 | (ediff-defvar-local ediff-auto-refine-limit 14000 |
| 186 | "*Auto-refine only the regions of this size \(in bytes\) or less.") | 209 | "*Auto-refine only the regions of this size \(in bytes\) or less.") |
| 187 | 210 | ||
| 188 | ;;; General | 211 | ;;; General |
| @@ -227,9 +250,9 @@ one optional arguments, diff-number to refine.") | |||
| 227 | ;; ediff-setup-diff-regions-function, which can also have the value | 250 | ;; ediff-setup-diff-regions-function, which can also have the value |
| 228 | ;; ediff-setup-diff-regions3, which takes 4 arguments. | 251 | ;; ediff-setup-diff-regions3, which takes 4 arguments. |
| 229 | (defun ediff-setup-diff-regions (file-A file-B file-C) | 252 | (defun ediff-setup-diff-regions (file-A file-B file-C) |
| 230 | ;; looking either for '-c' or a 'c' in a set of clustered non-long options | 253 | ;; looking for '-c', '-i', or a 'c', 'i' among clustered non-long options |
| 231 | (if (string-match "^-c\\| -c\\|-[^- ]+c" ediff-diff-options) | 254 | (if (string-match "^-[ci]\\| -[ci]\\|-[^- ]+[ci]" ediff-diff-options) |
| 232 | (error "Option `-c' is not allowed in `ediff-diff-options'")) | 255 | (error "Options `-c' and `-i' are not allowed in `ediff-diff-options'")) |
| 233 | 256 | ||
| 234 | ;; create, if it doesn't exist | 257 | ;; create, if it doesn't exist |
| 235 | (or (ediff-buffer-live-p ediff-diff-buffer) | 258 | (or (ediff-buffer-live-p ediff-diff-buffer) |
| @@ -266,7 +289,7 @@ one optional arguments, diff-number to refine.") | |||
| 266 | (ediff-exec-process ediff-diff-program | 289 | (ediff-exec-process ediff-diff-program |
| 267 | diff-buffer | 290 | diff-buffer |
| 268 | 'synchronize | 291 | 'synchronize |
| 269 | ediff-diff-options file1 file2) | 292 | ediff-actual-diff-options file1 file2) |
| 270 | (message "") | 293 | (message "") |
| 271 | (ediff-with-current-buffer diff-buffer | 294 | (ediff-with-current-buffer diff-buffer |
| 272 | (buffer-size)))))) | 295 | (buffer-size)))))) |
| @@ -284,7 +307,9 @@ one optional arguments, diff-number to refine.") | |||
| 284 | (let (diff3-job diff-program diff-options ok-regexp diff-list) | 307 | (let (diff3-job diff-program diff-options ok-regexp diff-list) |
| 285 | (setq diff3-job ediff-3way-job | 308 | (setq diff3-job ediff-3way-job |
| 286 | diff-program (if diff3-job ediff-diff3-program ediff-diff-program) | 309 | diff-program (if diff3-job ediff-diff3-program ediff-diff-program) |
| 287 | diff-options (if diff3-job ediff-diff3-options ediff-diff-options) | 310 | diff-options (if diff3-job |
| 311 | ediff-actual-diff3-options | ||
| 312 | ediff-actual-diff-options) | ||
| 288 | ok-regexp (if diff3-job | 313 | ok-regexp (if diff3-job |
| 289 | ediff-diff3-ok-lines-regexp | 314 | ediff-diff3-ok-lines-regexp |
| 290 | ediff-diff-ok-lines-regexp)) | 315 | ediff-diff-ok-lines-regexp)) |
| @@ -366,11 +391,14 @@ one optional arguments, diff-number to refine.") | |||
| 366 | (B-buffer ediff-buffer-B) | 391 | (B-buffer ediff-buffer-B) |
| 367 | (C-buffer ediff-buffer-C) | 392 | (C-buffer ediff-buffer-C) |
| 368 | (a-prev 1) ; this is needed to set the first diff line correctly | 393 | (a-prev 1) ; this is needed to set the first diff line correctly |
| 394 | (a-prev-pt nil) | ||
| 369 | (b-prev 1) | 395 | (b-prev 1) |
| 396 | (b-prev-pt nil) | ||
| 370 | (c-prev 1) | 397 | (c-prev 1) |
| 398 | (c-prev-pt nil) | ||
| 371 | diff-list shift-A shift-B | 399 | diff-list shift-A shift-B |
| 372 | ) | 400 | ) |
| 373 | 401 | ||
| 374 | ;; diff list contains word numbers, unless changed later | 402 | ;; diff list contains word numbers, unless changed later |
| 375 | (setq diff-list (cons (if word-mode 'words 'points) | 403 | (setq diff-list (cons (if word-mode 'words 'points) |
| 376 | diff-list)) | 404 | diff-list)) |
| @@ -382,7 +410,7 @@ one optional arguments, diff-number to refine.") | |||
| 382 | shift-B | 410 | shift-B |
| 383 | (ediff-overlay-start | 411 | (ediff-overlay-start |
| 384 | (ediff-get-value-according-to-buffer-type 'B bounds)))) | 412 | (ediff-get-value-according-to-buffer-type 'B bounds)))) |
| 385 | 413 | ||
| 386 | ;; reset point in buffers A/B/C | 414 | ;; reset point in buffers A/B/C |
| 387 | (ediff-with-current-buffer A-buffer | 415 | (ediff-with-current-buffer A-buffer |
| 388 | (goto-char (if shift-A shift-A (point-min)))) | 416 | (goto-char (if shift-A shift-A (point-min)))) |
| @@ -466,11 +494,13 @@ one optional arguments, diff-number to refine.") | |||
| 466 | ;; we must disable and then restore longlines-mode | 494 | ;; we must disable and then restore longlines-mode |
| 467 | (if (eq longlines-mode-val 1) | 495 | (if (eq longlines-mode-val 1) |
| 468 | (longlines-mode 0)) | 496 | (longlines-mode 0)) |
| 497 | (goto-char (or a-prev-pt shift-A (point-min))) | ||
| 469 | (forward-line (- a-begin a-prev)) | 498 | (forward-line (- a-begin a-prev)) |
| 470 | (setq a-begin-pt (point)) | 499 | (setq a-begin-pt (point)) |
| 471 | (forward-line (- a-end a-begin)) | 500 | (forward-line (- a-end a-begin)) |
| 472 | (setq a-end-pt (point) | 501 | (setq a-end-pt (point) |
| 473 | a-prev a-end) | 502 | a-prev a-end |
| 503 | a-prev-pt a-end-pt) | ||
| 474 | (if (eq longlines-mode-val 1) | 504 | (if (eq longlines-mode-val 1) |
| 475 | (longlines-mode longlines-mode-val)) | 505 | (longlines-mode longlines-mode-val)) |
| 476 | )) | 506 | )) |
| @@ -479,11 +509,13 @@ one optional arguments, diff-number to refine.") | |||
| 479 | (if (and (boundp 'longlines-mode) longlines-mode) 1 0))) | 509 | (if (and (boundp 'longlines-mode) longlines-mode) 1 0))) |
| 480 | (if (eq longlines-mode-val 1) | 510 | (if (eq longlines-mode-val 1) |
| 481 | (longlines-mode 0)) | 511 | (longlines-mode 0)) |
| 512 | (goto-char (or b-prev-pt shift-B (point-min))) | ||
| 482 | (forward-line (- b-begin b-prev)) | 513 | (forward-line (- b-begin b-prev)) |
| 483 | (setq b-begin-pt (point)) | 514 | (setq b-begin-pt (point)) |
| 484 | (forward-line (- b-end b-begin)) | 515 | (forward-line (- b-end b-begin)) |
| 485 | (setq b-end-pt (point) | 516 | (setq b-end-pt (point) |
| 486 | b-prev b-end) | 517 | b-prev b-end |
| 518 | b-prev-pt b-end-pt) | ||
| 487 | (if (eq longlines-mode-val 1) | 519 | (if (eq longlines-mode-val 1) |
| 488 | (longlines-mode longlines-mode-val)) | 520 | (longlines-mode longlines-mode-val)) |
| 489 | )) | 521 | )) |
| @@ -493,11 +525,13 @@ one optional arguments, diff-number to refine.") | |||
| 493 | (if (and (boundp 'longlines-mode) longlines-mode) 1 0))) | 525 | (if (and (boundp 'longlines-mode) longlines-mode) 1 0))) |
| 494 | (if (eq longlines-mode-val 1) | 526 | (if (eq longlines-mode-val 1) |
| 495 | (longlines-mode 0)) | 527 | (longlines-mode 0)) |
| 528 | (goto-char (or c-prev-pt (point-min))) | ||
| 496 | (forward-line (- c-begin c-prev)) | 529 | (forward-line (- c-begin c-prev)) |
| 497 | (setq c-begin-pt (point)) | 530 | (setq c-begin-pt (point)) |
| 498 | (forward-line (- c-end c-begin)) | 531 | (forward-line (- c-end c-begin)) |
| 499 | (setq c-end-pt (point) | 532 | (setq c-end-pt (point) |
| 500 | c-prev c-end) | 533 | c-prev c-end |
| 534 | c-prev-pt c-end-pt) | ||
| 501 | (if (eq longlines-mode-val 1) | 535 | (if (eq longlines-mode-val 1) |
| 502 | (longlines-mode longlines-mode-val)) | 536 | (longlines-mode longlines-mode-val)) |
| 503 | ))) | 537 | ))) |
| @@ -987,8 +1021,11 @@ delimiter regions")) | |||
| 987 | (C-buffer ediff-buffer-C) | 1021 | (C-buffer ediff-buffer-C) |
| 988 | (anc-buffer ediff-ancestor-buffer) | 1022 | (anc-buffer ediff-ancestor-buffer) |
| 989 | (a-prev 1) ; needed to set the first diff line correctly | 1023 | (a-prev 1) ; needed to set the first diff line correctly |
| 1024 | (a-prev-pt nil) | ||
| 990 | (b-prev 1) | 1025 | (b-prev 1) |
| 1026 | (b-prev-pt nil) | ||
| 991 | (c-prev 1) | 1027 | (c-prev 1) |
| 1028 | (c-prev-pt nil) | ||
| 992 | (anc-prev 1) | 1029 | (anc-prev 1) |
| 993 | diff-list shift-A shift-B shift-C | 1030 | diff-list shift-A shift-B shift-C |
| 994 | ) | 1031 | ) |
| @@ -1089,11 +1126,13 @@ delimiter regions")) | |||
| 1089 | ;; we must disable and then restore longlines-mode | 1126 | ;; we must disable and then restore longlines-mode |
| 1090 | (if (eq longlines-mode-val 1) | 1127 | (if (eq longlines-mode-val 1) |
| 1091 | (longlines-mode 0)) | 1128 | (longlines-mode 0)) |
| 1129 | (goto-char (or a-prev-pt shift-A (point-min))) | ||
| 1092 | (forward-line (- a-begin a-prev)) | 1130 | (forward-line (- a-begin a-prev)) |
| 1093 | (setq a-begin-pt (point)) | 1131 | (setq a-begin-pt (point)) |
| 1094 | (forward-line (- a-end a-begin)) | 1132 | (forward-line (- a-end a-begin)) |
| 1095 | (setq a-end-pt (point) | 1133 | (setq a-end-pt (point) |
| 1096 | a-prev a-end) | 1134 | a-prev a-end |
| 1135 | a-prev-pt a-end-pt) | ||
| 1097 | (if (eq longlines-mode-val 1) | 1136 | (if (eq longlines-mode-val 1) |
| 1098 | (longlines-mode longlines-mode-val)) | 1137 | (longlines-mode longlines-mode-val)) |
| 1099 | )) | 1138 | )) |
| @@ -1102,11 +1141,13 @@ delimiter regions")) | |||
| 1102 | (if (and (boundp 'longlines-mode) longlines-mode) 1 0))) | 1141 | (if (and (boundp 'longlines-mode) longlines-mode) 1 0))) |
| 1103 | (if (eq longlines-mode-val 1) | 1142 | (if (eq longlines-mode-val 1) |
| 1104 | (longlines-mode 0)) | 1143 | (longlines-mode 0)) |
| 1144 | (goto-char (or b-prev-pt shift-B (point-min))) | ||
| 1105 | (forward-line (- b-begin b-prev)) | 1145 | (forward-line (- b-begin b-prev)) |
| 1106 | (setq b-begin-pt (point)) | 1146 | (setq b-begin-pt (point)) |
| 1107 | (forward-line (- b-end b-begin)) | 1147 | (forward-line (- b-end b-begin)) |
| 1108 | (setq b-end-pt (point) | 1148 | (setq b-end-pt (point) |
| 1109 | b-prev b-end) | 1149 | b-prev b-end |
| 1150 | b-prev-pt b-end-pt) | ||
| 1110 | (if (eq longlines-mode-val 1) | 1151 | (if (eq longlines-mode-val 1) |
| 1111 | (longlines-mode longlines-mode-val)) | 1152 | (longlines-mode longlines-mode-val)) |
| 1112 | )) | 1153 | )) |
| @@ -1115,11 +1156,13 @@ delimiter regions")) | |||
| 1115 | (if (and (boundp 'longlines-mode) longlines-mode) 1 0))) | 1156 | (if (and (boundp 'longlines-mode) longlines-mode) 1 0))) |
| 1116 | (if (eq longlines-mode-val 1) | 1157 | (if (eq longlines-mode-val 1) |
| 1117 | (longlines-mode 0)) | 1158 | (longlines-mode 0)) |
| 1159 | (goto-char (or c-prev-pt shift-C (point-min))) | ||
| 1118 | (forward-line (- c-begin c-prev)) | 1160 | (forward-line (- c-begin c-prev)) |
| 1119 | (setq c-begin-pt (point)) | 1161 | (setq c-begin-pt (point)) |
| 1120 | (forward-line (- c-end c-begin)) | 1162 | (forward-line (- c-end c-begin)) |
| 1121 | (setq c-end-pt (point) | 1163 | (setq c-end-pt (point) |
| 1122 | c-prev c-end) | 1164 | c-prev c-end |
| 1165 | c-prev-pt c-end-pt) | ||
| 1123 | (if (eq longlines-mode-val 1) | 1166 | (if (eq longlines-mode-val 1) |
| 1124 | (longlines-mode longlines-mode-val)) | 1167 | (longlines-mode longlines-mode-val)) |
| 1125 | )) | 1168 | )) |
| @@ -1171,13 +1214,17 @@ delimiter regions")) | |||
| 1171 | ;; File-C is either the third file to compare (in case of 3-way comparison) | 1214 | ;; File-C is either the third file to compare (in case of 3-way comparison) |
| 1172 | ;; or it is the ancestor file. | 1215 | ;; or it is the ancestor file. |
| 1173 | (defun ediff-setup-diff-regions3 (file-A file-B file-C) | 1216 | (defun ediff-setup-diff-regions3 (file-A file-B file-C) |
| 1217 | ;; looking for '-i' or a 'i' among clustered non-long options | ||
| 1218 | (if (string-match "^-i\\| -i\\|-[^- ]+i" ediff-diff-options) | ||
| 1219 | (error "Option `-i' is not allowed in `ediff-diff3-options'")) | ||
| 1220 | |||
| 1174 | (or (ediff-buffer-live-p ediff-diff-buffer) | 1221 | (or (ediff-buffer-live-p ediff-diff-buffer) |
| 1175 | (setq ediff-diff-buffer | 1222 | (setq ediff-diff-buffer |
| 1176 | (get-buffer-create (ediff-unique-buffer-name "*ediff-diff" "*")))) | 1223 | (get-buffer-create (ediff-unique-buffer-name "*ediff-diff" "*")))) |
| 1177 | 1224 | ||
| 1178 | (message "Computing differences ...") | 1225 | (message "Computing differences ...") |
| 1179 | (ediff-exec-process ediff-diff3-program ediff-diff-buffer 'synchronize | 1226 | (ediff-exec-process ediff-diff3-program ediff-diff-buffer 'synchronize |
| 1180 | ediff-diff3-options file-A file-B file-C) | 1227 | ediff-actual-diff3-options file-A file-B file-C) |
| 1181 | 1228 | ||
| 1182 | (ediff-prepare-error-list ediff-diff3-ok-lines-regexp ediff-diff-buffer) | 1229 | (ediff-prepare-error-list ediff-diff3-ok-lines-regexp ediff-diff-buffer) |
| 1183 | ;;(message "Computing differences ... done") | 1230 | ;;(message "Computing differences ... done") |
| @@ -1471,6 +1518,35 @@ affects only files whose names match the expression." | |||
| 1471 | (setq file-list-list (cdr file-list-list))) | 1518 | (setq file-list-list (cdr file-list-list))) |
| 1472 | (reverse result))) | 1519 | (reverse result))) |
| 1473 | 1520 | ||
| 1521 | ;; Ignore case handling - some ideas from drew.adams@@oracle.com | ||
| 1522 | (defun ediff-toggle-ignore-case () | ||
| 1523 | (interactive) | ||
| 1524 | (ediff-barf-if-not-control-buffer) | ||
| 1525 | (setq ediff-ignore-case (not ediff-ignore-case)) | ||
| 1526 | (cond (ediff-ignore-case | ||
| 1527 | (setq ediff-actual-diff-options | ||
| 1528 | (concat ediff-diff-options " " ediff-ignore-case-option) | ||
| 1529 | ediff-actual-diff3-options | ||
| 1530 | (concat ediff-diff3-options " " ediff-ignore-case-option3)) | ||
| 1531 | (message "Ignoring regions that differ only in case")) | ||
| 1532 | (t | ||
| 1533 | (setq ediff-actual-diff-options ediff-diff-options | ||
| 1534 | ediff-actual-diff3-options ediff-diff3-options) | ||
| 1535 | (message "Ignoring case differences turned OFF"))) | ||
| 1536 | (cond (ediff-merge-job | ||
| 1537 | (message "Ignoring letter case is too dangerous in merge jobs")) | ||
| 1538 | ((and ediff-diff3-job (string= ediff-ignore-case-option3 "")) | ||
| 1539 | (message "Ignoring letter case is not supported by this diff3 program")) | ||
| 1540 | ((and (not ediff-3way-job) (string= ediff-ignore-case-option "")) | ||
| 1541 | (message "Ignoring letter case is not supported by this diff program")) | ||
| 1542 | (t | ||
| 1543 | (sit-for 1) | ||
| 1544 | (ediff-update-diffs))) | ||
| 1545 | ) | ||
| 1546 | |||
| 1547 | |||
| 1548 | (provide 'ediff-diff) | ||
| 1549 | |||
| 1474 | 1550 | ||
| 1475 | ;;; Local Variables: | 1551 | ;;; Local Variables: |
| 1476 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) | 1552 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) |
diff --git a/lisp/ediff-help.el b/lisp/ediff-help.el index cc266e3c8a3..d5f505c7de3 100644 --- a/lisp/ediff-help.el +++ b/lisp/ediff-help.el | |||
| @@ -26,7 +26,6 @@ | |||
| 26 | 26 | ||
| 27 | ;;; Code: | 27 | ;;; Code: |
| 28 | 28 | ||
| 29 | (provide 'ediff-help) | ||
| 30 | 29 | ||
| 31 | ;; Compiler pacifier start | 30 | ;; Compiler pacifier start |
| 32 | (defvar ediff-multiframe) | 31 | (defvar ediff-multiframe) |
| @@ -61,8 +60,8 @@ For help on a specific command: Click Button 2 over it; or | |||
| 61 | p,DEL -previous diff | | -vert/horiz split | xy -copy buf X's region to Y | 60 | p,DEL -previous diff | | -vert/horiz split | xy -copy buf X's region to Y |
| 62 | n,SPC -next diff | h -hilighting | rx -restore buf X's old diff | 61 | n,SPC -next diff | h -hilighting | rx -restore buf X's old diff |
| 63 | j -jump to diff | @ -auto-refinement | * -refine current region | 62 | j -jump to diff | @ -auto-refinement | * -refine current region |
| 64 | gx -goto X's point| | ! -update diff regions | 63 | gx -goto X's point| ## -ignore whitespace | ! -update diff regions |
| 65 | C-l -recenter | ## -ignore whitespace | | 64 | C-l -recenter | #c -ignore case | |
| 66 | v/V -scroll up/dn | #f/#h -focus/hide regions | wx -save buf X | 65 | v/V -scroll up/dn | #f/#h -focus/hide regions | wx -save buf X |
| 67 | </> -scroll lt/rt | X -read-only in buf X | wd -save diff output | 66 | </> -scroll lt/rt | X -read-only in buf X | wd -save diff output |
| 68 | ~ -rotate buffers| m -wide display | | 67 | ~ -rotate buffers| m -wide display | |
| @@ -75,8 +74,8 @@ Normally, not a user option. See `ediff-help-message' for details.") | |||
| 75 | p,DEL -previous diff | | -vert/horiz split |a/b -copy A/B's region to B/A | 74 | p,DEL -previous diff | | -vert/horiz split |a/b -copy A/B's region to B/A |
| 76 | n,SPC -next diff | h -hilighting | rx -restore buf X's old diff | 75 | n,SPC -next diff | h -hilighting | rx -restore buf X's old diff |
| 77 | j -jump to diff | @ -auto-refinement | * -refine current region | 76 | j -jump to diff | @ -auto-refinement | * -refine current region |
| 78 | gx -goto X's point| | ! -update diff regions | 77 | gx -goto X's point| ## -ignore whitespace | ! -update diff regions |
| 79 | C-l -recenter | ## -ignore whitespace | | 78 | C-l -recenter | #c -ignore case | |
| 80 | v/V -scroll up/dn | #f/#h -focus/hide regions | wx -save buf X | 79 | v/V -scroll up/dn | #f/#h -focus/hide regions | wx -save buf X |
| 81 | </> -scroll lt/rt | X -read-only in buf X | wd -save diff output | 80 | </> -scroll lt/rt | X -read-only in buf X | wd -save diff output |
| 82 | ~ -swap variants | m -wide display | | 81 | ~ -swap variants | m -wide display | |
| @@ -89,8 +88,8 @@ Normally, not a user option. See `ediff-help-message' for details.") | |||
| 89 | p,DEL -previous diff | | -vert/horiz split |a/b -copy A/B's region to B/A | 88 | p,DEL -previous diff | | -vert/horiz split |a/b -copy A/B's region to B/A |
| 90 | n,SPC -next diff | h -hilighting | rx -restore buf X's old diff | 89 | n,SPC -next diff | h -hilighting | rx -restore buf X's old diff |
| 91 | j -jump to diff | @ -auto-refinement | * -refine current region | 90 | j -jump to diff | @ -auto-refinement | * -refine current region |
| 92 | gx -goto X's point| % -narrow/widen buffs | ! -update diff regions | 91 | gx -goto X's point| ## -ignore whitespace | ! -update diff regions |
| 93 | C-l -recenter | ## -ignore whitespace | | 92 | C-l -recenter | #c -ignore case | % -narrow/widen buffs |
| 94 | v/V -scroll up/dn | #f/#h -focus/hide regions | wx -save buf X | 93 | v/V -scroll up/dn | #f/#h -focus/hide regions | wx -save buf X |
| 95 | </> -scroll lt/rt | X -read-only in buf X | wd -save diff output | 94 | </> -scroll lt/rt | X -read-only in buf X | wd -save diff output |
| 96 | ~ -swap variants | m -wide display | | 95 | ~ -swap variants | m -wide display | |
| @@ -103,8 +102,8 @@ Normally, not a user option. See `ediff-help-message' for details.") | |||
| 103 | p,DEL -previous diff | | -vert/horiz split | xy -copy buf X's region to Y | 102 | p,DEL -previous diff | | -vert/horiz split | xy -copy buf X's region to Y |
| 104 | n,SPC -next diff | h -hilighting | rx -restore buf X's old diff | 103 | n,SPC -next diff | h -hilighting | rx -restore buf X's old diff |
| 105 | j -jump to diff | | | 104 | j -jump to diff | | |
| 106 | gx -goto X's point| % -narrow/widen buffs | ! -recompute diffs | 105 | gx -goto X's point| % -narrow/widen buffs | ! -recompute diffs |
| 107 | C-l -recenter | | | 106 | C-l -recenter | #c -ignore case | |
| 108 | v/V -scroll up/dn | #f/#h -focus/hide regions | wx -save buf X | 107 | v/V -scroll up/dn | #f/#h -focus/hide regions | wx -save buf X |
| 109 | </> -scroll lt/rt | X -read-only in buf X | wd -save diff output | 108 | </> -scroll lt/rt | X -read-only in buf X | wd -save diff output |
| 110 | ~ -swap variants | m -wide display | | 109 | ~ -swap variants | m -wide display | |
| @@ -228,6 +227,7 @@ the value of this variable and the variables `ediff-help-message-*' in | |||
| 228 | ((string= cmd "r") (re-search-forward "^`r'")) | 227 | ((string= cmd "r") (re-search-forward "^`r'")) |
| 229 | ((string= cmd "rx") (re-search-forward "^`ra'")) | 228 | ((string= cmd "rx") (re-search-forward "^`ra'")) |
| 230 | ((string= cmd "##") (re-search-forward "^`##'")) | 229 | ((string= cmd "##") (re-search-forward "^`##'")) |
| 230 | ((string= cmd "#c") (re-search-forward "^`#c'")) | ||
| 231 | ((string= cmd "#f/#h") (re-search-forward "^`#f'")) | 231 | ((string= cmd "#f/#h") (re-search-forward "^`#f'")) |
| 232 | ((string= cmd "X") (re-search-forward "^`A'")) | 232 | ((string= cmd "X") (re-search-forward "^`A'")) |
| 233 | ((string= cmd "v/V") (re-search-forward "^`v'")) | 233 | ((string= cmd "v/V") (re-search-forward "^`v'")) |
| @@ -325,5 +325,8 @@ the value of this variable and the variables `ediff-help-message-*' in | |||
| 325 | (customize-group "ediff")) | 325 | (customize-group "ediff")) |
| 326 | 326 | ||
| 327 | 327 | ||
| 328 | (provide 'ediff-help) | ||
| 329 | |||
| 330 | |||
| 328 | ;;; arch-tag: 05659813-7fcf-4274-964f-d2f577431a9d | 331 | ;;; arch-tag: 05659813-7fcf-4274-964f-d2f577431a9d |
| 329 | ;;; ediff-help.el ends here | 332 | ;;; ediff-help.el ends here |
diff --git a/lisp/ediff-hook.el b/lisp/ediff-hook.el index 1b86e2f8f62..fcf261efd06 100644 --- a/lisp/ediff-hook.el +++ b/lisp/ediff-hook.el | |||
| @@ -371,5 +371,6 @@ | |||
| 371 | 371 | ||
| 372 | (provide 'ediff-hook) | 372 | (provide 'ediff-hook) |
| 373 | 373 | ||
| 374 | |||
| 374 | ;;; arch-tag: 512f8656-8a4b-4789-af5d-5c6144498df3 | 375 | ;;; arch-tag: 512f8656-8a4b-4789-af5d-5c6144498df3 |
| 375 | ;;; ediff-hook.el ends here | 376 | ;;; ediff-hook.el ends here |
diff --git a/lisp/ediff-init.el b/lisp/ediff-init.el index 4897ffd2e59..2fc0ceefe4d 100644 --- a/lisp/ediff-init.el +++ b/lisp/ediff-init.el | |||
| @@ -1867,6 +1867,7 @@ Unless optional argument INPLACE is non-nil, return a new string." | |||
| 1867 | (set-buffer ,old-buffer) | 1867 | (set-buffer ,old-buffer) |
| 1868 | (set-syntax-table ,old-table))))))) | 1868 | (set-syntax-table ,old-table))))))) |
| 1869 | 1869 | ||
| 1870 | |||
| 1870 | (provide 'ediff-init) | 1871 | (provide 'ediff-init) |
| 1871 | 1872 | ||
| 1872 | 1873 | ||
diff --git a/lisp/ediff-merg.el b/lisp/ediff-merg.el index 7f0eea2cf09..92f462c0181 100644 --- a/lisp/ediff-merg.el +++ b/lisp/ediff-merg.el | |||
| @@ -26,7 +26,6 @@ | |||
| 26 | 26 | ||
| 27 | ;;; Code: | 27 | ;;; Code: |
| 28 | 28 | ||
| 29 | (provide 'ediff-merg) | ||
| 30 | 29 | ||
| 31 | ;; compiler pacifier | 30 | ;; compiler pacifier |
| 32 | (defvar ediff-window-A) | 31 | (defvar ediff-window-A) |
| @@ -390,6 +389,9 @@ Combining is done according to the specifications in variable | |||
| 390 | ))) | 389 | ))) |
| 391 | 390 | ||
| 392 | 391 | ||
| 392 | (provide 'ediff-merg) | ||
| 393 | |||
| 394 | |||
| 393 | ;;; Local Variables: | 395 | ;;; Local Variables: |
| 394 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) | 396 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) |
| 395 | ;;; eval: (put 'ediff-with-current-buffer 'lisp-indent-hook 1) | 397 | ;;; eval: (put 'ediff-with-current-buffer 'lisp-indent-hook 1) |
diff --git a/lisp/ediff-mult.el b/lisp/ediff-mult.el index c24e32a2124..0bbd3298c7a 100644 --- a/lisp/ediff-mult.el +++ b/lisp/ediff-mult.el | |||
| @@ -104,7 +104,6 @@ | |||
| 104 | 104 | ||
| 105 | ;;; Code: | 105 | ;;; Code: |
| 106 | 106 | ||
| 107 | (provide 'ediff-mult) | ||
| 108 | 107 | ||
| 109 | (defgroup ediff-mult nil | 108 | (defgroup ediff-mult nil |
| 110 | "Multi-file and multi-buffer processing in Ediff." | 109 | "Multi-file and multi-buffer processing in Ediff." |
| @@ -123,7 +122,6 @@ | |||
| 123 | ;; end pacifier | 122 | ;; end pacifier |
| 124 | 123 | ||
| 125 | (require 'ediff-init) | 124 | (require 'ediff-init) |
| 126 | (require 'ediff-util) | ||
| 127 | 125 | ||
| 128 | ;; meta-buffer | 126 | ;; meta-buffer |
| 129 | (ediff-defvar-local ediff-meta-buffer nil "") | 127 | (ediff-defvar-local ediff-meta-buffer nil "") |
| @@ -1473,6 +1471,7 @@ Useful commands: | |||
| 1473 | (ediff-overlay-put overl 'highlight t)) | 1471 | (ediff-overlay-put overl 'highlight t)) |
| 1474 | (ediff-overlay-put overl 'ediff-meta-info prop) | 1472 | (ediff-overlay-put overl 'ediff-meta-info prop) |
| 1475 | (ediff-overlay-put overl 'invisible hidden) | 1473 | (ediff-overlay-put overl 'invisible hidden) |
| 1474 | (ediff-overlay-put overl 'follow-link t) | ||
| 1476 | (if (numberp session-number) | 1475 | (if (numberp session-number) |
| 1477 | (ediff-overlay-put overl 'ediff-meta-session-number session-number)))) | 1476 | (ediff-overlay-put overl 'ediff-meta-session-number session-number)))) |
| 1478 | 1477 | ||
| @@ -2384,6 +2383,8 @@ for operation, or simply indicate which are equal files. If it is nil, then | |||
| 2384 | )) | 2383 | )) |
| 2385 | 2384 | ||
| 2386 | 2385 | ||
| 2386 | (provide 'ediff-mult) | ||
| 2387 | |||
| 2387 | 2388 | ||
| 2388 | ;;; Local Variables: | 2389 | ;;; Local Variables: |
| 2389 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) | 2390 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) |
diff --git a/lisp/ediff-ptch.el b/lisp/ediff-ptch.el index 9c5c75d847c..b911c33f0fb 100644 --- a/lisp/ediff-ptch.el +++ b/lisp/ediff-ptch.el | |||
| @@ -26,7 +26,6 @@ | |||
| 26 | 26 | ||
| 27 | ;;; Code: | 27 | ;;; Code: |
| 28 | 28 | ||
| 29 | (provide 'ediff-ptch) | ||
| 30 | 29 | ||
| 31 | (defgroup ediff-ptch nil | 30 | (defgroup ediff-ptch nil |
| 32 | "Ediff patch support." | 31 | "Ediff patch support." |
| @@ -844,6 +843,8 @@ you can still examine the changes via M-x ediff-files" | |||
| 844 | 843 | ||
| 845 | 844 | ||
| 846 | 845 | ||
| 846 | (provide 'ediff-ptch) | ||
| 847 | |||
| 847 | 848 | ||
| 848 | ;;; Local Variables: | 849 | ;;; Local Variables: |
| 849 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) | 850 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) |
diff --git a/lisp/ediff-util.el b/lisp/ediff-util.el index feb7b69d7b6..dff3c6bee61 100644 --- a/lisp/ediff-util.el +++ b/lisp/ediff-util.el | |||
| @@ -26,7 +26,6 @@ | |||
| 26 | 26 | ||
| 27 | ;;; Code: | 27 | ;;; Code: |
| 28 | 28 | ||
| 29 | (provide 'ediff-util) | ||
| 30 | 29 | ||
| 31 | ;; Compiler pacifier | 30 | ;; Compiler pacifier |
| 32 | (defvar ediff-patch-diagnostics) | 31 | (defvar ediff-patch-diagnostics) |
| @@ -49,6 +48,7 @@ | |||
| 49 | 48 | ||
| 50 | (eval-when-compile | 49 | (eval-when-compile |
| 51 | (let ((load-path (cons (expand-file-name ".") load-path))) | 50 | (let ((load-path (cons (expand-file-name ".") load-path))) |
| 51 | (provide 'ediff-util) ; to break recursive load cycle | ||
| 52 | (or (featurep 'ediff-init) | 52 | (or (featurep 'ediff-init) |
| 53 | (load "ediff-init.el" nil nil 'nosuffix)) | 53 | (load "ediff-init.el" nil nil 'nosuffix)) |
| 54 | (or (featurep 'ediff-help) | 54 | (or (featurep 'ediff-help) |
| @@ -234,6 +234,7 @@ to invocation.") | |||
| 234 | (define-key ediff-mode-map "#" nil) | 234 | (define-key ediff-mode-map "#" nil) |
| 235 | (define-key ediff-mode-map "#h" 'ediff-toggle-regexp-match) | 235 | (define-key ediff-mode-map "#h" 'ediff-toggle-regexp-match) |
| 236 | (define-key ediff-mode-map "#f" 'ediff-toggle-regexp-match) | 236 | (define-key ediff-mode-map "#f" 'ediff-toggle-regexp-match) |
| 237 | (define-key ediff-mode-map "#c" 'ediff-toggle-ignore-case) | ||
| 237 | (or ediff-word-mode | 238 | (or ediff-word-mode |
| 238 | (define-key ediff-mode-map "##" 'ediff-toggle-skip-similar)) | 239 | (define-key ediff-mode-map "##" 'ediff-toggle-skip-similar)) |
| 239 | (define-key ediff-mode-map "o" nil) | 240 | (define-key ediff-mode-map "o" nil) |
| @@ -1133,7 +1134,7 @@ of the current buffer." | |||
| 1133 | ;; )) | 1134 | ;; )) |
| 1134 | 1135 | ||
| 1135 | 1136 | ||
| 1136 | (defsubst ediff-file-checked-out-p (file) | 1137 | (defun ediff-file-checked-out-p (file) |
| 1137 | (or (not (featurep 'vc-hooks)) | 1138 | (or (not (featurep 'vc-hooks)) |
| 1138 | (and (vc-backend file) | 1139 | (and (vc-backend file) |
| 1139 | (if (fboundp 'vc-state) | 1140 | (if (fboundp 'vc-state) |
| @@ -1143,7 +1144,7 @@ of the current buffer." | |||
| 1143 | (vc-locking-user file)) | 1144 | (vc-locking-user file)) |
| 1144 | ))) | 1145 | ))) |
| 1145 | 1146 | ||
| 1146 | (defsubst ediff-file-checked-in-p (file) | 1147 | (defun ediff-file-checked-in-p (file) |
| 1147 | (and (featurep 'vc-hooks) | 1148 | (and (featurep 'vc-hooks) |
| 1148 | ;; CVS files are considered not checked in | 1149 | ;; CVS files are considered not checked in |
| 1149 | (not (memq (vc-backend file) '(nil CVS))) | 1150 | (not (memq (vc-backend file) '(nil CVS))) |
| @@ -3079,7 +3080,7 @@ Hit \\[ediff-recenter] to reset the windows afterward." | |||
| 3079 | ))) | 3080 | ))) |
| 3080 | 3081 | ||
| 3081 | 3082 | ||
| 3082 | (defsubst ediff-highlight-diff (n) | 3083 | (defun ediff-highlight-diff (n) |
| 3083 | "Put face on diff N. Invoked for X displays only." | 3084 | "Put face on diff N. Invoked for X displays only." |
| 3084 | (ediff-highlight-diff-in-one-buffer n 'A) | 3085 | (ediff-highlight-diff-in-one-buffer n 'A) |
| 3085 | (ediff-highlight-diff-in-one-buffer n 'B) | 3086 | (ediff-highlight-diff-in-one-buffer n 'B) |
| @@ -3088,7 +3089,7 @@ Hit \\[ediff-recenter] to reset the windows afterward." | |||
| 3088 | ) | 3089 | ) |
| 3089 | 3090 | ||
| 3090 | 3091 | ||
| 3091 | (defsubst ediff-unhighlight-diff () | 3092 | (defun ediff-unhighlight-diff () |
| 3092 | "Remove overlays from buffers A, B, and C." | 3093 | "Remove overlays from buffers A, B, and C." |
| 3093 | (ediff-unhighlight-diff-in-one-buffer 'A) | 3094 | (ediff-unhighlight-diff-in-one-buffer 'A) |
| 3094 | (ediff-unhighlight-diff-in-one-buffer 'B) | 3095 | (ediff-unhighlight-diff-in-one-buffer 'B) |
| @@ -3097,7 +3098,7 @@ Hit \\[ediff-recenter] to reset the windows afterward." | |||
| 3097 | ) | 3098 | ) |
| 3098 | 3099 | ||
| 3099 | ;; delete highlighting overlays, restore faces to their original form | 3100 | ;; delete highlighting overlays, restore faces to their original form |
| 3100 | (defsubst ediff-unhighlight-diffs-totally () | 3101 | (defun ediff-unhighlight-diffs-totally () |
| 3101 | (ediff-unhighlight-diffs-totally-in-one-buffer 'A) | 3102 | (ediff-unhighlight-diffs-totally-in-one-buffer 'A) |
| 3102 | (ediff-unhighlight-diffs-totally-in-one-buffer 'B) | 3103 | (ediff-unhighlight-diffs-totally-in-one-buffer 'B) |
| 3103 | (ediff-unhighlight-diffs-totally-in-one-buffer 'C) | 3104 | (ediff-unhighlight-diffs-totally-in-one-buffer 'C) |
| @@ -3686,7 +3687,7 @@ Ediff Control Panel to restore highlighting." | |||
| 3686 | (>= (point) end)))))) | 3687 | (>= (point) end)))))) |
| 3687 | 3688 | ||
| 3688 | 3689 | ||
| 3689 | (defsubst ediff-get-region-contents (n buf-type ctrl-buf &optional start end) | 3690 | (defun ediff-get-region-contents (n buf-type ctrl-buf &optional start end) |
| 3690 | (ediff-with-current-buffer | 3691 | (ediff-with-current-buffer |
| 3691 | (ediff-with-current-buffer ctrl-buf (ediff-get-buffer buf-type)) | 3692 | (ediff-with-current-buffer ctrl-buf (ediff-get-buffer buf-type)) |
| 3692 | (buffer-substring | 3693 | (buffer-substring |
| @@ -3945,6 +3946,7 @@ Ediff Control Panel to restore highlighting." | |||
| 3945 | (ediff-device-type (ediff-device-type)) | 3946 | (ediff-device-type (ediff-device-type)) |
| 3946 | varlist salutation buffer-name) | 3947 | varlist salutation buffer-name) |
| 3947 | (setq varlist '(ediff-diff-program ediff-diff-options | 3948 | (setq varlist '(ediff-diff-program ediff-diff-options |
| 3949 | ediff-diff3-program ediff-diff3-options | ||
| 3948 | ediff-patch-program ediff-patch-options | 3950 | ediff-patch-program ediff-patch-options |
| 3949 | ediff-shell | 3951 | ediff-shell |
| 3950 | ediff-use-faces | 3952 | ediff-use-faces |
| @@ -4300,6 +4302,8 @@ Mail anyway? (y or n) ") | |||
| 4300 | 4302 | ||
| 4301 | (run-hooks 'ediff-load-hook) | 4303 | (run-hooks 'ediff-load-hook) |
| 4302 | 4304 | ||
| 4305 | (provide 'ediff-util) | ||
| 4306 | |||
| 4303 | 4307 | ||
| 4304 | ;;; Local Variables: | 4308 | ;;; Local Variables: |
| 4305 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) | 4309 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) |
diff --git a/lisp/ediff-vers.el b/lisp/ediff-vers.el index 4c9dc4dd9c8..3e8b1c37572 100644 --- a/lisp/ediff-vers.el +++ b/lisp/ediff-vers.el | |||
| @@ -311,6 +311,7 @@ | |||
| 311 | 311 | ||
| 312 | (provide 'ediff-vers) | 312 | (provide 'ediff-vers) |
| 313 | 313 | ||
| 314 | |||
| 314 | ;;; Local Variables: | 315 | ;;; Local Variables: |
| 315 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) | 316 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) |
| 316 | ;;; eval: (put 'ediff-with-current-buffer 'lisp-indent-hook 1) | 317 | ;;; eval: (put 'ediff-with-current-buffer 'lisp-indent-hook 1) |
diff --git a/lisp/ediff-wind.el b/lisp/ediff-wind.el index 648a80b6156..28369f9f6bd 100644 --- a/lisp/ediff-wind.el +++ b/lisp/ediff-wind.el | |||
| @@ -26,7 +26,6 @@ | |||
| 26 | 26 | ||
| 27 | ;;; Code: | 27 | ;;; Code: |
| 28 | 28 | ||
| 29 | (provide 'ediff-wind) | ||
| 30 | 29 | ||
| 31 | ;; Compiler pacifier | 30 | ;; Compiler pacifier |
| 32 | (defvar icon-title-format) | 31 | (defvar icon-title-format) |
| @@ -1314,6 +1313,9 @@ It assumes that it is called from within the control buffer." | |||
| 1314 | ediff-wide-display-p))))))) | 1313 | ediff-wide-display-p))))))) |
| 1315 | 1314 | ||
| 1316 | 1315 | ||
| 1316 | (provide 'ediff-wind) | ||
| 1317 | |||
| 1318 | |||
| 1317 | ;;; Local Variables: | 1319 | ;;; Local Variables: |
| 1318 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) | 1320 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) |
| 1319 | ;;; eval: (put 'ediff-with-current-buffer 'lisp-indent-hook 1) | 1321 | ;;; eval: (put 'ediff-with-current-buffer 'lisp-indent-hook 1) |
diff --git a/lisp/ediff.el b/lisp/ediff.el index abb0f22b047..bb6cfc6b72e 100644 --- a/lisp/ediff.el +++ b/lisp/ediff.el | |||
| @@ -7,8 +7,8 @@ | |||
| 7 | ;; Created: February 2, 1994 | 7 | ;; Created: February 2, 1994 |
| 8 | ;; Keywords: comparing, merging, patching, tools, unix | 8 | ;; Keywords: comparing, merging, patching, tools, unix |
| 9 | 9 | ||
| 10 | (defconst ediff-version "2.80.1" "The current version of Ediff") | 10 | (defconst ediff-version "2.81" "The current version of Ediff") |
| 11 | (defconst ediff-date "November 25, 2005" "Date of last update") | 11 | (defconst ediff-date "February 18, 2006" "Date of last update") |
| 12 | 12 | ||
| 13 | 13 | ||
| 14 | ;; This file is part of GNU Emacs. | 14 | ;; This file is part of GNU Emacs. |
| @@ -107,7 +107,6 @@ | |||
| 107 | 107 | ||
| 108 | ;;; Code: | 108 | ;;; Code: |
| 109 | 109 | ||
| 110 | (provide 'ediff) | ||
| 111 | 110 | ||
| 112 | ;; Compiler pacifier | 111 | ;; Compiler pacifier |
| 113 | (defvar cvs-cookie-handle) | 112 | (defvar cvs-cookie-handle) |
| @@ -121,6 +120,7 @@ | |||
| 121 | (load "pcl-cvs" 'noerror))) | 120 | (load "pcl-cvs" 'noerror))) |
| 122 | (eval-when-compile | 121 | (eval-when-compile |
| 123 | (let ((load-path (cons (expand-file-name ".") load-path))) | 122 | (let ((load-path (cons (expand-file-name ".") load-path))) |
| 123 | (provide 'ediff) ; to break recursive load cycle | ||
| 124 | (or (featurep 'ediff-init) | 124 | (or (featurep 'ediff-init) |
| 125 | (load "ediff-init.el" nil nil 'nosuffix)) | 125 | (load "ediff-init.el" nil nil 'nosuffix)) |
| 126 | (or (featurep 'ediff-mult) | 126 | (or (featurep 'ediff-mult) |
| @@ -1374,7 +1374,7 @@ patch. If not given, the user is prompted according to the prefix argument." | |||
| 1374 | patch-buf | 1374 | patch-buf |
| 1375 | (read-buffer | 1375 | (read-buffer |
| 1376 | "Which buffer to patch? " | 1376 | "Which buffer to patch? " |
| 1377 | (current-buffer)))) | 1377 | (ediff-other-buffer patch-buf)))) |
| 1378 | 1378 | ||
| 1379 | 1379 | ||
| 1380 | ;;;###autoload | 1380 | ;;;###autoload |
| @@ -1533,6 +1533,9 @@ With optional NODE, goes to that node." | |||
| 1533 | 1533 | ||
| 1534 | (run-hooks 'ediff-load-hook) | 1534 | (run-hooks 'ediff-load-hook) |
| 1535 | 1535 | ||
| 1536 | (provide 'ediff) | ||
| 1537 | |||
| 1538 | |||
| 1536 | ;;; Local Variables: | 1539 | ;;; Local Variables: |
| 1537 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) | 1540 | ;;; eval: (put 'ediff-defvar-local 'lisp-indent-hook 'defun) |
| 1538 | ;;; eval: (put 'ediff-with-current-buffer 'lisp-indent-hook 1) | 1541 | ;;; eval: (put 'ediff-with-current-buffer 'lisp-indent-hook 1) |
diff --git a/lisp/emacs-lisp/unsafep.el b/lisp/emacs-lisp/unsafep.el index 41e98694c71..aeaf653aef6 100644 --- a/lisp/emacs-lisp/unsafep.el +++ b/lisp/emacs-lisp/unsafep.el | |||
| @@ -148,10 +148,10 @@ of symbols with local bindings." | |||
| 148 | ((eq fun 'lambda) | 148 | ((eq fun 'lambda) |
| 149 | ;;First arg is temporary bindings | 149 | ;;First arg is temporary bindings |
| 150 | (mapc #'(lambda (x) | 150 | (mapc #'(lambda (x) |
| 151 | (let ((y (unsafep-variable x t))) | ||
| 152 | (if y (throw 'unsafep y))) | ||
| 153 | (or (memq x '(&optional &rest)) | 151 | (or (memq x '(&optional &rest)) |
| 154 | (push x unsafep-vars))) | 152 | (let ((y (unsafep-variable x t))) |
| 153 | (if y (throw 'unsafep y)) | ||
| 154 | (push x unsafep-vars)))) | ||
| 155 | (cadr form)) | 155 | (cadr form)) |
| 156 | (unsafep-progn (cddr form))) | 156 | (unsafep-progn (cddr form))) |
| 157 | ((eq fun 'let) | 157 | ((eq fun 'let) |
| @@ -247,17 +247,16 @@ and throws a reason to `unsafep' if unsafe. Returns SYM." | |||
| 247 | (if reason (throw 'unsafep reason)) | 247 | (if reason (throw 'unsafep reason)) |
| 248 | sym)) | 248 | sym)) |
| 249 | 249 | ||
| 250 | (defun unsafep-variable (sym global-okay) | 250 | (defun unsafep-variable (sym to-bind) |
| 251 | "Return nil if SYM is safe as a let-binding sym | 251 | "Return nil if SYM is safe to set or bind, or a reason why not. |
| 252 | \(because it already has a temporary binding or is a non-risky buffer-local | 252 | If TO-BIND is nil, check whether SYM is safe to set. |
| 253 | variable), otherwise a reason why it is unsafe. Failing to be locally bound | 253 | If TO-BIND is t, check whether SYM is safe to bind." |
| 254 | is okay if GLOBAL-OKAY is non-nil." | ||
| 255 | (cond | 254 | (cond |
| 256 | ((not (symbolp sym)) | 255 | ((not (symbolp sym)) |
| 257 | `(variable ,sym)) | 256 | `(variable ,sym)) |
| 258 | ((risky-local-variable-p sym nil) | 257 | ((risky-local-variable-p sym nil) |
| 259 | `(risky-local-variable ,sym)) | 258 | `(risky-local-variable ,sym)) |
| 260 | ((not (or global-okay | 259 | ((not (or to-bind |
| 261 | (memq sym unsafep-vars) | 260 | (memq sym unsafep-vars) |
| 262 | (local-variable-p sym))) | 261 | (local-variable-p sym))) |
| 263 | `(global-variable ,sym)))) | 262 | `(global-variable ,sym)))) |
diff --git a/lisp/emulation/viper-cmd.el b/lisp/emulation/viper-cmd.el index db82952a6ef..645f4f26eaf 100644 --- a/lisp/emulation/viper-cmd.el +++ b/lisp/emulation/viper-cmd.el | |||
| @@ -196,6 +196,15 @@ | |||
| 196 | (viper-save-cursor-color 'before-insert-mode)) | 196 | (viper-save-cursor-color 'before-insert-mode)) |
| 197 | ;; set insert mode cursor color | 197 | ;; set insert mode cursor color |
| 198 | (viper-change-cursor-color viper-insert-state-cursor-color))) | 198 | (viper-change-cursor-color viper-insert-state-cursor-color))) |
| 199 | (if (eq viper-current-state 'emacs-state) | ||
| 200 | (let ((has-saved-cursor-color-in-emacs-mode | ||
| 201 | (stringp (viper-get-saved-cursor-color-in-emacs-mode)))) | ||
| 202 | (or has-saved-cursor-color-in-emacs-mode | ||
| 203 | (string= (viper-get-cursor-color) viper-emacs-state-cursor-color) | ||
| 204 | ;; save current color, if not already saved | ||
| 205 | (viper-save-cursor-color 'before-emacs-mode)) | ||
| 206 | ;; set emacs mode cursor color | ||
| 207 | (viper-change-cursor-color viper-emacs-state-cursor-color))) | ||
| 199 | 208 | ||
| 200 | (if (and (memq this-command '(dabbrev-expand hippie-expand)) | 209 | (if (and (memq this-command '(dabbrev-expand hippie-expand)) |
| 201 | (integerp viper-pre-command-point) | 210 | (integerp viper-pre-command-point) |
| @@ -643,9 +652,12 @@ | |||
| 643 | (indent-to-left-margin)) | 652 | (indent-to-left-margin)) |
| 644 | (viper-add-newline-at-eob-if-necessary) | 653 | (viper-add-newline-at-eob-if-necessary) |
| 645 | (viper-adjust-undo) | 654 | (viper-adjust-undo) |
| 646 | (viper-change-state 'vi-state) | ||
| 647 | 655 | ||
| 648 | (viper-restore-cursor-color 'after-insert-mode) | 656 | (if (eq viper-current-state 'emacs-state) |
| 657 | (viper-restore-cursor-color 'after-emacs-mode) | ||
| 658 | (viper-restore-cursor-color 'after-insert-mode)) | ||
| 659 | |||
| 660 | (viper-change-state 'vi-state) | ||
| 649 | 661 | ||
| 650 | ;; Protect against user errors in hooks | 662 | ;; Protect against user errors in hooks |
| 651 | (condition-case conds | 663 | (condition-case conds |
| @@ -709,9 +721,17 @@ | |||
| 709 | (or (viper-overlay-p viper-replace-overlay) | 721 | (or (viper-overlay-p viper-replace-overlay) |
| 710 | (viper-set-replace-overlay (point-min) (point-min))) | 722 | (viper-set-replace-overlay (point-min) (point-min))) |
| 711 | (viper-hide-replace-overlay) | 723 | (viper-hide-replace-overlay) |
| 724 | |||
| 725 | (let ((has-saved-cursor-color-in-emacs-mode | ||
| 726 | (stringp (viper-get-saved-cursor-color-in-emacs-mode)))) | ||
| 727 | (or has-saved-cursor-color-in-emacs-mode | ||
| 728 | (string= (viper-get-cursor-color) viper-emacs-state-cursor-color) | ||
| 729 | (viper-save-cursor-color 'before-emacs-mode)) | ||
| 730 | (viper-change-cursor-color viper-emacs-state-cursor-color)) | ||
| 731 | |||
| 712 | (viper-change-state 'emacs-state) | 732 | (viper-change-state 'emacs-state) |
| 713 | 733 | ||
| 714 | ;; Protect agains user errors in hooks | 734 | ;; Protect against user errors in hooks |
| 715 | (condition-case conds | 735 | (condition-case conds |
| 716 | (run-hooks 'viper-emacs-state-hook) | 736 | (run-hooks 'viper-emacs-state-hook) |
| 717 | (error | 737 | (error |
| @@ -820,12 +840,12 @@ Vi's prefix argument will be used. Otherwise, the prefix argument passed to | |||
| 820 | ;; The next cmd and viper-set-unread-command-events | 840 | ;; The next cmd and viper-set-unread-command-events |
| 821 | ;; are intended to prevent the input method | 841 | ;; are intended to prevent the input method |
| 822 | ;; from swallowing ^M, ^Q and other special characters | 842 | ;; from swallowing ^M, ^Q and other special characters |
| 823 | (setq ch (read-char)) | 843 | (setq ch (read-char-exclusive)) |
| 824 | ;; replace ^M with the newline | 844 | ;; replace ^M with the newline |
| 825 | (if (eq ch ?\C-m) (setq ch ?\n)) | 845 | (if (eq ch ?\C-m) (setq ch ?\n)) |
| 826 | ;; Make sure ^V and ^Q work as quotation chars | 846 | ;; Make sure ^V and ^Q work as quotation chars |
| 827 | (if (memq ch '(?\C-v ?\C-q)) | 847 | (if (memq ch '(?\C-v ?\C-q)) |
| 828 | (setq ch (read-char))) | 848 | (setq ch (read-char-exclusive))) |
| 829 | (viper-set-unread-command-events ch) | 849 | (viper-set-unread-command-events ch) |
| 830 | (quail-input-method nil) | 850 | (quail-input-method nil) |
| 831 | 851 | ||
| @@ -842,12 +862,12 @@ Vi's prefix argument will be used. Otherwise, the prefix argument passed to | |||
| 842 | ;; same as above but for XEmacs, which doesn't have | 862 | ;; same as above but for XEmacs, which doesn't have |
| 843 | ;; quail-input-method | 863 | ;; quail-input-method |
| 844 | (let (unread-command-events) | 864 | (let (unread-command-events) |
| 845 | (setq ch (read-char)) | 865 | (setq ch (read-char-exclusive)) |
| 846 | ;; replace ^M with the newline | 866 | ;; replace ^M with the newline |
| 847 | (if (eq ch ?\C-m) (setq ch ?\n)) | 867 | (if (eq ch ?\C-m) (setq ch ?\n)) |
| 848 | ;; Make sure ^V and ^Q work as quotation chars | 868 | ;; Make sure ^V and ^Q work as quotation chars |
| 849 | (if (memq ch '(?\C-v ?\C-q)) | 869 | (if (memq ch '(?\C-v ?\C-q)) |
| 850 | (setq ch (read-char))) | 870 | (setq ch (read-char-exclusive))) |
| 851 | (viper-set-unread-command-events ch) | 871 | (viper-set-unread-command-events ch) |
| 852 | (quail-start-translation nil) | 872 | (quail-start-translation nil) |
| 853 | 873 | ||
| @@ -867,12 +887,12 @@ Vi's prefix argument will be used. Otherwise, the prefix argument passed to | |||
| 867 | (setq ch (aref (read-key-sequence nil) 0))) | 887 | (setq ch (aref (read-key-sequence nil) 0))) |
| 868 | (insert ch)) | 888 | (insert ch)) |
| 869 | (t | 889 | (t |
| 870 | (setq ch (read-char)) | 890 | (setq ch (read-char-exclusive)) |
| 871 | ;; replace ^M with the newline | 891 | ;; replace ^M with the newline |
| 872 | (if (eq ch ?\C-m) (setq ch ?\n)) | 892 | (if (eq ch ?\C-m) (setq ch ?\n)) |
| 873 | ;; Make sure ^V and ^Q work as quotation chars | 893 | ;; Make sure ^V and ^Q work as quotation chars |
| 874 | (if (memq ch '(?\C-v ?\C-q)) | 894 | (if (memq ch '(?\C-v ?\C-q)) |
| 875 | (setq ch (read-char))) | 895 | (setq ch (read-char-exclusive))) |
| 876 | (insert ch)) | 896 | (insert ch)) |
| 877 | ) | 897 | ) |
| 878 | (setq last-command-event | 898 | (setq last-command-event |
| @@ -2131,7 +2151,7 @@ To turn this feature off, set this variable to nil." | |||
| 2131 | Remove this function from `viper-minibuffer-exit-hook', if this causes | 2151 | Remove this function from `viper-minibuffer-exit-hook', if this causes |
| 2132 | problems." | 2152 | problems." |
| 2133 | (if (viper-is-in-minibuffer) | 2153 | (if (viper-is-in-minibuffer) |
| 2134 | (progn | 2154 | (let ((inhibit-field-text-motion t)) |
| 2135 | (goto-char (viper-minibuffer-real-start)) | 2155 | (goto-char (viper-minibuffer-real-start)) |
| 2136 | (end-of-line) | 2156 | (end-of-line) |
| 2137 | (delete-region (point) (point-max))))) | 2157 | (delete-region (point) (point-max))))) |
diff --git a/lisp/emulation/viper-init.el b/lisp/emulation/viper-init.el index 59a78e46dee..661fc6ede7f 100644 --- a/lisp/emulation/viper-init.el +++ b/lisp/emulation/viper-init.el | |||
| @@ -434,6 +434,13 @@ delete the text being replaced, as in standard Vi." | |||
| 434 | (if (fboundp 'make-variable-frame-local) | 434 | (if (fboundp 'make-variable-frame-local) |
| 435 | (make-variable-frame-local 'viper-insert-state-cursor-color)) | 435 | (make-variable-frame-local 'viper-insert-state-cursor-color)) |
| 436 | 436 | ||
| 437 | (defcustom viper-emacs-state-cursor-color "Magenta" | ||
| 438 | "Cursor color when Viper is in emacs state." | ||
| 439 | :type 'string | ||
| 440 | :group 'viper) | ||
| 441 | (if (fboundp 'make-variable-frame-local) | ||
| 442 | (make-variable-frame-local 'viper-emacs-state-cursor-color)) | ||
| 443 | |||
| 437 | ;; internal var, used to remember the default cursor color of emacs frames | 444 | ;; internal var, used to remember the default cursor color of emacs frames |
| 438 | (defvar viper-vi-state-cursor-color nil) | 445 | (defvar viper-vi-state-cursor-color nil) |
| 439 | (if (fboundp 'make-variable-frame-local) | 446 | (if (fboundp 'make-variable-frame-local) |
diff --git a/lisp/emulation/viper-util.el b/lisp/emulation/viper-util.el index 8f79c0dab4a..c7fe792b5f2 100644 --- a/lisp/emulation/viper-util.el +++ b/lisp/emulation/viper-util.el | |||
| @@ -175,9 +175,12 @@ | |||
| 175 | (selected-frame) | 175 | (selected-frame) |
| 176 | (list | 176 | (list |
| 177 | (cons | 177 | (cons |
| 178 | (if (eq before-which-mode 'before-replace-mode) | 178 | (cond ((eq before-which-mode 'before-replace-mode) |
| 179 | 'viper-saved-cursor-color-in-replace-mode | 179 | 'viper-saved-cursor-color-in-replace-mode) |
| 180 | 'viper-saved-cursor-color-in-insert-mode) | 180 | ((eq before-which-mode 'before-emacs-mode) |
| 181 | 'viper-saved-cursor-color-in-emacs-mode) | ||
| 182 | (t | ||
| 183 | 'viper-saved-cursor-color-in-insert-mode)) | ||
| 181 | color))) | 184 | color))) |
| 182 | )))) | 185 | )))) |
| 183 | 186 | ||
| @@ -188,7 +191,9 @@ | |||
| 188 | (if viper-emacs-p 'frame-parameter 'frame-property) | 191 | (if viper-emacs-p 'frame-parameter 'frame-property) |
| 189 | (selected-frame) | 192 | (selected-frame) |
| 190 | 'viper-saved-cursor-color-in-replace-mode) | 193 | 'viper-saved-cursor-color-in-replace-mode) |
| 191 | viper-vi-state-cursor-color)) | 194 | (if (eq viper-current-state 'emacs-mode) |
| 195 | viper-emacs-state-cursor-color | ||
| 196 | viper-vi-state-cursor-color))) | ||
| 192 | 197 | ||
| 193 | (defsubst viper-get-saved-cursor-color-in-insert-mode () | 198 | (defsubst viper-get-saved-cursor-color-in-insert-mode () |
| 194 | (or | 199 | (or |
| @@ -196,15 +201,27 @@ | |||
| 196 | (if viper-emacs-p 'frame-parameter 'frame-property) | 201 | (if viper-emacs-p 'frame-parameter 'frame-property) |
| 197 | (selected-frame) | 202 | (selected-frame) |
| 198 | 'viper-saved-cursor-color-in-insert-mode) | 203 | 'viper-saved-cursor-color-in-insert-mode) |
| 204 | (if (eq viper-current-state 'emacs-mode) | ||
| 205 | viper-emacs-state-cursor-color | ||
| 206 | viper-vi-state-cursor-color))) | ||
| 207 | |||
| 208 | (defsubst viper-get-saved-cursor-color-in-emacs-mode () | ||
| 209 | (or | ||
| 210 | (funcall | ||
| 211 | (if viper-emacs-p 'frame-parameter 'frame-property) | ||
| 212 | (selected-frame) | ||
| 213 | 'viper-saved-cursor-color-in-emacs-mode) | ||
| 199 | viper-vi-state-cursor-color)) | 214 | viper-vi-state-cursor-color)) |
| 200 | 215 | ||
| 201 | ;; restore cursor color from replace overlay | 216 | ;; restore cursor color from replace overlay |
| 202 | (defun viper-restore-cursor-color(after-which-mode) | 217 | (defun viper-restore-cursor-color(after-which-mode) |
| 203 | (if (viper-overlay-p viper-replace-overlay) | 218 | (if (viper-overlay-p viper-replace-overlay) |
| 204 | (viper-change-cursor-color | 219 | (viper-change-cursor-color |
| 205 | (if (eq after-which-mode 'after-replace-mode) | 220 | (cond ((eq after-which-mode 'after-replace-mode) |
| 206 | (viper-get-saved-cursor-color-in-replace-mode) | 221 | (viper-get-saved-cursor-color-in-replace-mode)) |
| 207 | (viper-get-saved-cursor-color-in-insert-mode)) | 222 | ((eq after-which-mode 'after-emacs-mode) |
| 223 | (viper-get-saved-cursor-color-in-emacs-mode)) | ||
| 224 | (t (viper-get-saved-cursor-color-in-insert-mode))) | ||
| 208 | ))) | 225 | ))) |
| 209 | 226 | ||
| 210 | 227 | ||
diff --git a/lisp/emulation/viper.el b/lisp/emulation/viper.el index 223cff3dd99..fc55d291550 100644 --- a/lisp/emulation/viper.el +++ b/lisp/emulation/viper.el | |||
| @@ -9,7 +9,7 @@ | |||
| 9 | ;; Author: Michael Kifer <kifer@cs.stonybrook.edu> | 9 | ;; Author: Michael Kifer <kifer@cs.stonybrook.edu> |
| 10 | ;; Keywords: emulations | 10 | ;; Keywords: emulations |
| 11 | 11 | ||
| 12 | (defconst viper-version "3.11.5 of November 25, 2005" | 12 | (defconst viper-version "3.12 of February 18, 2006" |
| 13 | "The current version of Viper") | 13 | "The current version of Viper") |
| 14 | 14 | ||
| 15 | ;; This file is part of GNU Emacs. | 15 | ;; This file is part of GNU Emacs. |
diff --git a/lisp/erc/ChangeLog b/lisp/erc/ChangeLog index ec2098c7bd3..92f8c401336 100644 --- a/lisp/erc/ChangeLog +++ b/lisp/erc/ChangeLog | |||
| @@ -1,5 +1,21 @@ | |||
| 1 | 2006-02-19 Michael Olson <mwolson@gnu.org> | ||
| 2 | |||
| 3 | * erc-capab.el (erc-capab-send-identify-messages): Make sure some | ||
| 4 | parameters are strings before using them. Thanks to Alejandro | ||
| 5 | Benitez for the report. | ||
| 6 | |||
| 7 | * erc.el (erc-version-string): Release ERC 5.1.2. | ||
| 8 | |||
| 9 | 2006-02-19 Diane Murray <disumu@x3y2z1.net> | ||
| 10 | |||
| 11 | * erc-button.el (erc-button-keymap): Bind `erc-button-previous' to | ||
| 12 | <C-tab>. | ||
| 13 | (erc-button-previous): New function. | ||
| 14 | |||
| 1 | 2006-02-15 Michael Olson <mwolson@gnu.org> | 15 | 2006-02-15 Michael Olson <mwolson@gnu.org> |
| 2 | 16 | ||
| 17 | * NEWS: Add category for ERC 5.2. | ||
| 18 | |||
| 3 | * erc.el (erc): Move to the end of the buffer when a continued | 19 | * erc.el (erc): Move to the end of the buffer when a continued |
| 4 | session is detected. Thanks to e1f and indio for the report and | 20 | session is detected. Thanks to e1f and indio for the report and |
| 5 | testing a potential fix. | 21 | testing a potential fix. |
| @@ -150,7 +166,7 @@ | |||
| 150 | * erc-stamp.el: Use new arch tagline, since the other one wasn't | 166 | * erc-stamp.el: Use new arch tagline, since the other one wasn't |
| 151 | being treated properly. | 167 | being treated properly. |
| 152 | 168 | ||
| 153 | * erc.el (erc-version-string): Release ERC 5.1.1 | 169 | * erc.el (erc-version-string): Release ERC 5.1.1. |
| 154 | 170 | ||
| 155 | 2006-02-03 Zhang Wei <id.brep@gmail.com> (tiny change) | 171 | 2006-02-03 Zhang Wei <id.brep@gmail.com> (tiny change) |
| 156 | 172 | ||
diff --git a/lisp/erc/erc-button.el b/lisp/erc/erc-button.el index 6c6998a3afc..2ec625cc87f 100644 --- a/lisp/erc/erc-button.el +++ b/lisp/erc/erc-button.el | |||
| @@ -216,6 +216,7 @@ PAR is a number of a regexp grouping whose text will be passed to | |||
| 216 | (define-key map (kbd "<button2>") 'erc-button-click-button) | 216 | (define-key map (kbd "<button2>") 'erc-button-click-button) |
| 217 | (define-key map (kbd "<mouse-2>") 'erc-button-click-button)) | 217 | (define-key map (kbd "<mouse-2>") 'erc-button-click-button)) |
| 218 | (define-key map (kbd "TAB") 'erc-button-next) | 218 | (define-key map (kbd "TAB") 'erc-button-next) |
| 219 | (define-key map (kbd "<C-tab>") 'erc-button-previous) | ||
| 219 | (set-keymap-parent map erc-mode-map) | 220 | (set-keymap-parent map erc-mode-map) |
| 220 | map) | 221 | map) |
| 221 | "Local keymap for ERC buttons.") | 222 | "Local keymap for ERC buttons.") |
| @@ -427,6 +428,22 @@ call it with the value of the `erc-data' text property." | |||
| 427 | (error "No next button")) | 428 | (error "No next button")) |
| 428 | t))) | 429 | t))) |
| 429 | 430 | ||
| 431 | (defun erc-button-previous () | ||
| 432 | "Go to the previous button in this buffer." | ||
| 433 | (interactive) | ||
| 434 | (let ((here (point))) | ||
| 435 | (when (< here (erc-beg-of-input-line)) | ||
| 436 | (while (and (get-text-property here 'erc-callback) | ||
| 437 | (not (= here (point-min)))) | ||
| 438 | (setq here (1- here))) | ||
| 439 | (while (and (not (get-text-property here 'erc-callback)) | ||
| 440 | (not (= here (point-min)))) | ||
| 441 | (setq here (1- here))) | ||
| 442 | (if (> here (point-min)) | ||
| 443 | (goto-char here) | ||
| 444 | (error "No previous button")) | ||
| 445 | t))) | ||
| 446 | |||
| 430 | (defun erc-browse-emacswiki (thing) | 447 | (defun erc-browse-emacswiki (thing) |
| 431 | "Browse to thing in the emacs-wiki." | 448 | "Browse to thing in the emacs-wiki." |
| 432 | (browse-url (concat erc-emacswiki-url thing))) | 449 | (browse-url (concat erc-emacswiki-url thing))) |
diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el index e1dc240901b..63ff60d762e 100644 --- a/lisp/erc/erc.el +++ b/lisp/erc/erc.el | |||
| @@ -66,7 +66,7 @@ | |||
| 66 | 66 | ||
| 67 | ;;; Code: | 67 | ;;; Code: |
| 68 | 68 | ||
| 69 | (defconst erc-version-string "Version 5.1.1" | 69 | (defconst erc-version-string "Version 5.1.2" |
| 70 | "ERC version. This is used by function `erc-version'.") | 70 | "ERC version. This is used by function `erc-version'.") |
| 71 | 71 | ||
| 72 | (eval-when-compile (require 'cl)) | 72 | (eval-when-compile (require 'cl)) |
diff --git a/lisp/ffap.el b/lisp/ffap.el index 1b6665d16d5..5ff63bfdec2 100644 --- a/lisp/ffap.el +++ b/lisp/ffap.el | |||
| @@ -1255,7 +1255,8 @@ which may actually result in an url rather than a filename." | |||
| 1255 | (abbreviate-file-name (expand-file-name guess)) | 1255 | (abbreviate-file-name (expand-file-name guess)) |
| 1256 | )) | 1256 | )) |
| 1257 | (setq dir (file-name-directory guess)))) | 1257 | (setq dir (file-name-directory guess)))) |
| 1258 | (let ((minibuffer-completing-file-name t)) | 1258 | (let ((minibuffer-completing-file-name t) |
| 1259 | (completion-ignore-case read-file-name-completion-ignore-case)) | ||
| 1259 | (setq guess | 1260 | (setq guess |
| 1260 | (completing-read | 1261 | (completing-read |
| 1261 | prompt | 1262 | prompt |
| @@ -1321,6 +1322,12 @@ which may actually result in an url rather than a filename." | |||
| 1321 | (defvar ffap-highlight t | 1322 | (defvar ffap-highlight t |
| 1322 | "If non-nil, ffap highlights the current buffer substring.") | 1323 | "If non-nil, ffap highlights the current buffer substring.") |
| 1323 | 1324 | ||
| 1325 | (defface ffap | ||
| 1326 | '((t :inherit highlight)) | ||
| 1327 | "Face used to highlight the current buffer substring." | ||
| 1328 | :group 'ffap | ||
| 1329 | :version "22.1") | ||
| 1330 | |||
| 1324 | (defvar ffap-highlight-overlay nil | 1331 | (defvar ffap-highlight-overlay nil |
| 1325 | "Overlay used by `ffap-highlight'.") | 1332 | "Overlay used by `ffap-highlight'.") |
| 1326 | 1333 | ||
| @@ -1344,8 +1351,7 @@ Uses the face `ffap' if it is defined, or else `highlight'." | |||
| 1344 | (t | 1351 | (t |
| 1345 | (setq ffap-highlight-overlay | 1352 | (setq ffap-highlight-overlay |
| 1346 | (apply 'make-overlay ffap-string-at-point-region)) | 1353 | (apply 'make-overlay ffap-string-at-point-region)) |
| 1347 | (overlay-put ffap-highlight-overlay 'face | 1354 | (overlay-put ffap-highlight-overlay 'face 'ffap)))) |
| 1348 | (if (facep 'ffap) 'ffap 'highlight))))) | ||
| 1349 | 1355 | ||
| 1350 | 1356 | ||
| 1351 | ;;; Main Entrance (`find-file-at-point' == `ffap'): | 1357 | ;;; Main Entrance (`find-file-at-point' == `ffap'): |
diff --git a/lisp/files.el b/lisp/files.el index 285cd50e6af..ab69c7958a9 100644 --- a/lisp/files.el +++ b/lisp/files.el | |||
| @@ -447,10 +447,11 @@ use `before-save-hook'.") | |||
| 447 | The value can be t, nil or something else. | 447 | The value can be t, nil or something else. |
| 448 | 448 | ||
| 449 | A value of t means file local variables specifications are obeyed | 449 | A value of t means file local variables specifications are obeyed |
| 450 | if all the specified variables are safe. If any variables are | 450 | if all the specified variable values are safe; if any values are |
| 451 | not safe, you will be queries before setting them. | 451 | not safe, Emacs queries you, once, whether to set them all. |
| 452 | A value of nil means file local variables are ignored. | 452 | |
| 453 | Any other value means to always query. | 453 | A value of nil means always ignore the file local variables. |
| 454 | Any other value means always query you once whether to set them all. | ||
| 454 | 455 | ||
| 455 | This variable also controls use of major modes specified in | 456 | This variable also controls use of major modes specified in |
| 456 | a -*- line. | 457 | a -*- line. |
| @@ -2218,6 +2219,129 @@ Otherwise, return nil; point may be changed." | |||
| 2218 | (setq end (point)) | 2219 | (setq end (point)) |
| 2219 | (goto-char beg) | 2220 | (goto-char beg) |
| 2220 | end)))) | 2221 | end)))) |
| 2222 | |||
| 2223 | ;;; Handling file local variables | ||
| 2224 | |||
| 2225 | (defvar ignored-local-variables | ||
| 2226 | '(ignored-local-variables safe-local-variable-values) | ||
| 2227 | "Variables to be ignored in a file's local variable spec.") | ||
| 2228 | |||
| 2229 | (defvar hack-local-variables-hook nil | ||
| 2230 | "Normal hook run after processing a file's local variables specs. | ||
| 2231 | Major modes can use this to examine user-specified local variables | ||
| 2232 | in order to initialize other data structure based on them.") | ||
| 2233 | |||
| 2234 | (defcustom safe-local-variable-values nil | ||
| 2235 | "List variable-value pairs that are considered safe. | ||
| 2236 | Each element is a cons cell (VAR . VAL), where VAR is a variable | ||
| 2237 | symbol and VAL is a value that is considered safe." | ||
| 2238 | :group 'find-file | ||
| 2239 | :type 'alist) | ||
| 2240 | |||
| 2241 | (defcustom safe-local-eval-forms nil | ||
| 2242 | "*Expressions that are considered safe in an `eval:' local variable. | ||
| 2243 | Add expressions to this list if you want Emacs to evaluate them, when | ||
| 2244 | they appear in an `eval' local variable specification, without first | ||
| 2245 | asking you for confirmation." | ||
| 2246 | :group 'find-file | ||
| 2247 | :version "22.1" | ||
| 2248 | :type '(repeat sexp)) | ||
| 2249 | |||
| 2250 | ;; Risky local variables: | ||
| 2251 | (mapc (lambda (var) (put var 'risky-local-variable t)) | ||
| 2252 | '(after-load-alist | ||
| 2253 | auto-mode-alist | ||
| 2254 | buffer-auto-save-file-name | ||
| 2255 | buffer-file-name | ||
| 2256 | buffer-file-truename | ||
| 2257 | buffer-undo-list | ||
| 2258 | dabbrev-case-fold-search | ||
| 2259 | dabbrev-case-replace | ||
| 2260 | debugger | ||
| 2261 | default-text-properties | ||
| 2262 | display-time-string | ||
| 2263 | enable-local-eval | ||
| 2264 | eval | ||
| 2265 | exec-directory | ||
| 2266 | exec-path | ||
| 2267 | file-name-handler-alist | ||
| 2268 | font-lock-defaults | ||
| 2269 | format-alist | ||
| 2270 | frame-title-format | ||
| 2271 | global-mode-string | ||
| 2272 | header-line-format | ||
| 2273 | icon-title-format | ||
| 2274 | ignored-local-variables | ||
| 2275 | imenu--index-alist | ||
| 2276 | imenu-generic-expression | ||
| 2277 | inhibit-quit | ||
| 2278 | input-method-alist | ||
| 2279 | load-path | ||
| 2280 | max-lisp-eval-depth | ||
| 2281 | max-specpdl-size | ||
| 2282 | minor-mode-alist | ||
| 2283 | minor-mode-map-alist | ||
| 2284 | minor-mode-overriding-map-alist | ||
| 2285 | mode-line-buffer-identification | ||
| 2286 | mode-line-format | ||
| 2287 | mode-line-modes | ||
| 2288 | mode-line-modified | ||
| 2289 | mode-line-mule-info | ||
| 2290 | mode-line-position | ||
| 2291 | mode-line-process | ||
| 2292 | mode-name | ||
| 2293 | outline-level | ||
| 2294 | overriding-local-map | ||
| 2295 | overriding-terminal-local-map | ||
| 2296 | parse-time-rules | ||
| 2297 | process-environment | ||
| 2298 | rmail-output-file-alist | ||
| 2299 | save-some-buffers-action-alist | ||
| 2300 | special-display-buffer-names | ||
| 2301 | standard-input | ||
| 2302 | standard-output | ||
| 2303 | unread-command-events | ||
| 2304 | vc-mode)) | ||
| 2305 | |||
| 2306 | ;; Safe local variables: | ||
| 2307 | ;; | ||
| 2308 | ;; For variables defined by minor modes, put the safety declarations | ||
| 2309 | ;; here, not in the file defining the minor mode (when Emacs visits a | ||
| 2310 | ;; file specifying that local variable, the minor mode file may not be | ||
| 2311 | ;; loaded yet). For variables defined by major modes, the safety | ||
| 2312 | ;; declarations can go into the major mode's file, since that will be | ||
| 2313 | ;; loaded before file variables are processed. | ||
| 2314 | |||
| 2315 | (let ((string-or-null (lambda (a) (or (stringp a) (null a))))) | ||
| 2316 | (eval | ||
| 2317 | `(mapc (lambda (pair) | ||
| 2318 | (put (car pair) 'safe-local-variable (cdr pair))) | ||
| 2319 | '((byte-compile-dynamic . t) | ||
| 2320 | (c-basic-offset . integerp) | ||
| 2321 | (c-file-style . stringp) | ||
| 2322 | (c-indent-level . integerp) | ||
| 2323 | (comment-column . integerp) | ||
| 2324 | (compile-command . ,string-or-null) | ||
| 2325 | (fill-column . integerp) | ||
| 2326 | (fill-prefix . ,string-or-null) | ||
| 2327 | (indent-tabs-mode . t) | ||
| 2328 | (ispell-check-comments . (lambda (a) | ||
| 2329 | (memq a '(nil t exclusive)))) | ||
| 2330 | (ispell-local-dictionary . ,string-or-null) | ||
| 2331 | (kept-new-versions . integerp) | ||
| 2332 | (no-byte-compile . t) | ||
| 2333 | (no-update-autoloads . t) | ||
| 2334 | (outline-regexp . ,string-or-null) | ||
| 2335 | (page-delimiter . ,string-or-null) | ||
| 2336 | (paragraph-start . ,string-or-null) | ||
| 2337 | (paragraph-separate . ,string-or-null) | ||
| 2338 | (sentence-end . ,string-or-null) | ||
| 2339 | (sentence-end-double-space . t) | ||
| 2340 | (tab-width . integerp) | ||
| 2341 | (truncate-lines . t) | ||
| 2342 | (version-control . t))))) | ||
| 2343 | |||
| 2344 | (put 'c-set-style 'safe-local-eval-function t) | ||
| 2221 | 2345 | ||
| 2222 | (defun hack-local-variables-confirm (vars unsafe-vars risky-vars) | 2346 | (defun hack-local-variables-confirm (vars unsafe-vars risky-vars) |
| 2223 | (if noninteractive | 2347 | (if noninteractive |
| @@ -2346,18 +2470,6 @@ and VAL is the specified value." | |||
| 2346 | mode-specified | 2470 | mode-specified |
| 2347 | result)))) | 2471 | result)))) |
| 2348 | 2472 | ||
| 2349 | (defvar hack-local-variables-hook nil | ||
| 2350 | "Normal hook run after processing a file's local variables specs. | ||
| 2351 | Major modes can use this to examine user-specified local variables | ||
| 2352 | in order to initialize other data structure based on them.") | ||
| 2353 | |||
| 2354 | (defcustom safe-local-variable-values nil | ||
| 2355 | "List variable-value pairs that are considered safe. | ||
| 2356 | Each element is a cons cell (VAR . VAL), where VAR is a variable | ||
| 2357 | symbol and VAL is a value that is considered safe." | ||
| 2358 | :group 'find-file | ||
| 2359 | :type 'alist) | ||
| 2360 | |||
| 2361 | (defun hack-local-variables (&optional mode-only) | 2473 | (defun hack-local-variables (&optional mode-only) |
| 2362 | "Parse and put into effect this buffer's local variables spec. | 2474 | "Parse and put into effect this buffer's local variables spec. |
| 2363 | If MODE-ONLY is non-nil, all we do is check whether the major mode | 2475 | If MODE-ONLY is non-nil, all we do is check whether the major mode |
| @@ -2479,92 +2591,6 @@ is specified, returning t if it is specified." | |||
| 2479 | (hack-one-local-variable (car elt) (cdr elt))))) | 2591 | (hack-one-local-variable (car elt) (cdr elt))))) |
| 2480 | (run-hooks 'hack-local-variables-hook)))))) | 2592 | (run-hooks 'hack-local-variables-hook)))))) |
| 2481 | 2593 | ||
| 2482 | (defvar ignored-local-variables | ||
| 2483 | '(ignored-local-variables safe-local-variable-values) | ||
| 2484 | "Variables to be ignored in a file's local variable spec.") | ||
| 2485 | |||
| 2486 | ;; Get confirmation before setting these variables as locals in a file. | ||
| 2487 | (put 'debugger 'risky-local-variable t) | ||
| 2488 | (put 'enable-local-eval 'risky-local-variable t) | ||
| 2489 | (put 'ignored-local-variables 'risky-local-variable t) | ||
| 2490 | (put 'ignored-local-variables 'safe-local-variable-values t) | ||
| 2491 | (put 'eval 'risky-local-variable t) | ||
| 2492 | (put 'file-name-handler-alist 'risky-local-variable t) | ||
| 2493 | (put 'inhibit-quit 'risky-local-variable t) | ||
| 2494 | (put 'minor-mode-alist 'risky-local-variable t) | ||
| 2495 | (put 'minor-mode-map-alist 'risky-local-variable t) | ||
| 2496 | (put 'minor-mode-overriding-map-alist 'risky-local-variable t) | ||
| 2497 | (put 'overriding-local-map 'risky-local-variable t) | ||
| 2498 | (put 'overriding-terminal-local-map 'risky-local-variable t) | ||
| 2499 | (put 'auto-mode-alist 'risky-local-variable t) | ||
| 2500 | (put 'after-load-alist 'risky-local-variable t) | ||
| 2501 | (put 'buffer-file-name 'risky-local-variable t) | ||
| 2502 | (put 'buffer-undo-list 'risky-local-variable t) | ||
| 2503 | (put 'buffer-auto-save-file-name 'risky-local-variable t) | ||
| 2504 | (put 'buffer-file-truename 'risky-local-variable t) | ||
| 2505 | (put 'default-text-properties 'risky-local-variable t) | ||
| 2506 | (put 'exec-path 'risky-local-variable t) | ||
| 2507 | (put 'load-path 'risky-local-variable t) | ||
| 2508 | (put 'exec-directory 'risky-local-variable t) | ||
| 2509 | (put 'process-environment 'risky-local-variable t) | ||
| 2510 | (put 'dabbrev-case-fold-search 'risky-local-variable t) | ||
| 2511 | (put 'dabbrev-case-replace 'risky-local-variable t) | ||
| 2512 | ;; Don't wait for outline.el to be loaded, for the sake of outline-minor-mode. | ||
| 2513 | (put 'outline-level 'risky-local-variable t) | ||
| 2514 | (put 'rmail-output-file-alist 'risky-local-variable t) | ||
| 2515 | (put 'font-lock-defaults 'risky-local-variable t) | ||
| 2516 | (put 'special-display-buffer-names 'risky-local-variable t) | ||
| 2517 | (put 'frame-title-format 'risky-local-variable t) | ||
| 2518 | (put 'global-mode-string 'risky-local-variable t) | ||
| 2519 | (put 'header-line-format 'risky-local-variable t) | ||
| 2520 | (put 'icon-title-format 'risky-local-variable t) | ||
| 2521 | (put 'input-method-alist 'risky-local-variable t) | ||
| 2522 | (put 'format-alist 'risky-local-variable t) | ||
| 2523 | (put 'vc-mode 'risky-local-variable t) | ||
| 2524 | (put 'imenu-generic-expression 'risky-local-variable t) | ||
| 2525 | (put 'imenu--index-alist 'risky-local-variable t) | ||
| 2526 | (put 'standard-input 'risky-local-variable t) | ||
| 2527 | (put 'standard-output 'risky-local-variable t) | ||
| 2528 | (put 'unread-command-events 'risky-local-variable t) | ||
| 2529 | (put 'max-lisp-eval-depth 'risky-local-variable t) | ||
| 2530 | (put 'max-specpdl-size 'risky-local-variable t) | ||
| 2531 | (put 'mode-line-format 'risky-local-variable t) | ||
| 2532 | (put 'mode-line-modified 'risky-local-variable t) | ||
| 2533 | (put 'mode-line-mule-info 'risky-local-variable t) | ||
| 2534 | (put 'mode-line-buffer-identification 'risky-local-variable t) | ||
| 2535 | (put 'mode-line-modes 'risky-local-variable t) | ||
| 2536 | (put 'mode-line-position 'risky-local-variable t) | ||
| 2537 | (put 'mode-line-process 'risky-local-variable t) | ||
| 2538 | (put 'mode-name 'risky-local-variable t) | ||
| 2539 | (put 'display-time-string 'risky-local-variable t) | ||
| 2540 | (put 'parse-time-rules 'risky-local-variable t) | ||
| 2541 | |||
| 2542 | ;; Commonly-encountered local variables that are safe: | ||
| 2543 | (let ((string-or-null (lambda (a) (or (stringp a) (null a))))) | ||
| 2544 | (eval | ||
| 2545 | `(mapc (lambda (pair) | ||
| 2546 | (put (car pair) 'safe-local-variable (cdr pair))) | ||
| 2547 | '((byte-compile-dynamic . t) | ||
| 2548 | (c-basic-offset . integerp) | ||
| 2549 | (c-file-style . stringp) | ||
| 2550 | (c-indent-level . integerp) | ||
| 2551 | (comment-column . integerp) | ||
| 2552 | (compile-command . ,string-or-null) | ||
| 2553 | (fill-column . integerp) | ||
| 2554 | (fill-prefix . ,string-or-null) | ||
| 2555 | (indent-tabs-mode . t) | ||
| 2556 | (kept-new-versions . integerp) | ||
| 2557 | (no-byte-compile . t) | ||
| 2558 | (no-update-autoloads . t) | ||
| 2559 | (outline-regexp . ,string-or-null) | ||
| 2560 | (page-delimiter . ,string-or-null) | ||
| 2561 | (paragraph-start . ,string-or-null) | ||
| 2562 | (paragraph-separate . ,string-or-null) | ||
| 2563 | (sentence-end . ,string-or-null) | ||
| 2564 | (sentence-end-double-space . t) | ||
| 2565 | (tab-width . integerp) | ||
| 2566 | (version-control . t))))) | ||
| 2567 | |||
| 2568 | (defun safe-local-variable-p (sym val) | 2594 | (defun safe-local-variable-p (sym val) |
| 2569 | "Non-nil if SYM is safe as a file-local variable with value VAL. | 2595 | "Non-nil if SYM is safe as a file-local variable with value VAL. |
| 2570 | It is safe if any of these conditions are met: | 2596 | It is safe if any of these conditions are met: |
| @@ -2602,17 +2628,6 @@ It is dangerous if either of these conditions are met: | |||
| 2602 | -[0-9]+$\\|font-lock-syntactic-keywords$\\|-frame-alist$\\|-mode-alist$\\|\ | 2628 | -[0-9]+$\\|font-lock-syntactic-keywords$\\|-frame-alist$\\|-mode-alist$\\|\ |
| 2603 | -map$\\|-map-alist$" (symbol-name sym)))) | 2629 | -map$\\|-map-alist$" (symbol-name sym)))) |
| 2604 | 2630 | ||
| 2605 | (defcustom safe-local-eval-forms nil | ||
| 2606 | "*Expressions that are considered \"safe\" in an `eval:' local variable. | ||
| 2607 | Add expressions to this list if you want Emacs to evaluate them, when | ||
| 2608 | they appear in an `eval' local variable specification, without first | ||
| 2609 | asking you for confirmation." | ||
| 2610 | :group 'find-file | ||
| 2611 | :version "22.1" | ||
| 2612 | :type '(repeat sexp)) | ||
| 2613 | |||
| 2614 | (put 'c-set-style 'safe-local-eval-function t) | ||
| 2615 | |||
| 2616 | (defun hack-one-local-variable-quotep (exp) | 2631 | (defun hack-one-local-variable-quotep (exp) |
| 2617 | (and (consp exp) (eq (car exp) 'quote) (consp (cdr exp)))) | 2632 | (and (consp exp) (eq (car exp) 'quote) (consp (cdr exp)))) |
| 2618 | 2633 | ||
| @@ -3630,7 +3645,6 @@ This requires the external program `diff' to be in your `exec-path'." | |||
| 3630 | (?d diff-buffer-with-file | 3645 | (?d diff-buffer-with-file |
| 3631 | "view changes in file")) | 3646 | "view changes in file")) |
| 3632 | "ACTION-ALIST argument used in call to `map-y-or-n-p'.") | 3647 | "ACTION-ALIST argument used in call to `map-y-or-n-p'.") |
| 3633 | (put 'save-some-buffers-action-alist 'risky-local-variable t) | ||
| 3634 | 3648 | ||
| 3635 | (defvar buffer-save-without-query nil | 3649 | (defvar buffer-save-without-query nil |
| 3636 | "Non-nil means `save-some-buffers' should save this buffer without asking.") | 3650 | "Non-nil means `save-some-buffers' should save this buffer without asking.") |
diff --git a/lisp/fringe.el b/lisp/fringe.el index fd9e70b5846..317fff0973c 100644 --- a/lisp/fringe.el +++ b/lisp/fringe.el | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | ;;; fringe.el --- change fringes appearance in various ways | 1 | ;;; fringe.el --- fringe setup and control |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. |
| 4 | 4 | ||
| @@ -25,8 +25,9 @@ | |||
| 25 | 25 | ||
| 26 | ;;; Commentary: | 26 | ;;; Commentary: |
| 27 | 27 | ||
| 28 | ;; This file contains helpful functions for customizing the appearance | 28 | ;; This file contains code to initialize the built-in fringe bitmaps |
| 29 | ;; of the fringe. | 29 | ;; as well as helpful functions for customizing the appearance of the |
| 30 | ;; fringe. | ||
| 30 | 31 | ||
| 31 | ;; The code is influenced by scroll-bar.el and avoid.el. The author | 32 | ;; The code is influenced by scroll-bar.el and avoid.el. The author |
| 32 | ;; gratefully acknowledge comments and suggestions made by Miles | 33 | ;; gratefully acknowledge comments and suggestions made by Miles |
| @@ -40,32 +41,52 @@ | |||
| 40 | :version "22.1" | 41 | :version "22.1" |
| 41 | :group 'frames) | 42 | :group 'frames) |
| 42 | 43 | ||
| 43 | ;; Standard fringe bitmaps | 44 | ;; Define the built-in fringe bitmaps and setup default mappings |
| 44 | 45 | ||
| 45 | (defmacro fringe-bitmap-p (symbol) | 46 | (when (boundp 'fringe-bitmaps) |
| 46 | "Return non-nil if SYMBOL is a fringe bitmap." | 47 | (let ((bitmaps '(question-mark |
| 47 | `(get ,symbol 'fringe)) | 48 | left-arrow right-arrow up-arrow down-arrow |
| 48 | 49 | left-curly-arrow right-curly-arrow | |
| 49 | (defvar fringe-bitmaps) | 50 | left-triangle right-triangle |
| 50 | |||
| 51 | (unless (or (not (boundp 'fringe-bitmaps)) | ||
| 52 | (get 'left-truncation 'fringe)) | ||
| 53 | (let ((bitmaps '(left-truncation right-truncation | ||
| 54 | up-arrow down-arrow | ||
| 55 | continued-line continuation-line | ||
| 56 | overlay-arrow | ||
| 57 | top-left-angle top-right-angle | 51 | top-left-angle top-right-angle |
| 58 | bottom-left-angle bottom-right-angle | 52 | bottom-left-angle bottom-right-angle |
| 59 | left-bracket right-bracket | 53 | left-bracket right-bracket |
| 60 | filled-box-cursor hollow-box-cursor hollow-square | 54 | filled-rectangle hollow-rectangle |
| 61 | bar-cursor hbar-cursor | 55 | filled-square hollow-square |
| 56 | vertical-bar horizontal-bar | ||
| 62 | empty-line)) | 57 | empty-line)) |
| 63 | (bn 2)) | 58 | (bn 1)) |
| 64 | (while bitmaps | 59 | (while bitmaps |
| 65 | (push (car bitmaps) fringe-bitmaps) | 60 | (push (car bitmaps) fringe-bitmaps) |
| 66 | (put (car bitmaps) 'fringe bn) | 61 | (put (car bitmaps) 'fringe bn) |
| 67 | (setq bitmaps (cdr bitmaps) | 62 | (setq bitmaps (cdr bitmaps) |
| 68 | bn (1+ bn))))) | 63 | bn (1+ bn)))) |
| 64 | |||
| 65 | (setq-default fringe-indicator-alist | ||
| 66 | '((truncation . (left-arrow right-arrow)) | ||
| 67 | (continuation . (left-curly-arrow right-curly-arrow)) | ||
| 68 | (overlay-arrow . right-triangle) | ||
| 69 | (up . up-arrow) | ||
| 70 | (down . down-arrow) | ||
| 71 | (top . (top-left-angle top-right-angle)) | ||
| 72 | (bottom . (bottom-left-angle bottom-right-angle | ||
| 73 | top-right-angle top-left-angle)) | ||
| 74 | (top-bottom . (left-bracket right-bracket | ||
| 75 | top-right-angle top-left-angle)) | ||
| 76 | (empty-line . empty-line) | ||
| 77 | (unknown . question-mark))) | ||
| 78 | |||
| 79 | (setq-default fringe-cursor-alist | ||
| 80 | '((box . filled-rectangle) | ||
| 81 | (hollow . hollow-rectangle) | ||
| 82 | (bar . vertical-bar) | ||
| 83 | (hbar . horizontal-bar) | ||
| 84 | (hollow-small . hollow-square)))) | ||
| 85 | |||
| 86 | |||
| 87 | (defmacro fringe-bitmap-p (symbol) | ||
| 88 | "Return non-nil if SYMBOL is a fringe bitmap." | ||
| 89 | `(get ,symbol 'fringe)) | ||
| 69 | 90 | ||
| 70 | 91 | ||
| 71 | ;; Control presence of fringes | 92 | ;; Control presence of fringes |
| @@ -137,7 +158,6 @@ See `fringe-mode' for possible values and their effect." | |||
| 137 | ;; Otherwise impose the user-specified value of fringe-mode. | 158 | ;; Otherwise impose the user-specified value of fringe-mode. |
| 138 | (custom-initialize-reset symbol value)))) | 159 | (custom-initialize-reset symbol value)))) |
| 139 | 160 | ||
| 140 | ;;;###autoload | ||
| 141 | (defcustom fringe-mode nil | 161 | (defcustom fringe-mode nil |
| 142 | "*Specify appearance of fringes on all frames. | 162 | "*Specify appearance of fringes on all frames. |
| 143 | This variable can be nil (the default) meaning the fringes should have | 163 | This variable can be nil (the default) meaning the fringes should have |
| @@ -195,7 +215,6 @@ frame parameter is used." | |||
| 195 | nil | 215 | nil |
| 196 | 0))))) | 216 | 0))))) |
| 197 | 217 | ||
| 198 | ;;;###autoload | ||
| 199 | (defun fringe-mode (&optional mode) | 218 | (defun fringe-mode (&optional mode) |
| 200 | "Set the default appearance of fringes on all frames. | 219 | "Set the default appearance of fringes on all frames. |
| 201 | 220 | ||
| @@ -221,7 +240,6 @@ frame only, see the command `set-fringe-style'." | |||
| 221 | (interactive (list (fringe-query-style 'all-frames))) | 240 | (interactive (list (fringe-query-style 'all-frames))) |
| 222 | (set-fringe-mode mode)) | 241 | (set-fringe-mode mode)) |
| 223 | 242 | ||
| 224 | ;;;###autoload | ||
| 225 | (defun set-fringe-style (&optional mode) | 243 | (defun set-fringe-style (&optional mode) |
| 226 | "Set the default appearance of fringes on the selected frame. | 244 | "Set the default appearance of fringes on the selected frame. |
| 227 | 245 | ||
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 903be005174..c77c92d05c7 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog | |||
| @@ -1,3 +1,9 @@ | |||
| 1 | 2006-02-20 Katsumi Yamaoka <yamaoka@jpl.org> | ||
| 2 | |||
| 3 | * rfc2047.el (rfc2047-charset-to-coding-system): Don't check the | ||
| 4 | coding system which mm-charset-to-coding-system returns for a | ||
| 5 | given charset is valid. | ||
| 6 | |||
| 1 | 2006-02-16 Juanma Barranquero <lekktu@gmail.com> | 7 | 2006-02-16 Juanma Barranquero <lekktu@gmail.com> |
| 2 | 8 | ||
| 3 | * html2text.el (html2text-remove-tag-list): | 9 | * html2text.el (html2text-remove-tag-list): |
diff --git a/lisp/gnus/rfc2047.el b/lisp/gnus/rfc2047.el index 1167cb0a62b..501a161e83e 100644 --- a/lisp/gnus/rfc2047.el +++ b/lisp/gnus/rfc2047.el | |||
| @@ -835,7 +835,7 @@ If your Emacs implementation can't decode CHARSET, return nil." | |||
| 835 | (cond ((eq cs 'ascii) | 835 | (cond ((eq cs 'ascii) |
| 836 | (setq cs (or (mm-charset-to-coding-system mail-parse-charset) | 836 | (setq cs (or (mm-charset-to-coding-system mail-parse-charset) |
| 837 | 'raw-text))) | 837 | 'raw-text))) |
| 838 | ((setq cs (mm-coding-system-p cs))) | 838 | ((mm-coding-system-p cs)) |
| 839 | ((and charset | 839 | ((and charset |
| 840 | (listp mail-parse-ignored-charsets) | 840 | (listp mail-parse-ignored-charsets) |
| 841 | (memq 'gnus-unknown mail-parse-ignored-charsets)) | 841 | (memq 'gnus-unknown mail-parse-ignored-charsets)) |
diff --git a/lisp/help-fns.el b/lisp/help-fns.el index 32719275edd..d30fc02c409 100644 --- a/lisp/help-fns.el +++ b/lisp/help-fns.el | |||
| @@ -252,6 +252,7 @@ face (according to `face-differs-from-default-p')." | |||
| 252 | "\\)" | 252 | "\\)" |
| 253 | "\\(?:es\\|s\\|th\\)?" ; for ARGth, ARGs | 253 | "\\(?:es\\|s\\|th\\)?" ; for ARGth, ARGs |
| 254 | "\\(?:-[a-z0-9-]+\\)?" ; for ARG-xxx, ARG-n | 254 | "\\(?:-[a-z0-9-]+\\)?" ; for ARG-xxx, ARG-n |
| 255 | "\\(?:-[{([<`\"].*?\\)?"; for ARG-{x}, (x), <x>, [x], `x' | ||
| 255 | "\\>") ; end of word | 256 | "\\>") ; end of word |
| 256 | (help-default-arg-highlight arg) | 257 | (help-default-arg-highlight arg) |
| 257 | doc t t 1))))) | 258 | doc t t 1))))) |
diff --git a/lisp/help.el b/lisp/help.el index 02045948ecb..f74293b8dd6 100644 --- a/lisp/help.el +++ b/lisp/help.el | |||
| @@ -579,12 +579,8 @@ temporarily enables it to allow getting help on disabled items and buttons." | |||
| 579 | (setq key (read-key-sequence "Describe key (or click or menu item): ")) | 579 | (setq key (read-key-sequence "Describe key (or click or menu item): ")) |
| 580 | (list | 580 | (list |
| 581 | key | 581 | key |
| 582 | (prefix-numeric-value current-prefix-arg) | 582 | (if current-prefix-arg (prefix-numeric-value current-prefix-arg)) |
| 583 | ;; If KEY is a down-event, read the corresponding up-event | 583 | 1)) |
| 584 | ;; and use it as the third argument. | ||
| 585 | (if (and (consp key) (symbolp (car key)) | ||
| 586 | (memq 'down (cdr (get (car key) 'event-symbol-elements)))) | ||
| 587 | (read-event)))) | ||
| 588 | ;; Put yank-menu back as it was, if we changed it. | 584 | ;; Put yank-menu back as it was, if we changed it. |
| 589 | (when saved-yank-menu | 585 | (when saved-yank-menu |
| 590 | (setq yank-menu (copy-sequence saved-yank-menu)) | 586 | (setq yank-menu (copy-sequence saved-yank-menu)) |
diff --git a/lisp/icomplete.el b/lisp/icomplete.el index 191f1d324e6..f53ef7c91d1 100644 --- a/lisp/icomplete.el +++ b/lisp/icomplete.el | |||
| @@ -146,7 +146,7 @@ is minibuffer." | |||
| 146 | (if (commandp func-name) | 146 | (if (commandp func-name) |
| 147 | (save-excursion | 147 | (save-excursion |
| 148 | (let* ((sym (intern func-name)) | 148 | (let* ((sym (intern func-name)) |
| 149 | (buf (other-buffer)) | 149 | (buf (other-buffer nil t)) |
| 150 | (map (save-excursion (set-buffer buf) (current-local-map))) | 150 | (map (save-excursion (set-buffer buf) (current-local-map))) |
| 151 | (keys (where-is-internal sym map))) | 151 | (keys (where-is-internal sym map))) |
| 152 | (if keys | 152 | (if keys |
diff --git a/lisp/info.el b/lisp/info.el index e3514fb9729..e9d7f5ca2de 100644 --- a/lisp/info.el +++ b/lisp/info.el | |||
| @@ -622,12 +622,6 @@ just return nil (no error)." | |||
| 622 | (cond | 622 | (cond |
| 623 | ((string= (downcase filename) "dir") | 623 | ((string= (downcase filename) "dir") |
| 624 | (setq found t)) | 624 | (setq found t)) |
| 625 | ((string= filename "apropos") | ||
| 626 | (setq found 'apropos)) | ||
| 627 | ((string= filename "history") | ||
| 628 | (setq found 'history)) | ||
| 629 | ((string= filename "toc") | ||
| 630 | (setq found 'toc)) | ||
| 631 | (t | 625 | (t |
| 632 | (let ((dirs (if (string-match "^\\./" filename) | 626 | (let ((dirs (if (string-match "^\\./" filename) |
| 633 | ;; If specified name starts with `./' | 627 | ;; If specified name starts with `./' |
| @@ -673,7 +667,8 @@ just return nil (no error)." | |||
| 673 | (if noerror | 667 | (if noerror |
| 674 | (setq filename nil) | 668 | (setq filename nil) |
| 675 | (error "Info file %s does not exist" filename))) | 669 | (error "Info file %s does not exist" filename))) |
| 676 | filename))) | 670 | filename) |
| 671 | (and (member filename '(apropos history toc)) filename))) | ||
| 677 | 672 | ||
| 678 | (defun Info-find-node (filename nodename &optional no-going-back) | 673 | (defun Info-find-node (filename nodename &optional no-going-back) |
| 679 | "Go to an Info node specified as separate FILENAME and NODENAME. | 674 | "Go to an Info node specified as separate FILENAME and NODENAME. |
| @@ -891,9 +886,6 @@ a case-insensitive match is tried." | |||
| 891 | (setq Info-current-file | 886 | (setq Info-current-file |
| 892 | (cond | 887 | (cond |
| 893 | ((eq filename t) "dir") | 888 | ((eq filename t) "dir") |
| 894 | ((eq filename 'apropos) "apropos") | ||
| 895 | ((eq filename 'history) "history") | ||
| 896 | ((eq filename 'toc) "toc") | ||
| 897 | (t filename))) | 889 | (t filename))) |
| 898 | )) | 890 | )) |
| 899 | ;; Use string-equal, not equal, to ignore text props. | 891 | ;; Use string-equal, not equal, to ignore text props. |
| @@ -1409,7 +1401,7 @@ any double quotes or backslashes must be escaped (\\\",\\\\)." | |||
| 1409 | (if (stringp Info-current-file) | 1401 | (if (stringp Info-current-file) |
| 1410 | (replace-regexp-in-string | 1402 | (replace-regexp-in-string |
| 1411 | "%" "%%" (file-name-nondirectory Info-current-file)) | 1403 | "%" "%%" (file-name-nondirectory Info-current-file)) |
| 1412 | "") | 1404 | (format "*%S*" Info-current-file)) |
| 1413 | ") " | 1405 | ") " |
| 1414 | (if Info-current-node | 1406 | (if Info-current-node |
| 1415 | (propertize (replace-regexp-in-string | 1407 | (propertize (replace-regexp-in-string |
| @@ -1648,7 +1640,8 @@ If DIRECTION is `backward', search in the reverse direction." | |||
| 1648 | ;; Skip Tag Table node | 1640 | ;; Skip Tag Table node |
| 1649 | (save-excursion | 1641 | (save-excursion |
| 1650 | (and (search-backward "\^_" nil t) | 1642 | (and (search-backward "\^_" nil t) |
| 1651 | (looking-at "\^_\nTag Table")))))) | 1643 | (looking-at |
| 1644 | "\^_\n\\(Tag Table\\|Local Variables\\)")))))) | ||
| 1652 | (let ((search-spaces-regexp Info-search-whitespace-regexp)) | 1645 | (let ((search-spaces-regexp Info-search-whitespace-regexp)) |
| 1653 | (if (if backward | 1646 | (if (if backward |
| 1654 | (re-search-backward regexp bound t) | 1647 | (re-search-backward regexp bound t) |
| @@ -1736,7 +1729,8 @@ If DIRECTION is `backward', search in the reverse direction." | |||
| 1736 | ;; Skip Tag Table node | 1729 | ;; Skip Tag Table node |
| 1737 | (save-excursion | 1730 | (save-excursion |
| 1738 | (and (search-backward "\^_" nil t) | 1731 | (and (search-backward "\^_" nil t) |
| 1739 | (looking-at "\^_\nTag Table")))))) | 1732 | (looking-at |
| 1733 | "\^_\n\\(Tag Table\\|Local Variables\\)")))))) | ||
| 1740 | (let ((search-spaces-regexp Info-search-whitespace-regexp)) | 1734 | (let ((search-spaces-regexp Info-search-whitespace-regexp)) |
| 1741 | (if (if backward | 1735 | (if (if backward |
| 1742 | (re-search-backward regexp nil t) | 1736 | (re-search-backward regexp nil t) |
| @@ -1831,11 +1825,11 @@ If DIRECTION is `backward', search in the reverse direction." | |||
| 1831 | 1825 | ||
| 1832 | (defun Info-isearch-push-state () | 1826 | (defun Info-isearch-push-state () |
| 1833 | `(lambda (cmd) | 1827 | `(lambda (cmd) |
| 1834 | (Info-isearch-pop-state cmd ,Info-current-file ,Info-current-node))) | 1828 | (Info-isearch-pop-state cmd ',Info-current-file ',Info-current-node))) |
| 1835 | 1829 | ||
| 1836 | (defun Info-isearch-pop-state (cmd file node) | 1830 | (defun Info-isearch-pop-state (cmd file node) |
| 1837 | (or (and (string= Info-current-file file) | 1831 | (or (and (equal Info-current-file file) |
| 1838 | (string= Info-current-node node)) | 1832 | (equal Info-current-node node)) |
| 1839 | (progn (Info-find-node file node) (sit-for 0)))) | 1833 | (progn (Info-find-node file node) (sit-for 0)))) |
| 1840 | 1834 | ||
| 1841 | (defun Info-isearch-start () | 1835 | (defun Info-isearch-start () |
| @@ -1853,7 +1847,7 @@ if ERRORNAME is nil, just return nil." | |||
| 1853 | (forward-line 1) | 1847 | (forward-line 1) |
| 1854 | (cond ((re-search-backward | 1848 | (cond ((re-search-backward |
| 1855 | (concat name ":" (Info-following-node-name-re)) bound t) | 1849 | (concat name ":" (Info-following-node-name-re)) bound t) |
| 1856 | (match-string 1)) | 1850 | (match-string-no-properties 1)) |
| 1857 | ((not (eq errorname t)) | 1851 | ((not (eq errorname t)) |
| 1858 | (error "Node has no %s" | 1852 | (error "Node has no %s" |
| 1859 | (capitalize (or errorname name))))))))) | 1853 | (capitalize (or errorname name))))))))) |
| @@ -1875,7 +1869,7 @@ End of submatch 0, 1, and 3 are the same, so you can safely concat." | |||
| 1875 | ;;; For compatibility; other files have used this name. | 1869 | ;;; For compatibility; other files have used this name. |
| 1876 | (defun Info-following-node-name () | 1870 | (defun Info-following-node-name () |
| 1877 | (and (looking-at (Info-following-node-name-re)) | 1871 | (and (looking-at (Info-following-node-name-re)) |
| 1878 | (match-string 1))) | 1872 | (match-string-no-properties 1))) |
| 1879 | 1873 | ||
| 1880 | (defun Info-next () | 1874 | (defun Info-next () |
| 1881 | "Go to the next node of this node." | 1875 | "Go to the next node of this node." |
| @@ -1909,7 +1903,8 @@ If SAME-FILE is non-nil, do not move to a different Info file." | |||
| 1909 | (Info-goto-node node) | 1903 | (Info-goto-node node) |
| 1910 | (setq p (point)) | 1904 | (setq p (point)) |
| 1911 | (goto-char (point-min)) | 1905 | (goto-char (point-min)) |
| 1912 | (if (and (search-forward "\n* Menu:" nil t) | 1906 | (if (and (stringp old-file) |
| 1907 | (search-forward "\n* Menu:" nil t) | ||
| 1913 | (re-search-forward | 1908 | (re-search-forward |
| 1914 | (if (string-equal old-node "Top") | 1909 | (if (string-equal old-node "Top") |
| 1915 | (concat "\n\\*[^:]+: +(" (file-name-nondirectory old-file) ")") | 1910 | (concat "\n\\*[^:]+: +(" (file-name-nondirectory old-file) ")") |
| @@ -1977,51 +1972,53 @@ If SAME-FILE is non-nil, do not move to a different Info file." | |||
| 1977 | (while hl | 1972 | (while hl |
| 1978 | (let ((file (nth 0 (car hl))) | 1973 | (let ((file (nth 0 (car hl))) |
| 1979 | (node (nth 1 (car hl)))) | 1974 | (node (nth 1 (car hl)))) |
| 1980 | (if (and (string-equal file curr-file) | 1975 | (if (and (equal file curr-file) |
| 1981 | (string-equal node curr-node)) | 1976 | (equal node curr-node)) |
| 1982 | (setq p (point))) | 1977 | (setq p (point))) |
| 1983 | (insert "* " node ": (" | 1978 | (if (stringp file) |
| 1984 | (propertize (or (file-name-directory file) "") 'invisible t) | 1979 | (insert "* " node ": (" |
| 1985 | (file-name-nondirectory file) | 1980 | (propertize (or (file-name-directory file) "") 'invisible t) |
| 1986 | ")" node ".\n")) | 1981 | (file-name-nondirectory file) |
| 1982 | ")" node ".\n"))) | ||
| 1987 | (setq hl (cdr hl)))))) | 1983 | (setq hl (cdr hl)))))) |
| 1988 | (Info-find-node "history" "Top") | 1984 | (Info-find-node 'history "Top") |
| 1989 | (goto-char (or p (point-min))))) | 1985 | (goto-char (or p (point-min))))) |
| 1990 | 1986 | ||
| 1991 | (defun Info-toc () | 1987 | (defun Info-toc () |
| 1992 | "Go to a node with table of contents of the current Info file. | 1988 | "Go to a node with table of contents of the current Info file. |
| 1993 | Table of contents is created from the tree structure of menus." | 1989 | Table of contents is created from the tree structure of menus." |
| 1994 | (interactive) | 1990 | (interactive) |
| 1995 | (let ((curr-file (substring-no-properties Info-current-file)) | 1991 | (if (stringp Info-current-file) |
| 1996 | (curr-node (substring-no-properties Info-current-node)) | 1992 | (let ((curr-file (substring-no-properties Info-current-file)) |
| 1997 | p) | 1993 | (curr-node (substring-no-properties Info-current-node)) |
| 1998 | (with-current-buffer (get-buffer-create " *info-toc*") | 1994 | p) |
| 1999 | (let ((inhibit-read-only t) | 1995 | (with-current-buffer (get-buffer-create " *info-toc*") |
| 2000 | (node-list (Info-build-toc curr-file))) | 1996 | (let ((inhibit-read-only t) |
| 2001 | (erase-buffer) | 1997 | (node-list (Info-build-toc curr-file))) |
| 2002 | (goto-char (point-min)) | 1998 | (erase-buffer) |
| 2003 | (insert "\n\^_\nFile: toc, Node: Top, Up: (dir)\n\n") | 1999 | (goto-char (point-min)) |
| 2004 | (insert "Table of Contents\n*****************\n\n") | 2000 | (insert "\n\^_\nFile: toc, Node: Top, Up: (dir)\n\n") |
| 2005 | (insert "*Note Top: (" curr-file ")Top.\n") | 2001 | (insert "Table of Contents\n*****************\n\n") |
| 2006 | (Info-insert-toc | 2002 | (insert "*Note Top: (" curr-file ")Top.\n") |
| 2007 | (nth 2 (assoc "Top" node-list)) ; get Top nodes | 2003 | (Info-insert-toc |
| 2008 | node-list 0 curr-file)) | 2004 | (nth 2 (assoc "Top" node-list)) ; get Top nodes |
| 2009 | (if (not (bobp)) | 2005 | node-list 0 curr-file)) |
| 2010 | (let ((Info-hide-note-references 'hide) | 2006 | (if (not (bobp)) |
| 2011 | (Info-fontify-visited-nodes nil)) | 2007 | (let ((Info-hide-note-references 'hide) |
| 2012 | (Info-mode) | 2008 | (Info-fontify-visited-nodes nil)) |
| 2013 | (setq Info-current-file "toc" Info-current-node "Top") | 2009 | (Info-mode) |
| 2014 | (goto-char (point-min)) | 2010 | (setq Info-current-file 'toc Info-current-node "Top") |
| 2015 | (narrow-to-region (or (re-search-forward "\n[\^_\f]\n" nil t) | 2011 | (goto-char (point-min)) |
| 2016 | (point-min)) | 2012 | (narrow-to-region (or (re-search-forward "\n[\^_\f]\n" nil t) |
| 2017 | (point-max)) | 2013 | (point-min)) |
| 2018 | (Info-fontify-node) | 2014 | (point-max)) |
| 2019 | (widen))) | 2015 | (Info-fontify-node) |
| 2020 | (goto-char (point-min)) | 2016 | (widen))) |
| 2021 | (if (setq p (search-forward (concat "*Note " curr-node ":") nil t)) | 2017 | (goto-char (point-min)) |
| 2022 | (setq p (- p (length curr-node) 2)))) | 2018 | (if (setq p (search-forward (concat "*Note " curr-node ":") nil t)) |
| 2023 | (Info-find-node "toc" "Top") | 2019 | (setq p (- p (length curr-node) 2)))) |
| 2024 | (goto-char (or p (point-min))))) | 2020 | (Info-find-node 'toc "Top") |
| 2021 | (goto-char (or p (point-min)))))) | ||
| 2025 | 2022 | ||
| 2026 | (defun Info-insert-toc (nodes node-list level curr-file) | 2023 | (defun Info-insert-toc (nodes node-list level curr-file) |
| 2027 | "Insert table of contents with references to nodes." | 2024 | "Insert table of contents with references to nodes." |
| @@ -2221,16 +2218,18 @@ Because of ambiguities, this should be concatenated with something like | |||
| 2221 | (setq Info-point-loc | 2218 | (setq Info-point-loc |
| 2222 | (if (match-beginning 5) | 2219 | (if (match-beginning 5) |
| 2223 | (string-to-number (match-string 5)) | 2220 | (string-to-number (match-string 5)) |
| 2224 | (buffer-substring (match-beginning 0) (1- (match-beginning 1))))) | 2221 | (buffer-substring-no-properties |
| 2222 | (match-beginning 0) (1- (match-beginning 1))))) | ||
| 2225 | ;;; Uncomment next line to use names of cross-references in non-index nodes: | 2223 | ;;; Uncomment next line to use names of cross-references in non-index nodes: |
| 2226 | ;;; (setq Info-point-loc | 2224 | ;;; (setq Info-point-loc |
| 2227 | ;;; (buffer-substring (match-beginning 0) (1- (match-beginning 1)))) | 2225 | ;;; (buffer-substring (match-beginning 0) (1- (match-beginning 1)))) |
| 2228 | ) | 2226 | ) |
| 2229 | (replace-regexp-in-string | 2227 | (replace-regexp-in-string |
| 2230 | "[ \n]+" " " | 2228 | "[ \n]+" " " |
| 2231 | (or (match-string 2) | 2229 | (or (match-string-no-properties 2) |
| 2232 | ;; If the node name is the menu entry name (using `entry::'). | 2230 | ;; If the node name is the menu entry name (using `entry::'). |
| 2233 | (buffer-substring (match-beginning 0) (1- (match-beginning 1))))))) | 2231 | (buffer-substring-no-properties |
| 2232 | (match-beginning 0) (1- (match-beginning 1))))))) | ||
| 2234 | 2233 | ||
| 2235 | ;; No one calls this. | 2234 | ;; No one calls this. |
| 2236 | ;;(defun Info-menu-item-sequence (list) | 2235 | ;;(defun Info-menu-item-sequence (list) |
| @@ -2684,7 +2683,7 @@ following nodes whose names also contain the word \"Index\"." | |||
| 2684 | (or file (setq file Info-current-file)) | 2683 | (or file (setq file Info-current-file)) |
| 2685 | (or (assoc file Info-index-nodes) | 2684 | (or (assoc file Info-index-nodes) |
| 2686 | ;; Skip virtual Info files | 2685 | ;; Skip virtual Info files |
| 2687 | (and (member file '("dir" "history" "toc" "apropos")) | 2686 | (and (member file '("dir" apropos history toc)) |
| 2688 | (setq Info-index-nodes (cons (cons file nil) Info-index-nodes))) | 2687 | (setq Info-index-nodes (cons (cons file nil) Info-index-nodes))) |
| 2689 | (not (stringp file)) | 2688 | (not (stringp file)) |
| 2690 | (if Info-file-supports-index-cookies | 2689 | (if Info-file-supports-index-cookies |
| @@ -2926,7 +2925,7 @@ Build a menu of the possible matches." | |||
| 2926 | (message "%s" (if (eq (car-safe err) 'error) | 2925 | (message "%s" (if (eq (car-safe err) 'error) |
| 2927 | (nth 1 err) err)) | 2926 | (nth 1 err) err)) |
| 2928 | (sit-for 1 t))))) | 2927 | (sit-for 1 t))))) |
| 2929 | (Info-goto-node (concat "(" current-file ")" current-node)) | 2928 | (Info-find-node current-file current-node) |
| 2930 | (setq Info-history ohist | 2929 | (setq Info-history ohist |
| 2931 | Info-history-list ohist-list) | 2930 | Info-history-list ohist-list) |
| 2932 | (message "Searching indices...done") | 2931 | (message "Searching indices...done") |
| @@ -2945,7 +2944,7 @@ Build a menu of the possible matches." | |||
| 2945 | (if (nth 3 entry) | 2944 | (if (nth 3 entry) |
| 2946 | (concat " (line " (nth 3 entry) ")") | 2945 | (concat " (line " (nth 3 entry) ")") |
| 2947 | ""))))) | 2946 | ""))))) |
| 2948 | (Info-find-node "apropos" "Index") | 2947 | (Info-find-node 'apropos "Index") |
| 2949 | (setq Info-complete-cache nil))))) | 2948 | (setq Info-complete-cache nil))))) |
| 2950 | 2949 | ||
| 2951 | (defun Info-undefined () | 2950 | (defun Info-undefined () |
| @@ -3287,10 +3286,14 @@ With a zero prefix arg, put the name inside a function call to `info'." | |||
| 3287 | (interactive "P") | 3286 | (interactive "P") |
| 3288 | (unless Info-current-node | 3287 | (unless Info-current-node |
| 3289 | (error "No current Info node")) | 3288 | (error "No current Info node")) |
| 3290 | (let ((node (concat "(" (file-name-nondirectory Info-current-file) ")" | 3289 | (let ((node (if (stringp Info-current-file) |
| 3291 | Info-current-node))) | 3290 | (concat "(" (file-name-nondirectory Info-current-file) ")" |
| 3291 | Info-current-node)))) | ||
| 3292 | (if (zerop (prefix-numeric-value arg)) | 3292 | (if (zerop (prefix-numeric-value arg)) |
| 3293 | (setq node (concat "(info \"" node "\")"))) | 3293 | (setq node (concat "(info \"" node "\")"))) |
| 3294 | (unless (stringp Info-current-file) | ||
| 3295 | (setq node (format "(Info-find-node '%S '%S)" | ||
| 3296 | Info-current-file Info-current-node))) | ||
| 3294 | (kill-new node) | 3297 | (kill-new node) |
| 3295 | (message "%s" node))) | 3298 | (message "%s" node))) |
| 3296 | 3299 | ||
| @@ -3817,29 +3820,30 @@ the variable `Info-file-list-for-emacs'." | |||
| 3817 | "^[ \t]+" "" | 3820 | "^[ \t]+" "" |
| 3818 | (replace-regexp-in-string | 3821 | (replace-regexp-in-string |
| 3819 | "[ \t\n]+" " " | 3822 | "[ \t\n]+" " " |
| 3820 | (or (match-string 5) | 3823 | (or (match-string-no-properties 5) |
| 3821 | (and (not (equal (match-string 4) "")) | 3824 | (and (not (equal (match-string 4) "")) |
| 3822 | (match-string 4)) | 3825 | (match-string-no-properties 4)) |
| 3823 | (match-string 2))))) | 3826 | (match-string-no-properties 2))))) |
| 3824 | (external-link-p | 3827 | (external-link-p |
| 3825 | (string-match "(\\([^)]+\\))\\([^)]*\\)" node)) | 3828 | (string-match "(\\([^)]+\\))\\([^)]*\\)" node)) |
| 3826 | (file (if external-link-p | 3829 | (file (if external-link-p |
| 3827 | (file-name-nondirectory | 3830 | (file-name-nondirectory |
| 3828 | (match-string 1 node)) | 3831 | (match-string-no-properties 1 node)) |
| 3829 | Info-current-file)) | 3832 | Info-current-file)) |
| 3830 | (hl Info-history-list) | 3833 | (hl Info-history-list) |
| 3831 | res) | 3834 | res) |
| 3832 | (if external-link-p | 3835 | (if external-link-p |
| 3833 | (setq node (if (equal (match-string 2 node) "") | 3836 | (setq node (if (equal (match-string 2 node) "") |
| 3834 | "Top" | 3837 | "Top" |
| 3835 | (match-string 2 node)))) | 3838 | (match-string-no-properties 2 node)))) |
| 3836 | (while hl | 3839 | (while hl |
| 3837 | (if (and (string-equal node (nth 1 (car hl))) | 3840 | (if (and (string-equal node (nth 1 (car hl))) |
| 3838 | (string-equal | 3841 | (equal file |
| 3839 | file (if external-link-p | 3842 | (if (and external-link-p |
| 3840 | (file-name-nondirectory | 3843 | (stringp (caar hl))) |
| 3841 | (caar hl)) | 3844 | (file-name-nondirectory |
| 3842 | (caar hl)))) | 3845 | (caar hl)) |
| 3846 | (caar hl)))) | ||
| 3843 | (setq res (car hl) hl nil) | 3847 | (setq res (car hl) hl nil) |
| 3844 | (setq hl (cdr hl)))) | 3848 | (setq hl (cdr hl)))) |
| 3845 | res))) 'info-xref-visited 'info-xref)) | 3849 | res))) 'info-xref-visited 'info-xref)) |
| @@ -3932,26 +3936,28 @@ the variable `Info-file-list-for-emacs'." | |||
| 3932 | (if (and Info-fontify-visited-nodes | 3936 | (if (and Info-fontify-visited-nodes |
| 3933 | (save-match-data | 3937 | (save-match-data |
| 3934 | (let* ((node (if (equal (match-string 3) "") | 3938 | (let* ((node (if (equal (match-string 3) "") |
| 3935 | (match-string 1) | 3939 | (match-string-no-properties 1) |
| 3936 | (match-string 3))) | 3940 | (match-string-no-properties 3))) |
| 3937 | (external-link-p | 3941 | (external-link-p |
| 3938 | (string-match "(\\([^)]+\\))\\([^)]*\\)" node)) | 3942 | (string-match "(\\([^)]+\\))\\([^)]*\\)" node)) |
| 3939 | (file (if external-link-p | 3943 | (file (if external-link-p |
| 3940 | (file-name-nondirectory | 3944 | (file-name-nondirectory |
| 3941 | (match-string 1 node)) | 3945 | (match-string-no-properties 1 node)) |
| 3942 | Info-current-file)) | 3946 | Info-current-file)) |
| 3943 | (hl Info-history-list) | 3947 | (hl Info-history-list) |
| 3944 | res) | 3948 | res) |
| 3945 | (if external-link-p | 3949 | (if external-link-p |
| 3946 | (setq node (if (equal (match-string 2 node) "") | 3950 | (setq node (if (equal (match-string 2 node) "") |
| 3947 | "Top" | 3951 | "Top" |
| 3948 | (match-string 2 node)))) | 3952 | (match-string-no-properties 2 node)))) |
| 3949 | (while hl | 3953 | (while hl |
| 3950 | (if (and (string-equal node (nth 1 (car hl))) | 3954 | (if (and (string-equal node (nth 1 (car hl))) |
| 3951 | (string-equal | 3955 | (equal file |
| 3952 | file (if external-link-p | 3956 | (if (and external-link-p |
| 3953 | (file-name-nondirectory (caar hl)) | 3957 | (stringp (caar hl))) |
| 3954 | (caar hl)))) | 3958 | (file-name-nondirectory |
| 3959 | (caar hl)) | ||
| 3960 | (caar hl)))) | ||
| 3955 | (setq res (car hl) hl nil) | 3961 | (setq res (car hl) hl nil) |
| 3956 | (setq hl (cdr hl)))) | 3962 | (setq hl (cdr hl)))) |
| 3957 | res))) 'info-xref-visited 'info-xref))) | 3963 | res))) 'info-xref-visited 'info-xref))) |
| @@ -4210,8 +4216,8 @@ BUFFER is the buffer speedbar is requesting buttons for." | |||
| 4210 | 4216 | ||
| 4211 | (defun Info-desktop-buffer-misc-data (desktop-dirname) | 4217 | (defun Info-desktop-buffer-misc-data (desktop-dirname) |
| 4212 | "Auxiliary information to be saved in desktop file." | 4218 | "Auxiliary information to be saved in desktop file." |
| 4213 | (if (not (member Info-current-file '("apropos" "history" "toc"))) | 4219 | (unless (member Info-current-file '(apropos history toc nil)) |
| 4214 | (list Info-current-file Info-current-node))) | 4220 | (list Info-current-file Info-current-node))) |
| 4215 | 4221 | ||
| 4216 | (defun Info-restore-desktop-buffer (desktop-buffer-file-name | 4222 | (defun Info-restore-desktop-buffer (desktop-buffer-file-name |
| 4217 | desktop-buffer-name | 4223 | desktop-buffer-name |
diff --git a/lisp/isearch.el b/lisp/isearch.el index c97f5062c61..32228aa6eb9 100644 --- a/lisp/isearch.el +++ b/lisp/isearch.el | |||
| @@ -116,8 +116,11 @@ When you put a space or spaces in the incremental regexp, it stands for | |||
| 116 | this, unless it is inside of a regexp construct such as [...] or *, + or ?. | 116 | this, unless it is inside of a regexp construct such as [...] or *, + or ?. |
| 117 | You might want to use something like \"[ \\t\\r\\n]+\" instead. | 117 | You might want to use something like \"[ \\t\\r\\n]+\" instead. |
| 118 | In the Customization buffer, that is `[' followed by a space, | 118 | In the Customization buffer, that is `[' followed by a space, |
| 119 | a tab, a carriage return (control-M), a newline, and `]+'." | 119 | a tab, a carriage return (control-M), a newline, and `]+'. |
| 120 | :type 'regexp | 120 | |
| 121 | When this is nil, each space you type matches literally, against one space." | ||
| 122 | :type '(choice (const :tag "Find Spaces Literally" nil) | ||
| 123 | regexp) | ||
| 121 | :group 'isearch) | 124 | :group 'isearch) |
| 122 | 125 | ||
| 123 | (defcustom search-invisible 'open | 126 | (defcustom search-invisible 'open |
diff --git a/lisp/loadup.el b/lisp/loadup.el index 58219104e40..00e9e35ff60 100644 --- a/lisp/loadup.el +++ b/lisp/loadup.el | |||
| @@ -163,6 +163,7 @@ | |||
| 163 | 163 | ||
| 164 | (if (fboundp 'x-create-frame) | 164 | (if (fboundp 'x-create-frame) |
| 165 | (progn | 165 | (progn |
| 166 | (load "fringe") | ||
| 166 | (load "image") | 167 | (load "image") |
| 167 | (load "international/fontset") | 168 | (load "international/fontset") |
| 168 | (load "dnd") | 169 | (load "dnd") |
diff --git a/lisp/mh-e/ChangeLog b/lisp/mh-e/ChangeLog index e5262693d8a..a1043c6c6ee 100644 --- a/lisp/mh-e/ChangeLog +++ b/lisp/mh-e/ChangeLog | |||
| @@ -1,3 +1,53 @@ | |||
| 1 | 2006-02-21 Eric Ding <ericding@alum.mit.edu> | ||
| 2 | |||
| 3 | * mh-e.el (mh-invisible-header-fields-internal): Added entry | ||
| 4 | "X-Sasl-enc:" | ||
| 5 | |||
| 6 | 2006-02-20 Eric Ding <ericding@alum.mit.edu> | ||
| 7 | |||
| 8 | * mh-e.el (mh-invisible-header-fields-internal): Added entries | ||
| 9 | "X-Authenticated-Sender:", "X-Barracuda-", "X-EFL-Spamscore", | ||
| 10 | "X-IronPort-AV:", "X-Mail-from:", "X-Mailman-Approved-At:", | ||
| 11 | "X-Resolved-to:", and "X-SA-Exim". Fixed "X-Bugzilla-" and | ||
| 12 | "X-Roving-" by removing unnecessary "*" at end. | ||
| 13 | |||
| 14 | 2006-02-19 Bill Wohler <wohler@newt.com> | ||
| 15 | |||
| 16 | * mh-alias.el (mh-address-mail-regexp) | ||
| 17 | (mh-goto-address-find-address-at-point): Delete copies from | ||
| 18 | goto-addr.el. | ||
| 19 | (mh-alias-suggest-alias): Use goto-address-mail-regexp instead of | ||
| 20 | mh-address-mail-regexp. | ||
| 21 | (mh-alias-add-address-under-point): Use | ||
| 22 | goto-address-find-address-at-point instead of | ||
| 23 | mh-goto-address-find-address-at-point. | ||
| 24 | |||
| 25 | * mh-e.el (mh-show-use-goto-addr-flag): Delete. | ||
| 26 | |||
| 27 | * mh-show.el (mh-show-mode): Mention goto-address-highlight-p in | ||
| 28 | docstring. | ||
| 29 | (mh-show-addr): Call goto-address unconditionally. User should use | ||
| 30 | goto-address-highlight-p instead of mh-show-use-goto-addr-flag. | ||
| 31 | |||
| 32 | 2006-02-18 Bill Wohler <wohler@newt.com> | ||
| 33 | |||
| 34 | * mh-e.el (Version, mh-version): Add +cvs to version. | ||
| 35 | |||
| 36 | 2006-02-18 Bill Wohler <wohler@newt.com> | ||
| 37 | |||
| 38 | Release MH-E version 7.92. | ||
| 39 | |||
| 40 | * mh-e.el (Version, mh-version): Update for release 7.92. | ||
| 41 | |||
| 42 | 2006-02-17 Bill Wohler <wohler@newt.com> | ||
| 43 | |||
| 44 | * mh-e.el (mh-folder-msg-number): Use purple on low-color, light | ||
| 45 | backgrounds per Mark's suggestion. | ||
| 46 | |||
| 47 | * mh-utils.el (mh-image-load-path): Fix problem that images on | ||
| 48 | load-path or image-load-path would win over relative paths (newer | ||
| 49 | MH-E or Emacs distribution). | ||
| 50 | |||
| 1 | 2006-02-16 Bill Wohler <wohler@newt.com> | 51 | 2006-02-16 Bill Wohler <wohler@newt.com> |
| 2 | 52 | ||
| 3 | * mh-e.el (mh-inherit-face-flag): New variable. Non-nil means that | 53 | * mh-e.el (mh-inherit-face-flag): New variable. Non-nil means that |
diff --git a/lisp/mh-e/mh-alias.el b/lisp/mh-e/mh-alias.el index 9dc2871241f..6dba65d69df 100644 --- a/lisp/mh-e/mh-alias.el +++ b/lisp/mh-e/mh-alias.el | |||
| @@ -35,6 +35,8 @@ | |||
| 35 | 35 | ||
| 36 | (mh-require-cl) | 36 | (mh-require-cl) |
| 37 | 37 | ||
| 38 | (require 'goto-addr) | ||
| 39 | |||
| 38 | (defvar mh-alias-alist 'not-read | 40 | (defvar mh-alias-alist 'not-read |
| 39 | "Alist of MH aliases.") | 41 | "Alist of MH aliases.") |
| 40 | (defvar mh-alias-blind-alist nil | 42 | (defvar mh-alias-blind-alist nil |
| @@ -62,11 +64,6 @@ alias files listed in your \"Aliasfile:\" MH profile component are | |||
| 62 | automatically included. You can update the alias list manually using | 64 | automatically included. You can update the alias list manually using |
| 63 | \\[mh-alias-reload].") | 65 | \\[mh-alias-reload].") |
| 64 | 66 | ||
| 65 | ;; Copy of `goto-address-mail-regexp'. | ||
| 66 | (defvar mh-address-mail-regexp | ||
| 67 | "[-a-zA-Z0-9._]+@\\([-a-zA-z0-9_]+\\.\\)+[a-zA-Z0-9]+" | ||
| 68 | "A regular expression probably matching an e-mail address.") | ||
| 69 | |||
| 70 | 67 | ||
| 71 | 68 | ||
| 72 | ;;; Alias Loading | 69 | ;;; Alias Loading |
| @@ -343,7 +340,7 @@ NO-COMMA-SWAP is non-nil." | |||
| 343 | ((string-match "^\\(.*\\) +<.*>$" string) | 340 | ((string-match "^\\(.*\\) +<.*>$" string) |
| 344 | ;; Some name <somename@foo.bar> -> recurse -> Some name | 341 | ;; Some name <somename@foo.bar> -> recurse -> Some name |
| 345 | (mh-alias-suggest-alias (match-string 1 string) no-comma-swap)) | 342 | (mh-alias-suggest-alias (match-string 1 string) no-comma-swap)) |
| 346 | ((string-match (concat mh-address-mail-regexp " +(\\(.*\\))$") string) | 343 | ((string-match (concat goto-address-mail-regexp " +(\\(.*\\))$") string) |
| 347 | ;; somename@foo.bar (Some name) -> recurse -> Some name | 344 | ;; somename@foo.bar (Some name) -> recurse -> Some name |
| 348 | (mh-alias-suggest-alias (match-string 1 string) no-comma-swap)) | 345 | (mh-alias-suggest-alias (match-string 1 string) no-comma-swap)) |
| 349 | ((string-match "^\\(Dr\\|Prof\\)\\.? +\\(.*\\)" string) | 346 | ((string-match "^\\(Dr\\|Prof\\)\\.? +\\(.*\\)" string) |
| @@ -595,24 +592,11 @@ filing messages." | |||
| 595 | (defun mh-alias-add-address-under-point () | 592 | (defun mh-alias-add-address-under-point () |
| 596 | "Insert an alias for address under point." | 593 | "Insert an alias for address under point." |
| 597 | (interactive) | 594 | (interactive) |
| 598 | (let ((address (mh-goto-address-find-address-at-point))) | 595 | (let ((address (goto-address-find-address-at-point))) |
| 599 | (if address | 596 | (if address |
| 600 | (mh-alias-add-alias nil address) | 597 | (mh-alias-add-alias nil address) |
| 601 | (message "No email address found under point")))) | 598 | (message "No email address found under point")))) |
| 602 | 599 | ||
| 603 | ;; From goto-addr.el, which we don't want to force-load on users. | ||
| 604 | (defun mh-goto-address-find-address-at-point () | ||
| 605 | "Find e-mail address around or before point. | ||
| 606 | |||
| 607 | Then search backwards to beginning of line for the start of an | ||
| 608 | e-mail address. If no e-mail address found, return nil." | ||
| 609 | (re-search-backward "[^-_A-z0-9.@]" (mh-line-beginning-position) 'lim) | ||
| 610 | (if (or (looking-at mh-address-mail-regexp) ; already at start | ||
| 611 | (and (re-search-forward mh-address-mail-regexp | ||
| 612 | (mh-line-end-position) 'lim) | ||
| 613 | (goto-char (match-beginning 0)))) | ||
| 614 | (mh-match-string-no-properties 0))) | ||
| 615 | |||
| 616 | (defun mh-alias-apropos (regexp) | 600 | (defun mh-alias-apropos (regexp) |
| 617 | "Show all aliases or addresses that match a regular expression REGEXP." | 601 | "Show all aliases or addresses that match a regular expression REGEXP." |
| 618 | (interactive "sAlias regexp: ") | 602 | (interactive "sAlias regexp: ") |
diff --git a/lisp/mh-e/mh-e.el b/lisp/mh-e/mh-e.el index 26b1ddd8050..5a07524aec4 100644 --- a/lisp/mh-e/mh-e.el +++ b/lisp/mh-e/mh-e.el | |||
| @@ -6,7 +6,7 @@ | |||
| 6 | 6 | ||
| 7 | ;; Author: Bill Wohler <wohler@newt.com> | 7 | ;; Author: Bill Wohler <wohler@newt.com> |
| 8 | ;; Maintainer: Bill Wohler <wohler@newt.com> | 8 | ;; Maintainer: Bill Wohler <wohler@newt.com> |
| 9 | ;; Version: 7.91+cvs | 9 | ;; Version: 7.92+cvs |
| 10 | ;; Keywords: mail | 10 | ;; Keywords: mail |
| 11 | 11 | ||
| 12 | ;; This file is part of GNU Emacs. | 12 | ;; This file is part of GNU Emacs. |
| @@ -121,7 +121,7 @@ | |||
| 121 | ;; Try to keep variables local to a single file. Provide accessors if | 121 | ;; Try to keep variables local to a single file. Provide accessors if |
| 122 | ;; variables are shared. Use this section as a last resort. | 122 | ;; variables are shared. Use this section as a last resort. |
| 123 | 123 | ||
| 124 | (defconst mh-version "7.91+cvs" "Version number of MH-E.") | 124 | (defconst mh-version "7.92+cvs" "Version number of MH-E.") |
| 125 | 125 | ||
| 126 | ;; Variants | 126 | ;; Variants |
| 127 | 127 | ||
| @@ -2303,17 +2303,20 @@ of citations entirely, choose \"None\"." | |||
| 2303 | "X-AntiAbuse:" ; cPanel | 2303 | "X-AntiAbuse:" ; cPanel |
| 2304 | "X-Apparently-From:" ; MS Outlook | 2304 | "X-Apparently-From:" ; MS Outlook |
| 2305 | "X-Apparently-To:" ; Egroups/yahoogroups mailing list manager | 2305 | "X-Apparently-To:" ; Egroups/yahoogroups mailing list manager |
| 2306 | "X-Authenticated-Sender:" ; AT&T Message Center (webmail) | ||
| 2306 | "X-Authentication-Warning:" ; sendmail | 2307 | "X-Authentication-Warning:" ; sendmail |
| 2308 | "X-Barracuda-" ; Barracuda spam scores | ||
| 2307 | "X-Beenthere:" ; Mailman mailing list manager | 2309 | "X-Beenthere:" ; Mailman mailing list manager |
| 2308 | "X-Bogosity:" ; bogofilter | 2310 | "X-Bogosity:" ; bogofilter |
| 2309 | "X-BrightmailFiltered:" ; Brightmail | 2311 | "X-BrightmailFiltered:" ; Brightmail |
| 2310 | "X-Brightmail-Tracker:" ; Brightmail | 2312 | "X-Brightmail-Tracker:" ; Brightmail |
| 2311 | "X-Bugzilla-*" ; Bugzilla | 2313 | "X-Bugzilla-" ; Bugzilla |
| 2312 | "X-Complaints-To:" | 2314 | "X-Complaints-To:" |
| 2313 | "X-ContentStamp:" ; NetZero | 2315 | "X-ContentStamp:" ; NetZero |
| 2314 | "X-Cron-Env:" | 2316 | "X-Cron-Env:" |
| 2315 | "X-DMCA" | 2317 | "X-DMCA" |
| 2316 | "X-Delivered" | 2318 | "X-Delivered" |
| 2319 | "X-EFL-Spamscore:" ; MIT alumni spam filtering | ||
| 2317 | "X-ELNK-Trace:" ; Earthlink mailer | 2320 | "X-ELNK-Trace:" ; Earthlink mailer |
| 2318 | "X-Envelope-Date:" ; GNU mailutils | 2321 | "X-Envelope-Date:" ; GNU mailutils |
| 2319 | "X-Envelope-From:" | 2322 | "X-Envelope-From:" |
| @@ -2337,6 +2340,7 @@ of citations entirely, choose \"None\"." | |||
| 2337 | "X-Habeas-SWE-9:" ; Spam | 2340 | "X-Habeas-SWE-9:" ; Spam |
| 2338 | "X-Hashcash:" ; hashcash | 2341 | "X-Hashcash:" ; hashcash |
| 2339 | "X-Info:" ; NTMail | 2342 | "X-Info:" ; NTMail |
| 2343 | "X-IronPort-AV:" ; IronPort AV | ||
| 2340 | "X-Juno-" ; Juno | 2344 | "X-Juno-" ; Juno |
| 2341 | "X-List-Host:" ; Unknown mailing list managers | 2345 | "X-List-Host:" ; Unknown mailing list managers |
| 2342 | "X-List-Subscribe:" ; Unknown mailing list managers | 2346 | "X-List-Subscribe:" ; Unknown mailing list managers |
| @@ -2346,12 +2350,14 @@ of citations entirely, choose \"None\"." | |||
| 2346 | "X-Loop:" ; Unknown mailing list managers | 2350 | "X-Loop:" ; Unknown mailing list managers |
| 2347 | "X-Lumos-SenderID:" ; Roving ConstantContact | 2351 | "X-Lumos-SenderID:" ; Roving ConstantContact |
| 2348 | "X-MAIL-INFO:" ; NetZero | 2352 | "X-MAIL-INFO:" ; NetZero |
| 2349 | "X-MHE-Checksum" ; Checksum added during index search | 2353 | "X-MHE-Checksum:" ; Checksum added during index search |
| 2350 | "X-MIME-Autoconverted:" ; sendmail | 2354 | "X-MIME-Autoconverted:" ; sendmail |
| 2351 | "X-MIMETrack:" | 2355 | "X-MIMETrack:" |
| 2352 | "X-MS-" ; MS Outlook | 2356 | "X-MS-" ; MS Outlook |
| 2357 | "X-Mail-from:" ; fastmail.fm | ||
| 2353 | "X-MailScanner" ; ListProc(tm) by CREN | 2358 | "X-MailScanner" ; ListProc(tm) by CREN |
| 2354 | "X-Mailing-List:" ; Unknown mailing list managers | 2359 | "X-Mailing-List:" ; Unknown mailing list managers |
| 2360 | "X-Mailman-Approved-At:" ; Mailman mailing list manager | ||
| 2355 | "X-Mailman-Version:" ; Mailman mailing list manager | 2361 | "X-Mailman-Version:" ; Mailman mailing list manager |
| 2356 | "X-Majordomo:" ; Majordomo mailing list manager | 2362 | "X-Majordomo:" ; Majordomo mailing list manager |
| 2357 | "X-Message-Id" | 2363 | "X-Message-Id" |
| @@ -2380,14 +2386,17 @@ of citations entirely, choose \"None\"." | |||
| 2380 | "X-Received-Date:" | 2386 | "X-Received-Date:" |
| 2381 | "X-Received:" | 2387 | "X-Received:" |
| 2382 | "X-Request-" | 2388 | "X-Request-" |
| 2389 | "X-Resolved-to:" ; fastmail.fm | ||
| 2383 | "X-Return-Path-Hint:" ; Roving ConstantContact | 2390 | "X-Return-Path-Hint:" ; Roving ConstantContact |
| 2384 | "X-Roving-*" ; Roving ConstantContact | 2391 | "X-Roving-" ; Roving ConstantContact |
| 2392 | "X-SA-Exim-" ; Exim SpamAssassin | ||
| 2385 | "X-SBClass:" ; Spam | 2393 | "X-SBClass:" ; Spam |
| 2386 | "X-SBNote:" ; Spam | 2394 | "X-SBNote:" ; Spam |
| 2387 | "X-SBPass:" ; Spam | 2395 | "X-SBPass:" ; Spam |
| 2388 | "X-SBRule:" ; Spam | 2396 | "X-SBRule:" ; Spam |
| 2389 | "X-SMTP-" | 2397 | "X-SMTP-" |
| 2390 | "X-Scanned-By" | 2398 | "X-Sasl-enc:" ; Apple Mail |
| 2399 | "X-Scanned-By:" | ||
| 2391 | "X-Sender:" | 2400 | "X-Sender:" |
| 2392 | "X-Server-Date:" | 2401 | "X-Server-Date:" |
| 2393 | "X-Server-Uuid:" | 2402 | "X-Server-Uuid:" |
| @@ -2615,22 +2624,6 @@ message are shown regardless of size." | |||
| 2615 | :type 'integer | 2624 | :type 'integer |
| 2616 | :group 'mh-show) | 2625 | :group 'mh-show) |
| 2617 | 2626 | ||
| 2618 | (defcustom mh-show-use-goto-addr-flag (and (boundp 'goto-address-highlight-p) | ||
| 2619 | goto-address-highlight-p) | ||
| 2620 | "*Non-nil means highlight URLs and email addresses\\<goto-address-highlight-keymap>. | ||
| 2621 | |||
| 2622 | To send a message using the highlighted email address or to view | ||
| 2623 | the web page for the highlighted URL, use the middle mouse button | ||
| 2624 | or \\[goto-address-at-point]. | ||
| 2625 | |||
| 2626 | See Info node `(mh-e)Sending Mail' to see how to configure Emacs | ||
| 2627 | to send the message using MH-E. | ||
| 2628 | |||
| 2629 | The default value of this option comes from the value of | ||
| 2630 | `goto-address-highlight-p'." | ||
| 2631 | :type 'boolean | ||
| 2632 | :group 'mh-show) | ||
| 2633 | |||
| 2634 | (defcustom mh-show-use-xface-flag (>= emacs-major-version 21) | 2627 | (defcustom mh-show-use-xface-flag (>= emacs-major-version 21) |
| 2635 | "*Non-nil means display face images in MH-show buffers. | 2628 | "*Non-nil means display face images in MH-show buffers. |
| 2636 | 2629 | ||
| @@ -3019,7 +3012,9 @@ GNU Emacs and XEmacs from at least 21.5.23 on.") | |||
| 3019 | (:foreground "snow4")) | 3012 | (:foreground "snow4")) |
| 3020 | (((class color) (min-colors 64) (background dark)) | 3013 | (((class color) (min-colors 64) (background dark)) |
| 3021 | (:foreground "snow3")) | 3014 | (:foreground "snow3")) |
| 3022 | (((class color)) | 3015 | (((class color) (background light)) |
| 3016 | (:foreground "purple")) | ||
| 3017 | (((class color) (background dark)) | ||
| 3023 | (:foreground "cyan")))) | 3018 | (:foreground "cyan")))) |
| 3024 | (mh-folder-refiled | 3019 | (mh-folder-refiled |
| 3025 | ((((class color) (min-colors 64) (background light)) | 3020 | ((((class color) (min-colors 64) (background light)) |
| @@ -3042,9 +3037,9 @@ GNU Emacs and XEmacs from at least 21.5.23 on.") | |||
| 3042 | (t | 3037 | (t |
| 3043 | (:bold t)))) | 3038 | (:bold t)))) |
| 3044 | (mh-folder-tick | 3039 | (mh-folder-tick |
| 3045 | ((((class color) (background dark)) | 3040 | ((((class color) (background light)) |
| 3046 | (:background "#dddf7e")) | 3041 | (:background "#dddf7e")) |
| 3047 | (((class color) (background light)) | 3042 | (((class color) (background dark)) |
| 3048 | (:background "#dddf7e")) | 3043 | (:background "#dddf7e")) |
| 3049 | (t | 3044 | (t |
| 3050 | (:underline t)))) | 3045 | (:underline t)))) |
diff --git a/lisp/mh-e/mh-show.el b/lisp/mh-e/mh-show.el index ab636ae8ab6..3ae609d9204 100644 --- a/lisp/mh-e/mh-show.el +++ b/lisp/mh-e/mh-show.el | |||
| @@ -36,13 +36,13 @@ | |||
| 36 | (require 'mh-e) | 36 | (require 'mh-e) |
| 37 | (require 'mh-scan) | 37 | (require 'mh-scan) |
| 38 | 38 | ||
| 39 | (require 'font-lock) | ||
| 39 | (require 'gnus-cite) | 40 | (require 'gnus-cite) |
| 40 | (require 'gnus-util) | 41 | (require 'gnus-util) |
| 42 | (require 'goto-addr) | ||
| 41 | 43 | ||
| 42 | (autoload 'mh-make-buffer-data "mh-mime") ;can't be automatically generated | 44 | (autoload 'mh-make-buffer-data "mh-mime") ;can't be automatically generated |
| 43 | 45 | ||
| 44 | (require 'font-lock) | ||
| 45 | |||
| 46 | 46 | ||
| 47 | 47 | ||
| 48 | ;;; MH-Folder Commands | 48 | ;;; MH-Folder Commands |
| @@ -818,6 +818,13 @@ operation." | |||
| 818 | (define-derived-mode mh-show-mode text-mode "MH-Show" | 818 | (define-derived-mode mh-show-mode text-mode "MH-Show" |
| 819 | "Major mode for showing messages in MH-E.\\<mh-show-mode-map> | 819 | "Major mode for showing messages in MH-E.\\<mh-show-mode-map> |
| 820 | 820 | ||
| 821 | Email addresses and URLs in the message are highlighted if the | ||
| 822 | option `goto-address-highlight-p' is on, which it is by default. | ||
| 823 | To view the web page for a highlighted URL or to send a message | ||
| 824 | using a highlighted email address, use the middle mouse button or | ||
| 825 | \\[goto-address-at-point]. See Info node `(mh-e)Sending Mail' to | ||
| 826 | see how to configure Emacs to send the message using MH-E. | ||
| 827 | |||
| 821 | The hook `mh-show-mode-hook' is called upon entry to this mode. | 828 | The hook `mh-show-mode-hook' is called upon entry to this mode. |
| 822 | 829 | ||
| 823 | See also `mh-folder-mode'. | 830 | See also `mh-folder-mode'. |
| @@ -877,10 +884,7 @@ See also `mh-folder-mode'. | |||
| 877 | ;;;###mh-autoload | 884 | ;;;###mh-autoload |
| 878 | (defun mh-show-addr () | 885 | (defun mh-show-addr () |
| 879 | "Use `goto-address'." | 886 | "Use `goto-address'." |
| 880 | (when mh-show-use-goto-addr-flag | 887 | (goto-address)) |
| 881 | (mh-require 'goto-addr nil t) | ||
| 882 | (if (fboundp 'goto-address) | ||
| 883 | (goto-address)))) | ||
| 884 | 888 | ||
| 885 | ;;;###mh-autoload | 889 | ;;;###mh-autoload |
| 886 | (defun mh-gnus-article-highlight-citation () | 890 | (defun mh-gnus-article-highlight-citation () |
diff --git a/lisp/mh-e/mh-utils.el b/lisp/mh-e/mh-utils.el index 58d29bc5d1c..c00558860d1 100644 --- a/lisp/mh-e/mh-utils.el +++ b/lisp/mh-e/mh-utils.el | |||
| @@ -111,18 +111,8 @@ already there. | |||
| 111 | See also variable `mh-image-load-path-called-flag'." | 111 | See also variable `mh-image-load-path-called-flag'." |
| 112 | (unless mh-image-load-path-called-flag | 112 | (unless mh-image-load-path-called-flag |
| 113 | (cond | 113 | (cond |
| 114 | (mh-image-load-path) ; user setting exists; we're done | 114 | (mh-image-load-path) ; user setting exists |
| 115 | ((mh-image-search-load-path "mh-logo.xpm") | 115 | ((let (mh-library-name) ; try relative setting |
| 116 | ;; Images already in image-load-path. | ||
| 117 | (setq mh-image-load-path | ||
| 118 | (file-name-directory (mh-image-search-load-path "mh-logo.xpm")))) | ||
| 119 | ((locate-library "mh-logo.xpm") | ||
| 120 | ;; Images already in load-path. | ||
| 121 | (setq mh-image-load-path | ||
| 122 | (file-name-directory (locate-library "mh-logo.xpm")))) | ||
| 123 | (t | ||
| 124 | ;; Guess `mh-image-load-path' if it wasn't provided by the user. | ||
| 125 | (let (mh-library-name) | ||
| 126 | ;; First, find mh-e in the load-path. | 116 | ;; First, find mh-e in the load-path. |
| 127 | (setq mh-library-name (locate-library "mh-e")) | 117 | (setq mh-library-name (locate-library "mh-e")) |
| 128 | (if (not mh-library-name) | 118 | (if (not mh-library-name) |
| @@ -131,7 +121,17 @@ See also variable `mh-image-load-path-called-flag'." | |||
| 131 | (setq mh-image-load-path | 121 | (setq mh-image-load-path |
| 132 | (expand-file-name (concat | 122 | (expand-file-name (concat |
| 133 | (file-name-directory mh-library-name) | 123 | (file-name-directory mh-library-name) |
| 134 | "../../etc/images")))))) | 124 | "../../etc/images"))) |
| 125 | (file-exists-p (expand-file-name "mh-logo.xpm" mh-image-load-path)))) | ||
| 126 | ((mh-image-search-load-path "mh-logo.xpm") | ||
| 127 | ;; Images in image-load-path. | ||
| 128 | (setq mh-image-load-path | ||
| 129 | (file-name-directory (mh-image-search-load-path "mh-logo.xpm")))) | ||
| 130 | ((locate-library "mh-logo.xpm") | ||
| 131 | ;; Images in load-path. | ||
| 132 | (setq mh-image-load-path | ||
| 133 | (file-name-directory (locate-library "mh-logo.xpm"))))) | ||
| 134 | |||
| 135 | (if (not (file-exists-p mh-image-load-path)) | 135 | (if (not (file-exists-p mh-image-load-path)) |
| 136 | (error "Directory %s in mh-image-load-path does not exist" | 136 | (error "Directory %s in mh-image-load-path does not exist" |
| 137 | mh-image-load-path)) | 137 | mh-image-load-path)) |
diff --git a/lisp/net/rcirc.el b/lisp/net/rcirc.el index 971b65bf25c..f2eff379d14 100644 --- a/lisp/net/rcirc.el +++ b/lisp/net/rcirc.el | |||
| @@ -49,7 +49,7 @@ | |||
| 49 | (defgroup rcirc nil | 49 | (defgroup rcirc nil |
| 50 | "Simple IRC client." | 50 | "Simple IRC client." |
| 51 | :version "22.1" | 51 | :version "22.1" |
| 52 | :prefix "rcirc" | 52 | :prefix "rcirc-" |
| 53 | :group 'applications) | 53 | :group 'applications) |
| 54 | 54 | ||
| 55 | (defcustom rcirc-server "irc.freenode.net" | 55 | (defcustom rcirc-server "irc.freenode.net" |
| @@ -295,16 +295,23 @@ If ARG is non-nil, prompt for a server to connect to." | |||
| 295 | (defvar rcirc-topic nil) | 295 | (defvar rcirc-topic nil) |
| 296 | (defvar rcirc-keepalive-timer nil) | 296 | (defvar rcirc-keepalive-timer nil) |
| 297 | (defvar rcirc-last-server-message-time nil) | 297 | (defvar rcirc-last-server-message-time nil) |
| 298 | (defun rcirc-connect (server port nick user-name full-name startup-channels) | 298 | (defun rcirc-connect (&optional server port nick user-name full-name startup-channels) |
| 299 | (add-hook 'window-configuration-change-hook | 299 | (add-hook 'window-configuration-change-hook |
| 300 | 'rcirc-window-configuration-change) | 300 | 'rcirc-window-configuration-change) |
| 301 | 301 | ||
| 302 | (save-excursion | 302 | (save-excursion |
| 303 | (message "Connecting to %s..." server) | 303 | (message "Connecting to %s..." server) |
| 304 | (let* ((inhibit-eol-conversion) | 304 | (let* ((inhibit-eol-conversion) |
| 305 | (port-number (if (stringp port) | 305 | (port-number (if port |
| 306 | (string-to-number port) | 306 | (if (stringp port) |
| 307 | port)) | 307 | (string-to-number port) |
| 308 | port) | ||
| 309 | rcirc-port)) | ||
| 310 | (server (or server rcirc-server)) | ||
| 311 | (nick (or nick rcirc-nick)) | ||
| 312 | (user-name (or user-name rcirc-user-name)) | ||
| 313 | (full-name (or full-name rcirc-user-full-name)) | ||
| 314 | (startup-channels (or startup-channels (rcirc-startup-channels server))) | ||
| 308 | (process (open-network-stream server nil server port-number))) | 315 | (process (open-network-stream server nil server port-number))) |
| 309 | ;; set up process | 316 | ;; set up process |
| 310 | (set-process-coding-system process 'raw-text 'raw-text) | 317 | (set-process-coding-system process 'raw-text 'raw-text) |
| @@ -758,9 +765,9 @@ if there is no existing buffer for TARGET, otherwise return nil." | |||
| 758 | Create the buffer if it doesn't exist." | 765 | Create the buffer if it doesn't exist." |
| 759 | (let ((buffer (rcirc-get-buffer process target))) | 766 | (let ((buffer (rcirc-get-buffer process target))) |
| 760 | (if buffer | 767 | (if buffer |
| 761 | (progn | 768 | (with-current-buffer buffer |
| 762 | (when (not rcirc-target) | 769 | (when (not rcirc-target) |
| 763 | (setq rcirc-target target)) | 770 | (setq rcirc-target target)) |
| 764 | buffer) | 771 | buffer) |
| 765 | ;; create the buffer | 772 | ;; create the buffer |
| 766 | (with-rcirc-process-buffer process | 773 | (with-rcirc-process-buffer process |
| @@ -896,20 +903,22 @@ Create the buffer if it doesn't exist." | |||
| 896 | (kill-buffer (current-buffer)) | 903 | (kill-buffer (current-buffer)) |
| 897 | (set-window-configuration rcirc-window-configuration)) | 904 | (set-window-configuration rcirc-window-configuration)) |
| 898 | 905 | ||
| 899 | (defun rcirc-get-any-buffer (process) | 906 | (defun rcirc-any-buffer (process) |
| 900 | "Return a buffer for PROCESS, either the one selected or the process buffer." | 907 | "Return a buffer for PROCESS, either the one selected or the process buffer." |
| 901 | (let ((buffer (window-buffer (selected-window)))) | 908 | (if rcirc-always-use-server-buffer-flag |
| 902 | (if (and buffer | 909 | (process-buffer process) |
| 903 | (with-current-buffer buffer | 910 | (let ((buffer (window-buffer (selected-window)))) |
| 904 | (and (eq major-mode 'rcirc-mode) | 911 | (if (and buffer |
| 905 | (eq rcirc-process process)))) | 912 | (with-current-buffer buffer |
| 906 | buffer | 913 | (and (eq major-mode 'rcirc-mode) |
| 907 | (process-buffer process)))) | 914 | (eq rcirc-process process)))) |
| 915 | buffer | ||
| 916 | (process-buffer process))))) | ||
| 908 | 917 | ||
| 909 | (defcustom rcirc-response-formats | 918 | (defcustom rcirc-response-formats |
| 910 | '(("PRIVMSG" . "%T<%n> %m") | 919 | '(("PRIVMSG" . "%T<%N> %m") |
| 911 | ("NOTICE" . "%T-%n- %m") | 920 | ("NOTICE" . "%T-%N- %m") |
| 912 | ("ACTION" . "%T[%n] %m") | 921 | ("ACTION" . "%T[%N %m]") |
| 913 | ("COMMAND" . "%T%m") | 922 | ("COMMAND" . "%T%m") |
| 914 | ("ERROR" . "%T%fw!!! %m") | 923 | ("ERROR" . "%T%fw!!! %m") |
| 915 | (t . "%T%fp*** %fs%n %r %m")) | 924 | (t . "%T%fp*** %fs%n %r %m")) |
| @@ -921,7 +930,8 @@ The entry's value part should be a string, which is inserted with | |||
| 921 | the of the following escape sequences replaced by the described values: | 930 | the of the following escape sequences replaced by the described values: |
| 922 | 931 | ||
| 923 | %m The message text | 932 | %m The message text |
| 924 | %n The sender's nick (with face `rcirc-my-nick' or `rcirc-other-nick') | 933 | %n The sender's nick |
| 934 | %N The sender's nick (with face `rcirc-my-nick' or `rcirc-other-nick') | ||
| 925 | %r The response-type | 935 | %r The response-type |
| 926 | %T The timestamp (with face `rcirc-timestamp') | 936 | %T The timestamp (with face `rcirc-timestamp') |
| 927 | %t The target | 937 | %t The target |
| @@ -959,13 +969,20 @@ is found by looking up RESPONSE in `rcirc-response-formats'." | |||
| 959 | (cond ((eq key ?%) | 969 | (cond ((eq key ?%) |
| 960 | ;; %% -- literal % character | 970 | ;; %% -- literal % character |
| 961 | "%") | 971 | "%") |
| 962 | ((eq key ?n) | 972 | ((or (eq key ?n) (eq key ?N)) |
| 963 | ;; %n -- nick | 973 | ;; %n/%N -- nick |
| 964 | (rcirc-facify (concat (rcirc-abbrev-nick sender) | 974 | (let ((nick (concat (if (string= (with-rcirc-process-buffer |
| 965 | (and target (concat "," target))) | 975 | process rcirc-server) |
| 966 | (if (string= sender (rcirc-nick process)) | 976 | sender) |
| 967 | 'rcirc-my-nick | 977 | "" |
| 968 | 'rcirc-other-nick))) | 978 | (rcirc-abbrev-nick sender)) |
| 979 | (and target (concat "," target))))) | ||
| 980 | (rcirc-facify nick | ||
| 981 | (if (eq key ?n) | ||
| 982 | face | ||
| 983 | (if (string= sender (rcirc-nick process)) | ||
| 984 | 'rcirc-my-nick | ||
| 985 | 'rcirc-other-nick))))) | ||
| 969 | ((eq key ?T) | 986 | ((eq key ?T) |
| 970 | ;; %T -- timestamp | 987 | ;; %T -- timestamp |
| 971 | (rcirc-facify | 988 | (rcirc-facify |
| @@ -1015,9 +1032,7 @@ is found by looking up RESPONSE in `rcirc-response-formats'." | |||
| 1015 | (assert (not (bufferp target))) | 1032 | (assert (not (bufferp target))) |
| 1016 | (with-rcirc-process-buffer process | 1033 | (with-rcirc-process-buffer process |
| 1017 | (cond ((not target) | 1034 | (cond ((not target) |
| 1018 | (if rcirc-always-use-server-buffer-flag | 1035 | (rcirc-any-buffer process)) |
| 1019 | (process-buffer process) | ||
| 1020 | (rcirc-get-any-buffer process))) | ||
| 1021 | ((not (rcirc-channel-p target)) | 1036 | ((not (rcirc-channel-p target)) |
| 1022 | ;; message from another user | 1037 | ;; message from another user |
| 1023 | (if (string= response "PRIVMSG") | 1038 | (if (string= response "PRIVMSG") |
| @@ -1026,7 +1041,7 @@ is found by looking up RESPONSE in `rcirc-response-formats'." | |||
| 1026 | sender)) | 1041 | sender)) |
| 1027 | (rcirc-get-buffer process target t))) | 1042 | (rcirc-get-buffer process target t))) |
| 1028 | ((or (rcirc-get-buffer process target) | 1043 | ((or (rcirc-get-buffer process target) |
| 1029 | (rcirc-get-any-buffer process)))))) | 1044 | (rcirc-any-buffer process)))))) |
| 1030 | 1045 | ||
| 1031 | (defvar rcirc-activity-type nil) | 1046 | (defvar rcirc-activity-type nil) |
| 1032 | (make-variable-buffer-local 'rcirc-activity-type) | 1047 | (make-variable-buffer-local 'rcirc-activity-type) |
| @@ -1069,22 +1084,26 @@ record activity." | |||
| 1069 | (set-marker-insertion-type rcirc-prompt-start-marker nil) | 1084 | (set-marker-insertion-type rcirc-prompt-start-marker nil) |
| 1070 | (set-marker-insertion-type rcirc-prompt-end-marker nil) | 1085 | (set-marker-insertion-type rcirc-prompt-end-marker nil) |
| 1071 | 1086 | ||
| 1072 | ;; fill the text we just inserted, maybe | 1087 | (let ((text-start (make-marker))) |
| 1073 | (when (and rcirc-fill-flag | 1088 | (set-marker text-start |
| 1074 | (not (string= response "372"))) ;/motd | 1089 | (or (next-single-property-change fill-start |
| 1075 | (let ((fill-prefix | 1090 | 'rcirc-text) |
| 1076 | (or rcirc-fill-prefix | 1091 | (point-max))) |
| 1077 | (make-string | 1092 | ;; squeeze spaces out of text before rcirc-text |
| 1078 | (or (next-single-property-change 0 'rcirc-text | 1093 | (fill-region fill-start (1- text-start)) |
| 1079 | fmted-text) | 1094 | |
| 1080 | 8) | 1095 | ;; fill the text we just inserted, maybe |
| 1081 | ?\s))) | 1096 | (when (and rcirc-fill-flag |
| 1082 | (fill-column (cond ((eq rcirc-fill-column 'frame-width) | 1097 | (not (string= response "372"))) ;/motd |
| 1083 | (1- (frame-width))) | 1098 | (let ((fill-prefix |
| 1084 | (rcirc-fill-column | 1099 | (or rcirc-fill-prefix |
| 1085 | rcirc-fill-column) | 1100 | (make-string (- text-start fill-start) ?\s))) |
| 1086 | (t fill-column)))) | 1101 | (fill-column (cond ((eq rcirc-fill-column 'frame-width) |
| 1087 | (fill-region fill-start rcirc-prompt-start-marker 'left t)))) | 1102 | (1- (frame-width))) |
| 1103 | (rcirc-fill-column | ||
| 1104 | rcirc-fill-column) | ||
| 1105 | (t fill-column)))) | ||
| 1106 | (fill-region fill-start rcirc-prompt-start-marker 'left t))))) | ||
| 1088 | 1107 | ||
| 1089 | ;; set inserted text to be read-only | 1108 | ;; set inserted text to be read-only |
| 1090 | (when rcirc-read-only-flag | 1109 | (when rcirc-read-only-flag |
| @@ -1175,14 +1194,15 @@ record activity." | |||
| 1175 | 1194 | ||
| 1176 | (defun rcirc-put-nick-channel (process nick channel) | 1195 | (defun rcirc-put-nick-channel (process nick channel) |
| 1177 | "Add CHANNEL to list associated with NICK." | 1196 | "Add CHANNEL to list associated with NICK." |
| 1178 | (with-rcirc-process-buffer process | 1197 | (let ((nick (rcirc-user-nick nick))) |
| 1179 | (let* ((chans (gethash nick rcirc-nick-table)) | 1198 | (with-rcirc-process-buffer process |
| 1180 | (record (assoc-string channel chans t))) | 1199 | (let* ((chans (gethash nick rcirc-nick-table)) |
| 1181 | (if record | 1200 | (record (assoc-string channel chans t))) |
| 1182 | (setcdr record (current-time)) | 1201 | (if record |
| 1183 | (puthash nick (cons (cons channel (current-time)) | 1202 | (setcdr record (current-time)) |
| 1184 | chans) | 1203 | (puthash nick (cons (cons channel (current-time)) |
| 1185 | rcirc-nick-table))))) | 1204 | chans) |
| 1205 | rcirc-nick-table)))))) | ||
| 1186 | 1206 | ||
| 1187 | (defun rcirc-nick-remove (process nick) | 1207 | (defun rcirc-nick-remove (process nick) |
| 1188 | "Remove NICK from table." | 1208 | "Remove NICK from table." |
| @@ -1613,15 +1633,21 @@ ones added to the list automatically are marked with an asterisk." | |||
| 1613 | (propertize (or string "") 'face face 'rear-nonsticky t)) | 1633 | (propertize (or string "") 'face face 'rear-nonsticky t)) |
| 1614 | 1634 | ||
| 1615 | (defvar rcirc-url-regexp | 1635 | (defvar rcirc-url-regexp |
| 1616 | (rx word-boundary | 1636 | (rx-to-string |
| 1617 | (or "www." | 1637 | `(and word-boundary |
| 1618 | (and (or "http" "https" "ftp" "file" "gopher" "news" "telnet" "wais" | 1638 | (or "www." |
| 1619 | "mailto") | 1639 | (and (or "http" "https" "ftp" "file" "gopher" "news" "telnet" |
| 1620 | "://" | 1640 | "wais" "mailto") |
| 1621 | (1+ (char "a-zA-Z0-9_.")) | 1641 | "://" |
| 1622 | (optional ":" (1+ (char "0-9"))))) | 1642 | (1+ (char "-a-zA-Z0-9_.")) |
| 1623 | (1+ (char "-a-zA-Z0-9_=!?#$\@~`%&*+|\\/:;.,{}[]")) | 1643 | (optional ":" (1+ (char "0-9")))) |
| 1624 | (char "-a-zA-Z0-9_=#$\@~`%&*+|\\/:;{}[]")) | 1644 | (and (1+ (char "-a-zA-Z0-9_.")) |
| 1645 | (or ".com" ".net" ".org") | ||
| 1646 | word-boundary)) | ||
| 1647 | (optional | ||
| 1648 | (and "/" | ||
| 1649 | (1+ (char "-a-zA-Z0-9_=!?#$\@~`%&*+|\\/:;.,{}[]")) | ||
| 1650 | (char "-a-zA-Z0-9_=#$\@~`%&*+|\\/:;{}[]"))))) | ||
| 1625 | "Regexp matching URLs. Set to nil to disable URL features in rcirc.") | 1651 | "Regexp matching URLs. Set to nil to disable URL features in rcirc.") |
| 1626 | 1652 | ||
| 1627 | (defun rcirc-browse-url (&optional arg) | 1653 | (defun rcirc-browse-url (&optional arg) |
diff --git a/lisp/progmodes/gdb-ui.el b/lisp/progmodes/gdb-ui.el index 2e7fa41d622..df603dc0d74 100644 --- a/lisp/progmodes/gdb-ui.el +++ b/lisp/progmodes/gdb-ui.el | |||
| @@ -107,8 +107,10 @@ | |||
| 107 | (defvar gdb-current-language nil) | 107 | (defvar gdb-current-language nil) |
| 108 | (defvar gdb-var-list nil | 108 | (defvar gdb-var-list nil |
| 109 | "List of variables in watch window. | 109 | "List of variables in watch window. |
| 110 | Each element has the form (EXPRESSION VARNUM NUMCHILD TYPE VALUE CHANGED-P).") | 110 | Each element has the form (EXPRESSION VARNUM NUMCHILD TYPE VALUE STATUS) where |
| 111 | (defvar gdb-var-changed nil "Non-nil means that `gdb-var-list' has changed.") | 111 | STATUS is nil (unchanged), `changed' or `out-of-scope'.") |
| 112 | (defvar gdb-force-update t | ||
| 113 | "Non-nil means that view of watch expressions will be updated in the speedbar.") | ||
| 112 | (defvar gdb-main-file nil "Source file from which program execution begins.") | 114 | (defvar gdb-main-file nil "Source file from which program execution begins.") |
| 113 | (defvar gdb-overlay-arrow-position nil) | 115 | (defvar gdb-overlay-arrow-position nil) |
| 114 | (defvar gdb-server-prefix nil) | 116 | (defvar gdb-server-prefix nil) |
| @@ -454,7 +456,7 @@ With arg, use separate IO iff arg is positive." | |||
| 454 | gdb-current-language nil | 456 | gdb-current-language nil |
| 455 | gdb-frame-number nil | 457 | gdb-frame-number nil |
| 456 | gdb-var-list nil | 458 | gdb-var-list nil |
| 457 | gdb-var-changed nil | 459 | gdb-force-update t |
| 458 | gdb-first-post-prompt t | 460 | gdb-first-post-prompt t |
| 459 | gdb-prompting nil | 461 | gdb-prompting nil |
| 460 | gdb-input-queue nil | 462 | gdb-input-queue nil |
| @@ -540,7 +542,7 @@ With arg, use separate IO iff arg is positive." | |||
| 540 | (forward-char 2) | 542 | (forward-char 2) |
| 541 | (gud-call (concat "until *%a"))))))))) | 543 | (gud-call (concat "until *%a"))))))))) |
| 542 | 544 | ||
| 543 | (defcustom gdb-speedbar-auto-raise t | 545 | (defcustom gdb-speedbar-auto-raise nil |
| 544 | "If non-nil raise speedbar every time display of watch expressions is\ | 546 | "If non-nil raise speedbar every time display of watch expressions is\ |
| 545 | updated." | 547 | updated." |
| 546 | :type 'boolean | 548 | :type 'boolean |
| @@ -608,8 +610,7 @@ With arg, automatically raise speedbar iff arg is positive." | |||
| 608 | (nth 1 var) "\"\n") | 610 | (nth 1 var) "\"\n") |
| 609 | (concat "-var-evaluate-expression " (nth 1 var) "\n")) | 611 | (concat "-var-evaluate-expression " (nth 1 var) "\n")) |
| 610 | `(lambda () (gdb-var-evaluate-expression-handler | 612 | `(lambda () (gdb-var-evaluate-expression-handler |
| 611 | ,(nth 1 var) nil)))) | 613 | ,(nth 1 var) nil))))) |
| 612 | (setq gdb-var-changed t)) | ||
| 613 | (if (search-forward "Undefined command" nil t) | 614 | (if (search-forward "Undefined command" nil t) |
| 614 | (message-box "Watching expressions requires gdb 6.0 onwards") | 615 | (message-box "Watching expressions requires gdb 6.0 onwards") |
| 615 | (message "No symbol \"%s\" in current context." expr)))) | 616 | (message "No symbol \"%s\" in current context." expr)))) |
| @@ -618,16 +619,11 @@ With arg, automatically raise speedbar iff arg is positive." | |||
| 618 | (goto-char (point-min)) | 619 | (goto-char (point-min)) |
| 619 | (re-search-forward ".*value=\\(\".*\"\\)" nil t) | 620 | (re-search-forward ".*value=\\(\".*\"\\)" nil t) |
| 620 | (catch 'var-found | 621 | (catch 'var-found |
| 621 | (let ((num 0)) | 622 | (dolist (var gdb-var-list) |
| 622 | (dolist (var gdb-var-list) | 623 | (when (string-equal varnum (cadr var)) |
| 623 | (if (string-equal varnum (cadr var)) | 624 | (if changed (setcar (nthcdr 5 var) 'changed)) |
| 624 | (progn | 625 | (setcar (nthcdr 4 var) (read (match-string 1))) |
| 625 | (if changed (setcar (nthcdr 5 var) t)) | 626 | (throw 'var-found nil))))) |
| 626 | (setcar (nthcdr 4 var) (read (match-string 1))) | ||
| 627 | (setcar (nthcdr num gdb-var-list) var) | ||
| 628 | (throw 'var-found nil))) | ||
| 629 | (setq num (+ num 1))))) | ||
| 630 | (setq gdb-var-changed t)) | ||
| 631 | 627 | ||
| 632 | (defun gdb-var-list-children (varnum) | 628 | (defun gdb-var-list-children (varnum) |
| 633 | (gdb-enqueue-input | 629 | (gdb-enqueue-input |
| @@ -676,17 +672,22 @@ type=\"\\(.*?\\)\"") | |||
| 676 | (defconst gdb-var-update-regexp "name=\"\\(.*?\\)\",in_scope=\"\\(.*?\\)\"") | 672 | (defconst gdb-var-update-regexp "name=\"\\(.*?\\)\",in_scope=\"\\(.*?\\)\"") |
| 677 | 673 | ||
| 678 | (defun gdb-var-update-handler () | 674 | (defun gdb-var-update-handler () |
| 675 | (dolist (var gdb-var-list) | ||
| 676 | (setcar (nthcdr 5 var) nil)) | ||
| 679 | (goto-char (point-min)) | 677 | (goto-char (point-min)) |
| 680 | (while (re-search-forward gdb-var-update-regexp nil t) | 678 | (while (re-search-forward gdb-var-update-regexp nil t) |
| 681 | (catch 'var-found-1 | 679 | (let ((varnum (match-string 1))) |
| 682 | (let ((varnum (match-string 1))) | 680 | (if (string-equal (match-string 2) "false") |
| 683 | (dolist (var gdb-var-list) | 681 | (catch 'var-found |
| 684 | (gdb-enqueue-input | 682 | (dolist (var gdb-var-list) |
| 685 | (list | 683 | (when (string-equal varnum (cadr var)) |
| 686 | (concat "server interpreter mi \"-var-evaluate-expression " | 684 | (setcar (nthcdr 5 var) 'out-of-scope) |
| 687 | varnum "\"\n") | 685 | (throw 'var-found nil)))) |
| 688 | `(lambda () (gdb-var-evaluate-expression-handler ,varnum t)))) | 686 | (gdb-enqueue-input |
| 689 | (throw 'var-found-1 nil))))) | 687 | (list |
| 688 | (concat "server interpreter mi \"-var-evaluate-expression " | ||
| 689 | varnum "\"\n") | ||
| 690 | `(lambda () (gdb-var-evaluate-expression-handler ,varnum t))))))) | ||
| 690 | (setq gdb-pending-triggers | 691 | (setq gdb-pending-triggers |
| 691 | (delq 'gdb-var-update gdb-pending-triggers)) | 692 | (delq 'gdb-var-update gdb-pending-triggers)) |
| 692 | (when (and (boundp 'speedbar-frame) (frame-live-p speedbar-frame)) | 693 | (when (and (boundp 'speedbar-frame) (frame-live-p speedbar-frame)) |
| @@ -722,8 +723,7 @@ type=\"\\(.*?\\)\"") | |||
| 722 | (setq gdb-var-list (delq var gdb-var-list)) | 723 | (setq gdb-var-list (delq var gdb-var-list)) |
| 723 | (dolist (varchild gdb-var-list) | 724 | (dolist (varchild gdb-var-list) |
| 724 | (if (string-match (concat (nth 1 var) "\\.") (nth 1 varchild)) | 725 | (if (string-match (concat (nth 1 var) "\\.") (nth 1 varchild)) |
| 725 | (setq gdb-var-list (delq varchild gdb-var-list)))) | 726 | (setq gdb-var-list (delq varchild gdb-var-list))))))))) |
| 726 | (setq gdb-var-changed t)))))) | ||
| 727 | 727 | ||
| 728 | (defun gdb-edit-value (text token indent) | 728 | (defun gdb-edit-value (text token indent) |
| 729 | "Assign a value to a variable displayed in the speedbar." | 729 | "Assign a value to a variable displayed in the speedbar." |
| @@ -739,8 +739,9 @@ type=\"\\(.*?\\)\"") | |||
| 739 | 'ignore)))) | 739 | 'ignore)))) |
| 740 | 740 | ||
| 741 | (defcustom gdb-show-changed-values t | 741 | (defcustom gdb-show-changed-values t |
| 742 | "If non-nil highlight values that have recently changed in the speedbar. | 742 | "If non-nil change the face of out of scope variables and changed values. |
| 743 | The highlighting is done with `font-lock-warning-face'." | 743 | Out of scope variables are suppressed with `shadow' face. |
| 744 | Changed values are highlighted with the face `font-lock-warning-face'." | ||
| 744 | :type 'boolean | 745 | :type 'boolean |
| 745 | :group 'gud | 746 | :group 'gud |
| 746 | :version "22.1") | 747 | :version "22.1") |
| @@ -760,7 +761,7 @@ INDENT is the current indentation depth." | |||
| 760 | (dolist (var gdb-var-list) | 761 | (dolist (var gdb-var-list) |
| 761 | (if (string-match (concat token "\\.") (nth 1 var)) | 762 | (if (string-match (concat token "\\.") (nth 1 var)) |
| 762 | (setq gdb-var-list (delq var gdb-var-list)))) | 763 | (setq gdb-var-list (delq var gdb-var-list)))) |
| 763 | (setq gdb-var-changed t) | 764 | (setq gdb-force-update t) |
| 764 | (with-current-buffer gud-comint-buffer | 765 | (with-current-buffer gud-comint-buffer |
| 765 | (speedbar-timer-fn))))) | 766 | (speedbar-timer-fn))))) |
| 766 | 767 | ||
| @@ -1214,8 +1215,7 @@ happens to be appropriate." | |||
| 1214 | ;; FIXME: with GDB-6 on Darwin, this might very well work. | 1215 | ;; FIXME: with GDB-6 on Darwin, this might very well work. |
| 1215 | ;; Only needed/used with speedbar/watch expressions. | 1216 | ;; Only needed/used with speedbar/watch expressions. |
| 1216 | (when (and (boundp 'speedbar-frame) (frame-live-p speedbar-frame)) | 1217 | (when (and (boundp 'speedbar-frame) (frame-live-p speedbar-frame)) |
| 1217 | (dolist (var gdb-var-list) | 1218 | (setq gdb-force-update t) |
| 1218 | (setcar (nthcdr 5 var) nil)) | ||
| 1219 | (if (string-equal gdb-version "pre-6.4") | 1219 | (if (string-equal gdb-version "pre-6.4") |
| 1220 | (gdb-var-update) | 1220 | (gdb-var-update) |
| 1221 | (gdb-var-update-1))))) | 1221 | (gdb-var-update-1))))) |
| @@ -2626,6 +2626,8 @@ Kills the gdb buffers and resets the source buffers." | |||
| 2626 | (setq gdb-overlay-arrow-position nil)) | 2626 | (setq gdb-overlay-arrow-position nil)) |
| 2627 | (setq overlay-arrow-variable-list | 2627 | (setq overlay-arrow-variable-list |
| 2628 | (delq 'gdb-overlay-arrow-position overlay-arrow-variable-list)) | 2628 | (delq 'gdb-overlay-arrow-position overlay-arrow-variable-list)) |
| 2629 | (if (and (boundp 'speedbar-frame) (frame-live-p speedbar-frame)) | ||
| 2630 | (speedbar-refresh)) | ||
| 2629 | (setq gud-running nil) | 2631 | (setq gud-running nil) |
| 2630 | (setq gdb-active-process nil) | 2632 | (setq gdb-active-process nil) |
| 2631 | (setq gdb-var-list nil) | 2633 | (setq gdb-var-list nil) |
| @@ -3022,7 +3024,6 @@ value=\\(\".*?\"\\),type=\"\\(.+?\\)\"}") | |||
| 3022 | (throw 'child-already-watched nil))) | 3024 | (throw 'child-already-watched nil))) |
| 3023 | (push varchild var-list)))) | 3025 | (push varchild var-list)))) |
| 3024 | (push var var-list))) | 3026 | (push var var-list))) |
| 3025 | (setq gdb-var-changed t) | ||
| 3026 | (setq gdb-var-list (nreverse var-list))))) | 3027 | (setq gdb-var-list (nreverse var-list))))) |
| 3027 | 3028 | ||
| 3028 | ; Uses "-var-update --all-values". Needs GDB 6.4 onwards. | 3029 | ; Uses "-var-update --all-values". Needs GDB 6.4 onwards. |
| @@ -3041,23 +3042,20 @@ value=\\(\".*?\"\\),type=\"\\(.+?\\)\"}") | |||
| 3041 | "name=\"\\(.*?\\)\",\\(?:value=\\(\".*?\"\\),\\)?in_scope=\"\\(.*?\\)\"") | 3042 | "name=\"\\(.*?\\)\",\\(?:value=\\(\".*?\"\\),\\)?in_scope=\"\\(.*?\\)\"") |
| 3042 | 3043 | ||
| 3043 | (defun gdb-var-update-handler-1 () | 3044 | (defun gdb-var-update-handler-1 () |
| 3045 | (dolist (var gdb-var-list) | ||
| 3046 | (setcar (nthcdr 5 var) nil)) | ||
| 3044 | (goto-char (point-min)) | 3047 | (goto-char (point-min)) |
| 3045 | (while (re-search-forward gdb-var-update-regexp-1 nil t) | 3048 | (while (re-search-forward gdb-var-update-regexp-1 nil t) |
| 3046 | (let ((varnum (match-string 1))) | 3049 | (let ((varnum (match-string 1))) |
| 3047 | (catch 'var-found1 | 3050 | (catch 'var-found |
| 3048 | (let ((num 0)) | 3051 | (dolist (var gdb-var-list) |
| 3049 | (dolist (var gdb-var-list) | 3052 | (when (string-equal varnum (cadr var)) |
| 3050 | (if (string-equal varnum (cadr var)) | 3053 | (if (string-equal (match-string 3) "false") |
| 3051 | (progn | 3054 | (setcar (nthcdr 5 var) 'out-of-scope) |
| 3052 | (setcar (nthcdr 5 var) t) | 3055 | (setcar (nthcdr 5 var) 'changed) |
| 3053 | (setcar (nthcdr 4 var) | 3056 | (setcar (nthcdr 4 var) |
| 3054 | (if (string-equal (match-string 3) "true") | 3057 | (read (match-string 2)))) |
| 3055 | (read (match-string 2)) | 3058 | (throw 'var-found nil)))))) |
| 3056 | "*changed*")) | ||
| 3057 | (setcar (nthcdr num gdb-var-list) var) | ||
| 3058 | (throw 'var-found1 nil))) | ||
| 3059 | (setq num (+ num 1)))))) | ||
| 3060 | (setq gdb-var-changed t)) | ||
| 3061 | (setq gdb-pending-triggers | 3059 | (setq gdb-pending-triggers |
| 3062 | (delq 'gdb-var-update gdb-pending-triggers)) | 3060 | (delq 'gdb-var-update gdb-pending-triggers)) |
| 3063 | (when (and (boundp 'speedbar-frame) (frame-live-p speedbar-frame)) | 3061 | (when (and (boundp 'speedbar-frame) (frame-live-p speedbar-frame)) |
diff --git a/lisp/progmodes/gud.el b/lisp/progmodes/gud.el index 1d5172a1a52..ea2586a31d6 100644 --- a/lisp/progmodes/gud.el +++ b/lisp/progmodes/gud.el | |||
| @@ -43,14 +43,13 @@ | |||
| 43 | (eval-when-compile (require 'cl)) ; for case macro | 43 | (eval-when-compile (require 'cl)) ; for case macro |
| 44 | 44 | ||
| 45 | (require 'comint) | 45 | (require 'comint) |
| 46 | (require 'font-lock) | ||
| 47 | 46 | ||
| 48 | (defvar gdb-active-process) | 47 | (defvar gdb-active-process) |
| 49 | (defvar gdb-define-alist) | 48 | (defvar gdb-define-alist) |
| 50 | (defvar gdb-macro-info) | 49 | (defvar gdb-macro-info) |
| 51 | (defvar gdb-server-prefix) | 50 | (defvar gdb-server-prefix) |
| 52 | (defvar gdb-show-changed-values) | 51 | (defvar gdb-show-changed-values) |
| 53 | (defvar gdb-var-changed) | 52 | (defvar gdb-force-update) |
| 54 | (defvar gdb-var-list) | 53 | (defvar gdb-var-list) |
| 55 | (defvar gdb-speedbar-auto-raise) | 54 | (defvar gdb-speedbar-auto-raise) |
| 56 | (defvar tool-bar-map) | 55 | (defvar tool-bar-map) |
| @@ -444,7 +443,7 @@ required by the caller." | |||
| 444 | (p (window-point window))) | 443 | (p (window-point window))) |
| 445 | (cond | 444 | (cond |
| 446 | ((memq minor-mode '(gdbmi gdba)) | 445 | ((memq minor-mode '(gdbmi gdba)) |
| 447 | (when (or gdb-var-changed | 446 | (when (or gdb-force-update |
| 448 | (not (save-excursion | 447 | (not (save-excursion |
| 449 | (goto-char (point-min)) | 448 | (goto-char (point-min)) |
| 450 | (let ((case-fold-search t)) | 449 | (let ((case-fold-search t)) |
| @@ -453,51 +452,68 @@ required by the caller." | |||
| 453 | (insert "Watch Expressions:\n") | 452 | (insert "Watch Expressions:\n") |
| 454 | (if gdb-speedbar-auto-raise | 453 | (if gdb-speedbar-auto-raise |
| 455 | (raise-frame speedbar-frame)) | 454 | (raise-frame speedbar-frame)) |
| 456 | (let ((var-list gdb-var-list)) | 455 | (let ((var-list gdb-var-list) parent) |
| 457 | (while var-list | 456 | (while var-list |
| 458 | (let* (char (depth 0) (start 0) | 457 | (let* (char (depth 0) (start 0) (var (car var-list)) |
| 459 | (var (car var-list)) (varnum (nth 1 var))) | 458 | (expr (car var)) (varnum (nth 1 var)) |
| 459 | (type (nth 3 var)) (status (nth 5 var))) | ||
| 460 | (put-text-property | ||
| 461 | 0 (length expr) 'face font-lock-variable-name-face expr) | ||
| 462 | (put-text-property | ||
| 463 | 0 (length type) 'face font-lock-type-face type) | ||
| 460 | (while (string-match "\\." varnum start) | 464 | (while (string-match "\\." varnum start) |
| 461 | (setq depth (1+ depth) | 465 | (setq depth (1+ depth) |
| 462 | start (1+ (match-beginning 0)))) | 466 | start (1+ (match-beginning 0)))) |
| 467 | (if (eq depth 0) (setq parent nil)) | ||
| 463 | (if (or (equal (nth 2 var) "0") | 468 | (if (or (equal (nth 2 var) "0") |
| 464 | (and (equal (nth 2 var) "1") | 469 | (and (equal (nth 2 var) "1") |
| 465 | (string-match "char \\*$" (nth 3 var)))) | 470 | (string-match "char \\*$" type))) |
| 466 | (speedbar-make-tag-line 'bracket ?? nil nil | 471 | (speedbar-make-tag-line |
| 467 | (concat (car var) "\t" (nth 4 var)) | 472 | 'bracket ?? nil nil |
| 468 | 'gdb-edit-value | 473 | (concat expr "\t" (nth 4 var)) |
| 469 | nil | 474 | (if (or parent (eq status 'out-of-scope)) |
| 470 | (if (and (nth 5 var) | 475 | nil 'gdb-edit-value) |
| 471 | gdb-show-changed-values) | 476 | nil |
| 472 | 'font-lock-warning-face | 477 | (if gdb-show-changed-values |
| 473 | nil) depth) | 478 | (or parent (case status |
| 479 | (changed 'font-lock-warning-face) | ||
| 480 | (out-of-scope 'shadow) | ||
| 481 | (t t))) | ||
| 482 | t) | ||
| 483 | depth) | ||
| 484 | (if (eq status 'out-of-scope) (setq parent 'shadow)) | ||
| 474 | (if (and (cadr var-list) | 485 | (if (and (cadr var-list) |
| 475 | (string-match (concat varnum "\\.") | 486 | (string-match (concat varnum "\\.") |
| 476 | (cadr (cadr var-list)))) | 487 | (cadr (cadr var-list)))) |
| 477 | (setq char ?-) | 488 | (setq char ?-) |
| 478 | (setq char ?+)) | 489 | (setq char ?+)) |
| 479 | (if (string-match "\\*$" (nth 3 var)) | 490 | (if (string-match "\\*$" type) |
| 480 | (speedbar-make-tag-line 'bracket char | 491 | (speedbar-make-tag-line |
| 481 | 'gdb-speedbar-expand-node varnum | 492 | 'bracket char |
| 482 | (concat (car var) "\t" | 493 | 'gdb-speedbar-expand-node varnum |
| 483 | (nth 3 var)"\t" | 494 | (concat expr "\t" |
| 484 | (nth 4 var)) | 495 | type "\t" |
| 485 | 'gdb-edit-value nil | 496 | (nth 4 var)) |
| 486 | (if (and (nth 5 var) | 497 | (if (or parent status 'out-of-scope) |
| 487 | gdb-show-changed-values) | 498 | nil 'gdb-edit-value) |
| 488 | 'font-lock-warning-face | 499 | nil |
| 489 | nil) depth) | 500 | (if (and (or parent status) gdb-show-changed-values) |
| 490 | (speedbar-make-tag-line 'bracket char | 501 | 'shadow t) |
| 491 | 'gdb-speedbar-expand-node varnum | 502 | depth) |
| 492 | (concat (car var) "\t" (nth 3 var)) | 503 | (speedbar-make-tag-line |
| 493 | nil nil nil depth)))) | 504 | 'bracket char |
| 505 | 'gdb-speedbar-expand-node varnum | ||
| 506 | (concat expr "\t" type) | ||
| 507 | nil nil | ||
| 508 | (if (and (or parent status) gdb-show-changed-values) | ||
| 509 | 'shadow t) | ||
| 510 | depth)))) | ||
| 494 | (setq var-list (cdr var-list)))) | 511 | (setq var-list (cdr var-list)))) |
| 495 | (setq gdb-var-changed nil))) | 512 | (setq gdb-force-update nil))) |
| 496 | (t (if (and (save-excursion | 513 | (t (unless (and (save-excursion |
| 497 | (goto-char (point-min)) | 514 | (goto-char (point-min)) |
| 498 | (looking-at "Current Stack:")) | 515 | (looking-at "Current Stack:")) |
| 499 | (equal gud-last-last-frame gud-last-speedbar-stackframe)) | 516 | (equal gud-last-last-frame gud-last-speedbar-stackframe)) |
| 500 | nil | ||
| 501 | (let ((gud-frame-list | 517 | (let ((gud-frame-list |
| 502 | (cond ((eq minor-mode 'gdb) | 518 | (cond ((eq minor-mode 'gdb) |
| 503 | (gud-gdb-get-stackframe buffer)) | 519 | (gud-gdb-get-stackframe buffer)) |
diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el index a70941d9d3e..0ea9eef96cb 100644 --- a/lisp/progmodes/sh-script.el +++ b/lisp/progmodes/sh-script.el | |||
| @@ -1438,6 +1438,16 @@ with your script for an edit-interpret-debug cycle." | |||
| 1438 | ((and buffer-file-name | 1438 | ((and buffer-file-name |
| 1439 | (string-match "\\.m?spec\\'" buffer-file-name)) | 1439 | (string-match "\\.m?spec\\'" buffer-file-name)) |
| 1440 | "rpm"))))) | 1440 | "rpm"))))) |
| 1441 | (unless interpreter | ||
| 1442 | (setq interpreter | ||
| 1443 | (cond ((string-match "[.]sh\\>" buffer-file-name) | ||
| 1444 | "sh") | ||
| 1445 | ((string-match "[.]bash\\>" buffer-file-name) | ||
| 1446 | "bash") | ||
| 1447 | ((string-match "[.]ksh\\>" buffer-file-name) | ||
| 1448 | "ksh") | ||
| 1449 | ((string-match "[.]csh\\>" buffer-file-name) | ||
| 1450 | "csh")))) | ||
| 1441 | (sh-set-shell (or interpreter sh-shell-file) nil nil)) | 1451 | (sh-set-shell (or interpreter sh-shell-file) nil nil)) |
| 1442 | (run-mode-hooks 'sh-mode-hook)) | 1452 | (run-mode-hooks 'sh-mode-hook)) |
| 1443 | 1453 | ||
diff --git a/lisp/sort.el b/lisp/sort.el index 174a8531786..5183bf65afa 100644 --- a/lisp/sort.el +++ b/lisp/sort.el | |||
| @@ -499,8 +499,9 @@ Use \\[untabify] to convert tabs to spaces before sorting." | |||
| 499 | ;; in the region, since the sort utility would lose the | 499 | ;; in the region, since the sort utility would lose the |
| 500 | ;; properties. | 500 | ;; properties. |
| 501 | (let ((sort-args (list (if reverse "-rt\n" "-t\n") | 501 | (let ((sort-args (list (if reverse "-rt\n" "-t\n") |
| 502 | (concat "+0." (int-to-string col-start)) | 502 | (format "-k1.%d,1.%d" |
| 503 | (concat "-0." (int-to-string col-end))))) | 503 | (1+ col-start) |
| 504 | (1+ col-end))))) | ||
| 504 | (when sort-fold-case | 505 | (when sort-fold-case |
| 505 | (push "-f" sort-args)) | 506 | (push "-f" sort-args)) |
| 506 | (apply #'call-process-region beg1 end1 "sort" t t nil sort-args)) | 507 | (apply #'call-process-region beg1 end1 "sort" t t nil sort-args)) |
diff --git a/lisp/speedbar.el b/lisp/speedbar.el index 4e639c586f2..4f0e2edf7cb 100644 --- a/lisp/speedbar.el +++ b/lisp/speedbar.el | |||
| @@ -1708,9 +1708,13 @@ Separators are not active, have no labels, depth, or actions." | |||
| 1708 | (defun speedbar-make-button (start end face mouse function &optional token) | 1708 | (defun speedbar-make-button (start end face mouse function &optional token) |
| 1709 | "Create a button from START to END, with FACE as the display face. | 1709 | "Create a button from START to END, with FACE as the display face. |
| 1710 | MOUSE is the mouse face. When this button is clicked on FUNCTION | 1710 | MOUSE is the mouse face. When this button is clicked on FUNCTION |
| 1711 | will be run with the TOKEN parameter (any Lisp object)" | 1711 | will be run with the TOKEN parameter (any Lisp object). If FACE |
| 1712 | is t use the text properties of the string that is passed as an | ||
| 1713 | argument." | ||
| 1714 | (unless (eq face t) | ||
| 1715 | (put-text-property start end 'face face)) | ||
| 1712 | (add-text-properties | 1716 | (add-text-properties |
| 1713 | start end `(face ,face mouse-face ,mouse invisible nil | 1717 | start end `(mouse-face ,mouse invisible nil |
| 1714 | speedbar-text ,(buffer-substring-no-properties start end))) | 1718 | speedbar-text ,(buffer-substring-no-properties start end))) |
| 1715 | (if speedbar-use-tool-tips-flag | 1719 | (if speedbar-use-tool-tips-flag |
| 1716 | (put-text-property start end 'help-echo #'dframe-help-echo)) | 1720 | (put-text-property start end 'help-echo #'dframe-help-echo)) |
diff --git a/lisp/textmodes/ispell.el b/lisp/textmodes/ispell.el index f52ed056994..d6fdbffad74 100644 --- a/lisp/textmodes/ispell.el +++ b/lisp/textmodes/ispell.el | |||
| @@ -508,11 +508,7 @@ re-start emacs." | |||
| 508 | (const "~nroff") (const "~list") | 508 | (const "~nroff") (const "~list") |
| 509 | (const "~latin1") (const "~latin3") | 509 | (const "~latin1") (const "~latin3") |
| 510 | (const :tag "default" nil)) | 510 | (const :tag "default" nil)) |
| 511 | (choice :tag "Coding system" | 511 | (coding-system :tag "Coding System"))) |
| 512 | (const iso-8859-1) | ||
| 513 | (const iso-8859-2) | ||
| 514 | (const koi8-r) | ||
| 515 | (const windows-1251)))) | ||
| 516 | :group 'ispell) | 512 | :group 'ispell) |
| 517 | 513 | ||
| 518 | 514 | ||
| @@ -570,10 +566,10 @@ re-start emacs." | |||
| 570 | '(("esperanto" | 566 | '(("esperanto" |
| 571 | "[A-Za-z\246\254\266\274\306\330\335\336\346\370\375\376]" | 567 | "[A-Za-z\246\254\266\274\306\330\335\336\346\370\375\376]" |
| 572 | "[^A-Za-z\246\254\266\274\306\330\335\336\346\370\375\376]" | 568 | "[^A-Za-z\246\254\266\274\306\330\335\336\346\370\375\376]" |
| 573 | "[-']" t ("-C") "~latin3" iso-8859-1) | 569 | "[-']" t ("-C") "~latin3" iso-8859-3) |
| 574 | ("esperanto-tex" | 570 | ("esperanto-tex" |
| 575 | "[A-Za-z^\\]" "[^A-Za-z^\\]" | 571 | "[A-Za-z^\\]" "[^A-Za-z^\\]" |
| 576 | "[-'`\"]" t ("-C" "-d" "esperanto") "~tex" iso-8859-1) | 572 | "[-'`\"]" t ("-C" "-d" "esperanto") "~tex" iso-8859-3) |
| 577 | ("francais7" | 573 | ("francais7" |
| 578 | "[A-Za-z]" "[^A-Za-z]" "[`'^---]" t nil nil iso-8859-1) | 574 | "[A-Za-z]" "[^A-Za-z]" "[`'^---]" t nil nil iso-8859-1) |
| 579 | ("francais" ; Francais.aff | 575 | ("francais" ; Francais.aff |
| @@ -2574,7 +2570,7 @@ By just answering RET you can find out what the current dictionary is." | |||
| 2574 | (mapcar 'list (ispell-valid-dictionary-list))) | 2570 | (mapcar 'list (ispell-valid-dictionary-list))) |
| 2575 | nil t) | 2571 | nil t) |
| 2576 | current-prefix-arg)) | 2572 | current-prefix-arg)) |
| 2577 | (unless arg (ispell-accept-buffer-local-defs)) | 2573 | (unless arg (ispell-buffer-local-dict)) |
| 2578 | (if (equal dict "default") (setq dict nil)) | 2574 | (if (equal dict "default") (setq dict nil)) |
| 2579 | ;; This relies on completing-read's bug of returning "" for no match | 2575 | ;; This relies on completing-read's bug of returning "" for no match |
| 2580 | (cond ((equal dict "") | 2576 | (cond ((equal dict "") |
diff --git a/lisp/url/ChangeLog b/lisp/url/ChangeLog index 04cd080db8f..cb002731eec 100644 --- a/lisp/url/ChangeLog +++ b/lisp/url/ChangeLog | |||
| @@ -1,3 +1,13 @@ | |||
| 1 | 2006-02-20 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 2 | |||
| 3 | * url.el (url-redirect-buffer): New var. | ||
| 4 | (url-retrieve-synchronously): Use it to follow redirections. | ||
| 5 | |||
| 6 | * url-http.el: Require `url' rather than try to autoload parts of it. | ||
| 7 | (url-http-find-free-connection): `url-open-stream' needs a real buffer. | ||
| 8 | (url-http-parse-headers): Set `url-redirect-buffer' when following | ||
| 9 | a redirection reply. | ||
| 10 | |||
| 1 | 2006-01-18 Stefan Monnier <monnier@iro.umontreal.ca> | 11 | 2006-01-18 Stefan Monnier <monnier@iro.umontreal.ca> |
| 2 | 12 | ||
| 3 | * url-news.el: Move defvars out of eval-when-compile. | 13 | * url-news.el: Move defvars out of eval-when-compile. |
| @@ -18,7 +28,7 @@ | |||
| 18 | (url-history-save-history): Create parent dir if necessary. | 28 | (url-history-save-history): Create parent dir if necessary. |
| 19 | (url-history-save-history): Don't write the initialization of | 29 | (url-history-save-history): Don't write the initialization of |
| 20 | url-history-hash-table into the history file. | 30 | url-history-hash-table into the history file. |
| 21 | (url-have-visited-url): Simplify since url-history-hash-table is non-nil. | 31 | (url-have-visited-url): Simplify since url-history-hash-table isn't nil. |
| 22 | (url-completion-function): Simplify. | 32 | (url-completion-function): Simplify. |
| 23 | 33 | ||
| 24 | * url-cookie.el (url-cookie-parse-file): Don't complain of missing file. | 34 | * url-cookie.el (url-cookie-parse-file): Don't complain of missing file. |
diff --git a/lisp/url/url-http.el b/lisp/url/url-http.el index ac8f490f3e8..22ca6010ef9 100644 --- a/lisp/url/url-http.el +++ b/lisp/url/url-http.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; url-http.el --- HTTP retrieval routines | 1 | ;;; url-http.el --- HTTP retrieval routines |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1999, 2001, 2004, 2005, 2006 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1999, 2001, 2004, 2005, 2006 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Bill Perry <wmperry@gnu.org> | 5 | ;; Author: Bill Perry <wmperry@gnu.org> |
| 6 | ;; Keywords: comm, data, processes | 6 | ;; Keywords: comm, data, processes |
| @@ -35,10 +35,8 @@ | |||
| 35 | (require 'url-cookie) | 35 | (require 'url-cookie) |
| 36 | (require 'mail-parse) | 36 | (require 'mail-parse) |
| 37 | (require 'url-auth) | 37 | (require 'url-auth) |
| 38 | (autoload 'url-retrieve-synchronously "url") | 38 | (require 'url) |
| 39 | (autoload 'url-retrieve "url") | ||
| 40 | (autoload 'url-cache-create-filename "url-cache") | 39 | (autoload 'url-cache-create-filename "url-cache") |
| 41 | (autoload 'url-mark-buffer-as-dead "url") | ||
| 42 | 40 | ||
| 43 | (defconst url-http-default-port 80 "Default HTTP port.") | 41 | (defconst url-http-default-port 80 "Default HTTP port.") |
| 44 | (defconst url-http-asynchronous-p t "HTTP retrievals are asynchronous.") | 42 | (defconst url-http-asynchronous-p t "HTTP retrievals are asynchronous.") |
| @@ -57,15 +55,13 @@ Valid values are 1.1 and 1.0. | |||
| 57 | This is only useful when debugging the HTTP subsystem. | 55 | This is only useful when debugging the HTTP subsystem. |
| 58 | 56 | ||
| 59 | Setting this to 1.0 will tell servers not to send chunked encoding, | 57 | Setting this to 1.0 will tell servers not to send chunked encoding, |
| 60 | and other HTTP/1.1 specific features. | 58 | and other HTTP/1.1 specific features.") |
| 61 | ") | ||
| 62 | 59 | ||
| 63 | (defvar url-http-attempt-keepalives t | 60 | (defvar url-http-attempt-keepalives t |
| 64 | "Whether to use a single TCP connection multiple times in HTTP. | 61 | "Whether to use a single TCP connection multiple times in HTTP. |
| 65 | This is only useful when debugging the HTTP subsystem. Setting to | 62 | This is only useful when debugging the HTTP subsystem. Setting to |
| 66 | `nil' will explicitly close the connection to the server after every | 63 | nil will explicitly close the connection to the server after every |
| 67 | request. | 64 | request.") |
| 68 | ") | ||
| 69 | 65 | ||
| 70 | ;(eval-when-compile | 66 | ;(eval-when-compile |
| 71 | ;; These are all macros so that they are hidden from external sight | 67 | ;; These are all macros so that they are hidden from external sight |
| @@ -119,10 +115,14 @@ request. | |||
| 119 | (url-http-debug "Reusing existing connection: %s:%d" host port) | 115 | (url-http-debug "Reusing existing connection: %s:%d" host port) |
| 120 | (url-http-debug "Contacting host: %s:%d" host port)) | 116 | (url-http-debug "Contacting host: %s:%d" host port)) |
| 121 | (url-lazy-message "Contacting host: %s:%d" host port) | 117 | (url-lazy-message "Contacting host: %s:%d" host port) |
| 122 | (url-http-mark-connection-as-busy host port | 118 | (url-http-mark-connection-as-busy |
| 123 | (or found | 119 | host port |
| 124 | (url-open-stream host nil host | 120 | (or found |
| 125 | port))))) | 121 | (let ((buf (generate-new-buffer " *url-http-temp*"))) |
| 122 | ;; `url-open-stream' needs a buffer in which to do things | ||
| 123 | ;; like authentication. But we use another buffer afterwards. | ||
| 124 | (unwind-protect (url-open-stream host buf host port) | ||
| 125 | (kill-buffer buf))))))) | ||
| 126 | 126 | ||
| 127 | ;; Building an HTTP request | 127 | ;; Building an HTTP request |
| 128 | (defun url-http-user-agent-string () | 128 | (defun url-http-user-agent-string () |
| @@ -346,7 +346,7 @@ This allows us to use `mail-fetch-field', etc." | |||
| 346 | 346 | ||
| 347 | (defun url-http-handle-cookies () | 347 | (defun url-http-handle-cookies () |
| 348 | "Handle all set-cookie / set-cookie2 headers in an HTTP response. | 348 | "Handle all set-cookie / set-cookie2 headers in an HTTP response. |
| 349 | The buffer must already be narrowed to the headers, so mail-fetch-field will | 349 | The buffer must already be narrowed to the headers, so `mail-fetch-field' will |
| 350 | work correctly." | 350 | work correctly." |
| 351 | (let ((cookies (mail-fetch-field "Set-Cookie" nil nil t)) | 351 | (let ((cookies (mail-fetch-field "Set-Cookie" nil nil t)) |
| 352 | (cookies2 (mail-fetch-field "Set-Cookie2" nil nil t)) | 352 | (cookies2 (mail-fetch-field "Set-Cookie2" nil nil t)) |
| @@ -509,10 +509,17 @@ should be shown to the user." | |||
| 509 | (let ((url-request-method url-http-method) | 509 | (let ((url-request-method url-http-method) |
| 510 | (url-request-data url-http-data) | 510 | (url-request-data url-http-data) |
| 511 | (url-request-extra-headers url-http-extra-headers)) | 511 | (url-request-extra-headers url-http-extra-headers)) |
| 512 | (url-retrieve redirect-uri url-callback-function | 512 | ;; Put in the current buffer a forwarding pointer to the new |
| 513 | (cons :redirect | 513 | ;; destination buffer. |
| 514 | (cons redirect-uri | 514 | ;; FIXME: This is a hack to fix url-retrieve-synchronously |
| 515 | url-callback-arguments))) | 515 | ;; without changing the API. Instead url-retrieve should |
| 516 | ;; either simply not return the "destination" buffer, or it | ||
| 517 | ;; should take an optional `dest-buf' argument. | ||
| 518 | (set (make-local-variable 'url-redirect-buffer) | ||
| 519 | (url-retrieve redirect-uri url-callback-function | ||
| 520 | (cons :redirect | ||
| 521 | (cons redirect-uri | ||
| 522 | url-callback-arguments)))) | ||
| 516 | (url-mark-buffer-as-dead (current-buffer)))))) | 523 | (url-mark-buffer-as-dead (current-buffer)))))) |
| 517 | (4 ; Client error | 524 | (4 ; Client error |
| 518 | ;; 400 Bad Request | 525 | ;; 400 Bad Request |
| @@ -1156,7 +1163,7 @@ CBARGS as the arguments." | |||
| 1156 | 1163 | ||
| 1157 | ;;;###autoload | 1164 | ;;;###autoload |
| 1158 | (defun url-http-options (url) | 1165 | (defun url-http-options (url) |
| 1159 | "Returns a property list describing options available for URL. | 1166 | "Return a property list describing options available for URL. |
| 1160 | This list is retrieved using the `OPTIONS' HTTP method. | 1167 | This list is retrieved using the `OPTIONS' HTTP method. |
| 1161 | 1168 | ||
| 1162 | Property list members: | 1169 | Property list members: |
| @@ -1179,8 +1186,7 @@ p3p | |||
| 1179 | The `Platform For Privacy Protection' description for the resource. | 1186 | The `Platform For Privacy Protection' description for the resource. |
| 1180 | Currently this is just the raw header contents. This is likely to | 1187 | Currently this is just the raw header contents. This is likely to |
| 1181 | change once P3P is formally supported by the URL package or | 1188 | change once P3P is formally supported by the URL package or |
| 1182 | Emacs/W3. | 1189 | Emacs/W3." |
| 1183 | " | ||
| 1184 | (let* ((url-request-method "OPTIONS") | 1190 | (let* ((url-request-method "OPTIONS") |
| 1185 | (url-request-data nil) | 1191 | (url-request-data nil) |
| 1186 | (buffer (url-retrieve-synchronously url)) | 1192 | (buffer (url-retrieve-synchronously url)) |
diff --git a/lisp/url/url.el b/lisp/url/url.el index 10c449cb30b..07ac55dcd3d 100644 --- a/lisp/url/url.el +++ b/lisp/url/url.el | |||
| @@ -114,6 +114,13 @@ Emacs." | |||
| 114 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | 114 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
| 115 | ;;; Retrieval functions | 115 | ;;; Retrieval functions |
| 116 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | 116 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
| 117 | |||
| 118 | (defvar url-redirect-buffer nil | ||
| 119 | "New buffer into which the retrieval will take place. | ||
| 120 | Sometimes while retrieving a URL, the URL library needs to use another buffer | ||
| 121 | than the one returned initially by `url-retrieve'. In this case, it sets this | ||
| 122 | variable in the original buffer as a forwarding pointer.") | ||
| 123 | |||
| 117 | ;;;###autoload | 124 | ;;;###autoload |
| 118 | (defun url-retrieve (url callback &optional cbargs) | 125 | (defun url-retrieve (url callback &optional cbargs) |
| 119 | "Retrieve URL asynchronously and call CALLBACK with CBARGS when finished. | 126 | "Retrieve URL asynchronously and call CALLBACK with CBARGS when finished. |
| @@ -189,18 +196,22 @@ no further processing). URL is either a string or a parsed URL." | |||
| 189 | (url-debug 'retrieval | 196 | (url-debug 'retrieval |
| 190 | "Spinning in url-retrieve-synchronously: %S (%S)" | 197 | "Spinning in url-retrieve-synchronously: %S (%S)" |
| 191 | retrieval-done asynch-buffer) | 198 | retrieval-done asynch-buffer) |
| 192 | (if (and proc (memq (process-status proc) | 199 | (if (buffer-local-value 'url-redirect-buffer asynch-buffer) |
| 193 | '(closed exit signal failed)) | 200 | (setq proc (get-buffer-process |
| 194 | ;; Make sure another process hasn't been started, as can | 201 | (setq asynch-buffer |
| 195 | ;; happen with http redirections. | 202 | (buffer-local-value 'url-redirect-buffer |
| 196 | (eq proc (or (get-buffer-process asynch-buffer) proc))) | 203 | asynch-buffer)))) |
| 197 | ;; FIXME: It's not clear whether url-retrieve's callback is | 204 | (if (and proc (memq (process-status proc) |
| 198 | ;; guaranteed to be called or not. It seems that url-http | 205 | '(closed exit signal failed)) |
| 199 | ;; decides sometimes consciously not to call it, so it's not | 206 | ;; Make sure another process hasn't been started. |
| 200 | ;; clear that it's a bug, but even then we need to decide how | 207 | (eq proc (or (get-buffer-process asynch-buffer) proc))) |
| 201 | ;; url-http can then warn us that the download has completed. | 208 | ;; FIXME: It's not clear whether url-retrieve's callback is |
| 202 | ;; In the mean time, we use this here workaround. | 209 | ;; guaranteed to be called or not. It seems that url-http |
| 203 | (setq retrieval-done t) | 210 | ;; decides sometimes consciously not to call it, so it's not |
| 211 | ;; clear that it's a bug, but even then we need to decide how | ||
| 212 | ;; url-http can then warn us that the download has completed. | ||
| 213 | ;; In the mean time, we use this here workaround. | ||
| 214 | (setq retrieval-done t)) | ||
| 204 | ;; We used to use `sit-for' here, but in some cases it wouldn't | 215 | ;; We used to use `sit-for' here, but in some cases it wouldn't |
| 205 | ;; work because apparently pending keyboard input would always | 216 | ;; work because apparently pending keyboard input would always |
| 206 | ;; interrupt it before it got a chance to handle process input. | 217 | ;; interrupt it before it got a chance to handle process input. |
diff --git a/lispref/ChangeLog b/lispref/ChangeLog index 480676a8c5f..f1f263d18a5 100644 --- a/lispref/ChangeLog +++ b/lispref/ChangeLog | |||
| @@ -1,4 +1,40 @@ | |||
| 1 | 2006-02-16 Johan Bockg,AC%(Brd <bojohan+mail@dd.chalmers.se> (tiny change) | 1 | 2006-02-21 Giorgos Keramidas <keramida@ceid.upatras.gr> (tiny change) |
| 2 | |||
| 3 | * display.texi (Fringe Indicators, Fringe Cursors): Fix typos. | ||
| 4 | |||
| 5 | * windows.texi (Window Tree): Fix typo. | ||
| 6 | |||
| 7 | 2006-02-20 Kim F. Storm <storm@cua.dk> | ||
| 8 | |||
| 9 | * display.texi (Fringe Indicators): New section. | ||
| 10 | Move indicate-empty-lines, indicate-buffer-boundaries, and | ||
| 11 | default-indicate-buffer-boundaries here. | ||
| 12 | Add fringe-indicator-alist and default-fringes-indicator-alist. | ||
| 13 | Add list of logical fringe indicator symbols. | ||
| 14 | Update list of standard bitmap names. | ||
| 15 | (Fringe Cursors): New section. | ||
| 16 | Move overflow-newline-into-fringe here. | ||
| 17 | Add fringe-cursor-alist and default-fringes-cursor-alist. | ||
| 18 | Add list of fringe cursor symbols. | ||
| 19 | |||
| 20 | 2006-02-20 Juanma Barranquero <lekktu@gmail.com> | ||
| 21 | |||
| 22 | * commands.texi (Using Interactive): Fix reference to node | ||
| 23 | "Minibuffers". | ||
| 24 | |||
| 25 | 2006-02-19 Richard M. Stallman <rms@gnu.org> | ||
| 26 | |||
| 27 | * minibuf.texi (High-Level Completion): | ||
| 28 | Add xref to read-input-method-name. | ||
| 29 | |||
| 30 | * files.texi (Relative File Names): Move file-relative-name here. | ||
| 31 | (File Name Expansion): From here. Minor clarifications. | ||
| 32 | |||
| 33 | * commands.texi (Using Interactive): Add xrefs about reading input. | ||
| 34 | Clarify remarks about that moving point and mark. | ||
| 35 | Put string case before list case. | ||
| 36 | |||
| 37 | 2006-02-16 Johan Bockg,Ae(Brd <bojohan@dd.chalmers.se> | ||
| 2 | 38 | ||
| 3 | * display.texi (Other Display Specs, Image Descriptors): Revert | 39 | * display.texi (Other Display Specs, Image Descriptors): Revert |
| 4 | erroneous changes. The previous description of image-descriptors | 40 | erroneous changes. The previous description of image-descriptors |
diff --git a/lispref/commands.texi b/lispref/commands.texi index 7a2cdb8edf9..797a5ced8e9 100644 --- a/lispref/commands.texi +++ b/lispref/commands.texi | |||
| @@ -151,37 +151,6 @@ arguments. This leads quickly to an error if the command requires one | |||
| 151 | or more arguments. | 151 | or more arguments. |
| 152 | 152 | ||
| 153 | @item | 153 | @item |
| 154 | It may be a Lisp expression that is not a string; then it should be a | ||
| 155 | form that is evaluated to get a list of arguments to pass to the | ||
| 156 | command. | ||
| 157 | @cindex argument evaluation form | ||
| 158 | |||
| 159 | If this expression reads keyboard input (this includes using the | ||
| 160 | minibuffer), keep in mind that the integer value of point or the mark | ||
| 161 | before reading input may be incorrect after reading input. This is | ||
| 162 | because the current buffer may be receiving subprocess output; | ||
| 163 | if subprocess output arrives while the command is waiting for input, | ||
| 164 | it could relocate point and the mark. | ||
| 165 | |||
| 166 | Here's an example of what @emph{not} to do: | ||
| 167 | |||
| 168 | @smallexample | ||
| 169 | (interactive | ||
| 170 | (list (region-beginning) (region-end) | ||
| 171 | (read-string "Foo: " nil 'my-history))) | ||
| 172 | @end smallexample | ||
| 173 | |||
| 174 | @noindent | ||
| 175 | Here's how to avoid the problem, by examining point and the mark only | ||
| 176 | after reading the keyboard input: | ||
| 177 | |||
| 178 | @smallexample | ||
| 179 | (interactive | ||
| 180 | (let ((string (read-string "Foo: " nil 'my-history))) | ||
| 181 | (list (region-beginning) (region-end) string))) | ||
| 182 | @end smallexample | ||
| 183 | |||
| 184 | @item | ||
| 185 | @cindex argument prompt | 154 | @cindex argument prompt |
| 186 | It may be a string; then its contents should consist of a code character | 155 | It may be a string; then its contents should consist of a code character |
| 187 | followed by a prompt (which some code characters use and some ignore). | 156 | followed by a prompt (which some code characters use and some ignore). |
| @@ -231,6 +200,39 @@ You can use @samp{*} and @samp{@@} together; the order does not matter. | |||
| 231 | Actual reading of arguments is controlled by the rest of the prompt | 200 | Actual reading of arguments is controlled by the rest of the prompt |
| 232 | string (starting with the first character that is not @samp{*} or | 201 | string (starting with the first character that is not @samp{*} or |
| 233 | @samp{@@}). | 202 | @samp{@@}). |
| 203 | |||
| 204 | @item | ||
| 205 | It may be a Lisp expression that is not a string; then it should be a | ||
| 206 | form that is evaluated to get a list of arguments to pass to the | ||
| 207 | command. Usually this form will call various functions to read input | ||
| 208 | from the user, most often through the minibuffer (@pxref{Minibuffers}) | ||
| 209 | or directly from the keyboard (@pxref{Reading Input}). | ||
| 210 | @cindex argument evaluation form | ||
| 211 | |||
| 212 | Providing point or the mark as an argument value is also common, but | ||
| 213 | if you do this @emph{and} read input (whether using the minibuffer or | ||
| 214 | not), be sure to get the integer values of point or the mark after | ||
| 215 | reading. The current buffer may be receiving subprocess output; if | ||
| 216 | subprocess output arrives while the command is waiting for input, it | ||
| 217 | could relocate point and the mark. | ||
| 218 | |||
| 219 | Here's an example of what @emph{not} to do: | ||
| 220 | |||
| 221 | @smallexample | ||
| 222 | (interactive | ||
| 223 | (list (region-beginning) (region-end) | ||
| 224 | (read-string "Foo: " nil 'my-history))) | ||
| 225 | @end smallexample | ||
| 226 | |||
| 227 | @noindent | ||
| 228 | Here's how to avoid the problem, by examining point and the mark after | ||
| 229 | reading the keyboard input: | ||
| 230 | |||
| 231 | @smallexample | ||
| 232 | (interactive | ||
| 233 | (let ((string (read-string "Foo: " nil 'my-history))) | ||
| 234 | (list (region-beginning) (region-end) string))) | ||
| 235 | @end smallexample | ||
| 234 | @end itemize | 236 | @end itemize |
| 235 | 237 | ||
| 236 | @cindex examining the @code{interactive} form | 238 | @cindex examining the @code{interactive} form |
diff --git a/lispref/display.texi b/lispref/display.texi index 20b8df8d466..b9d949a01dd 100644 --- a/lispref/display.texi +++ b/lispref/display.texi | |||
| @@ -2722,7 +2722,9 @@ continuation, horizontal scrolling, and the overlay arrow. | |||
| 2722 | 2722 | ||
| 2723 | @menu | 2723 | @menu |
| 2724 | * Fringe Size/Pos:: Specifying where to put the window fringes. | 2724 | * Fringe Size/Pos:: Specifying where to put the window fringes. |
| 2725 | * Fringe Bitmaps:: Displaying bitmaps in the window fringes. | 2725 | * Fringe Indicators:: Displaying indicator icons in the window fringes. |
| 2726 | * Fringe Cursors:: Displaying cursors in the right fringe. | ||
| 2727 | * Fringe Bitmaps:: Specifying bitmaps for fringe indicators. | ||
| 2726 | * Customizing Bitmaps:: Specifying your own bitmaps to use in the fringes. | 2728 | * Customizing Bitmaps:: Specifying your own bitmaps to use in the fringes. |
| 2727 | * Overlay Arrow:: Display of an arrow to indicate position. | 2729 | * Overlay Arrow:: Display of an arrow to indicate position. |
| 2728 | @end menu | 2730 | @end menu |
| @@ -2774,6 +2776,151 @@ window is used. The value has the form @code{(@var{left-width} | |||
| 2774 | @var{right-width} @var{outside-margins})}. | 2776 | @var{right-width} @var{outside-margins})}. |
| 2775 | @end defun | 2777 | @end defun |
| 2776 | 2778 | ||
| 2779 | |||
| 2780 | @node Fringe Indicators | ||
| 2781 | @subsection Fringe Indicators | ||
| 2782 | @cindex fringe indicators | ||
| 2783 | @cindex indicators, fringe | ||
| 2784 | |||
| 2785 | The @dfn{fringe indicators} are tiny icons Emacs displays in the | ||
| 2786 | window fringe (on a graphic display) to indicate truncated or | ||
| 2787 | continued lines, buffer boundaries, overlay arrow, etc. | ||
| 2788 | |||
| 2789 | @defopt indicate-empty-lines | ||
| 2790 | @tindex indicate-empty-lines | ||
| 2791 | @cindex fringes, and empty line indication | ||
| 2792 | When this is non-@code{nil}, Emacs displays a special glyph in the | ||
| 2793 | fringe of each empty line at the end of the buffer, on graphical | ||
| 2794 | displays. @xref{Fringes}. This variable is automatically | ||
| 2795 | buffer-local in every buffer. | ||
| 2796 | @end defopt | ||
| 2797 | |||
| 2798 | @defvar indicate-buffer-boundaries | ||
| 2799 | This buffer-local variable controls how the buffer boundaries and | ||
| 2800 | window scrolling are indicated in the window fringes. | ||
| 2801 | |||
| 2802 | Emacs can indicate the buffer boundaries---that is, the first and last | ||
| 2803 | line in the buffer---with angle icons when they appear on the screen. | ||
| 2804 | In addition, Emacs can display an up-arrow in the fringe to show | ||
| 2805 | that there is text above the screen, and a down-arrow to show | ||
| 2806 | there is text below the screen. | ||
| 2807 | |||
| 2808 | There are four kinds of basic values: | ||
| 2809 | |||
| 2810 | @table @asis | ||
| 2811 | @item @code{nil} | ||
| 2812 | Don't display the icons. | ||
| 2813 | @item @code{left} | ||
| 2814 | Display them in the left fringe. | ||
| 2815 | @item @code{right} | ||
| 2816 | Display them in the right fringe. | ||
| 2817 | @item @var{anything-else} | ||
| 2818 | Display the icon at the top of the window top in the left fringe, and other | ||
| 2819 | in the right fringe. | ||
| 2820 | @end table | ||
| 2821 | |||
| 2822 | If value is a cons @code{(@var{angles} . @var{arrows})}, @var{angles} | ||
| 2823 | controls the angle icons, and @var{arrows} controls the arrows. Both | ||
| 2824 | @var{angles} and @var{arrows} work according to the table above. | ||
| 2825 | Thus, @code{(t . right)} places the top angle icon in the left | ||
| 2826 | fringe, the bottom angle icon in the right fringe, and both arrows in | ||
| 2827 | the right fringe. | ||
| 2828 | @end defvar | ||
| 2829 | |||
| 2830 | @defvar default-indicate-buffer-boundaries | ||
| 2831 | The value of this variable is the default value for | ||
| 2832 | @code{indicate-buffer-boundaries} in buffers that do not override it. | ||
| 2833 | @end defvar | ||
| 2834 | |||
| 2835 | @defvar fringe-indicator-alist | ||
| 2836 | This buffer-local variable specifies the mapping from logical fringe | ||
| 2837 | indicators to the actual bitmaps displayed in the window fringes. | ||
| 2838 | |||
| 2839 | These symbols identify the logical fringe indicators: | ||
| 2840 | |||
| 2841 | @table @asis | ||
| 2842 | @item Truncation and continuation line indicators: | ||
| 2843 | @code{truncation}, @code{continuation}. | ||
| 2844 | |||
| 2845 | @item Buffer position indicators: | ||
| 2846 | @code{up}, @code{down}, | ||
| 2847 | @code{top}, @code{bottom}, | ||
| 2848 | @code{top-bottom}. | ||
| 2849 | |||
| 2850 | @item Empty line indicator: | ||
| 2851 | @code{empty-line}. | ||
| 2852 | |||
| 2853 | @item Overlay arrow indicator: | ||
| 2854 | @code{overlay-arrow}. | ||
| 2855 | |||
| 2856 | @item Unknown bitmap indicator: | ||
| 2857 | @code{unknown}. | ||
| 2858 | @end table | ||
| 2859 | |||
| 2860 | The value is an alist where each element @code{(@var{indicator} . @var{bitmaps})} | ||
| 2861 | specifies the fringe bitmaps used to display a specific logical | ||
| 2862 | fringe indicator. | ||
| 2863 | |||
| 2864 | Here, @var{indicator} specifies the logical indicator type, and | ||
| 2865 | @var{bitmaps} is list of symbols @code{(@var{left} @var{right} | ||
| 2866 | [@var{left1} @var{right1}])} which specifies the actual bitmap shown | ||
| 2867 | in the left or right fringe for the logical indicator. | ||
| 2868 | |||
| 2869 | The @var{left} and @var{right} symbols specify the bitmaps shown in | ||
| 2870 | the left and/or right fringe for the specific indicator. The | ||
| 2871 | @var{left1} or @var{right1} bitmaps are used only for the `bottom' and | ||
| 2872 | `top-bottom indicators when the last (only) line in has no final | ||
| 2873 | newline. Alternatively, @var{bitmaps} may be a single symbol which is | ||
| 2874 | used in both left and right fringes. | ||
| 2875 | |||
| 2876 | When @code{fringe-indicator-alist} has a buffer-local value, and there | ||
| 2877 | is no bitmap defined for a logical indicator, or the bitmap is | ||
| 2878 | @code{t}, the corresponding value from the (non-local) | ||
| 2879 | @code{default-fringes-indicator-alist} is used. | ||
| 2880 | |||
| 2881 | To completely hide a specific indicator, set the bitmap to @code{nil}. | ||
| 2882 | @end defvar | ||
| 2883 | |||
| 2884 | @defvar default-fringes-indicator-alist | ||
| 2885 | The value of this variable is the default value for | ||
| 2886 | @code{fringe-indicator-alist} in buffers that do not override it. | ||
| 2887 | @end defvar | ||
| 2888 | |||
| 2889 | @table @asis | ||
| 2890 | @item Standard fringe bitmaps for indicators: | ||
| 2891 | @code{left-arrow}, @code{right-arrow}, @code{up-arrow}, @code{down-arrow}, | ||
| 2892 | @code{left-curly-arrow}, @code{right-curly-arrow}, | ||
| 2893 | @code{left-triangle}, @code{right-triangle}, | ||
| 2894 | @code{top-left-angle}, @code{ top-right-angle}, | ||
| 2895 | @code{bottom-left-angle}, @code{bottom-right-angle}, | ||
| 2896 | @code{left-bracket}, @code{right-bracket}, | ||
| 2897 | @code{filled-rectangle}, @code{hollow-rectangle}, | ||
| 2898 | @code{filled-square}, @code{hollow-square}, | ||
| 2899 | @code{vertical-bar}, @code{horizontal-bar}, | ||
| 2900 | @code{empty-line}, | ||
| 2901 | @code{question-mark}. | ||
| 2902 | @end table | ||
| 2903 | |||
| 2904 | @node Fringe Cursors | ||
| 2905 | @subsection Fringe Cursors | ||
| 2906 | @cindex fringe cursors | ||
| 2907 | @cindex cursor, fringe | ||
| 2908 | |||
| 2909 | When a line is exactly as wide as the window, Emacs displays the | ||
| 2910 | cursor in the right fringe instead of using two lines. Different | ||
| 2911 | bitmaps are used to represent the cursor in the fringe depending on | ||
| 2912 | the current buffer's cursor type. | ||
| 2913 | |||
| 2914 | @table @asis | ||
| 2915 | @item Logical cursor types: | ||
| 2916 | @code{box} , @code{hollow}, @code{bar}, | ||
| 2917 | @code{hbar}, @code{hollow-small}. | ||
| 2918 | @end table | ||
| 2919 | |||
| 2920 | The @code{hollow-small} type is used instead of @code{hollow} when the | ||
| 2921 | normal @code{hollow-rectangle} bitmap is too tall to fit on a specific | ||
| 2922 | display line. | ||
| 2923 | |||
| 2777 | @defvar overflow-newline-into-fringe | 2924 | @defvar overflow-newline-into-fringe |
| 2778 | If this is non-@code{nil}, lines exactly as wide as the window (not | 2925 | If this is non-@code{nil}, lines exactly as wide as the window (not |
| 2779 | counting the final newline character) are not continued. Instead, | 2926 | counting the final newline character) are not continued. Instead, |
| @@ -2781,16 +2928,44 @@ when point is at the end of the line, the cursor appears in the right | |||
| 2781 | fringe. | 2928 | fringe. |
| 2782 | @end defvar | 2929 | @end defvar |
| 2783 | 2930 | ||
| 2931 | @defvar fringe-cursor-alist | ||
| 2932 | This variable specifies the mapping from logical cursor type to the | ||
| 2933 | actual fringe bitmaps displayed in the right fringe. The value is an | ||
| 2934 | alist where each element @code{(@var{cursor}. @var{bitmap})} specifies | ||
| 2935 | the fringe bitmaps used to display a specific logical cursor type in | ||
| 2936 | the fringe. Here, @var{cursor} specifies the logical cursor type and | ||
| 2937 | @var{bitmap} is a symbol specifying the fringe bitmap to be displayed | ||
| 2938 | for that logical cursor type. | ||
| 2939 | |||
| 2940 | When @code{fringe-cursor-alist} has a buffer-local value, and there is | ||
| 2941 | no bitmap defined for a cursor type, the corresponding value from the | ||
| 2942 | (non-local) @code{default-fringes-indicator-alist} is used. | ||
| 2943 | @end defvar | ||
| 2944 | |||
| 2945 | @defvar default-fringes-cursor-alist | ||
| 2946 | The value of this variable is the default value for | ||
| 2947 | @code{fringe-cursor-alist} in buffers that do not override it. | ||
| 2948 | @end defvar | ||
| 2949 | |||
| 2950 | @table @asis | ||
| 2951 | @item Standard bitmaps for displaying the cursor in right fringe: | ||
| 2952 | @code{filled-rectangle}, @code{hollow-rectangle}, | ||
| 2953 | @code{filled-square}, @code{hollow-square}, | ||
| 2954 | @code{vertical-bar}, @code{horizontal-bar}. | ||
| 2955 | @end table | ||
| 2956 | |||
| 2957 | |||
| 2784 | @node Fringe Bitmaps | 2958 | @node Fringe Bitmaps |
| 2785 | @subsection Fringe Bitmaps | 2959 | @subsection Fringe Bitmaps |
| 2786 | @cindex fringe bitmaps | 2960 | @cindex fringe bitmaps |
| 2787 | @cindex bitmaps, fringe | 2961 | @cindex bitmaps, fringe |
| 2788 | 2962 | ||
| 2789 | The @dfn{fringe bitmaps} are tiny icons Emacs displays in the window | 2963 | The @dfn{fringe bitmaps} are the actual bitmaps which represent the |
| 2790 | fringe (on a graphic display) to indicate truncated or continued | 2964 | logical fringe indicators for truncated or continued lines, buffer |
| 2791 | lines, buffer boundaries, overlay arrow, etc. The fringe bitmaps are | 2965 | boundaries, overlay arrow, etc. Fringe bitmap symbols have their own |
| 2792 | shared by all frames and windows. You can redefine the built-in | 2966 | name space. The fringe bitmaps are shared by all frames and windows. |
| 2793 | fringe bitmaps, and you can define new fringe bitmaps. | 2967 | You can redefine the built-in fringe bitmaps, and you can define new |
| 2968 | fringe bitmaps. | ||
| 2794 | 2969 | ||
| 2795 | The way to display a bitmap in the left or right fringes for a given | 2970 | The way to display a bitmap in the left or right fringes for a given |
| 2796 | line in a window is by specifying the @code{display} property for one | 2971 | line in a window is by specifying the @code{display} property for one |
| @@ -2804,32 +2979,6 @@ default @code{fringe} face. @var{face} is automatically merged with | |||
| 2804 | the @code{fringe} face, so normally @var{face} need only specify the | 2979 | the @code{fringe} face, so normally @var{face} need only specify the |
| 2805 | foreground color for the bitmap. | 2980 | foreground color for the bitmap. |
| 2806 | 2981 | ||
| 2807 | These symbols identify the standard fringe bitmaps. Evaluate | ||
| 2808 | @code{(require 'fringe)} to define them. Fringe bitmap symbols have | ||
| 2809 | their own name space. | ||
| 2810 | |||
| 2811 | @table @asis | ||
| 2812 | @item Truncation and continuation line bitmaps: | ||
| 2813 | @code{left-truncation}, @code{right-truncation}, | ||
| 2814 | @code{continued-line}, @code{continuation-line}. | ||
| 2815 | |||
| 2816 | @item Buffer indication bitmaps: | ||
| 2817 | @code{up-arrow}, @code{down-arrow}, | ||
| 2818 | @code{top-left-angle}, @code{top-right-angle}, | ||
| 2819 | @code{bottom-left-angle}, @code{bottom-right-angle}, | ||
| 2820 | @code{left-bracket}, @code{right-bracket}. | ||
| 2821 | |||
| 2822 | @item Empty line indication bitmap: | ||
| 2823 | @code{empty-line}. | ||
| 2824 | |||
| 2825 | @item Overlay arrow bitmap: | ||
| 2826 | @code{overlay-arrow}. | ||
| 2827 | |||
| 2828 | @item Bitmaps for displaying the cursor in right fringe: | ||
| 2829 | @code{filled-box-cursor}, @code{hollow-box-cursor}, @code{hollow-square}, | ||
| 2830 | @code{bar-cursor}, @code{hbar-cursor}. | ||
| 2831 | @end table | ||
| 2832 | |||
| 2833 | @defun fringe-bitmaps-at-pos &optional pos window | 2982 | @defun fringe-bitmaps-at-pos &optional pos window |
| 2834 | This function returns the fringe bitmaps of the display line | 2983 | This function returns the fringe bitmaps of the display line |
| 2835 | containing position @var{pos} in window @var{window}. The return | 2984 | containing position @var{pos} in window @var{window}. The return |
| @@ -4598,52 +4747,6 @@ is completely independent of the user-settable tab stops used by the | |||
| 4598 | command @code{tab-to-tab-stop}. @xref{Indent Tabs}. | 4747 | command @code{tab-to-tab-stop}. @xref{Indent Tabs}. |
| 4599 | @end defopt | 4748 | @end defopt |
| 4600 | 4749 | ||
| 4601 | @defopt indicate-empty-lines | ||
| 4602 | @tindex indicate-empty-lines | ||
| 4603 | @cindex fringes, and empty line indication | ||
| 4604 | When this is non-@code{nil}, Emacs displays a special glyph in the | ||
| 4605 | fringe of each empty line at the end of the buffer, on graphical | ||
| 4606 | displays. @xref{Fringes}. This variable is automatically | ||
| 4607 | buffer-local in every buffer. | ||
| 4608 | @end defopt | ||
| 4609 | |||
| 4610 | @defvar indicate-buffer-boundaries | ||
| 4611 | This buffer-local variable controls how the buffer boundaries and | ||
| 4612 | window scrolling are indicated in the window fringes. | ||
| 4613 | |||
| 4614 | Emacs can indicate the buffer boundaries---that is, the first and last | ||
| 4615 | line in the buffer---with angle icons when they appear on the screen. | ||
| 4616 | In addition, Emacs can display an up-arrow in the fringe to show | ||
| 4617 | that there is text above the screen, and a down-arrow to show | ||
| 4618 | there is text below the screen. | ||
| 4619 | |||
| 4620 | There are four kinds of basic values: | ||
| 4621 | |||
| 4622 | @table @asis | ||
| 4623 | @item @code{nil} | ||
| 4624 | Don't display the icons. | ||
| 4625 | @item @code{left} | ||
| 4626 | Display them in the left fringe. | ||
| 4627 | @item @code{right} | ||
| 4628 | Display them in the right fringe. | ||
| 4629 | @item @var{anything-else} | ||
| 4630 | Display the icon at the top of the window top in the left fringe, and other | ||
| 4631 | in the right fringe. | ||
| 4632 | @end table | ||
| 4633 | |||
| 4634 | If value is a cons @code{(@var{angles} . @var{arrows})}, @var{angles} | ||
| 4635 | controls the angle icons, and @var{arrows} controls the arrows. Both | ||
| 4636 | @var{angles} and @var{arrows} work according to the table above. | ||
| 4637 | Thus, @code{(t . right)} places the top angle icon in the left | ||
| 4638 | fringe, the bottom angle icon in the right fringe, and both arrows in | ||
| 4639 | the right fringe. | ||
| 4640 | @end defvar | ||
| 4641 | |||
| 4642 | @defvar default-indicate-buffer-boundaries | ||
| 4643 | The value of this variable is the default value for | ||
| 4644 | @code{indicate-buffer-boundaries} in buffers that do not override it. | ||
| 4645 | @end defvar | ||
| 4646 | |||
| 4647 | @node Display Tables | 4750 | @node Display Tables |
| 4648 | @section Display Tables | 4751 | @section Display Tables |
| 4649 | 4752 | ||
diff --git a/lispref/files.texi b/lispref/files.texi index 36cdfa5d2bd..417bab81360 100644 --- a/lispref/files.texi +++ b/lispref/files.texi | |||
| @@ -1770,6 +1770,32 @@ Unix syntax and VMS syntax. | |||
| 1770 | @end example | 1770 | @end example |
| 1771 | @end defun | 1771 | @end defun |
| 1772 | 1772 | ||
| 1773 | Given a possibly relative file name, you can convert it to an | ||
| 1774 | absolute name using @code{expand-file-name} (@pxref{File Name | ||
| 1775 | Expansion}). This function converts absolute file names to relative | ||
| 1776 | names: | ||
| 1777 | |||
| 1778 | @defun file-relative-name filename &optional directory | ||
| 1779 | This function tries to return a relative name that is equivalent to | ||
| 1780 | @var{filename}, assuming the result will be interpreted relative to | ||
| 1781 | @var{directory} (an absolute directory name or directory file name). | ||
| 1782 | If @var{directory} is omitted or @code{nil}, it defaults to the | ||
| 1783 | current buffer's default directory. | ||
| 1784 | |||
| 1785 | On some operating systems, an absolute file name begins with a device | ||
| 1786 | name. On such systems, @var{filename} has no relative equivalent based | ||
| 1787 | on @var{directory} if they start with two different device names. In | ||
| 1788 | this case, @code{file-relative-name} returns @var{filename} in absolute | ||
| 1789 | form. | ||
| 1790 | |||
| 1791 | @example | ||
| 1792 | (file-relative-name "/foo/bar" "/foo/") | ||
| 1793 | @result{} "bar" | ||
| 1794 | (file-relative-name "/foo/bar" "/hack/") | ||
| 1795 | @result{} "../foo/bar" | ||
| 1796 | @end example | ||
| 1797 | @end defun | ||
| 1798 | |||
| 1773 | @node Directory Names | 1799 | @node Directory Names |
| 1774 | @comment node-name, next, previous, up | 1800 | @comment node-name, next, previous, up |
| 1775 | @subsection Directory Names | 1801 | @subsection Directory Names |
| @@ -1910,16 +1936,13 @@ you must specify the default directory name as well as the file name to | |||
| 1910 | be expanded. Expansion also simplifies file names by eliminating | 1936 | be expanded. Expansion also simplifies file names by eliminating |
| 1911 | redundancies such as @file{./} and @file{@var{name}/../}. | 1937 | redundancies such as @file{./} and @file{@var{name}/../}. |
| 1912 | 1938 | ||
| 1913 | In the next two functions, the @var{directory} argument can be either | ||
| 1914 | a directory name or a directory file name. @xref{Directory Names}. | ||
| 1915 | |||
| 1916 | @defun expand-file-name filename &optional directory | 1939 | @defun expand-file-name filename &optional directory |
| 1917 | This function converts @var{filename} to an absolute file name. If | 1940 | This function converts @var{filename} to an absolute file name. If |
| 1918 | @var{directory} is supplied, it is the default directory to start with | 1941 | @var{directory} is supplied, it is the default directory to start with |
| 1919 | if @var{filename} is relative. (The value of @var{directory} should | 1942 | if @var{filename} is relative. (The value of @var{directory} should |
| 1920 | itself be an absolute directory name; it may start with @samp{~}.) | 1943 | itself be an absolute directory name or directory file name; it may |
| 1921 | Otherwise, the current buffer's value of @code{default-directory} is | 1944 | start with @samp{~}.) Otherwise, the current buffer's value of |
| 1922 | used. For example: | 1945 | @code{default-directory} is used. For example: |
| 1923 | 1946 | ||
| 1924 | @example | 1947 | @example |
| 1925 | @group | 1948 | @group |
| @@ -1981,27 +2004,6 @@ should make sure to call @code{file-truename} without prior direct or | |||
| 1981 | indirect calls to @code{expand-file-name}. @xref{Truenames}. | 2004 | indirect calls to @code{expand-file-name}. @xref{Truenames}. |
| 1982 | @end defun | 2005 | @end defun |
| 1983 | 2006 | ||
| 1984 | @c Emacs 19 feature | ||
| 1985 | @defun file-relative-name filename &optional directory | ||
| 1986 | This function does the inverse of expansion---it tries to return a | ||
| 1987 | relative name that is equivalent to @var{filename} when interpreted | ||
| 1988 | relative to @var{directory}. If @var{directory} is omitted or | ||
| 1989 | @code{nil}, it defaults to the current buffer's default directory. | ||
| 1990 | |||
| 1991 | On some operating systems, an absolute file name begins with a device | ||
| 1992 | name. On such systems, @var{filename} has no relative equivalent based | ||
| 1993 | on @var{directory} if they start with two different device names. In | ||
| 1994 | this case, @code{file-relative-name} returns @var{filename} in absolute | ||
| 1995 | form. | ||
| 1996 | |||
| 1997 | @example | ||
| 1998 | (file-relative-name "/foo/bar" "/foo/") | ||
| 1999 | @result{} "bar" | ||
| 2000 | (file-relative-name "/foo/bar" "/hack/") | ||
| 2001 | @result{} "../foo/bar" | ||
| 2002 | @end example | ||
| 2003 | @end defun | ||
| 2004 | |||
| 2005 | @defvar default-directory | 2007 | @defvar default-directory |
| 2006 | The value of this buffer-local variable is the default directory for the | 2008 | The value of this buffer-local variable is the default directory for the |
| 2007 | current buffer. It should be an absolute directory name; it may start | 2009 | current buffer. It should be an absolute directory name; it may start |
diff --git a/lispref/minibuf.texi b/lispref/minibuf.texi index 65887c4c172..4faf8fd374c 100644 --- a/lispref/minibuf.texi +++ b/lispref/minibuf.texi | |||
| @@ -1194,7 +1194,8 @@ predicate @code{user-variable-p} instead of @code{commandp}: | |||
| 1194 | @end defun | 1194 | @end defun |
| 1195 | 1195 | ||
| 1196 | See also the functions @code{read-coding-system} and | 1196 | See also the functions @code{read-coding-system} and |
| 1197 | @code{read-non-nil-coding-system}, in @ref{User-Chosen Coding Systems}. | 1197 | @code{read-non-nil-coding-system}, in @ref{User-Chosen Coding Systems}, |
| 1198 | and @code{read-input-method-name}, in @ref{Input Methods}. | ||
| 1198 | 1199 | ||
| 1199 | @node Reading File Names | 1200 | @node Reading File Names |
| 1200 | @subsection Reading File Names | 1201 | @subsection Reading File Names |
diff --git a/lispref/windows.texi b/lispref/windows.texi index fe1d6212df0..dc780e7b828 100644 --- a/lispref/windows.texi +++ b/lispref/windows.texi | |||
| @@ -2196,7 +2196,7 @@ root window, and @var{mini} is the frame's minibuffer window. | |||
| 2196 | 2196 | ||
| 2197 | If the root window is not split, @var{root} is the root window itself. | 2197 | If the root window is not split, @var{root} is the root window itself. |
| 2198 | Otherwise, @var{root} is a list @code{(@var{dir} @var{edges} @var{w1} | 2198 | Otherwise, @var{root} is a list @code{(@var{dir} @var{edges} @var{w1} |
| 2199 | @var{w2} ...)} where @var{dir} is @code{nil} for a horisontal split, | 2199 | @var{w2} ...)} where @var{dir} is @code{nil} for a horizontal split, |
| 2200 | and @code{t} for a vertical split, @var{edges} gives the combined size and | 2200 | and @code{t} for a vertical split, @var{edges} gives the combined size and |
| 2201 | position of the subwindows in the split, and the rest of the elements | 2201 | position of the subwindows in the split, and the rest of the elements |
| 2202 | are the subwindows in the split. Each of the subwindows may again be | 2202 | are the subwindows in the split. Each of the subwindows may again be |
diff --git a/man/ChangeLog b/man/ChangeLog index 0d22e6d17bc..764e22eca15 100644 --- a/man/ChangeLog +++ b/man/ChangeLog | |||
| @@ -1,3 +1,24 @@ | |||
| 1 | 2006-02-21 Nick Roberts <nickrob@snap.net.nz> | ||
| 2 | |||
| 3 | * building.texi (Watch Expressions): Update and describe | ||
| 4 | gdb-speedbar-auto-raise. | ||
| 5 | |||
| 6 | 2006-02-19 Richard M. Stallman <rms@gnu.org> | ||
| 7 | |||
| 8 | * emacs.texi: Use @smallbook. | ||
| 9 | (Top): Update ref to Emacs paper, delete ref to Cookbook. | ||
| 10 | Update subnode menu. | ||
| 11 | |||
| 12 | * building.texi (Lisp Interaction): Minor addition. | ||
| 13 | |||
| 14 | 2006-02-18 Nick Roberts <nickrob@snap.net.nz> | ||
| 15 | |||
| 16 | * building.texi (Watch Expressions): Update and be more precise. | ||
| 17 | |||
| 18 | 2006-02-17 Eli Zaretskii <eliz@gnu.org> | ||
| 19 | |||
| 20 | * faq.texi: Remove the coding cookie, it's not needed anymore. | ||
| 21 | |||
| 1 | 2006-02-15 Francesco Potort,Al(B <pot@gnu.org> | 22 | 2006-02-15 Francesco Potort,Al(B <pot@gnu.org> |
| 2 | 23 | ||
| 3 | * maintaining.texi (Create Tags Table): Explain why the | 24 | * maintaining.texi (Create Tags Table): Explain why the |
diff --git a/man/building.texi b/man/building.texi index 497c2777a5a..ccabf22b549 100644 --- a/man/building.texi +++ b/man/building.texi | |||
| @@ -936,9 +936,9 @@ in the tool bar (@code{gud-watch}). | |||
| 936 | Each watch expression is displayed in the speedbar. Complex data | 936 | Each watch expression is displayed in the speedbar. Complex data |
| 937 | types, such as arrays, structures and unions are represented in a tree | 937 | types, such as arrays, structures and unions are represented in a tree |
| 938 | format. Leaves and simple data types show the name of the expression | 938 | format. Leaves and simple data types show the name of the expression |
| 939 | and its value, and display the type as a tooltip. Higher levels show | 939 | and its value and, when the speedbar frame is selected, display the |
| 940 | the name, type and address value for pointers and just the name and | 940 | type as a tooltip. Higher levels show the name, type and address |
| 941 | type otherwise. | 941 | value for pointers and just the name and type otherwise. |
| 942 | 942 | ||
| 943 | To expand or contract a complex data type, click @kbd{Mouse-2} | 943 | To expand or contract a complex data type, click @kbd{Mouse-2} |
| 944 | on the tag to the left of the expression. | 944 | on the tag to the left of the expression. |
| @@ -958,7 +958,9 @@ edit it. Either way, this reads the new value using the minibuffer. | |||
| 958 | If you set the variable @code{gdb-show-changed-values} to | 958 | If you set the variable @code{gdb-show-changed-values} to |
| 959 | non-@code{nil} (the default value), Emacs uses | 959 | non-@code{nil} (the default value), Emacs uses |
| 960 | @code{font-lock-warning-face} to highlight values that have recently | 960 | @code{font-lock-warning-face} to highlight values that have recently |
| 961 | changed. | 961 | changed and @code{shadow} face to make variables which have gone out of |
| 962 | scope less noticeable. When a variable goes out of scope you can't | ||
| 963 | edit its value. | ||
| 962 | 964 | ||
| 963 | @vindex gdb-use-colon-colon-notation | 965 | @vindex gdb-use-colon-colon-notation |
| 964 | If the variable @code{gdb-use-colon-colon-notation} is | 966 | If the variable @code{gdb-use-colon-colon-notation} is |
| @@ -967,6 +969,12 @@ format to display variables in the speedbar. Since this does not work | |||
| 967 | for variables defined in compound statements, the default value is | 969 | for variables defined in compound statements, the default value is |
| 968 | @code{nil}. | 970 | @code{nil}. |
| 969 | 971 | ||
| 972 | @vindex gdb-speedbar-auto-raise | ||
| 973 | To automatically raise the speedbar every time the display of watch | ||
| 974 | expressions updates, set @code{gdb-speedbar-auto-raise} to | ||
| 975 | non-@code{nil}. This can be useful if you are debugging with a full | ||
| 976 | screen Emacs frame. | ||
| 977 | |||
| 970 | @node Other GDB User Interface Buffers | 978 | @node Other GDB User Interface Buffers |
| 971 | @subsubsection Other Buffers | 979 | @subsubsection Other Buffers |
| 972 | 980 | ||
| @@ -1277,7 +1285,8 @@ buffer in Lisp Interaction mode. | |||
| 1277 | is to use Inferior Emacs-Lisp mode, which provides an interface rather | 1285 | is to use Inferior Emacs-Lisp mode, which provides an interface rather |
| 1278 | like Shell mode (@pxref{Shell Mode}) for evaluating Emacs Lisp | 1286 | like Shell mode (@pxref{Shell Mode}) for evaluating Emacs Lisp |
| 1279 | expressions. Type @kbd{M-x ielm} to create an @samp{*ielm*} buffer | 1287 | expressions. Type @kbd{M-x ielm} to create an @samp{*ielm*} buffer |
| 1280 | which uses this mode. | 1288 | which uses this mode. For more information see that command's |
| 1289 | documentation. | ||
| 1281 | 1290 | ||
| 1282 | @node External Lisp | 1291 | @node External Lisp |
| 1283 | @section Running an External Lisp | 1292 | @section Running an External Lisp |
diff --git a/man/ediff.texi b/man/ediff.texi index 67e822049cb..01e79c821d0 100644 --- a/man/ediff.texi +++ b/man/ediff.texi | |||
| @@ -686,6 +686,16 @@ Even though such regions will be skipped over, you can still jump to any | |||
| 686 | one of them by typing the region number and then `j'. Typing @kbd{##} | 686 | one of them by typing the region number and then `j'. Typing @kbd{##} |
| 687 | again puts Ediff back in the original state. | 687 | again puts Ediff back in the original state. |
| 688 | 688 | ||
| 689 | @item #c | ||
| 690 | @kindex #c | ||
| 691 | @vindex ediff-ignore-case-option | ||
| 692 | @vindex ediff-ignore-case-option3 | ||
| 693 | @vindex ediff-ignore-case | ||
| 694 | Toggle case sensitivity in the diff program. All diffs are recomputed. | ||
| 695 | Case sensitivity is controlled by the variables | ||
| 696 | @code{ediff-ignore-case-option}, @code{ediff-ignore-case-option3}, | ||
| 697 | and @code{ediff-ignore-case}, which are explained elsewhere. | ||
| 698 | |||
| 689 | @item #h | 699 | @item #h |
| 690 | @itemx #f | 700 | @itemx #f |
| 691 | @kindex #f | 701 | @kindex #f |
| @@ -1584,6 +1594,28 @@ Ediff may take a long time to skip over them because it has to compute fine | |||
| 1584 | differences of all intermediate regions. This delay does not indicate any | 1594 | differences of all intermediate regions. This delay does not indicate any |
| 1585 | problem. | 1595 | problem. |
| 1586 | 1596 | ||
| 1597 | @vindex ediff-ignore-case-option | ||
| 1598 | @vindex ediff-ignore-case-option3 | ||
| 1599 | @vindex ediff-ignore-case | ||
| 1600 | Finally, Ediff can be told to ignore the case of the letters. This behavior | ||
| 1601 | can be toggled with @kbd{#c} and it is controlled with three variables: | ||
| 1602 | Toggle case sensitivity in the diff program. All diffs are recomputed. | ||
| 1603 | Case sensitivity is controlled by the variables | ||
| 1604 | @code{ediff-ignore-case-option}, @code{ediff-ignore-case-option3}, and | ||
| 1605 | @code{ediff-ignore-case}. | ||
| 1606 | |||
| 1607 | The variable @code{ediff-ignore-case-option} specifies the option to pass | ||
| 1608 | to the diff program for comparing two files or buffers. For GNU | ||
| 1609 | @code{diff}, this option is @code{"-i"}. The variable | ||
| 1610 | @code{ediff-ignore-case-option3} specifies the option to pass to the | ||
| 1611 | @code{diff3} program in order to make it case-insensitive. GNU @code{diff3} | ||
| 1612 | does not have such an option, so when merging or comparing three files with | ||
| 1613 | this program, ignoring the letter case is not supported. | ||
| 1614 | |||
| 1615 | The variable @code{ediff-ignore-case} controls whether Ediff starts out by | ||
| 1616 | ignoring letter case or not. It can be set in @file{.emacs} using | ||
| 1617 | @code{setq-default}. | ||
| 1618 | |||
| 1587 | @node Highlighting Difference Regions, Narrowing, Selective Browsing, Customization | 1619 | @node Highlighting Difference Regions, Narrowing, Selective Browsing, Customization |
| 1588 | @section Highlighting Difference Regions | 1620 | @section Highlighting Difference Regions |
| 1589 | 1621 | ||
| @@ -2388,6 +2420,7 @@ Here is a hopefully full list of contributors: | |||
| 2388 | 2420 | ||
| 2389 | @example | 2421 | @example |
| 2390 | Adrian Aichner (aichner@@ecf.teradyne.com), | 2422 | Adrian Aichner (aichner@@ecf.teradyne.com), |
| 2423 | Drew Adams (drew.adams@@oracle.com), | ||
| 2391 | Steve Baur (steve@@xemacs.org), | 2424 | Steve Baur (steve@@xemacs.org), |
| 2392 | Neal Becker (neal@@ctd.comsat.com), | 2425 | Neal Becker (neal@@ctd.comsat.com), |
| 2393 | E.@: Jay Berkenbilt (ejb@@ql.org), | 2426 | E.@: Jay Berkenbilt (ejb@@ql.org), |
diff --git a/man/emacs.texi b/man/emacs.texi index 59e95e13446..ce3c7318945 100644 --- a/man/emacs.texi +++ b/man/emacs.texi | |||
| @@ -39,7 +39,7 @@ Software Foundation raise funds for GNU development.'' | |||
| 39 | @c copy of this manual that will be published. the manual should go | 39 | @c copy of this manual that will be published. the manual should go |
| 40 | @c onto the distribution in the full, 8.5 x 11" size. | 40 | @c onto the distribution in the full, 8.5 x 11" size. |
| 41 | 41 | ||
| 42 | @c @smallbook | 42 | @smallbook |
| 43 | 43 | ||
| 44 | @setchapternewpage odd | 44 | @setchapternewpage odd |
| 45 | @defcodeindex op | 45 | @defcodeindex op |
| @@ -609,7 +609,7 @@ Running Debuggers Under Emacs | |||
| 609 | implement a graphical debugging environment through | 609 | implement a graphical debugging environment through |
| 610 | Emacs. | 610 | Emacs. |
| 611 | 611 | ||
| 612 | Maintaining Programs | 612 | Maintaining Large Programs |
| 613 | 613 | ||
| 614 | * Change Log:: Maintaining a change history for your program. | 614 | * Change Log:: Maintaining a change history for your program. |
| 615 | * Format of ChangeLog:: What the change log file looks like. | 615 | * Format of ChangeLog:: What the change log file looks like. |
| @@ -950,15 +950,12 @@ with GNU Emacs. The Info file and the printed book contain | |||
| 950 | substantially the same text and are generated from the same source | 950 | substantially the same text and are generated from the same source |
| 951 | files, which are also distributed along with GNU Emacs. | 951 | files, which are also distributed along with GNU Emacs. |
| 952 | 952 | ||
| 953 | GNU Emacs is a member of the Emacs editor family. There are many Emacs | 953 | GNU Emacs is a member of the Emacs editor family. There are many |
| 954 | editors, all sharing common principles of organization. For information on | 954 | Emacs editors, all sharing common principles of organization. For |
| 955 | the underlying philosophy of Emacs and the lessons learned from its | 955 | information on the underlying philosophy of Emacs and the lessons |
| 956 | development, write for a copy of AI memo 519a, @cite{Emacs, the Extensible, | 956 | learned from its development, see @cite{Emacs, the Extensible, |
| 957 | Customizable Self-Documenting Display Editor}, is available from | 957 | Customizable Self-Documenting Display Editor}, available from |
| 958 | @url{ftp://publications.ai.mit.edu/ai-publications/pdf/AIM-519A.pdf}. | 958 | @url{ftp://publications.ai.mit.edu/ai-publications/pdf/AIM-519A.pdf}. |
| 959 | Another useful publication is LCS TM-165, @cite{A Cookbook for an | ||
| 960 | Emacs}, by Craig Finseth, is available from the MIT libraries in some | ||
| 961 | fashion. | ||
| 962 | 959 | ||
| 963 | This edition of the manual is intended for use with GNU Emacs | 960 | This edition of the manual is intended for use with GNU Emacs |
| 964 | installed on GNU and Unix systems. GNU Emacs can also be used on VMS, | 961 | installed on GNU and Unix systems. GNU Emacs can also be used on VMS, |
diff --git a/man/erc.texi b/man/erc.texi index fb9c60d635d..4713afa2fbc 100644 --- a/man/erc.texi +++ b/man/erc.texi | |||
| @@ -12,7 +12,7 @@ | |||
| 12 | @syncodeindex fn cp | 12 | @syncodeindex fn cp |
| 13 | 13 | ||
| 14 | @copying | 14 | @copying |
| 15 | This manual is for ERC version 5.1.1. | 15 | This manual is for ERC version 5.1.2. |
| 16 | 16 | ||
| 17 | Copyright @copyright{} 2005, 2006 Free Software Foundation, Inc. | 17 | Copyright @copyright{} 2005, 2006 Free Software Foundation, Inc. |
| 18 | 18 | ||
diff --git a/man/faq.texi b/man/faq.texi index fd69ad663b5..01becae0c87 100644 --- a/man/faq.texi +++ b/man/faq.texi | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | \input texinfo @c -*- coding: latin-1; mode: texinfo; -*- | 1 | \input texinfo @c -*- mode: texinfo; -*- |
| 2 | @c %**start of header | 2 | @c %**start of header |
| 3 | @setfilename ../info/efaq | 3 | @setfilename ../info/efaq |
| 4 | @settitle GNU Emacs FAQ | 4 | @settitle GNU Emacs FAQ |
diff --git a/man/viper.texi b/man/viper.texi index 4ad437a762d..46d62670345 100644 --- a/man/viper.texi +++ b/man/viper.texi | |||
| @@ -1870,6 +1870,10 @@ application. | |||
| 1870 | @vindex @code{viper-insert-state-cursor-color} | 1870 | @vindex @code{viper-insert-state-cursor-color} |
| 1871 | If set to a valid color, this will be the cursor color when Viper is in | 1871 | If set to a valid color, this will be the cursor color when Viper is in |
| 1872 | insert state. | 1872 | insert state. |
| 1873 | @item viper-emacs-state-cursor-color nil | ||
| 1874 | @vindex @code{viper-emacs-state-cursor-color} | ||
| 1875 | If set to a valid color, this will be the cursor color when Viper is in | ||
| 1876 | emacs state. | ||
| 1873 | @item viper-replace-region-end-delimiter "$" | 1877 | @item viper-replace-region-end-delimiter "$" |
| 1874 | A string used to mark the end of replacement regions. It is used only on | 1878 | A string used to mark the end of replacement regions. It is used only on |
| 1875 | TTYs or if @code{viper-use-replace-region-delimiters} is non-@code{nil}. | 1879 | TTYs or if @code{viper-use-replace-region-delimiters} is non-@code{nil}. |
diff --git a/src/ChangeLog b/src/ChangeLog index 1276e2498ef..2547e146e46 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,150 @@ | |||
| 1 | 2006-02-22 Kim F. Storm <storm@cua.dk> | ||
| 2 | |||
| 3 | * fringe.c (draw_fringe_bitmap): Fix overlay-arrow display. | ||
| 4 | |||
| 5 | 2006-02-21 Kim F. Storm <storm@cua.dk> | ||
| 6 | |||
| 7 | * fringe.c (syms_of_fringe) <fringe-bitmaps>: Doc fix. | ||
| 8 | |||
| 9 | 2006-02-21 Zhang Wei <brep@newsmth.org> | ||
| 10 | |||
| 11 | * xfns.c (Fx_file_dialog, Motif and GTK): DECODE_FILE before | ||
| 12 | returning it. | ||
| 13 | |||
| 14 | 2006-02-21 Giorgos Keramidas <keramida@ceid.upatras.gr> (tiny change) | ||
| 15 | |||
| 16 | * fringe.c (horizontal_bar_bits): Rename from `horisontal_bar_bits'. | ||
| 17 | (standard_bitmaps): Use it. | ||
| 18 | |||
| 19 | 2006-02-21 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> | ||
| 20 | |||
| 21 | * macterm.c (mac_draw_string_common): Remove arg MODE. New arg | ||
| 22 | BG_WIDTH. All uses changed. Draw background if BG_WIDTH is not zero. | ||
| 23 | (mac_draw_image_string, mac_draw_image_string_16): New arg BG_WIDTH. | ||
| 24 | [USE_CG_TEXT_DRAWING] (mac_draw_image_string_cg): Rename from | ||
| 25 | mac_draw_string_cg. New arg BG_WIDTH. All uses changed. Draw | ||
| 26 | background if BG_WIDTH is not zero. Use float constants as | ||
| 27 | divisors instead of double. Use alloca instead of xmalloc/xfree. | ||
| 28 | (x_draw_glyph_string_background, x_draw_glyph_string_foreground) | ||
| 29 | [!MAC_OS8 || USE_ATSUI]: Background may be drawn using | ||
| 30 | mac_draw_image_string* functions. | ||
| 31 | (XLoadQueryFont) [MAC_OS8 && USE_ATSUI]: Don't adjust heights of | ||
| 32 | some fonts when srcCopy text transfer mode might be used. | ||
| 33 | (mac_begin_clip, mac_end_clip): Check if region is empty. | ||
| 34 | (mac_set_clip_rectangles): When resetting clip region, make it | ||
| 35 | empty instead of disposing of it. | ||
| 36 | |||
| 37 | 2006-02-20 Kim F. Storm <storm@cua.dk> | ||
| 38 | |||
| 39 | * Makefile.in: Add fringe.elc to WINDOW_SUPPORT. | ||
| 40 | |||
| 41 | * buffer.h (struct buffer): New members fringe_indicator_alist and | ||
| 42 | fringe_cursor_alist. | ||
| 43 | |||
| 44 | * buffer.c (init_buffer_once): Set dummy default values for | ||
| 45 | fringe-indicator-alist and fringe-cursor-alist. The proper | ||
| 46 | default values are set by pre-loading fringe.el. | ||
| 47 | (syms_of_buffer): defvar_per_buffer new fringe-indicator-alist and | ||
| 48 | fringe-cursor-alist buffer-local variables and defvar_lisp_nopro | ||
| 49 | corresponding default- variables. | ||
| 50 | |||
| 51 | * fringe.c (enum fringe_bitmap_type): Remove. Change all uses | ||
| 52 | to use `int'. | ||
| 53 | (NO_FRINGE_BITMAP, UNDEF_FRINGE_BITMAP, MAX_STANDARD_FRINGE_BITMAPS): | ||
| 54 | Define explicitly. | ||
| 55 | (Qtruncation, Qcontinuation, Qempty_line, Qtop_bottom) | ||
| 56 | (Qhollow_small): New variables. | ||
| 57 | (syms_of_fringe): Intern and staticpro them. | ||
| 58 | (question_mark_bits): Rename from unknown_bits. | ||
| 59 | (left_curly_arrow_bits): Rename from continuation_bits. | ||
| 60 | (right_curly_arrow_bits): Rename from continued_bits. | ||
| 61 | (left_triangle_bits): Rename from ov_bits. | ||
| 62 | (right_triangle_bits): Added. | ||
| 63 | (filled_rectangle_bits): Rename from filled_box_cursor_bits. | ||
| 64 | (hollow_rectangle_bits): Rename from hollow_box_cursor_bits. | ||
| 65 | (filled_square_bits): Added. | ||
| 66 | (vertical_bar_bits): Rename from bar_cursor_bits. | ||
| 67 | (horizontal_bar_bits): Rename from hbar_cursor_bits. | ||
| 68 | (empty_line_bits): Rename from zv_bits. | ||
| 69 | (standard_bitmaps): Update to use new names. | ||
| 70 | (draw_fringe_bitmap_1): Make static. | ||
| 71 | (get_logical_cursor_bitmap, get_logical_fringe_bitmap): New functions | ||
| 72 | to map from logical cursors and indicators to physical bitmaps. | ||
| 73 | (draw_fringe_bitmap): Resolve fringe cursor and overlay-arrow | ||
| 74 | bitmaps using symbol names instead of bitmap numbers. | ||
| 75 | (update_window_fringes): Use logical indicator symbol names | ||
| 76 | instead of bitmap numbers for logical. Add bitmap cache. | ||
| 77 | (LEFT_FRINGE, RIGHT_FRINGE): New helper macros. | ||
| 78 | |||
| 79 | 2006-02-20 Chong Yidong <cyd@stupidchicken.com> | ||
| 80 | |||
| 81 | * regex.c: Revert 2006-02-19 change. | ||
| 82 | (xmalloc, xrealloc): Define these when not linked to Emacs. | ||
| 83 | Redefine malloc -> xmalloc, realloc -> xrealloc as in Emacs case. | ||
| 84 | |||
| 85 | 2006-02-19 Luc Teirlinck <teirllm@auburn.edu> | ||
| 86 | |||
| 87 | * regex.c (extend_range_table_work_area): Fix typo. | ||
| 88 | |||
| 89 | 2006-02-19 Richard M. Stallman <rms@gnu.org> | ||
| 90 | |||
| 91 | * xterm.c (x_catch_errors): Use xmalloc. | ||
| 92 | |||
| 93 | * regex.c (extend_range_table_work_area): Call xmalloc and xrealloc. | ||
| 94 | (regex_compile): Likewise. | ||
| 95 | (regcomp): Use xmalloc. | ||
| 96 | |||
| 97 | * gtkutil.c (malloc_widget_value): Use xmalloc. | ||
| 98 | |||
| 99 | * vm-limit.c [HAVE_GETRLIMIT]: Include sys/resource.h. | ||
| 100 | (check_memory_limits) [HAVE_GETRLIMIT]: Use getrlimit. | ||
| 101 | |||
| 102 | * xmenu.c (digest_single_submenu): When pane_string is empty, | ||
| 103 | do initialize save_wv. | ||
| 104 | |||
| 105 | 2006-02-19 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> | ||
| 106 | |||
| 107 | * xdisp.c (update_menu_bar) [MAC_OS]: Don't set | ||
| 108 | w->update_mode_line if arg F is not the selected frame. | ||
| 109 | |||
| 110 | * macmenu.c (popup_activated_flag, submenu_id) | ||
| 111 | (next_menubar_widget_id): Remove variables. | ||
| 112 | (initialize_frame_menubar): Remove function. | ||
| 113 | (pop_down_menu, mac_menu_show): Simplify save value. | ||
| 114 | (dispose_menus): New function. | ||
| 115 | (pop_down_menu, fill_menubar): Use it. | ||
| 116 | (fill_submenu): Remove function. All uses changed to fill_menu. | ||
| 117 | (add_menu_item): Remove args SUBMENU and FORCE_DISABLE. New arg | ||
| 118 | POS. Don't call SetMenuItemHierarchicalID here. | ||
| 119 | (fill_menu): Add arg SUBMENU_ID. Return submenu_id that is to be | ||
| 120 | used next. Call SetMenuItemHierarchicalID here. | ||
| 121 | (fill_menubar): Add arg DEEP_P. All uses changed. Clean up menu | ||
| 122 | objects if needed. Reuse existing menu bar titles if possible. | ||
| 123 | (set_frame_menubar): Don't clean up menu objects here. | ||
| 124 | |||
| 125 | 2006-02-18 Chong Yidong <cyd@stupidchicken.com> | ||
| 126 | |||
| 127 | * window.c (window_min_size_1): Ensure room for the scroll bar and | ||
| 128 | fringes. | ||
| 129 | |||
| 130 | 2006-02-17 Romain Francoise <romain@orebokech.com> | ||
| 131 | |||
| 132 | * puresize.h (BASE_PURESIZE): Increment to 1200000. | ||
| 133 | |||
| 134 | 2006-02-17 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 135 | |||
| 136 | * alloc.c (Fmake_symbol): Comment-out left-over assert from before the | ||
| 137 | addition of the BLOCK_INPUTs. | ||
| 138 | |||
| 139 | 2006-02-17 Juanma Barranquero <lekktu@gmail.com> | ||
| 140 | |||
| 141 | * window.c (Fset_window_scroll_bars): Doc fix. | ||
| 142 | |||
| 143 | 2006-02-17 Kenichi Handa <handa@m17n.org> | ||
| 144 | |||
| 145 | * xdisp.c (display_mode_element): Call display_string with correct | ||
| 146 | PREC arg (which must be a number of characters, not column width). | ||
| 147 | |||
| 1 | 2006-02-15 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> | 148 | 2006-02-15 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
| 2 | 149 | ||
| 3 | * frame.c (x_get_arg): Clear out PARAM in ALIST also on Mac. | 150 | * frame.c (x_get_arg): Clear out PARAM in ALIST also on Mac. |
diff --git a/src/Makefile.in b/src/Makefile.in index 3be09cac3ea..16a85dfe191 100644 --- a/src/Makefile.in +++ b/src/Makefile.in | |||
| @@ -679,11 +679,11 @@ otherobj= $(termcapobj) lastfile.o $(mallocobj) $(allocaobj) $(widgetobj) $(LIBO | |||
| 679 | 679 | ||
| 680 | #ifdef HAVE_WINDOW_SYSTEM | 680 | #ifdef HAVE_WINDOW_SYSTEM |
| 681 | #ifdef HAVE_X_WINDOWS | 681 | #ifdef HAVE_X_WINDOWS |
| 682 | #define WINDOW_SUPPORT ${lispsource}image.elc \ | 682 | #define WINDOW_SUPPORT ${lispsource}fringe.elc ${lispsource}image.elc \ |
| 683 | ${lispsource}international/fontset.elc ${lispsource}dnd.elc \ | 683 | ${lispsource}international/fontset.elc ${lispsource}dnd.elc \ |
| 684 | ${lispsource}tool-bar.elc ${lispsource}mwheel.elc ${lispsource}x-dnd.elc | 684 | ${lispsource}tool-bar.elc ${lispsource}mwheel.elc ${lispsource}x-dnd.elc |
| 685 | #else | 685 | #else |
| 686 | #define WINDOW_SUPPORT ${lispsource}image.elc \ | 686 | #define WINDOW_SUPPORT ${lispsource}fringe.elc ${lispsource}image.elc \ |
| 687 | ${lispsource}international/fontset.elc ${lispsource}dnd.elc \ | 687 | ${lispsource}international/fontset.elc ${lispsource}dnd.elc \ |
| 688 | ${lispsource}tool-bar.elc ${lispsource}mwheel.elc | 688 | ${lispsource}tool-bar.elc ${lispsource}mwheel.elc |
| 689 | #endif | 689 | #endif |
diff --git a/src/alloc.c b/src/alloc.c index 04efb708665..ea52c98fd24 100644 --- a/src/alloc.c +++ b/src/alloc.c | |||
| @@ -3166,7 +3166,7 @@ Its value and function definition are void, and its property list is nil. */) | |||
| 3166 | 3166 | ||
| 3167 | CHECK_STRING (name); | 3167 | CHECK_STRING (name); |
| 3168 | 3168 | ||
| 3169 | eassert (!handling_signal); | 3169 | /* eassert (!handling_signal); */ |
| 3170 | 3170 | ||
| 3171 | #ifndef SYNC_INPUT | 3171 | #ifndef SYNC_INPUT |
| 3172 | BLOCK_INPUT; | 3172 | BLOCK_INPUT; |
diff --git a/src/buffer.c b/src/buffer.c index 4dce7c40686..e6f93726f5a 100644 --- a/src/buffer.c +++ b/src/buffer.c | |||
| @@ -5009,6 +5009,8 @@ init_buffer_once () | |||
| 5009 | buffer_defaults.vertical_scroll_bar_type = Qt; | 5009 | buffer_defaults.vertical_scroll_bar_type = Qt; |
| 5010 | buffer_defaults.indicate_empty_lines = Qnil; | 5010 | buffer_defaults.indicate_empty_lines = Qnil; |
| 5011 | buffer_defaults.indicate_buffer_boundaries = Qnil; | 5011 | buffer_defaults.indicate_buffer_boundaries = Qnil; |
| 5012 | buffer_defaults.fringe_indicator_alist = Qnil; | ||
| 5013 | buffer_defaults.fringe_cursor_alist = Qnil; | ||
| 5012 | buffer_defaults.scroll_up_aggressively = Qnil; | 5014 | buffer_defaults.scroll_up_aggressively = Qnil; |
| 5013 | buffer_defaults.scroll_down_aggressively = Qnil; | 5015 | buffer_defaults.scroll_down_aggressively = Qnil; |
| 5014 | buffer_defaults.display_time = Qnil; | 5016 | buffer_defaults.display_time = Qnil; |
| @@ -5080,6 +5082,8 @@ init_buffer_once () | |||
| 5080 | XSETFASTINT (buffer_local_flags.vertical_scroll_bar_type, idx); ++idx; | 5082 | XSETFASTINT (buffer_local_flags.vertical_scroll_bar_type, idx); ++idx; |
| 5081 | XSETFASTINT (buffer_local_flags.indicate_empty_lines, idx); ++idx; | 5083 | XSETFASTINT (buffer_local_flags.indicate_empty_lines, idx); ++idx; |
| 5082 | XSETFASTINT (buffer_local_flags.indicate_buffer_boundaries, idx); ++idx; | 5084 | XSETFASTINT (buffer_local_flags.indicate_buffer_boundaries, idx); ++idx; |
| 5085 | XSETFASTINT (buffer_local_flags.fringe_indicator_alist, idx); ++idx; | ||
| 5086 | XSETFASTINT (buffer_local_flags.fringe_cursor_alist, idx); ++idx; | ||
| 5083 | XSETFASTINT (buffer_local_flags.scroll_up_aggressively, idx); ++idx; | 5087 | XSETFASTINT (buffer_local_flags.scroll_up_aggressively, idx); ++idx; |
| 5084 | XSETFASTINT (buffer_local_flags.scroll_down_aggressively, idx); ++idx; | 5088 | XSETFASTINT (buffer_local_flags.scroll_down_aggressively, idx); ++idx; |
| 5085 | XSETFASTINT (buffer_local_flags.header_line_format, idx); ++idx; | 5089 | XSETFASTINT (buffer_local_flags.header_line_format, idx); ++idx; |
| @@ -5373,6 +5377,16 @@ This is the same as (default-value 'indicate-empty-lines). */); | |||
| 5373 | doc: /* Default value of `indicate-buffer-boundaries' for buffers that don't override it. | 5377 | doc: /* Default value of `indicate-buffer-boundaries' for buffers that don't override it. |
| 5374 | This is the same as (default-value 'indicate-buffer-boundaries). */); | 5378 | This is the same as (default-value 'indicate-buffer-boundaries). */); |
| 5375 | 5379 | ||
| 5380 | DEFVAR_LISP_NOPRO ("default-fringe-indicator-alist", | ||
| 5381 | &buffer_defaults.fringe_indicator_alist, | ||
| 5382 | doc: /* Default value of `fringe-indicator-alist' for buffers that don't override it. | ||
| 5383 | This is the same as (default-value 'fringe-indicator-alist'). */); | ||
| 5384 | |||
| 5385 | DEFVAR_LISP_NOPRO ("default-fringe-cursor-alist", | ||
| 5386 | &buffer_defaults.fringe_cursor_alist, | ||
| 5387 | doc: /* Default value of `fringe-cursor-alist' for buffers that don't override it. | ||
| 5388 | This is the same as (default-value 'fringe-cursor-alist'). */); | ||
| 5389 | |||
| 5376 | DEFVAR_LISP_NOPRO ("default-scroll-up-aggressively", | 5390 | DEFVAR_LISP_NOPRO ("default-scroll-up-aggressively", |
| 5377 | &buffer_defaults.scroll_up_aggressively, | 5391 | &buffer_defaults.scroll_up_aggressively, |
| 5378 | doc: /* Default value of `scroll-up-aggressively'. | 5392 | doc: /* Default value of `scroll-up-aggressively'. |
| @@ -5718,6 +5732,40 @@ left fringe, the bottom angle bitmap in right fringe, and both arrow | |||
| 5718 | bitmaps in right fringe. To show just the angle bitmaps in the left | 5732 | bitmaps in right fringe. To show just the angle bitmaps in the left |
| 5719 | fringe, but no arrow bitmaps, use ((top . left) (bottom . left)). */); | 5733 | fringe, but no arrow bitmaps, use ((top . left) (bottom . left)). */); |
| 5720 | 5734 | ||
| 5735 | DEFVAR_PER_BUFFER ("fringe-indicator-alist", | ||
| 5736 | ¤t_buffer->fringe_indicator_alist, Qnil, | ||
| 5737 | doc: /* *Mapping from logical to physical fringe indicator bitmaps. | ||
| 5738 | The value is an alist where each element (INDICATOR . BITMAPS) | ||
| 5739 | specifies the fringe bitmaps used to display a specific logical | ||
| 5740 | fringe indicator. | ||
| 5741 | |||
| 5742 | INDICATOR specifies the logical indicator type which is one of the | ||
| 5743 | following symbols: `truncation' , `continuation', `overlay-arrow', | ||
| 5744 | `top', `bottom', `up', `down', `one-line', `empty-line', or `unknown'. | ||
| 5745 | |||
| 5746 | BITMAPS is list of symbols (LEFT RIGHT [LEFT1 RIGHT1]) which specifies | ||
| 5747 | the actual bitmap shown in the left or right fringe for the logical | ||
| 5748 | indicator. LEFT and RIGHT are the bitmaps shown in the left and/or | ||
| 5749 | right fringe for the specific indicator. The LEFT1 or RIGHT1 bitmaps | ||
| 5750 | are used only for the `bottom' and `one-line' indicators when the last | ||
| 5751 | (only) line in has no final newline. BITMAPS may also be a single | ||
| 5752 | symbol which is used in both left and right fringes. */); | ||
| 5753 | |||
| 5754 | DEFVAR_PER_BUFFER ("fringe-cursor-alist", | ||
| 5755 | ¤t_buffer->fringe_cursor_alist, Qnil, | ||
| 5756 | doc: /* *Mapping from logical to physical fringe cursor bitmaps. | ||
| 5757 | The value is an alist where each element (CURSOR . BITMAP) | ||
| 5758 | specifies the fringe bitmaps used to display a specific logical | ||
| 5759 | cursor type in the fringe. | ||
| 5760 | |||
| 5761 | CURSOR specifies the logical cursor type which is one of the following | ||
| 5762 | symbols: `box' , `hollow', `bar', `hbar', or `hollow-small'. The last | ||
| 5763 | one is used to show a hollow cursor on narrow lines display lines | ||
| 5764 | where the normal hollow cursor will not fit. | ||
| 5765 | |||
| 5766 | BITMAP is the corresponding fringe bitmap shown for the logical | ||
| 5767 | cursor type. */); | ||
| 5768 | |||
| 5721 | DEFVAR_PER_BUFFER ("scroll-up-aggressively", | 5769 | DEFVAR_PER_BUFFER ("scroll-up-aggressively", |
| 5722 | ¤t_buffer->scroll_up_aggressively, Qnil, | 5770 | ¤t_buffer->scroll_up_aggressively, Qnil, |
| 5723 | doc: /* How far to scroll windows upward. | 5771 | doc: /* How far to scroll windows upward. |
diff --git a/src/buffer.h b/src/buffer.h index a82f9578ff9..8015b2be15c 100644 --- a/src/buffer.h +++ b/src/buffer.h | |||
| @@ -743,6 +743,12 @@ struct buffer | |||
| 743 | /* Non-nil means indicate buffer boundaries and scrolling. */ | 743 | /* Non-nil means indicate buffer boundaries and scrolling. */ |
| 744 | Lisp_Object indicate_buffer_boundaries; | 744 | Lisp_Object indicate_buffer_boundaries; |
| 745 | 745 | ||
| 746 | /* Logical to physical fringe bitmap mappings. */ | ||
| 747 | Lisp_Object fringe_indicator_alist; | ||
| 748 | |||
| 749 | /* Logical to physical cursor bitmap mappings. */ | ||
| 750 | Lisp_Object fringe_cursor_alist; | ||
| 751 | |||
| 746 | /* Time stamp updated each time this buffer is displayed in a window. */ | 752 | /* Time stamp updated each time this buffer is displayed in a window. */ |
| 747 | Lisp_Object display_time; | 753 | Lisp_Object display_time; |
| 748 | 754 | ||
diff --git a/src/fringe.c b/src/fringe.c index bbb35b305ca..1a045d7034e 100644 --- a/src/fringe.c +++ b/src/fringe.c | |||
| @@ -49,31 +49,45 @@ Lisp_Object Voverflow_newline_into_fringe; | |||
| 49 | 49 | ||
| 50 | Lisp_Object Vfringe_bitmaps; | 50 | Lisp_Object Vfringe_bitmaps; |
| 51 | 51 | ||
| 52 | enum fringe_bitmap_type | 52 | /* Fringe bitmaps are represented in three different ways: |
| 53 | { | 53 | |
| 54 | NO_FRINGE_BITMAP = 0, | 54 | Logical bitmaps are used internally to denote things like |
| 55 | UNDEF_FRINGE_BITMAP, | 55 | 'end-of-buffer', 'left-truncation', 'overlay-arrow', etc. |
| 56 | LEFT_TRUNCATION_BITMAP, | 56 | |
| 57 | RIGHT_TRUNCATION_BITMAP, | 57 | Physical bitmaps specify the visual appearence of the bitmap, |
| 58 | UP_ARROW_BITMAP, | 58 | e.g. 'bottom-left-angle', 'left-arrow', 'left-triangle', etc. |
| 59 | DOWN_ARROW_BITMAP, | 59 | User defined bitmaps are physical bitmaps. |
| 60 | CONTINUED_LINE_BITMAP, | 60 | |
| 61 | CONTINUATION_LINE_BITMAP, | 61 | Internally, fringe bitmaps for a specific display row are |
| 62 | OVERLAY_ARROW_BITMAP, | 62 | represented as a simple integer that is used as an index |
| 63 | TOP_LEFT_ANGLE_BITMAP, | 63 | into the table of all defined bitmaps. This index is stored |
| 64 | TOP_RIGHT_ANGLE_BITMAP, | 64 | in the `fringe' property of the physical bitmap symbol. |
| 65 | BOTTOM_LEFT_ANGLE_BITMAP, | 65 | |
| 66 | BOTTOM_RIGHT_ANGLE_BITMAP, | 66 | Logical bitmaps are mapped to physical bitmaps through the |
| 67 | LEFT_BRACKET_BITMAP, | 67 | buffer-local `fringe-indicator-alist' variable. |
| 68 | RIGHT_BRACKET_BITMAP, | 68 | |
| 69 | FILLED_BOX_CURSOR_BITMAP, | 69 | Each element of this alist is a cons (LOGICAL . PHYSICAL) |
| 70 | HOLLOW_BOX_CURSOR_BITMAP, | 70 | mapping a logical bitmap to a physical bitmap. |
| 71 | HOLLOW_SQUARE_BITMAP, | 71 | PHYSICAL is either a symbol to use in both left and right fringe, |
| 72 | BAR_CURSOR_BITMAP, | 72 | or a cons of two symbols (LEFT . RIGHT) denoting different |
| 73 | HBAR_CURSOR_BITMAP, | 73 | bitmaps to use in left and right fringe. |
| 74 | ZV_LINE_BITMAP, | 74 | |
| 75 | MAX_STANDARD_FRINGE_BITMAPS | 75 | LOGICAL is first looked up in the window's buffer's buffer-local |
| 76 | }; | 76 | value of the fringe-indicator-alist variable, and if not present, |
| 77 | in the global value of fringe-indicator-alist. | ||
| 78 | |||
| 79 | If LOGICAL is not present in either alist, or the PHYSICAL value | ||
| 80 | found is nil, no bitmap is shown for the logical bitmap. | ||
| 81 | |||
| 82 | The `left-fringe' and `right-fringe' display properties | ||
| 83 | must specify physical bitmap symbols. | ||
| 84 | */ | ||
| 85 | |||
| 86 | extern Lisp_Object Qunknown; | ||
| 87 | Lisp_Object Qtruncation, Qcontinuation, Qoverlay_arrow; | ||
| 88 | Lisp_Object Qempty_line, Qtop_bottom; | ||
| 89 | extern Lisp_Object Qbar, Qhbar, Qbox, Qhollow; | ||
| 90 | Lisp_Object Qhollow_small; | ||
| 77 | 91 | ||
| 78 | enum fringe_bitmap_align | 92 | enum fringe_bitmap_align |
| 79 | { | 93 | { |
| @@ -110,7 +124,7 @@ struct fringe_bitmap | |||
| 110 | ...xx... | 124 | ...xx... |
| 111 | ...xx... | 125 | ...xx... |
| 112 | */ | 126 | */ |
| 113 | static unsigned short unknown_bits[] = { | 127 | static unsigned short question_mark_bits[] = { |
| 114 | 0x3c, 0x7e, 0x7e, 0x0c, 0x18, 0x18, 0x00, 0x18, 0x18}; | 128 | 0x3c, 0x7e, 0x7e, 0x0c, 0x18, 0x18, 0x00, 0x18, 0x18}; |
| 115 | 129 | ||
| 116 | /* An arrow like this: `<-'. */ | 130 | /* An arrow like this: `<-'. */ |
| @@ -172,20 +186,6 @@ static unsigned short up_arrow_bits[] = { | |||
| 172 | static unsigned short down_arrow_bits[] = { | 186 | static unsigned short down_arrow_bits[] = { |
| 173 | 0x18, 0x18, 0x18, 0x18, 0xff, 0x7e, 0x3c, 0x18}; | 187 | 0x18, 0x18, 0x18, 0x18, 0xff, 0x7e, 0x3c, 0x18}; |
| 174 | 188 | ||
| 175 | /* Marker for continued lines. */ | ||
| 176 | /* | ||
| 177 | ..xxxx.. | ||
| 178 | ..xxxxx. | ||
| 179 | ......xx | ||
| 180 | ..x..xxx | ||
| 181 | ..xxxxxx | ||
| 182 | ..xxxxx. | ||
| 183 | ..xxxx.. | ||
| 184 | ..xxxxx. | ||
| 185 | */ | ||
| 186 | static unsigned short continued_bits[] = { | ||
| 187 | 0x3c, 0x3e, 0x03, 0x27, 0x3f, 0x3e, 0x3c, 0x3e}; | ||
| 188 | |||
| 189 | /* Marker for continuation lines. */ | 189 | /* Marker for continuation lines. */ |
| 190 | /* | 190 | /* |
| 191 | ..xxxx.. | 191 | ..xxxx.. |
| @@ -197,24 +197,23 @@ static unsigned short continued_bits[] = { | |||
| 197 | ..xxxx.. | 197 | ..xxxx.. |
| 198 | .xxxxx.. | 198 | .xxxxx.. |
| 199 | */ | 199 | */ |
| 200 | static unsigned short continuation_bits[] = { | 200 | static unsigned short left_curly_arrow_bits[] = { |
| 201 | 0x3c, 0x7c, 0xc0, 0xe4, 0xfc, 0x7c, 0x3c, 0x7c}; | 201 | 0x3c, 0x7c, 0xc0, 0xe4, 0xfc, 0x7c, 0x3c, 0x7c}; |
| 202 | 202 | ||
| 203 | /* Overlay arrow bitmap. A triangular arrow. */ | 203 | /* Marker for continued lines. */ |
| 204 | /* | 204 | /* |
| 205 | xx...... | 205 | ..xxxx.. |
| 206 | xxxx.... | 206 | ..xxxxx. |
| 207 | xxxxx... | 207 | ......xx |
| 208 | xxxxxx.. | 208 | ..x..xxx |
| 209 | xxxxxx.. | 209 | ..xxxxxx |
| 210 | xxxxx... | 210 | ..xxxxx. |
| 211 | xxxx.... | 211 | ..xxxx.. |
| 212 | xx...... | 212 | ..xxxxx. |
| 213 | */ | 213 | */ |
| 214 | static unsigned short ov_bits[] = { | 214 | static unsigned short right_curly_arrow_bits[] = { |
| 215 | 0xc0, 0xf0, 0xf8, 0xfc, 0xfc, 0xf8, 0xf0, 0xc0}; | 215 | 0x3c, 0x3e, 0x03, 0x27, 0x3f, 0x3e, 0x3c, 0x3e}; |
| 216 | 216 | ||
| 217 | #if 0 | ||
| 218 | /* Reverse Overlay arrow bitmap. A triangular arrow. */ | 217 | /* Reverse Overlay arrow bitmap. A triangular arrow. */ |
| 219 | /* | 218 | /* |
| 220 | ......xx | 219 | ......xx |
| @@ -226,9 +225,22 @@ static unsigned short ov_bits[] = { | |||
| 226 | ....xxxx | 225 | ....xxxx |
| 227 | ......xx | 226 | ......xx |
| 228 | */ | 227 | */ |
| 229 | static unsigned short rev_ov_bits[] = { | 228 | static unsigned short left_triangle_bits[] = { |
| 230 | 0x03, 0x0f, 0x1f, 0x3f, 0x3f, 0x1f, 0x0f, 0x03}; | 229 | 0x03, 0x0f, 0x1f, 0x3f, 0x3f, 0x1f, 0x0f, 0x03}; |
| 231 | #endif | 230 | |
| 231 | /* Overlay arrow bitmap. A triangular arrow. */ | ||
| 232 | /* | ||
| 233 | xx...... | ||
| 234 | xxxx.... | ||
| 235 | xxxxx... | ||
| 236 | xxxxxx.. | ||
| 237 | xxxxxx.. | ||
| 238 | xxxxx... | ||
| 239 | xxxx.... | ||
| 240 | xx...... | ||
| 241 | */ | ||
| 242 | static unsigned short right_triangle_bits[] = { | ||
| 243 | 0xc0, 0xf0, 0xf8, 0xfc, 0xfc, 0xf8, 0xf0, 0xc0}; | ||
| 232 | 244 | ||
| 233 | /* First line bitmap. An top-left angle. */ | 245 | /* First line bitmap. An top-left angle. */ |
| 234 | /* | 246 | /* |
| @@ -334,7 +346,7 @@ static unsigned short right_bracket_bits[] = { | |||
| 334 | xxxxxxx. | 346 | xxxxxxx. |
| 335 | xxxxxxx. | 347 | xxxxxxx. |
| 336 | */ | 348 | */ |
| 337 | static unsigned short filled_box_cursor_bits[] = { | 349 | static unsigned short filled_rectangle_bits[] = { |
| 338 | 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe}; | 350 | 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe, 0xfe}; |
| 339 | 351 | ||
| 340 | /* Hollow box cursor bitmap. A hollow box; max 13 pixels high. */ | 352 | /* Hollow box cursor bitmap. A hollow box; max 13 pixels high. */ |
| @@ -353,9 +365,33 @@ static unsigned short filled_box_cursor_bits[] = { | |||
| 353 | x.....x. | 365 | x.....x. |
| 354 | xxxxxxx. | 366 | xxxxxxx. |
| 355 | */ | 367 | */ |
| 356 | static unsigned short hollow_box_cursor_bits[] = { | 368 | static unsigned short hollow_rectangle_bits[] = { |
| 357 | 0xfe, 0x82, 0x82, 0x82, 0x82, 0x82, 0x82, 0x82, 0x82, 0x82, 0x82, 0x82, 0xfe}; | 369 | 0xfe, 0x82, 0x82, 0x82, 0x82, 0x82, 0x82, 0x82, 0x82, 0x82, 0x82, 0x82, 0xfe}; |
| 358 | 370 | ||
| 371 | /* Hollow square bitmap. */ | ||
| 372 | /* | ||
| 373 | .xxxxxx. | ||
| 374 | .x....x. | ||
| 375 | .x....x. | ||
| 376 | .x....x. | ||
| 377 | .x....x. | ||
| 378 | .xxxxxx. | ||
| 379 | */ | ||
| 380 | static unsigned short hollow_square_bits[] = { | ||
| 381 | 0x7e, 0x42, 0x42, 0x42, 0x42, 0x7e}; | ||
| 382 | |||
| 383 | /* Filled square bitmap. */ | ||
| 384 | /* | ||
| 385 | .xxxxxx. | ||
| 386 | .xxxxxx. | ||
| 387 | .xxxxxx. | ||
| 388 | .xxxxxx. | ||
| 389 | .xxxxxx. | ||
| 390 | .xxxxxx. | ||
| 391 | */ | ||
| 392 | static unsigned short filled_square_bits[] = { | ||
| 393 | 0x7e, 0x7e, 0x7e, 0x7e, 0x7e, 0x7e}; | ||
| 394 | |||
| 359 | /* Bar cursor bitmap. A vertical bar; max 13 pixels high. */ | 395 | /* Bar cursor bitmap. A vertical bar; max 13 pixels high. */ |
| 360 | /* | 396 | /* |
| 361 | xx...... | 397 | xx...... |
| @@ -372,15 +408,15 @@ static unsigned short hollow_box_cursor_bits[] = { | |||
| 372 | xx...... | 408 | xx...... |
| 373 | xx...... | 409 | xx...... |
| 374 | */ | 410 | */ |
| 375 | static unsigned short bar_cursor_bits[] = { | 411 | static unsigned short vertical_bar_bits[] = { |
| 376 | 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0}; | 412 | 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0}; |
| 377 | 413 | ||
| 378 | /* HBar cursor bitmap. A horisontal bar; 2 pixels high. */ | 414 | /* HBar cursor bitmap. A horizontal bar; 2 pixels high. */ |
| 379 | /* | 415 | /* |
| 380 | xxxxxxx. | 416 | xxxxxxx. |
| 381 | xxxxxxx. | 417 | xxxxxxx. |
| 382 | */ | 418 | */ |
| 383 | static unsigned short hbar_cursor_bits[] = { | 419 | static unsigned short horizontal_bar_bits[] = { |
| 384 | 0xfe, 0xfe}; | 420 | 0xfe, 0xfe}; |
| 385 | 421 | ||
| 386 | 422 | ||
| @@ -394,7 +430,7 @@ static unsigned short hbar_cursor_bits[] = { | |||
| 394 | ..xxxx.. | 430 | ..xxxx.. |
| 395 | ........ | 431 | ........ |
| 396 | */ | 432 | */ |
| 397 | static unsigned short zv_bits[] = { | 433 | static unsigned short empty_line_bits[] = { |
| 398 | 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, | 434 | 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, |
| 399 | 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, | 435 | 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, |
| 400 | 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, | 436 | 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, |
| @@ -404,48 +440,45 @@ static unsigned short zv_bits[] = { | |||
| 404 | 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, | 440 | 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, |
| 405 | 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00}; | 441 | 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x3c, 0x00}; |
| 406 | 442 | ||
| 407 | /* Hollow square bitmap. */ | ||
| 408 | /* | ||
| 409 | .xxxxxx. | ||
| 410 | .x....x. | ||
| 411 | .x....x. | ||
| 412 | .x....x. | ||
| 413 | .x....x. | ||
| 414 | .xxxxxx. | ||
| 415 | */ | ||
| 416 | static unsigned short hollow_square_bits[] = { | ||
| 417 | 0x7e, 0x42, 0x42, 0x42, 0x42, 0x7e}; | ||
| 418 | |||
| 419 | 443 | ||
| 420 | #define BYTES_PER_BITMAP_ROW (sizeof (unsigned short)) | 444 | #define BYTES_PER_BITMAP_ROW (sizeof (unsigned short)) |
| 421 | #define STANDARD_BITMAP_HEIGHT(bits) (sizeof (bits)/BYTES_PER_BITMAP_ROW) | 445 | #define STANDARD_BITMAP_HEIGHT(bits) (sizeof (bits)/BYTES_PER_BITMAP_ROW) |
| 422 | #define FRBITS(bits) bits, STANDARD_BITMAP_HEIGHT (bits) | 446 | #define FRBITS(bits) bits, STANDARD_BITMAP_HEIGHT (bits) |
| 423 | 447 | ||
| 424 | struct fringe_bitmap standard_bitmaps[MAX_STANDARD_FRINGE_BITMAPS] = | 448 | /* NOTE: The order of these bitmaps must match the sequence |
| 449 | used in fringe.el to define the corresponding symbols. */ | ||
| 450 | |||
| 451 | struct fringe_bitmap standard_bitmaps[] = | ||
| 425 | { | 452 | { |
| 426 | { NULL, 0, 0, 0, 0, 0 }, /* NO_FRINGE_BITMAP */ | 453 | { NULL, 0, 0, 0, 0, 0 }, /* NO_FRINGE_BITMAP */ |
| 427 | { FRBITS (unknown_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, | 454 | { FRBITS (question_mark_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, |
| 428 | { FRBITS (left_arrow_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, | 455 | { FRBITS (left_arrow_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, |
| 429 | { FRBITS (right_arrow_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, | 456 | { FRBITS (right_arrow_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, |
| 430 | { FRBITS (up_arrow_bits), 8, 0, ALIGN_BITMAP_TOP, 0 }, | 457 | { FRBITS (up_arrow_bits), 8, 0, ALIGN_BITMAP_TOP, 0 }, |
| 431 | { FRBITS (down_arrow_bits), 8, 0, ALIGN_BITMAP_BOTTOM, 0 }, | 458 | { FRBITS (down_arrow_bits), 8, 0, ALIGN_BITMAP_BOTTOM, 0 }, |
| 432 | { FRBITS (continued_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, | 459 | { FRBITS (left_curly_arrow_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, |
| 433 | { FRBITS (continuation_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, | 460 | { FRBITS (right_curly_arrow_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, |
| 434 | { FRBITS (ov_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, | 461 | { FRBITS (left_triangle_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, |
| 462 | { FRBITS (right_triangle_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, | ||
| 435 | { FRBITS (top_left_angle_bits), 8, 0, ALIGN_BITMAP_TOP, 0 }, | 463 | { FRBITS (top_left_angle_bits), 8, 0, ALIGN_BITMAP_TOP, 0 }, |
| 436 | { FRBITS (top_right_angle_bits), 8, 0, ALIGN_BITMAP_TOP, 0 }, | 464 | { FRBITS (top_right_angle_bits), 8, 0, ALIGN_BITMAP_TOP, 0 }, |
| 437 | { FRBITS (bottom_left_angle_bits), 8, 0, ALIGN_BITMAP_BOTTOM, 0 }, | 465 | { FRBITS (bottom_left_angle_bits), 8, 0, ALIGN_BITMAP_BOTTOM, 0 }, |
| 438 | { FRBITS (bottom_right_angle_bits), 8, 0, ALIGN_BITMAP_BOTTOM, 0 }, | 466 | { FRBITS (bottom_right_angle_bits), 8, 0, ALIGN_BITMAP_BOTTOM, 0 }, |
| 439 | { FRBITS (left_bracket_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, | 467 | { FRBITS (left_bracket_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, |
| 440 | { FRBITS (right_bracket_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, | 468 | { FRBITS (right_bracket_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, |
| 441 | { FRBITS (filled_box_cursor_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, | 469 | { FRBITS (filled_rectangle_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, |
| 442 | { FRBITS (hollow_box_cursor_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, | 470 | { FRBITS (hollow_rectangle_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, |
| 471 | { FRBITS (filled_square_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, | ||
| 443 | { FRBITS (hollow_square_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, | 472 | { FRBITS (hollow_square_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, |
| 444 | { FRBITS (bar_cursor_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, | 473 | { FRBITS (vertical_bar_bits), 8, 0, ALIGN_BITMAP_CENTER, 0 }, |
| 445 | { FRBITS (hbar_cursor_bits), 8, 0, ALIGN_BITMAP_BOTTOM, 0 }, | 474 | { FRBITS (horizontal_bar_bits), 8, 0, ALIGN_BITMAP_BOTTOM, 0 }, |
| 446 | { FRBITS (zv_bits), 8, 3, ALIGN_BITMAP_TOP, 0 }, | 475 | { FRBITS (empty_line_bits), 8, 3, ALIGN_BITMAP_TOP, 0 }, |
| 447 | }; | 476 | }; |
| 448 | 477 | ||
| 478 | #define NO_FRINGE_BITMAP 0 | ||
| 479 | #define UNDEF_FRINGE_BITMAP 1 | ||
| 480 | #define MAX_STANDARD_FRINGE_BITMAPS (sizeof(standard_bitmaps)/sizeof(standard_bitmaps[0])) | ||
| 481 | |||
| 449 | static struct fringe_bitmap **fringe_bitmaps; | 482 | static struct fringe_bitmap **fringe_bitmaps; |
| 450 | static Lisp_Object *fringe_faces; | 483 | static Lisp_Object *fringe_faces; |
| 451 | static int max_fringe_bitmaps; | 484 | static int max_fringe_bitmaps; |
| @@ -516,12 +549,12 @@ get_fringe_bitmap_name (bn) | |||
| 516 | LEFT_P is 1 for left fringe, 0 for right fringe. | 549 | LEFT_P is 1 for left fringe, 0 for right fringe. |
| 517 | */ | 550 | */ |
| 518 | 551 | ||
| 519 | void | 552 | static void |
| 520 | draw_fringe_bitmap_1 (w, row, left_p, overlay, which) | 553 | draw_fringe_bitmap_1 (w, row, left_p, overlay, which) |
| 521 | struct window *w; | 554 | struct window *w; |
| 522 | struct glyph_row *row; | 555 | struct glyph_row *row; |
| 523 | int left_p, overlay; | 556 | int left_p, overlay; |
| 524 | enum fringe_bitmap_type which; | 557 | int which; |
| 525 | { | 558 | { |
| 526 | struct frame *f = XFRAME (WINDOW_FRAME (w)); | 559 | struct frame *f = XFRAME (WINDOW_FRAME (w)); |
| 527 | struct draw_fringe_bitmap_params p; | 560 | struct draw_fringe_bitmap_params p; |
| @@ -656,6 +689,134 @@ draw_fringe_bitmap_1 (w, row, left_p, overlay, which) | |||
| 656 | rif->draw_fringe_bitmap (w, row, &p); | 689 | rif->draw_fringe_bitmap (w, row, &p); |
| 657 | } | 690 | } |
| 658 | 691 | ||
| 692 | static int | ||
| 693 | get_logical_cursor_bitmap (w, cursor) | ||
| 694 | struct window *w; | ||
| 695 | Lisp_Object cursor; | ||
| 696 | { | ||
| 697 | Lisp_Object cmap, bm = Qnil; | ||
| 698 | |||
| 699 | if ((cmap = XBUFFER (w->buffer)->fringe_cursor_alist), !NILP (cmap)) | ||
| 700 | { | ||
| 701 | bm = Fassq (cursor, cmap); | ||
| 702 | if (CONSP (bm)) | ||
| 703 | { | ||
| 704 | if ((bm = XCDR (bm)), NILP (bm)) | ||
| 705 | return NO_FRINGE_BITMAP; | ||
| 706 | return lookup_fringe_bitmap (bm); | ||
| 707 | } | ||
| 708 | } | ||
| 709 | if (EQ (cmap, buffer_defaults.fringe_cursor_alist)) | ||
| 710 | return NO_FRINGE_BITMAP; | ||
| 711 | bm = Fassq (cursor, buffer_defaults.fringe_cursor_alist); | ||
| 712 | if (!CONSP (bm) || ((bm = XCDR (bm)), NILP (bm))) | ||
| 713 | return NO_FRINGE_BITMAP; | ||
| 714 | return lookup_fringe_bitmap (bm); | ||
| 715 | } | ||
| 716 | |||
| 717 | static int | ||
| 718 | get_logical_fringe_bitmap (w, bitmap, right_p, partial_p) | ||
| 719 | struct window *w; | ||
| 720 | Lisp_Object bitmap; | ||
| 721 | int right_p, partial_p; | ||
| 722 | { | ||
| 723 | Lisp_Object cmap, bm1 = Qnil, bm2 = Qnil, bm; | ||
| 724 | int ln1 = 0, ln2 = 0; | ||
| 725 | int ix1 = right_p; | ||
| 726 | int ix2 = ix1 + (partial_p ? 2 : 0); | ||
| 727 | |||
| 728 | /* Lookup in buffer-local fringe-indicator-alist before global alist. | ||
| 729 | |||
| 730 | Elements are: | ||
| 731 | BITMAP -- use for all | ||
| 732 | (L R) -- use for left right (whether partial or not) | ||
| 733 | (L R PL PR) -- use for left rigth partial-left partial-right | ||
| 734 | If any value in local binding is not present or t, use global value. | ||
| 735 | |||
| 736 | If partial, lookup partial bitmap in default value if not found here. | ||
| 737 | If not partial, or no partial spec is present, use non-partial bitmap. */ | ||
| 738 | |||
| 739 | if ((cmap = XBUFFER (w->buffer)->fringe_indicator_alist), !NILP (cmap)) | ||
| 740 | { | ||
| 741 | bm1 = Fassq (bitmap, cmap); | ||
| 742 | if (CONSP (bm1)) | ||
| 743 | { | ||
| 744 | if ((bm1 = XCDR (bm1)), NILP (bm1)) | ||
| 745 | return NO_FRINGE_BITMAP; | ||
| 746 | if (CONSP (bm1)) | ||
| 747 | { | ||
| 748 | ln1 = XINT (Flength (bm1)); | ||
| 749 | if (partial_p) | ||
| 750 | { | ||
| 751 | if (ln1 > ix2) | ||
| 752 | { | ||
| 753 | bm = Fnth (make_number (ix2), bm1); | ||
| 754 | if (!EQ (bm, Qt)) | ||
| 755 | goto found; | ||
| 756 | } | ||
| 757 | } | ||
| 758 | else | ||
| 759 | { | ||
| 760 | if (ln1 > ix1) | ||
| 761 | { | ||
| 762 | bm = Fnth (make_number (ix1), bm1); | ||
| 763 | if (!EQ (bm, Qt)) | ||
| 764 | goto found; | ||
| 765 | } | ||
| 766 | } | ||
| 767 | } | ||
| 768 | else if ((bm = bm1, !EQ (bm, Qt))) | ||
| 769 | goto found; | ||
| 770 | } | ||
| 771 | } | ||
| 772 | |||
| 773 | if (!EQ (cmap, buffer_defaults.fringe_indicator_alist) | ||
| 774 | && !NILP (buffer_defaults.fringe_indicator_alist)) | ||
| 775 | { | ||
| 776 | bm2 = Fassq (bitmap, buffer_defaults.fringe_indicator_alist); | ||
| 777 | if (CONSP (bm2)) | ||
| 778 | { | ||
| 779 | if ((bm2 = XCDR (bm2)), !NILP (bm2)) | ||
| 780 | { | ||
| 781 | if (CONSP (bm2)) | ||
| 782 | { | ||
| 783 | ln2 = XINT (Flength (bm2)); | ||
| 784 | if (partial_p) | ||
| 785 | { | ||
| 786 | if (ln2 > ix2) | ||
| 787 | { | ||
| 788 | bm = Fnth (make_number (ix2), bm2); | ||
| 789 | if (!EQ (bm, Qt)) | ||
| 790 | goto found; | ||
| 791 | } | ||
| 792 | } | ||
| 793 | } | ||
| 794 | } | ||
| 795 | } | ||
| 796 | } | ||
| 797 | |||
| 798 | if (ln1 > ix1) | ||
| 799 | { | ||
| 800 | bm = Fnth (make_number (ix1), bm1); | ||
| 801 | if (!EQ (bm, Qt)) | ||
| 802 | goto found; | ||
| 803 | } | ||
| 804 | |||
| 805 | if (ln2 > ix1) | ||
| 806 | { | ||
| 807 | bm = Fnth (make_number (ix1), bm2); | ||
| 808 | if (!EQ (bm, Qt)) | ||
| 809 | goto found; | ||
| 810 | return NO_FRINGE_BITMAP; | ||
| 811 | } | ||
| 812 | else if ((bm = bm2, NILP (bm))) | ||
| 813 | return NO_FRINGE_BITMAP; | ||
| 814 | |||
| 815 | found: | ||
| 816 | return lookup_fringe_bitmap (bm); | ||
| 817 | } | ||
| 818 | |||
| 819 | |||
| 659 | void | 820 | void |
| 660 | draw_fringe_bitmap (w, row, left_p) | 821 | draw_fringe_bitmap (w, row, left_p) |
| 661 | struct window *w; | 822 | struct window *w; |
| @@ -666,24 +827,24 @@ draw_fringe_bitmap (w, row, left_p) | |||
| 666 | 827 | ||
| 667 | if (!left_p && row->cursor_in_fringe_p) | 828 | if (!left_p && row->cursor_in_fringe_p) |
| 668 | { | 829 | { |
| 669 | int cursor = NO_FRINGE_BITMAP; | 830 | Lisp_Object cursor = Qnil; |
| 670 | 831 | ||
| 671 | switch (w->phys_cursor_type) | 832 | switch (w->phys_cursor_type) |
| 672 | { | 833 | { |
| 673 | case HOLLOW_BOX_CURSOR: | 834 | case HOLLOW_BOX_CURSOR: |
| 674 | if (row->visible_height >= STANDARD_BITMAP_HEIGHT (hollow_box_cursor_bits)) | 835 | if (row->visible_height >= STANDARD_BITMAP_HEIGHT (hollow_rectangle_bits)) |
| 675 | cursor = HOLLOW_BOX_CURSOR_BITMAP; | 836 | cursor = Qhollow; |
| 676 | else | 837 | else |
| 677 | cursor = HOLLOW_SQUARE_BITMAP; | 838 | cursor = Qhollow_small; |
| 678 | break; | 839 | break; |
| 679 | case FILLED_BOX_CURSOR: | 840 | case FILLED_BOX_CURSOR: |
| 680 | cursor = FILLED_BOX_CURSOR_BITMAP; | 841 | cursor = Qbox; |
| 681 | break; | 842 | break; |
| 682 | case BAR_CURSOR: | 843 | case BAR_CURSOR: |
| 683 | cursor = BAR_CURSOR_BITMAP; | 844 | cursor = Qbar; |
| 684 | break; | 845 | break; |
| 685 | case HBAR_CURSOR: | 846 | case HBAR_CURSOR: |
| 686 | cursor = HBAR_CURSOR_BITMAP; | 847 | cursor = Qhbar; |
| 687 | break; | 848 | break; |
| 688 | case NO_CURSOR: | 849 | case NO_CURSOR: |
| 689 | default: | 850 | default: |
| @@ -691,10 +852,14 @@ draw_fringe_bitmap (w, row, left_p) | |||
| 691 | row->cursor_in_fringe_p = 0; | 852 | row->cursor_in_fringe_p = 0; |
| 692 | break; | 853 | break; |
| 693 | } | 854 | } |
| 694 | if (cursor != NO_FRINGE_BITMAP) | 855 | if (!NILP (cursor)) |
| 695 | { | 856 | { |
| 696 | draw_fringe_bitmap_1 (w, row, 0, 2, cursor); | 857 | int bm = get_logical_cursor_bitmap (w, cursor); |
| 697 | overlay = cursor == FILLED_BOX_CURSOR_BITMAP ? 3 : 1; | 858 | if (bm != NO_FRINGE_BITMAP) |
| 859 | { | ||
| 860 | draw_fringe_bitmap_1 (w, row, 0, 2, bm); | ||
| 861 | overlay = EQ (cursor, Qbox) ? 3 : 1; | ||
| 862 | } | ||
| 698 | } | 863 | } |
| 699 | } | 864 | } |
| 700 | 865 | ||
| @@ -703,7 +868,7 @@ draw_fringe_bitmap (w, row, left_p) | |||
| 703 | if (left_p && row->overlay_arrow_bitmap != NO_FRINGE_BITMAP) | 868 | if (left_p && row->overlay_arrow_bitmap != NO_FRINGE_BITMAP) |
| 704 | draw_fringe_bitmap_1 (w, row, 1, 1, | 869 | draw_fringe_bitmap_1 (w, row, 1, 1, |
| 705 | (row->overlay_arrow_bitmap < 0 | 870 | (row->overlay_arrow_bitmap < 0 |
| 706 | ? OVERLAY_ARROW_BITMAP | 871 | ? get_logical_fringe_bitmap (w, Qoverlay_arrow, 0, 0) |
| 707 | : row->overlay_arrow_bitmap)); | 872 | : row->overlay_arrow_bitmap)); |
| 708 | } | 873 | } |
| 709 | 874 | ||
| @@ -795,6 +960,8 @@ update_window_fringes (w, keep_current_p) | |||
| 795 | Lisp_Object arrow_top = Qnil, arrow_bot = Qnil; | 960 | Lisp_Object arrow_top = Qnil, arrow_bot = Qnil; |
| 796 | Lisp_Object empty_pos; | 961 | Lisp_Object empty_pos; |
| 797 | Lisp_Object ind = Qnil; | 962 | Lisp_Object ind = Qnil; |
| 963 | #define MAX_BITMAP_CACHE (8*4) | ||
| 964 | int bitmap_cache[MAX_BITMAP_CACHE]; | ||
| 798 | 965 | ||
| 799 | if (w->pseudo_window_p) | 966 | if (w->pseudo_window_p) |
| 800 | return 0; | 967 | return 0; |
| @@ -880,11 +1047,27 @@ update_window_fringes (w, keep_current_p) | |||
| 880 | if (!NILP (empty_pos) && !EQ (empty_pos, Qright)) | 1047 | if (!NILP (empty_pos) && !EQ (empty_pos, Qright)) |
| 881 | empty_pos = WINDOW_LEFT_FRINGE_WIDTH (w) == 0 ? Qright : Qleft; | 1048 | empty_pos = WINDOW_LEFT_FRINGE_WIDTH (w) == 0 ? Qright : Qleft; |
| 882 | 1049 | ||
| 1050 | for (y = 0; y < MAX_BITMAP_CACHE; y++) | ||
| 1051 | bitmap_cache[y] = -1; | ||
| 1052 | |||
| 1053 | #define LEFT_FRINGE(cache, which, partial_p) \ | ||
| 1054 | (bitmap_cache[cache*4+partial_p] >= 0 \ | ||
| 1055 | ? bitmap_cache[cache*4+partial_p] \ | ||
| 1056 | : (bitmap_cache[cache*4+partial_p] = \ | ||
| 1057 | get_logical_fringe_bitmap (w, which, 0, partial_p))) | ||
| 1058 | |||
| 1059 | #define RIGHT_FRINGE(cache, which, partial_p) \ | ||
| 1060 | (bitmap_cache[cache*4+2+partial_p] >= 0 \ | ||
| 1061 | ? bitmap_cache[cache*4+2+partial_p] \ | ||
| 1062 | : (bitmap_cache[cache*4+2+partial_p] = \ | ||
| 1063 | get_logical_fringe_bitmap (w, which, 1, partial_p))) | ||
| 1064 | |||
| 1065 | |||
| 883 | for (y = 0, rn = 0; | 1066 | for (y = 0, rn = 0; |
| 884 | y < yb && rn < nrows; | 1067 | y < yb && rn < nrows; |
| 885 | y += row->height, rn++) | 1068 | y += row->height, rn++) |
| 886 | { | 1069 | { |
| 887 | enum fringe_bitmap_type left, right; | 1070 | int left, right; |
| 888 | unsigned left_face_id, right_face_id; | 1071 | unsigned left_face_id, right_face_id; |
| 889 | 1072 | ||
| 890 | row = w->desired_matrix->rows + rn; | 1073 | row = w->desired_matrix->rows + rn; |
| @@ -903,23 +1086,21 @@ update_window_fringes (w, keep_current_p) | |||
| 903 | left_face_id = row->left_user_fringe_face_id; | 1086 | left_face_id = row->left_user_fringe_face_id; |
| 904 | } | 1087 | } |
| 905 | else if (row->truncated_on_left_p) | 1088 | else if (row->truncated_on_left_p) |
| 906 | left = LEFT_TRUNCATION_BITMAP; | 1089 | left = LEFT_FRINGE(0, Qtruncation, 0); |
| 907 | else if (row->indicate_bob_p && EQ (boundary_top, Qleft)) | 1090 | else if (row->indicate_bob_p && EQ (boundary_top, Qleft)) |
| 908 | left = ((row->indicate_eob_p && EQ (boundary_bot, Qleft)) | 1091 | left = ((row->indicate_eob_p && EQ (boundary_bot, Qleft)) |
| 909 | ? (row->ends_at_zv_p | 1092 | ? LEFT_FRINGE (1, Qtop_bottom, row->ends_at_zv_p) |
| 910 | ? TOP_RIGHT_ANGLE_BITMAP : LEFT_BRACKET_BITMAP) | 1093 | : LEFT_FRINGE (2, Qtop, 0)); |
| 911 | : TOP_LEFT_ANGLE_BITMAP); | ||
| 912 | else if (row->indicate_eob_p && EQ (boundary_bot, Qleft)) | 1094 | else if (row->indicate_eob_p && EQ (boundary_bot, Qleft)) |
| 913 | left = (row->ends_at_zv_p | 1095 | left = LEFT_FRINGE (3, Qbottom, row->ends_at_zv_p); |
| 914 | ? TOP_RIGHT_ANGLE_BITMAP : BOTTOM_LEFT_ANGLE_BITMAP); | ||
| 915 | else if (MATRIX_ROW_CONTINUATION_LINE_P (row)) | 1096 | else if (MATRIX_ROW_CONTINUATION_LINE_P (row)) |
| 916 | left = CONTINUATION_LINE_BITMAP; | 1097 | left = LEFT_FRINGE (4, Qcontinuation, 0); |
| 917 | else if (row->indicate_empty_line_p && EQ (empty_pos, Qleft)) | 1098 | else if (row->indicate_empty_line_p && EQ (empty_pos, Qleft)) |
| 918 | left = ZV_LINE_BITMAP; | 1099 | left = LEFT_FRINGE (5, Qempty_line, 0); |
| 919 | else if (row->indicate_top_line_p && EQ (arrow_top, Qleft)) | 1100 | else if (row->indicate_top_line_p && EQ (arrow_top, Qleft)) |
| 920 | left = UP_ARROW_BITMAP; | 1101 | left = LEFT_FRINGE (6, Qup, 0); |
| 921 | else if (row->indicate_bottom_line_p && EQ (arrow_bot, Qleft)) | 1102 | else if (row->indicate_bottom_line_p && EQ (arrow_bot, Qleft)) |
| 922 | left = DOWN_ARROW_BITMAP; | 1103 | left = LEFT_FRINGE (7, Qdown, 0); |
| 923 | else | 1104 | else |
| 924 | left = NO_FRINGE_BITMAP; | 1105 | left = NO_FRINGE_BITMAP; |
| 925 | 1106 | ||
| @@ -932,23 +1113,21 @@ update_window_fringes (w, keep_current_p) | |||
| 932 | right_face_id = row->right_user_fringe_face_id; | 1113 | right_face_id = row->right_user_fringe_face_id; |
| 933 | } | 1114 | } |
| 934 | else if (row->truncated_on_right_p) | 1115 | else if (row->truncated_on_right_p) |
| 935 | right = RIGHT_TRUNCATION_BITMAP; | 1116 | right = RIGHT_FRINGE (0, Qtruncation, 0); |
| 936 | else if (row->indicate_bob_p && EQ (boundary_top, Qright)) | 1117 | else if (row->indicate_bob_p && EQ (boundary_top, Qright)) |
| 937 | right = ((row->indicate_eob_p && EQ (boundary_bot, Qright)) | 1118 | right = ((row->indicate_eob_p && EQ (boundary_bot, Qright)) |
| 938 | ? (row->ends_at_zv_p | 1119 | ? RIGHT_FRINGE (1, Qtop_bottom, row->ends_at_zv_p) |
| 939 | ? TOP_LEFT_ANGLE_BITMAP : RIGHT_BRACKET_BITMAP) | 1120 | : RIGHT_FRINGE (2, Qtop, 0)); |
| 940 | : TOP_RIGHT_ANGLE_BITMAP); | ||
| 941 | else if (row->indicate_eob_p && EQ (boundary_bot, Qright)) | 1121 | else if (row->indicate_eob_p && EQ (boundary_bot, Qright)) |
| 942 | right = (row->ends_at_zv_p | 1122 | right = RIGHT_FRINGE (3, Qbottom, row->ends_at_zv_p); |
| 943 | ? TOP_LEFT_ANGLE_BITMAP : BOTTOM_RIGHT_ANGLE_BITMAP); | ||
| 944 | else if (row->continued_p) | 1123 | else if (row->continued_p) |
| 945 | right = CONTINUED_LINE_BITMAP; | 1124 | right = RIGHT_FRINGE (4, Qcontinuation, 0); |
| 946 | else if (row->indicate_top_line_p && EQ (arrow_top, Qright)) | 1125 | else if (row->indicate_top_line_p && EQ (arrow_top, Qright)) |
| 947 | right = UP_ARROW_BITMAP; | 1126 | right = RIGHT_FRINGE (6, Qup, 0); |
| 948 | else if (row->indicate_bottom_line_p && EQ (arrow_bot, Qright)) | 1127 | else if (row->indicate_bottom_line_p && EQ (arrow_bot, Qright)) |
| 949 | right = DOWN_ARROW_BITMAP; | 1128 | right = RIGHT_FRINGE (7, Qdown, 0); |
| 950 | else if (row->indicate_empty_line_p && EQ (empty_pos, Qright)) | 1129 | else if (row->indicate_empty_line_p && EQ (empty_pos, Qright)) |
| 951 | right = ZV_LINE_BITMAP; | 1130 | right = RIGHT_FRINGE (5, Qempty_line, 0); |
| 952 | else | 1131 | else |
| 953 | right = NO_FRINGE_BITMAP; | 1132 | right = NO_FRINGE_BITMAP; |
| 954 | 1133 | ||
| @@ -1150,7 +1329,7 @@ If BITMAP overrides a standard fringe bitmap, the original bitmap is restored. | |||
| 1150 | 1329 | ||
| 1151 | void | 1330 | void |
| 1152 | init_fringe_bitmap (which, fb, once_p) | 1331 | init_fringe_bitmap (which, fb, once_p) |
| 1153 | enum fringe_bitmap_type which; | 1332 | int which; |
| 1154 | struct fringe_bitmap *fb; | 1333 | struct fringe_bitmap *fb; |
| 1155 | int once_p; | 1334 | int once_p; |
| 1156 | { | 1335 | { |
| @@ -1436,6 +1615,19 @@ Return nil if POS is not visible in WINDOW. */) | |||
| 1436 | void | 1615 | void |
| 1437 | syms_of_fringe () | 1616 | syms_of_fringe () |
| 1438 | { | 1617 | { |
| 1618 | Qtruncation = intern ("truncation"); | ||
| 1619 | staticpro (&Qtruncation); | ||
| 1620 | Qcontinuation = intern ("continuation"); | ||
| 1621 | staticpro (&Qcontinuation); | ||
| 1622 | Qoverlay_arrow = intern ("overlay-arrow"); | ||
| 1623 | staticpro (&Qoverlay_arrow); | ||
| 1624 | Qempty_line = intern ("empty-line"); | ||
| 1625 | staticpro (&Qempty_line); | ||
| 1626 | Qtop_bottom = intern ("top-bottom"); | ||
| 1627 | staticpro (&Qtop_bottom); | ||
| 1628 | Qhollow_small = intern ("hollow-small"); | ||
| 1629 | staticpro (&Qhollow_small); | ||
| 1630 | |||
| 1439 | defsubr (&Sdestroy_fringe_bitmap); | 1631 | defsubr (&Sdestroy_fringe_bitmap); |
| 1440 | defsubr (&Sdefine_fringe_bitmap); | 1632 | defsubr (&Sdefine_fringe_bitmap); |
| 1441 | defsubr (&Sfringe_bitmaps_at_pos); | 1633 | defsubr (&Sfringe_bitmaps_at_pos); |
| @@ -1451,8 +1643,7 @@ If nil, also continue lines which are exactly as wide as the window. */); | |||
| 1451 | Voverflow_newline_into_fringe = Qt; | 1643 | Voverflow_newline_into_fringe = Qt; |
| 1452 | 1644 | ||
| 1453 | DEFVAR_LISP ("fringe-bitmaps", &Vfringe_bitmaps, | 1645 | DEFVAR_LISP ("fringe-bitmaps", &Vfringe_bitmaps, |
| 1454 | doc: /* List of fringe bitmap symbols. | 1646 | doc: /* List of fringe bitmap symbols. */); |
| 1455 | You must (require 'fringe) to use fringe bitmap symbols in your programs." */); | ||
| 1456 | Vfringe_bitmaps = Qnil; | 1647 | Vfringe_bitmaps = Qnil; |
| 1457 | } | 1648 | } |
| 1458 | 1649 | ||
| @@ -1473,7 +1664,7 @@ mark_fringe_data () | |||
| 1473 | void | 1664 | void |
| 1474 | init_fringe_once () | 1665 | init_fringe_once () |
| 1475 | { | 1666 | { |
| 1476 | enum fringe_bitmap_type bt; | 1667 | int bt; |
| 1477 | 1668 | ||
| 1478 | for (bt = NO_FRINGE_BITMAP + 1; bt < MAX_STANDARD_FRINGE_BITMAPS; bt++) | 1669 | for (bt = NO_FRINGE_BITMAP + 1; bt < MAX_STANDARD_FRINGE_BITMAPS; bt++) |
| 1479 | init_fringe_bitmap(bt, &standard_bitmaps[bt], 1); | 1670 | init_fringe_bitmap(bt, &standard_bitmaps[bt], 1); |
| @@ -1503,7 +1694,7 @@ init_fringe () | |||
| 1503 | void | 1694 | void |
| 1504 | w32_init_fringe () | 1695 | w32_init_fringe () |
| 1505 | { | 1696 | { |
| 1506 | enum fringe_bitmap_type bt; | 1697 | int bt; |
| 1507 | 1698 | ||
| 1508 | if (!rif) | 1699 | if (!rif) |
| 1509 | return; | 1700 | return; |
diff --git a/src/gtkutil.c b/src/gtkutil.c index 5b7a5166888..203eab257f3 100644 --- a/src/gtkutil.c +++ b/src/gtkutil.c | |||
| @@ -199,7 +199,7 @@ malloc_widget_value () | |||
| 199 | } | 199 | } |
| 200 | else | 200 | else |
| 201 | { | 201 | { |
| 202 | wv = (widget_value *) malloc (sizeof (widget_value)); | 202 | wv = (widget_value *) xmalloc (sizeof (widget_value)); |
| 203 | malloc_cpt++; | 203 | malloc_cpt++; |
| 204 | } | 204 | } |
| 205 | memset (wv, 0, sizeof (widget_value)); | 205 | memset (wv, 0, sizeof (widget_value)); |
diff --git a/src/macmenu.c b/src/macmenu.c index bd4ad6291cf..fccbbe6402c 100644 --- a/src/macmenu.c +++ b/src/macmenu.c | |||
| @@ -189,8 +189,9 @@ static void single_keymap_panes P_ ((Lisp_Object, Lisp_Object, Lisp_Object, | |||
| 189 | static void list_of_panes P_ ((Lisp_Object)); | 189 | static void list_of_panes P_ ((Lisp_Object)); |
| 190 | static void list_of_items P_ ((Lisp_Object)); | 190 | static void list_of_items P_ ((Lisp_Object)); |
| 191 | 191 | ||
| 192 | static void fill_submenu (MenuHandle, widget_value *); | 192 | static int fill_menu P_ ((MenuHandle, widget_value *, int)); |
| 193 | static void fill_menubar (widget_value *); | 193 | static void fill_menubar P_ ((widget_value *, int)); |
| 194 | static void dispose_menus P_ ((int)); | ||
| 194 | 195 | ||
| 195 | 196 | ||
| 196 | /* This holds a Lisp vector that holds the results of decoding | 197 | /* This holds a Lisp vector that holds the results of decoding |
| @@ -247,15 +248,6 @@ static int menu_items_n_panes; | |||
| 247 | /* Current depth within submenus. */ | 248 | /* Current depth within submenus. */ |
| 248 | static int menu_items_submenu_depth; | 249 | static int menu_items_submenu_depth; |
| 249 | 250 | ||
| 250 | /* Flag which when set indicates a dialog or menu has been posted by | ||
| 251 | Xt on behalf of one of the widget sets. */ | ||
| 252 | static int popup_activated_flag; | ||
| 253 | |||
| 254 | /* Index of the next submenu */ | ||
| 255 | static int submenu_id; | ||
| 256 | |||
| 257 | static int next_menubar_widget_id; | ||
| 258 | |||
| 259 | /* This is set nonzero after the user activates the menu bar, and set | 251 | /* This is set nonzero after the user activates the menu bar, and set |
| 260 | to zero again after the menu bars are redisplayed by prepare_menu_bar. | 252 | to zero again after the menu bars are redisplayed by prepare_menu_bar. |
| 261 | While it is nonzero, all calls to set_frame_menubar go deep. | 253 | While it is nonzero, all calls to set_frame_menubar go deep. |
| @@ -1440,7 +1432,7 @@ install_menu_quit_handler (MenuHandle menu_handle) | |||
| 1440 | menu = GetMenuHandle (++i); | 1432 | menu = GetMenuHandle (++i); |
| 1441 | } | 1433 | } |
| 1442 | 1434 | ||
| 1443 | i = menu_handle ? MIN_POPUP_SUBMENU_ID : MIN_SUBMENU_ID; | 1435 | i = menu_handle ? MIN_POPUP_SUBMENU_ID : MIN_SUBMENU_ID; |
| 1444 | menu = GetMenuHandle (i); | 1436 | menu = GetMenuHandle (i); |
| 1445 | while (menu != NULL) | 1437 | while (menu != NULL) |
| 1446 | { | 1438 | { |
| @@ -1679,27 +1671,7 @@ set_frame_menubar (f, first_time, deep_p) | |||
| 1679 | /* Non-null value to indicate menubar has already been "created". */ | 1671 | /* Non-null value to indicate menubar has already been "created". */ |
| 1680 | f->output_data.mac->menubar_widget = 1; | 1672 | f->output_data.mac->menubar_widget = 1; |
| 1681 | 1673 | ||
| 1682 | { | 1674 | fill_menubar (first_wv->contents, deep_p); |
| 1683 | int i = MIN_MENU_ID; | ||
| 1684 | MenuHandle menu = GetMenuHandle (i); | ||
| 1685 | while (menu != NULL) | ||
| 1686 | { | ||
| 1687 | DeleteMenu (i); | ||
| 1688 | DisposeMenu (menu); | ||
| 1689 | menu = GetMenuHandle (++i); | ||
| 1690 | } | ||
| 1691 | |||
| 1692 | i = MIN_SUBMENU_ID; | ||
| 1693 | menu = GetMenuHandle (i); | ||
| 1694 | while (menu != NULL) | ||
| 1695 | { | ||
| 1696 | DeleteMenu (i); | ||
| 1697 | DisposeMenu (menu); | ||
| 1698 | menu = GetMenuHandle (++i); | ||
| 1699 | } | ||
| 1700 | } | ||
| 1701 | |||
| 1702 | fill_menubar (first_wv->contents); | ||
| 1703 | 1675 | ||
| 1704 | /* Add event handler so we can detect C-g. */ | 1676 | /* Add event handler so we can detect C-g. */ |
| 1705 | install_menu_quit_handler (NULL); | 1677 | install_menu_quit_handler (NULL); |
| @@ -1708,22 +1680,6 @@ set_frame_menubar (f, first_time, deep_p) | |||
| 1708 | UNBLOCK_INPUT; | 1680 | UNBLOCK_INPUT; |
| 1709 | } | 1681 | } |
| 1710 | 1682 | ||
| 1711 | /* Called from Fx_create_frame to create the initial menubar of a frame | ||
| 1712 | before it is mapped, so that the window is mapped with the menubar already | ||
| 1713 | there instead of us tacking it on later and thrashing the window after it | ||
| 1714 | is visible. */ | ||
| 1715 | |||
| 1716 | void | ||
| 1717 | initialize_frame_menubar (f) | ||
| 1718 | FRAME_PTR f; | ||
| 1719 | { | ||
| 1720 | /* This function is called before the first chance to redisplay | ||
| 1721 | the frame. It has to be, so the frame will have the right size. */ | ||
| 1722 | FRAME_MENU_BAR_ITEMS (f) = menu_bar_items (FRAME_MENU_BAR_ITEMS (f)); | ||
| 1723 | set_frame_menubar (f, 1, 1); | ||
| 1724 | } | ||
| 1725 | |||
| 1726 | |||
| 1727 | /* Get rid of the menu bar of frame F, and free its storage. | 1683 | /* Get rid of the menu bar of frame F, and free its storage. |
| 1728 | This is used when deleting a frame, and when turning off the menu bar. */ | 1684 | This is used when deleting a frame, and when turning off the menu bar. */ |
| 1729 | 1685 | ||
| @@ -1739,11 +1695,9 @@ static Lisp_Object | |||
| 1739 | pop_down_menu (arg) | 1695 | pop_down_menu (arg) |
| 1740 | Lisp_Object arg; | 1696 | Lisp_Object arg; |
| 1741 | { | 1697 | { |
| 1742 | struct Lisp_Save_Value *p1 = XSAVE_VALUE (Fcar (arg)); | 1698 | struct Lisp_Save_Value *p = XSAVE_VALUE (arg); |
| 1743 | struct Lisp_Save_Value *p2 = XSAVE_VALUE (Fcdr (arg)); | 1699 | FRAME_PTR f = p->pointer; |
| 1744 | 1700 | MenuHandle menu = GetMenuHandle (POPUP_SUBMENU_ID); | |
| 1745 | FRAME_PTR f = p1->pointer; | ||
| 1746 | MenuHandle *menu = p2->pointer; | ||
| 1747 | 1701 | ||
| 1748 | BLOCK_INPUT; | 1702 | BLOCK_INPUT; |
| 1749 | 1703 | ||
| @@ -1752,19 +1706,9 @@ pop_down_menu (arg) | |||
| 1752 | FRAME_MAC_DISPLAY_INFO (f)->grabbed = 0; | 1706 | FRAME_MAC_DISPLAY_INFO (f)->grabbed = 0; |
| 1753 | 1707 | ||
| 1754 | /* delete all menus */ | 1708 | /* delete all menus */ |
| 1755 | { | 1709 | dispose_menus (MIN_POPUP_SUBMENU_ID); |
| 1756 | int i = MIN_POPUP_SUBMENU_ID; | ||
| 1757 | MenuHandle submenu = GetMenuHandle (i); | ||
| 1758 | while (submenu != NULL) | ||
| 1759 | { | ||
| 1760 | DeleteMenu (i); | ||
| 1761 | DisposeMenu (submenu); | ||
| 1762 | submenu = GetMenuHandle (++i); | ||
| 1763 | } | ||
| 1764 | } | ||
| 1765 | |||
| 1766 | DeleteMenu (POPUP_SUBMENU_ID); | 1710 | DeleteMenu (POPUP_SUBMENU_ID); |
| 1767 | DisposeMenu (*menu); | 1711 | DisposeMenu (menu); |
| 1768 | 1712 | ||
| 1769 | UNBLOCK_INPUT; | 1713 | UNBLOCK_INPUT; |
| 1770 | 1714 | ||
| @@ -1998,8 +1942,8 @@ mac_menu_show (f, x, y, for_click, keymaps, title, error) | |||
| 1998 | 1942 | ||
| 1999 | /* Actually create the menu. */ | 1943 | /* Actually create the menu. */ |
| 2000 | menu = NewMenu (POPUP_SUBMENU_ID, "\p"); | 1944 | menu = NewMenu (POPUP_SUBMENU_ID, "\p"); |
| 2001 | submenu_id = MIN_POPUP_SUBMENU_ID; | 1945 | InsertMenu (menu, -1); |
| 2002 | fill_submenu (menu, first_wv->contents); | 1946 | fill_menu (menu, first_wv->contents, MIN_POPUP_SUBMENU_ID); |
| 2003 | 1947 | ||
| 2004 | /* Free the widget_value objects we used to specify the | 1948 | /* Free the widget_value objects we used to specify the |
| 2005 | contents. */ | 1949 | contents. */ |
| @@ -2016,11 +1960,7 @@ mac_menu_show (f, x, y, for_click, keymaps, title, error) | |||
| 2016 | menu_item_choice = 0; | 1960 | menu_item_choice = 0; |
| 2017 | menu_item_selection = 0; | 1961 | menu_item_selection = 0; |
| 2018 | 1962 | ||
| 2019 | InsertMenu (menu, -1); | 1963 | record_unwind_protect (pop_down_menu, make_save_value (f, 0)); |
| 2020 | |||
| 2021 | record_unwind_protect (pop_down_menu, | ||
| 2022 | Fcons (make_save_value (f, 0), | ||
| 2023 | make_save_value (&menu, 0))); | ||
| 2024 | 1964 | ||
| 2025 | /* Add event handler so we can detect C-g. */ | 1965 | /* Add event handler so we can detect C-g. */ |
| 2026 | install_menu_quit_handler (menu); | 1966 | install_menu_quit_handler (menu); |
| @@ -2421,15 +2361,16 @@ name_is_separator (name) | |||
| 2421 | } | 2361 | } |
| 2422 | 2362 | ||
| 2423 | static void | 2363 | static void |
| 2424 | add_menu_item (MenuHandle menu, widget_value *wv, int submenu, | 2364 | add_menu_item (menu, pos, wv) |
| 2425 | int force_disable) | 2365 | MenuHandle menu; |
| 2366 | int pos; | ||
| 2367 | widget_value *wv; | ||
| 2426 | { | 2368 | { |
| 2427 | #if TARGET_API_MAC_CARBON | 2369 | #if TARGET_API_MAC_CARBON |
| 2428 | CFStringRef item_name; | 2370 | CFStringRef item_name; |
| 2429 | #else | 2371 | #else |
| 2430 | Str255 item_name; | 2372 | Str255 item_name; |
| 2431 | #endif | 2373 | #endif |
| 2432 | int pos; | ||
| 2433 | 2374 | ||
| 2434 | if (name_is_separator (wv->name)) | 2375 | if (name_is_separator (wv->name)) |
| 2435 | AppendMenu (menu, "\p-"); | 2376 | AppendMenu (menu, "\p-"); |
| @@ -2438,8 +2379,6 @@ add_menu_item (MenuHandle menu, widget_value *wv, int submenu, | |||
| 2438 | AppendMenu (menu, "\pX"); | 2379 | AppendMenu (menu, "\pX"); |
| 2439 | 2380 | ||
| 2440 | #if TARGET_API_MAC_CARBON | 2381 | #if TARGET_API_MAC_CARBON |
| 2441 | pos = CountMenuItems (menu); | ||
| 2442 | |||
| 2443 | item_name = cfstring_create_with_utf8_cstring (wv->name); | 2382 | item_name = cfstring_create_with_utf8_cstring (wv->name); |
| 2444 | 2383 | ||
| 2445 | if (wv->key != NULL) | 2384 | if (wv->key != NULL) |
| @@ -2457,13 +2396,11 @@ add_menu_item (MenuHandle menu, widget_value *wv, int submenu, | |||
| 2457 | SetMenuItemTextWithCFString (menu, pos, item_name); | 2396 | SetMenuItemTextWithCFString (menu, pos, item_name); |
| 2458 | CFRelease (item_name); | 2397 | CFRelease (item_name); |
| 2459 | 2398 | ||
| 2460 | if (wv->enabled && !force_disable) | 2399 | if (wv->enabled) |
| 2461 | EnableMenuItem (menu, pos); | 2400 | EnableMenuItem (menu, pos); |
| 2462 | else | 2401 | else |
| 2463 | DisableMenuItem (menu, pos); | 2402 | DisableMenuItem (menu, pos); |
| 2464 | #else /* ! TARGET_API_MAC_CARBON */ | 2403 | #else /* ! TARGET_API_MAC_CARBON */ |
| 2465 | pos = CountMItems (menu); | ||
| 2466 | |||
| 2467 | item_name[sizeof (item_name) - 1] = '\0'; | 2404 | item_name[sizeof (item_name) - 1] = '\0'; |
| 2468 | strncpy (item_name, wv->name, sizeof (item_name) - 1); | 2405 | strncpy (item_name, wv->name, sizeof (item_name) - 1); |
| 2469 | if (wv->key != NULL) | 2406 | if (wv->key != NULL) |
| @@ -2477,88 +2414,140 @@ add_menu_item (MenuHandle menu, widget_value *wv, int submenu, | |||
| 2477 | c2pstr (item_name); | 2414 | c2pstr (item_name); |
| 2478 | SetMenuItemText (menu, pos, item_name); | 2415 | SetMenuItemText (menu, pos, item_name); |
| 2479 | 2416 | ||
| 2480 | if (wv->enabled && !force_disable) | 2417 | if (wv->enabled) |
| 2481 | EnableItem (menu, pos); | 2418 | EnableItem (menu, pos); |
| 2482 | else | 2419 | else |
| 2483 | DisableItem (menu, pos); | 2420 | DisableItem (menu, pos); |
| 2484 | #endif /* ! TARGET_API_MAC_CARBON */ | 2421 | #endif /* ! TARGET_API_MAC_CARBON */ |
| 2485 | 2422 | ||
| 2486 | /* Draw radio buttons and tickboxes. */ | 2423 | /* Draw radio buttons and tickboxes. */ |
| 2487 | { | ||
| 2488 | if (wv->selected && (wv->button_type == BUTTON_TYPE_TOGGLE || | 2424 | if (wv->selected && (wv->button_type == BUTTON_TYPE_TOGGLE || |
| 2489 | wv->button_type == BUTTON_TYPE_RADIO)) | 2425 | wv->button_type == BUTTON_TYPE_RADIO)) |
| 2490 | SetItemMark (menu, pos, checkMark); | 2426 | SetItemMark (menu, pos, checkMark); |
| 2491 | else | 2427 | else |
| 2492 | SetItemMark (menu, pos, noMark); | 2428 | SetItemMark (menu, pos, noMark); |
| 2493 | } | ||
| 2494 | 2429 | ||
| 2495 | SetMenuItemRefCon (menu, pos, (UInt32) wv->call_data); | 2430 | SetMenuItemRefCon (menu, pos, (UInt32) wv->call_data); |
| 2496 | } | 2431 | } |
| 2497 | |||
| 2498 | if (submenu != 0) | ||
| 2499 | SetMenuItemHierarchicalID (menu, pos, submenu); | ||
| 2500 | } | 2432 | } |
| 2501 | 2433 | ||
| 2502 | /* Construct native Mac OS menubar based on widget_value tree. */ | 2434 | /* Construct native Mac OS menu based on widget_value tree. */ |
| 2503 | 2435 | ||
| 2504 | static void | 2436 | static int |
| 2505 | fill_submenu (MenuHandle menu, widget_value *wv) | 2437 | fill_menu (menu, wv, submenu_id) |
| 2438 | MenuHandle menu; | ||
| 2439 | widget_value *wv; | ||
| 2440 | int submenu_id; | ||
| 2506 | { | 2441 | { |
| 2507 | for ( ; wv != NULL; wv = wv->next) | 2442 | int pos; |
| 2508 | if (wv->contents) | ||
| 2509 | { | ||
| 2510 | int cur_submenu = submenu_id++; | ||
| 2511 | MenuHandle submenu = NewMenu (cur_submenu, "\pX"); | ||
| 2512 | fill_submenu (submenu, wv->contents); | ||
| 2513 | InsertMenu (submenu, -1); | ||
| 2514 | add_menu_item (menu, wv, cur_submenu, 0); | ||
| 2515 | } | ||
| 2516 | else | ||
| 2517 | add_menu_item (menu, wv, 0, 0); | ||
| 2518 | } | ||
| 2519 | 2443 | ||
| 2444 | for (pos = 1; wv != NULL; wv = wv->next, pos++) | ||
| 2445 | { | ||
| 2446 | add_menu_item (menu, pos, wv); | ||
| 2447 | if (wv->contents) | ||
| 2448 | { | ||
| 2449 | MenuHandle submenu = NewMenu (submenu_id, "\pX"); | ||
| 2520 | 2450 | ||
| 2521 | /* Construct native Mac OS menu based on widget_value tree. */ | 2451 | InsertMenu (submenu, -1); |
| 2452 | SetMenuItemHierarchicalID (menu, pos, submenu_id); | ||
| 2453 | submenu_id = fill_menu (submenu, wv->contents, submenu_id + 1); | ||
| 2454 | } | ||
| 2455 | } | ||
| 2522 | 2456 | ||
| 2523 | static void | 2457 | return submenu_id; |
| 2524 | fill_menu (MenuHandle menu, widget_value *wv) | ||
| 2525 | { | ||
| 2526 | for ( ; wv != NULL; wv = wv->next) | ||
| 2527 | if (wv->contents) | ||
| 2528 | { | ||
| 2529 | int cur_submenu = submenu_id++; | ||
| 2530 | MenuHandle submenu = NewMenu (cur_submenu, "\pX"); | ||
| 2531 | fill_submenu (submenu, wv->contents); | ||
| 2532 | InsertMenu (submenu, -1); | ||
| 2533 | add_menu_item (menu, wv, cur_submenu, 0); | ||
| 2534 | } | ||
| 2535 | else | ||
| 2536 | add_menu_item (menu, wv, 0, 0); | ||
| 2537 | } | 2458 | } |
| 2538 | 2459 | ||
| 2539 | /* Construct native Mac OS menubar based on widget_value tree. */ | 2460 | /* Construct native Mac OS menubar based on widget_value tree. */ |
| 2540 | 2461 | ||
| 2541 | static void | 2462 | static void |
| 2542 | fill_menubar (widget_value *wv) | 2463 | fill_menubar (wv, deep_p) |
| 2464 | widget_value *wv; | ||
| 2465 | int deep_p; | ||
| 2543 | { | 2466 | { |
| 2544 | int id; | 2467 | int id, submenu_id; |
| 2468 | MenuHandle menu; | ||
| 2469 | Str255 title; | ||
| 2470 | #if !TARGET_API_MAC_CARBON | ||
| 2471 | int title_changed_p = 0; | ||
| 2472 | #endif | ||
| 2545 | 2473 | ||
| 2546 | submenu_id = MIN_SUBMENU_ID; | 2474 | /* Clean up the menu bar when filled by the entire menu trees. */ |
| 2475 | if (deep_p) | ||
| 2476 | { | ||
| 2477 | dispose_menus (MIN_MENU_ID); | ||
| 2478 | dispose_menus (MIN_SUBMENU_ID); | ||
| 2479 | #if !TARGET_API_MAC_CARBON | ||
| 2480 | title_changed_p = 1; | ||
| 2481 | #endif | ||
| 2482 | } | ||
| 2547 | 2483 | ||
| 2484 | /* Fill menu bar titles and submenus. Reuse the existing menu bar | ||
| 2485 | titles as much as possible to minimize redraw (if !deep_p). */ | ||
| 2486 | submenu_id = MIN_SUBMENU_ID; | ||
| 2548 | for (id = MIN_MENU_ID; wv != NULL; wv = wv->next, id++) | 2487 | for (id = MIN_MENU_ID; wv != NULL; wv = wv->next, id++) |
| 2549 | { | 2488 | { |
| 2550 | MenuHandle menu; | ||
| 2551 | Str255 title; | ||
| 2552 | |||
| 2553 | strncpy (title, wv->name, 255); | 2489 | strncpy (title, wv->name, 255); |
| 2554 | title[255] = 0; | 2490 | title[255] = '\0'; |
| 2555 | c2pstr (title); | 2491 | c2pstr (title); |
| 2556 | menu = NewMenu (id, title); | 2492 | |
| 2493 | menu = GetMenuHandle (id); | ||
| 2494 | if (menu) | ||
| 2495 | { | ||
| 2496 | #if TARGET_API_MAC_CARBON | ||
| 2497 | Str255 old_title; | ||
| 2498 | |||
| 2499 | GetMenuTitle (menu, old_title); | ||
| 2500 | if (!EqualString (title, old_title, false, false)) | ||
| 2501 | SetMenuTitle (menu, title); | ||
| 2502 | #else /* !TARGET_API_MAC_CARBON */ | ||
| 2503 | if (!EqualString (title, (*menu)->menuData, false, false)) | ||
| 2504 | { | ||
| 2505 | DeleteMenu (id); | ||
| 2506 | DisposeMenu (menu); | ||
| 2507 | menu = NewMenu (id, title); | ||
| 2508 | InsertMenu (menu, GetMenuHandle (id + 1) ? id + 1 : 0); | ||
| 2509 | title_changed_p = 1; | ||
| 2510 | } | ||
| 2511 | #endif /* !TARGET_API_MAC_CARBON */ | ||
| 2512 | } | ||
| 2513 | else | ||
| 2514 | { | ||
| 2515 | menu = NewMenu (id, title); | ||
| 2516 | InsertMenu (menu, 0); | ||
| 2517 | #if !TARGET_API_MAC_CARBON | ||
| 2518 | title_changed_p = 1; | ||
| 2519 | #endif | ||
| 2520 | } | ||
| 2557 | 2521 | ||
| 2558 | if (wv->contents) | 2522 | if (wv->contents) |
| 2559 | fill_menu (menu, wv->contents); | 2523 | submenu_id = fill_menu (menu, wv->contents, submenu_id); |
| 2524 | } | ||
| 2560 | 2525 | ||
| 2561 | InsertMenu (menu, 0); | 2526 | if (GetMenuHandle (id)) |
| 2527 | { | ||
| 2528 | dispose_menus (id); | ||
| 2529 | #if !TARGET_API_MAC_CARBON | ||
| 2530 | title_changed_p = 1; | ||
| 2531 | #endif | ||
| 2532 | } | ||
| 2533 | |||
| 2534 | #if !TARGET_API_MAC_CARBON | ||
| 2535 | if (title_changed_p) | ||
| 2536 | InvalMenuBar (); | ||
| 2537 | #endif | ||
| 2538 | } | ||
| 2539 | |||
| 2540 | static void | ||
| 2541 | dispose_menus (id) | ||
| 2542 | int id; | ||
| 2543 | { | ||
| 2544 | MenuHandle menu; | ||
| 2545 | |||
| 2546 | while ((menu = GetMenuHandle (id)) != NULL) | ||
| 2547 | { | ||
| 2548 | DeleteMenu (id); | ||
| 2549 | DisposeMenu (menu); | ||
| 2550 | id++; | ||
| 2562 | } | 2551 | } |
| 2563 | } | 2552 | } |
| 2564 | 2553 | ||
diff --git a/src/macterm.c b/src/macterm.c index 8439a79d65c..78ea90bfc8b 100644 --- a/src/macterm.c +++ b/src/macterm.c | |||
| @@ -285,7 +285,7 @@ mac_begin_clip (region) | |||
| 285 | if (new_region == NULL) | 285 | if (new_region == NULL) |
| 286 | new_region = NewRgn (); | 286 | new_region = NewRgn (); |
| 287 | 287 | ||
| 288 | if (region) | 288 | if (region && !EmptyRgn (region)) |
| 289 | { | 289 | { |
| 290 | GetClip (saved_port_clip_region); | 290 | GetClip (saved_port_clip_region); |
| 291 | SectRgn (saved_port_clip_region, region, new_region); | 291 | SectRgn (saved_port_clip_region, region, new_region); |
| @@ -297,7 +297,7 @@ static void | |||
| 297 | mac_end_clip (region) | 297 | mac_end_clip (region) |
| 298 | RgnHandle region; | 298 | RgnHandle region; |
| 299 | { | 299 | { |
| 300 | if (region) | 300 | if (region && !EmptyRgn (region)) |
| 301 | SetClip (saved_port_clip_region); | 301 | SetClip (saved_port_clip_region); |
| 302 | } | 302 | } |
| 303 | 303 | ||
| @@ -684,27 +684,15 @@ mac_invert_rectangle (f, x, y, width, height) | |||
| 684 | 684 | ||
| 685 | 685 | ||
| 686 | static void | 686 | static void |
| 687 | mac_draw_string_common (f, gc, x, y, buf, nchars, mode, bytes_per_char) | 687 | mac_draw_string_common (f, gc, x, y, buf, nchars, bg_width, bytes_per_char) |
| 688 | struct frame *f; | 688 | struct frame *f; |
| 689 | GC gc; | 689 | GC gc; |
| 690 | int x, y; | 690 | int x, y; |
| 691 | char *buf; | 691 | char *buf; |
| 692 | int nchars, mode, bytes_per_char; | 692 | int nchars, bg_width, bytes_per_char; |
| 693 | { | 693 | { |
| 694 | #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1020 | ||
| 695 | UInt32 textFlags, savedFlags; | ||
| 696 | if (mac_use_core_graphics) { | ||
| 697 | textFlags = kQDUseCGTextRendering; | ||
| 698 | savedFlags = SwapQDTextFlags(textFlags); | ||
| 699 | } | ||
| 700 | #endif | ||
| 701 | |||
| 702 | SetPortWindowPort (FRAME_MAC_WINDOW (f)); | 694 | SetPortWindowPort (FRAME_MAC_WINDOW (f)); |
| 703 | 695 | ||
| 704 | RGBForeColor (GC_FORE_COLOR (gc)); | ||
| 705 | if (mode != srcOr) | ||
| 706 | RGBBackColor (GC_BACK_COLOR (gc)); | ||
| 707 | |||
| 708 | #if USE_ATSUI | 696 | #if USE_ATSUI |
| 709 | if (GC_FONT (gc)->mac_style) | 697 | if (GC_FONT (gc)->mac_style) |
| 710 | { | 698 | { |
| @@ -726,91 +714,144 @@ mac_draw_string_common (f, gc, x, y, buf, nchars, mode, bytes_per_char) | |||
| 726 | nchars, | 714 | nchars, |
| 727 | GC_FONT (gc)->mac_style, | 715 | GC_FONT (gc)->mac_style, |
| 728 | &text_layout); | 716 | &text_layout); |
| 729 | if (err == noErr) | 717 | if (err != noErr) |
| 730 | { | 718 | return; |
| 731 | #ifdef MAC_OSX | 719 | #ifdef MAC_OSX |
| 732 | if (!mac_use_core_graphics) | 720 | if (!mac_use_core_graphics) |
| 733 | { | 721 | { |
| 734 | #endif | 722 | #endif |
| 735 | mac_begin_clip (GC_CLIP_REGION (gc)); | 723 | mac_begin_clip (GC_CLIP_REGION (gc)); |
| 736 | MoveTo (x, y); | 724 | RGBForeColor (GC_FORE_COLOR (gc)); |
| 737 | ATSUDrawText (text_layout, | 725 | if (bg_width) |
| 738 | kATSUFromTextBeginning, kATSUToTextEnd, | 726 | { |
| 739 | kATSUUseGrafPortPenLoc, kATSUUseGrafPortPenLoc); | 727 | Rect r; |
| 740 | mac_end_clip (GC_CLIP_REGION (gc)); | 728 | |
| 741 | #ifdef MAC_OSX | 729 | SetRect (&r, x, y - FONT_BASE (GC_FONT (gc)), |
| 730 | x + bg_width, y + FONT_DESCENT (GC_FONT (gc))); | ||
| 731 | RGBBackColor (GC_BACK_COLOR (gc)); | ||
| 732 | EraseRect (&r); | ||
| 733 | RGBBackColor (GC_BACK_COLOR (FRAME_NORMAL_GC (f))); | ||
| 742 | } | 734 | } |
| 743 | else | 735 | MoveTo (x, y); |
| 736 | ATSUDrawText (text_layout, | ||
| 737 | kATSUFromTextBeginning, kATSUToTextEnd, | ||
| 738 | kATSUUseGrafPortPenLoc, kATSUUseGrafPortPenLoc); | ||
| 739 | mac_end_clip (GC_CLIP_REGION (gc)); | ||
| 740 | #ifdef MAC_OSX | ||
| 741 | } | ||
| 742 | else | ||
| 743 | { | ||
| 744 | CGrafPtr port; | ||
| 745 | CGContextRef context; | ||
| 746 | float port_height = FRAME_PIXEL_HEIGHT (f); | ||
| 747 | ATSUAttributeTag tags[] = {kATSUCGContextTag}; | ||
| 748 | ByteCount sizes[] = {sizeof (CGContextRef)}; | ||
| 749 | ATSUAttributeValuePtr values[] = {&context}; | ||
| 750 | |||
| 751 | GetPort (&port); | ||
| 752 | QDBeginCGContext (port, &context); | ||
| 753 | if (gc->n_clip_rects || bg_width) | ||
| 744 | { | 754 | { |
| 745 | CGrafPtr port; | 755 | CGContextTranslateCTM (context, 0, port_height); |
| 746 | CGContextRef context; | 756 | CGContextScaleCTM (context, 1, -1); |
| 747 | float port_height = FRAME_PIXEL_HEIGHT (f); | ||
| 748 | ATSUAttributeTag tags[] = {kATSUCGContextTag}; | ||
| 749 | ByteCount sizes[] = {sizeof (CGContextRef)}; | ||
| 750 | ATSUAttributeValuePtr values[] = {&context}; | ||
| 751 | |||
| 752 | GetPort (&port); | ||
| 753 | QDBeginCGContext (port, &context); | ||
| 754 | if (gc->n_clip_rects) | 757 | if (gc->n_clip_rects) |
| 758 | CGContextClipToRects (context, gc->clip_rects, | ||
| 759 | gc->n_clip_rects); | ||
| 760 | if (bg_width) | ||
| 755 | { | 761 | { |
| 756 | CGContextTranslateCTM (context, 0, port_height); | 762 | CGContextSetRGBFillColor |
| 757 | CGContextScaleCTM (context, 1, -1); | 763 | (context, |
| 758 | CGContextClipToRects (context, gc->clip_rects, | 764 | RED_FROM_ULONG (gc->xgcv.background) / 255.0f, |
| 759 | gc->n_clip_rects); | 765 | GREEN_FROM_ULONG (gc->xgcv.background) / 255.0f, |
| 760 | CGContextScaleCTM (context, 1, -1); | 766 | BLUE_FROM_ULONG (gc->xgcv.background) / 255.0f, |
| 761 | CGContextTranslateCTM (context, 0, -port_height); | 767 | 1.0); |
| 768 | CGContextFillRect | ||
| 769 | (context, | ||
| 770 | CGRectMake (x, y - FONT_BASE (GC_FONT (gc)), | ||
| 771 | bg_width, FONT_HEIGHT (GC_FONT (gc)))); | ||
| 762 | } | 772 | } |
| 763 | CGContextSetRGBFillColor | 773 | CGContextScaleCTM (context, 1, -1); |
| 764 | (context, | 774 | CGContextTranslateCTM (context, 0, -port_height); |
| 765 | RED_FROM_ULONG (gc->xgcv.foreground) / 255.0, | 775 | } |
| 766 | GREEN_FROM_ULONG (gc->xgcv.foreground) / 255.0, | 776 | CGContextSetRGBFillColor |
| 767 | BLUE_FROM_ULONG (gc->xgcv.foreground) / 255.0, | 777 | (context, |
| 768 | 1.0); | 778 | RED_FROM_ULONG (gc->xgcv.foreground) / 255.0f, |
| 769 | err = ATSUSetLayoutControls (text_layout, | 779 | GREEN_FROM_ULONG (gc->xgcv.foreground) / 255.0f, |
| 770 | sizeof (tags) / sizeof (tags[0]), | 780 | BLUE_FROM_ULONG (gc->xgcv.foreground) / 255.0f, |
| 771 | tags, sizes, values); | 781 | 1.0); |
| 772 | if (err == noErr) | 782 | err = ATSUSetLayoutControls (text_layout, |
| 773 | ATSUDrawText (text_layout, | ||
| 774 | kATSUFromTextBeginning, kATSUToTextEnd, | ||
| 775 | Long2Fix (x), Long2Fix (port_height - y)); | ||
| 776 | CGContextSynchronize (context); | ||
| 777 | QDEndCGContext (port, &context); | ||
| 778 | #if 0 | ||
| 779 | /* This doesn't work on Mac OS X 10.1. */ | ||
| 780 | ATSUClearLayoutControls (text_layout, | ||
| 781 | sizeof (tags) / sizeof (tags[0]), | 783 | sizeof (tags) / sizeof (tags[0]), |
| 782 | tags); | 784 | tags, sizes, values); |
| 785 | if (err == noErr) | ||
| 786 | ATSUDrawText (text_layout, | ||
| 787 | kATSUFromTextBeginning, kATSUToTextEnd, | ||
| 788 | Long2Fix (x), Long2Fix (port_height - y)); | ||
| 789 | CGContextSynchronize (context); | ||
| 790 | QDEndCGContext (port, &context); | ||
| 791 | #if 0 | ||
| 792 | /* This doesn't work on Mac OS X 10.1. */ | ||
| 793 | ATSUClearLayoutControls (text_layout, | ||
| 794 | sizeof (tags) / sizeof (tags[0]), tags); | ||
| 783 | #else | 795 | #else |
| 784 | ATSUSetLayoutControls (text_layout, | 796 | ATSUSetLayoutControls (text_layout, |
| 785 | sizeof (tags) / sizeof (tags[0]), | 797 | sizeof (tags) / sizeof (tags[0]), |
| 786 | tags, sizes, values); | 798 | tags, sizes, values); |
| 787 | #endif | ||
| 788 | } | ||
| 789 | #endif | 799 | #endif |
| 790 | } | 800 | } |
| 801 | #endif /* MAC_OSX */ | ||
| 791 | } | 802 | } |
| 792 | else | 803 | else |
| 804 | #endif /* USE_ATSUI */ | ||
| 793 | { | 805 | { |
| 806 | #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1020 | ||
| 807 | UInt32 savedFlags; | ||
| 808 | |||
| 809 | if (mac_use_core_graphics) | ||
| 810 | savedFlags = SwapQDTextFlags (kQDUseCGTextRendering); | ||
| 794 | #endif | 811 | #endif |
| 795 | TextFont (GC_FONT (gc)->mac_fontnum); | 812 | mac_begin_clip (GC_CLIP_REGION (gc)); |
| 796 | TextSize (GC_FONT (gc)->mac_fontsize); | 813 | RGBForeColor (GC_FORE_COLOR (gc)); |
| 797 | TextFace (GC_FONT (gc)->mac_fontface); | 814 | #ifdef MAC_OS8 |
| 798 | TextMode (mode); | 815 | if (bg_width) |
| 816 | { | ||
| 817 | RGBBackColor (GC_BACK_COLOR (gc)); | ||
| 818 | TextMode (srcCopy); | ||
| 819 | } | ||
| 820 | else | ||
| 821 | TextMode (srcOr); | ||
| 822 | #else | ||
| 823 | /* We prefer not to use srcCopy text transfer mode on Mac OS X | ||
| 824 | because: | ||
| 825 | - Screen is double-buffered. (In srcCopy mode, a text is | ||
| 826 | drawn into an offscreen graphics world first. So | ||
| 827 | performance gain cannot be expected.) | ||
| 828 | - It lowers rendering quality. | ||
| 829 | - Some fonts leave garbage on cursor movement. */ | ||
| 830 | if (bg_width) | ||
| 831 | { | ||
| 832 | Rect r; | ||
| 799 | 833 | ||
| 800 | mac_begin_clip (GC_CLIP_REGION (gc)); | 834 | RGBBackColor (GC_BACK_COLOR (gc)); |
| 801 | MoveTo (x, y); | 835 | SetRect (&r, x, y - FONT_BASE (GC_FONT (gc)), |
| 802 | DrawText (buf, 0, nchars * bytes_per_char); | 836 | x + bg_width, y + FONT_DESCENT (GC_FONT (gc))); |
| 803 | mac_end_clip (GC_CLIP_REGION (gc)); | 837 | EraseRect (&r); |
| 804 | #if USE_ATSUI | 838 | } |
| 805 | } | 839 | TextMode (srcOr); |
| 806 | #endif | 840 | #endif |
| 841 | TextFont (GC_FONT (gc)->mac_fontnum); | ||
| 842 | TextSize (GC_FONT (gc)->mac_fontsize); | ||
| 843 | TextFace (GC_FONT (gc)->mac_fontface); | ||
| 844 | MoveTo (x, y); | ||
| 845 | DrawText (buf, 0, nchars * bytes_per_char); | ||
| 846 | if (bg_width) | ||
| 847 | RGBBackColor (GC_BACK_COLOR (FRAME_NORMAL_GC (f))); | ||
| 848 | mac_end_clip (GC_CLIP_REGION (gc)); | ||
| 807 | 849 | ||
| 808 | if (mode != srcOr) | ||
| 809 | RGBBackColor (GC_BACK_COLOR (FRAME_NORMAL_GC (f))); | ||
| 810 | #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1020 | 850 | #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1020 |
| 811 | if (mac_use_core_graphics) | 851 | if (mac_use_core_graphics) |
| 812 | SwapQDTextFlags(savedFlags); | 852 | SwapQDTextFlags(savedFlags); |
| 813 | #endif | 853 | #endif |
| 854 | } | ||
| 814 | } | 855 | } |
| 815 | 856 | ||
| 816 | 857 | ||
| @@ -824,7 +865,7 @@ mac_draw_string (f, gc, x, y, buf, nchars) | |||
| 824 | char *buf; | 865 | char *buf; |
| 825 | int nchars; | 866 | int nchars; |
| 826 | { | 867 | { |
| 827 | mac_draw_string_common (f, gc, x, y, buf, nchars, srcOr, 1); | 868 | mac_draw_string_common (f, gc, x, y, buf, nchars, 0, 1); |
| 828 | } | 869 | } |
| 829 | 870 | ||
| 830 | 871 | ||
| @@ -838,35 +879,35 @@ mac_draw_string_16 (f, gc, x, y, buf, nchars) | |||
| 838 | XChar2b *buf; | 879 | XChar2b *buf; |
| 839 | int nchars; | 880 | int nchars; |
| 840 | { | 881 | { |
| 841 | mac_draw_string_common (f, gc, x, y, (char *) buf, nchars, srcOr, 2); | 882 | mac_draw_string_common (f, gc, x, y, (char *) buf, nchars, 0, 2); |
| 842 | } | 883 | } |
| 843 | 884 | ||
| 844 | 885 | ||
| 845 | /* Mac replacement for XDrawImageString. */ | 886 | /* Mac replacement for XDrawImageString. */ |
| 846 | 887 | ||
| 847 | static void | 888 | static void |
| 848 | mac_draw_image_string (f, gc, x, y, buf, nchars) | 889 | mac_draw_image_string (f, gc, x, y, buf, nchars, bg_width) |
| 849 | struct frame *f; | 890 | struct frame *f; |
| 850 | GC gc; | 891 | GC gc; |
| 851 | int x, y; | 892 | int x, y; |
| 852 | char *buf; | 893 | char *buf; |
| 853 | int nchars; | 894 | int nchars, bg_width; |
| 854 | { | 895 | { |
| 855 | mac_draw_string_common (f, gc, x, y, buf, nchars, srcCopy, 1); | 896 | mac_draw_string_common (f, gc, x, y, buf, nchars, bg_width, 1); |
| 856 | } | 897 | } |
| 857 | 898 | ||
| 858 | 899 | ||
| 859 | /* Mac replacement for XDrawString16. */ | 900 | /* Mac replacement for XDrawString16. */ |
| 860 | 901 | ||
| 861 | static void | 902 | static void |
| 862 | mac_draw_image_string_16 (f, gc, x, y, buf, nchars) | 903 | mac_draw_image_string_16 (f, gc, x, y, buf, nchars, bg_width) |
| 863 | struct frame *f; | 904 | struct frame *f; |
| 864 | GC gc; | 905 | GC gc; |
| 865 | int x, y; | 906 | int x, y; |
| 866 | XChar2b *buf; | 907 | XChar2b *buf; |
| 867 | int nchars; | 908 | int nchars, bg_width; |
| 868 | { | 909 | { |
| 869 | mac_draw_string_common (f, gc, x, y, (char *) buf, nchars, srcCopy, 2); | 910 | mac_draw_string_common (f, gc, x, y, (char *) buf, nchars, bg_width, 2); |
| 870 | } | 911 | } |
| 871 | 912 | ||
| 872 | 913 | ||
| @@ -1040,12 +1081,12 @@ init_cg_text_anti_aliasing_threshold () | |||
| 1040 | } | 1081 | } |
| 1041 | 1082 | ||
| 1042 | static int | 1083 | static int |
| 1043 | mac_draw_string_cg (f, gc, x, y, buf, nchars) | 1084 | mac_draw_image_string_cg (f, gc, x, y, buf, nchars, bg_width) |
| 1044 | struct frame *f; | 1085 | struct frame *f; |
| 1045 | GC gc; | 1086 | GC gc; |
| 1046 | int x, y; | 1087 | int x, y; |
| 1047 | XChar2b *buf; | 1088 | XChar2b *buf; |
| 1048 | int nchars; | 1089 | int nchars, bg_width; |
| 1049 | { | 1090 | { |
| 1050 | CGrafPtr port; | 1091 | CGrafPtr port; |
| 1051 | float port_height, gx, gy; | 1092 | float port_height, gx, gy; |
| @@ -1062,7 +1103,9 @@ mac_draw_string_cg (f, gc, x, y, buf, nchars) | |||
| 1062 | gx = x; | 1103 | gx = x; |
| 1063 | gy = port_height - y; | 1104 | gy = port_height - y; |
| 1064 | glyphs = (CGGlyph *)buf; | 1105 | glyphs = (CGGlyph *)buf; |
| 1065 | advances = xmalloc (sizeof (CGSize) * nchars); | 1106 | advances = alloca (sizeof (CGSize) * nchars); |
| 1107 | if (advances == NULL) | ||
| 1108 | return 0; | ||
| 1066 | for (i = 0; i < nchars; i++) | 1109 | for (i = 0; i < nchars; i++) |
| 1067 | { | 1110 | { |
| 1068 | XCharStruct *pcm = mac_per_char_metric (GC_FONT (gc), buf, 0); | 1111 | XCharStruct *pcm = mac_per_char_metric (GC_FONT (gc), buf, 0); |
| @@ -1074,18 +1117,32 @@ mac_draw_string_cg (f, gc, x, y, buf, nchars) | |||
| 1074 | } | 1117 | } |
| 1075 | 1118 | ||
| 1076 | QDBeginCGContext (port, &context); | 1119 | QDBeginCGContext (port, &context); |
| 1077 | if (gc->n_clip_rects) | 1120 | if (gc->n_clip_rects || bg_width) |
| 1078 | { | 1121 | { |
| 1079 | CGContextTranslateCTM (context, 0, port_height); | 1122 | CGContextTranslateCTM (context, 0, port_height); |
| 1080 | CGContextScaleCTM (context, 1, -1); | 1123 | CGContextScaleCTM (context, 1, -1); |
| 1081 | CGContextClipToRects (context, gc->clip_rects, gc->n_clip_rects); | 1124 | if (gc->n_clip_rects) |
| 1125 | CGContextClipToRects (context, gc->clip_rects, gc->n_clip_rects); | ||
| 1126 | if (bg_width) | ||
| 1127 | { | ||
| 1128 | CGContextSetRGBFillColor | ||
| 1129 | (context, | ||
| 1130 | RED_FROM_ULONG (gc->xgcv.background) / 255.0f, | ||
| 1131 | GREEN_FROM_ULONG (gc->xgcv.background) / 255.0f, | ||
| 1132 | BLUE_FROM_ULONG (gc->xgcv.background) / 255.0f, | ||
| 1133 | 1.0); | ||
| 1134 | CGContextFillRect | ||
| 1135 | (context, | ||
| 1136 | CGRectMake (gx, y - FONT_BASE (GC_FONT (gc)), | ||
| 1137 | bg_width, FONT_HEIGHT (GC_FONT (gc)))); | ||
| 1138 | } | ||
| 1082 | CGContextScaleCTM (context, 1, -1); | 1139 | CGContextScaleCTM (context, 1, -1); |
| 1083 | CGContextTranslateCTM (context, 0, -port_height); | 1140 | CGContextTranslateCTM (context, 0, -port_height); |
| 1084 | } | 1141 | } |
| 1085 | CGContextSetRGBFillColor (context, | 1142 | CGContextSetRGBFillColor (context, |
| 1086 | RED_FROM_ULONG (gc->xgcv.foreground) / 255.0, | 1143 | RED_FROM_ULONG (gc->xgcv.foreground) / 255.0f, |
| 1087 | GREEN_FROM_ULONG (gc->xgcv.foreground) / 255.0, | 1144 | GREEN_FROM_ULONG (gc->xgcv.foreground) / 255.0f, |
| 1088 | BLUE_FROM_ULONG (gc->xgcv.foreground) / 255.0, | 1145 | BLUE_FROM_ULONG (gc->xgcv.foreground) / 255.0f, |
| 1089 | 1.0); | 1146 | 1.0); |
| 1090 | CGContextSetFont (context, GC_FONT (gc)->cg_font); | 1147 | CGContextSetFont (context, GC_FONT (gc)->cg_font); |
| 1091 | CGContextSetFontSize (context, GC_FONT (gc)->mac_fontsize); | 1148 | CGContextSetFontSize (context, GC_FONT (gc)->mac_fontsize); |
| @@ -1104,8 +1161,6 @@ mac_draw_string_cg (f, gc, x, y, buf, nchars) | |||
| 1104 | CGContextSynchronize (context); | 1161 | CGContextSynchronize (context); |
| 1105 | QDEndCGContext (port, &context); | 1162 | QDEndCGContext (port, &context); |
| 1106 | 1163 | ||
| 1107 | xfree (advances); | ||
| 1108 | |||
| 1109 | return 1; | 1164 | return 1; |
| 1110 | } | 1165 | } |
| 1111 | #endif | 1166 | #endif |
| @@ -1377,10 +1432,7 @@ mac_set_clip_rectangles (display, gc, rectangles, n) | |||
| 1377 | if (n == 0) | 1432 | if (n == 0) |
| 1378 | { | 1433 | { |
| 1379 | if (gc->clip_region) | 1434 | if (gc->clip_region) |
| 1380 | { | 1435 | SetEmptyRgn (gc->clip_region); |
| 1381 | DisposeRgn (gc->clip_region); | ||
| 1382 | gc->clip_region = NULL; | ||
| 1383 | } | ||
| 1384 | } | 1436 | } |
| 1385 | else | 1437 | else |
| 1386 | { | 1438 | { |
| @@ -2324,14 +2376,6 @@ x_clear_glyph_string_rect (s, x, y, w, h) | |||
| 2324 | } | 2376 | } |
| 2325 | 2377 | ||
| 2326 | 2378 | ||
| 2327 | /* We prefer not to use XDrawImageString (srcCopy text transfer mode) | ||
| 2328 | on Mac OS X because: | ||
| 2329 | - Screen is double-buffered. (In srcCopy mode, a text is drawn | ||
| 2330 | into an offscreen graphics world first. So performance gain | ||
| 2331 | cannot be expected.) | ||
| 2332 | - It lowers rendering quality. | ||
| 2333 | - Some fonts leave garbage on cursor movement. */ | ||
| 2334 | |||
| 2335 | /* Draw the background of glyph_string S. If S->background_filled_p | 2379 | /* Draw the background of glyph_string S. If S->background_filled_p |
| 2336 | is non-zero don't draw it. FORCE_P non-zero means draw the | 2380 | is non-zero don't draw it. FORCE_P non-zero means draw the |
| 2337 | background even if it wouldn't be drawn normally. This is used | 2381 | background even if it wouldn't be drawn normally. This is used |
| @@ -2363,12 +2407,10 @@ x_draw_glyph_string_background (s, force_p) | |||
| 2363 | } | 2407 | } |
| 2364 | else | 2408 | else |
| 2365 | #endif | 2409 | #endif |
| 2366 | #if defined (MAC_OS8) && !USE_ATSUI | ||
| 2367 | if (FONT_HEIGHT (s->font) < s->height - 2 * box_line_width | 2410 | if (FONT_HEIGHT (s->font) < s->height - 2 * box_line_width |
| 2368 | || s->font_not_found_p | 2411 | || s->font_not_found_p |
| 2369 | || s->extends_to_end_of_line_p | 2412 | || s->extends_to_end_of_line_p |
| 2370 | || force_p) | 2413 | || force_p) |
| 2371 | #endif | ||
| 2372 | { | 2414 | { |
| 2373 | x_clear_glyph_string_rect (s, s->x, s->y + box_line_width, | 2415 | x_clear_glyph_string_rect (s, s->x, s->y + box_line_width, |
| 2374 | s->background_width, | 2416 | s->background_width, |
| @@ -2385,7 +2427,7 @@ static void | |||
| 2385 | x_draw_glyph_string_foreground (s) | 2427 | x_draw_glyph_string_foreground (s) |
| 2386 | struct glyph_string *s; | 2428 | struct glyph_string *s; |
| 2387 | { | 2429 | { |
| 2388 | int i, x; | 2430 | int i, x, bg_width; |
| 2389 | 2431 | ||
| 2390 | /* If first glyph of S has a left box line, start drawing the text | 2432 | /* If first glyph of S has a left box line, start drawing the text |
| 2391 | of S to the right of that box line. */ | 2433 | of S to the right of that box line. */ |
| @@ -2424,7 +2466,6 @@ x_draw_glyph_string_foreground (s) | |||
| 2424 | for (i = 0; i < s->nchars; ++i) | 2466 | for (i = 0; i < s->nchars; ++i) |
| 2425 | char1b[i] = s->char2b[i].byte2; | 2467 | char1b[i] = s->char2b[i].byte2; |
| 2426 | 2468 | ||
| 2427 | #if defined (MAC_OS8) && !USE_ATSUI | ||
| 2428 | /* Draw text with XDrawString if background has already been | 2469 | /* Draw text with XDrawString if background has already been |
| 2429 | filled. Otherwise, use XDrawImageString. (Note that | 2470 | filled. Otherwise, use XDrawImageString. (Note that |
| 2430 | XDrawImageString is usually faster than XDrawString.) Always | 2471 | XDrawImageString is usually faster than XDrawString.) Always |
| @@ -2432,38 +2473,27 @@ x_draw_glyph_string_foreground (s) | |||
| 2432 | no chance that characters under a box cursor are invisible. */ | 2473 | no chance that characters under a box cursor are invisible. */ |
| 2433 | if (s->for_overlaps | 2474 | if (s->for_overlaps |
| 2434 | || (s->background_filled_p && s->hl != DRAW_CURSOR)) | 2475 | || (s->background_filled_p && s->hl != DRAW_CURSOR)) |
| 2435 | #endif | 2476 | bg_width = 0; /* Corresponds to XDrawString. */ |
| 2436 | { | 2477 | else |
| 2437 | /* Draw characters with 16-bit or 8-bit functions. */ | 2478 | bg_width = s->background_width; /* Corresponds to XDrawImageString. */ |
| 2438 | if (s->two_byte_p | 2479 | |
| 2480 | if (s->two_byte_p | ||
| 2439 | #if USE_ATSUI | 2481 | #if USE_ATSUI |
| 2440 | || GC_FONT (s->gc)->mac_style | 2482 | || GC_FONT (s->gc)->mac_style |
| 2441 | #endif | 2483 | #endif |
| 2442 | ) | 2484 | ) |
| 2443 | #if USE_CG_TEXT_DRAWING | 2485 | #if USE_CG_TEXT_DRAWING |
| 2444 | if (!s->two_byte_p | 2486 | if (!s->two_byte_p |
| 2445 | && mac_draw_string_cg (s->f, s->gc, x, s->ybase - boff, | 2487 | && mac_draw_image_string_cg (s->f, s->gc, x, s->ybase - boff, |
| 2446 | s->char2b, s->nchars)) | 2488 | s->char2b, s->nchars, bg_width)) |
| 2447 | ; | 2489 | ; |
| 2448 | else | 2490 | else |
| 2449 | #endif | 2491 | #endif |
| 2450 | mac_draw_string_16 (s->f, s->gc, x, s->ybase - boff, | 2492 | mac_draw_image_string_16 (s->f, s->gc, x, s->ybase - boff, |
| 2451 | s->char2b, s->nchars); | 2493 | s->char2b, s->nchars, bg_width); |
| 2452 | else | ||
| 2453 | mac_draw_string (s->f, s->gc, x, s->ybase - boff, | ||
| 2454 | char1b, s->nchars); | ||
| 2455 | } | ||
| 2456 | #if defined (MAC_OS8) && !USE_ATSUI | ||
| 2457 | else | 2494 | else |
| 2458 | { | 2495 | mac_draw_image_string (s->f, s->gc, x, s->ybase - boff, |
| 2459 | if (s->two_byte_p) | 2496 | char1b, s->nchars, bg_width); |
| 2460 | mac_draw_image_string_16 (s->f, s->gc, x, s->ybase - boff, | ||
| 2461 | s->char2b, s->nchars); | ||
| 2462 | else | ||
| 2463 | mac_draw_image_string (s->f, s->gc, x, s->ybase - boff, | ||
| 2464 | char1b, s->nchars); | ||
| 2465 | } | ||
| 2466 | #endif | ||
| 2467 | } | 2497 | } |
| 2468 | } | 2498 | } |
| 2469 | 2499 | ||
| @@ -7856,9 +7886,13 @@ XLoadQueryFont (Display *dpy, char *fontname) | |||
| 7856 | #if !defined (MAC_OS8) || USE_ATSUI | 7886 | #if !defined (MAC_OS8) || USE_ATSUI |
| 7857 | /* AppKit and WebKit do some adjustment to the heights of Courier, | 7887 | /* AppKit and WebKit do some adjustment to the heights of Courier, |
| 7858 | Helvetica, and Times. This only works on the environments where | 7888 | Helvetica, and Times. This only works on the environments where |
| 7859 | the XDrawImageString counterpart is never used. */ | 7889 | srcCopy text transfer mode is never used. */ |
| 7860 | if (strcmp (family, "courier") == 0 || strcmp (family, "helvetica") == 0 | 7890 | if ( |
| 7861 | || strcmp (family, "times") == 0) | 7891 | #ifdef MAC_OS8 /* implies USE_ATSUI */ |
| 7892 | font->mac_style && | ||
| 7893 | #endif | ||
| 7894 | (strcmp (family, "courier") == 0 || strcmp (family, "helvetica") == 0 | ||
| 7895 | || strcmp (family, "times") == 0)) | ||
| 7862 | font->ascent += (font->ascent + font->descent) * .15 + 0.5; | 7896 | font->ascent += (font->ascent + font->descent) * .15 + 0.5; |
| 7863 | #endif | 7897 | #endif |
| 7864 | 7898 | ||
diff --git a/src/puresize.h b/src/puresize.h index da81e09a345..93dac70c123 100644 --- a/src/puresize.h +++ b/src/puresize.h | |||
| @@ -43,7 +43,7 @@ Boston, MA 02110-1301, USA. */ | |||
| 43 | #endif | 43 | #endif |
| 44 | 44 | ||
| 45 | #ifndef BASE_PURESIZE | 45 | #ifndef BASE_PURESIZE |
| 46 | #define BASE_PURESIZE (1190000 + SYSTEM_PURESIZE_EXTRA + SITELOAD_PURESIZE_EXTRA) | 46 | #define BASE_PURESIZE (1200000 + SYSTEM_PURESIZE_EXTRA + SITELOAD_PURESIZE_EXTRA) |
| 47 | #endif | 47 | #endif |
| 48 | 48 | ||
| 49 | /* Increase BASE_PURESIZE by a ratio depending on the machine's word size. */ | 49 | /* Increase BASE_PURESIZE by a ratio depending on the machine's word size. */ |
diff --git a/src/regex.c b/src/regex.c index 3548ad3c048..48baacd81e2 100644 --- a/src/regex.c +++ b/src/regex.c | |||
| @@ -197,6 +197,51 @@ char *malloc (); | |||
| 197 | char *realloc (); | 197 | char *realloc (); |
| 198 | # endif | 198 | # endif |
| 199 | 199 | ||
| 200 | /* When used in Emacs's lib-src, we need xmalloc and xrealloc. */ | ||
| 201 | |||
| 202 | void * | ||
| 203 | xmalloc (size) | ||
| 204 | size_t size; | ||
| 205 | { | ||
| 206 | register void *val; | ||
| 207 | val = (void *) malloc (size); | ||
| 208 | if (!val && size) | ||
| 209 | { | ||
| 210 | write (2, "virtual memory exhausted\n", 25); | ||
| 211 | exit (1); | ||
| 212 | } | ||
| 213 | return val; | ||
| 214 | } | ||
| 215 | |||
| 216 | void * | ||
| 217 | xrealloc (block, size) | ||
| 218 | void *block; | ||
| 219 | size_t size; | ||
| 220 | { | ||
| 221 | register void *val; | ||
| 222 | /* We must call malloc explicitly when BLOCK is 0, since some | ||
| 223 | reallocs don't do this. */ | ||
| 224 | if (! block) | ||
| 225 | val = (void *) malloc (size); | ||
| 226 | else | ||
| 227 | val = (void *) realloc (block, size); | ||
| 228 | if (!val && size) | ||
| 229 | { | ||
| 230 | write (2, "virtual memory exhausted\n", 25); | ||
| 231 | exit (1); | ||
| 232 | } | ||
| 233 | return val; | ||
| 234 | } | ||
| 235 | |||
| 236 | # ifdef malloc | ||
| 237 | # undef malloc | ||
| 238 | # endif | ||
| 239 | # define malloc xmalloc | ||
| 240 | # ifdef realloc | ||
| 241 | # undef realloc | ||
| 242 | # endif | ||
| 243 | # define realloc xrealloc | ||
| 244 | |||
| 200 | /* When used in Emacs's lib-src, we need to get bzero and bcopy somehow. | 245 | /* When used in Emacs's lib-src, we need to get bzero and bcopy somehow. |
| 201 | If nothing else has been done, use the method below. */ | 246 | If nothing else has been done, use the method below. */ |
| 202 | # ifdef INHIBIT_STRING_HEADER | 247 | # ifdef INHIBIT_STRING_HEADER |
diff --git a/src/vm-limit.c b/src/vm-limit.c index fb127b27b74..48d13c323ae 100644 --- a/src/vm-limit.c +++ b/src/vm-limit.c | |||
| @@ -33,6 +33,10 @@ typedef void *POINTER; | |||
| 33 | 33 | ||
| 34 | #include "mem-limits.h" | 34 | #include "mem-limits.h" |
| 35 | 35 | ||
| 36 | #ifdef HAVE_GETRLIMIT | ||
| 37 | #include <sys/resource.h> | ||
| 38 | #endif | ||
| 39 | |||
| 36 | /* | 40 | /* |
| 37 | Level number of warnings already issued. | 41 | Level number of warnings already issued. |
| 38 | 0 -- no warnings issued. | 42 | 0 -- no warnings issued. |
| @@ -61,6 +65,19 @@ check_memory_limits () | |||
| 61 | unsigned long five_percent; | 65 | unsigned long five_percent; |
| 62 | unsigned long data_size; | 66 | unsigned long data_size; |
| 63 | 67 | ||
| 68 | #ifdef HAVE_GETRLIMIT | ||
| 69 | struct rlimit { | ||
| 70 | rlim_t rlim_cur; | ||
| 71 | rlim_t rlim_max; | ||
| 72 | } rlimit; | ||
| 73 | |||
| 74 | getrlimit (RLIMIT_DATA, &rlimit); | ||
| 75 | |||
| 76 | five_percent = rlimit.rlim_max / 20; | ||
| 77 | data_size = rlimit.rlim_cur; | ||
| 78 | |||
| 79 | #else /* not HAVE_GETRLIMIT */ | ||
| 80 | |||
| 64 | if (lim_data == 0) | 81 | if (lim_data == 0) |
| 65 | get_lim_data (); | 82 | get_lim_data (); |
| 66 | five_percent = lim_data / 20; | 83 | five_percent = lim_data / 20; |
| @@ -74,6 +91,8 @@ check_memory_limits () | |||
| 74 | cp = (char *) (*__morecore) (0); | 91 | cp = (char *) (*__morecore) (0); |
| 75 | data_size = (char *) cp - (char *) data_space_start; | 92 | data_size = (char *) cp - (char *) data_space_start; |
| 76 | 93 | ||
| 94 | #endif /* not HAVE_GETRLIMIT */ | ||
| 95 | |||
| 77 | if (warn_function) | 96 | if (warn_function) |
| 78 | switch (warnlevel) | 97 | switch (warnlevel) |
| 79 | { | 98 | { |
diff --git a/src/window.c b/src/window.c index c21e95cbef0..bd5a393b599 100644 --- a/src/window.c +++ b/src/window.c | |||
| @@ -2568,7 +2568,10 @@ window_min_size_1 (w, width_p) | |||
| 2568 | else | 2568 | else |
| 2569 | { | 2569 | { |
| 2570 | if (width_p) | 2570 | if (width_p) |
| 2571 | size = window_min_width; | 2571 | size = max (window_min_width, |
| 2572 | (MIN_SAFE_WINDOW_WIDTH | ||
| 2573 | + WINDOW_FRINGE_COLS (w) | ||
| 2574 | + WINDOW_SCROLL_BAR_COLS (w))); | ||
| 2572 | else | 2575 | else |
| 2573 | { | 2576 | { |
| 2574 | if (MINI_WINDOW_P (w) | 2577 | if (MINI_WINDOW_P (w) |
| @@ -4286,7 +4289,7 @@ adjust_window_trailing_edge (window, delta, horiz_flag) | |||
| 4286 | { | 4289 | { |
| 4287 | /* This may happen for the minibuffer. In that case | 4290 | /* This may happen for the minibuffer. In that case |
| 4288 | the window_deletion_count check below does not work. */ | 4291 | the window_deletion_count check below does not work. */ |
| 4289 | if (XINT (CURSIZE (p->next)) - delta <= 0) | 4292 | if (XINT (CURSIZE (p->next)) - delta <= 0) |
| 4290 | { | 4293 | { |
| 4291 | Fset_window_configuration (old_config); | 4294 | Fset_window_configuration (old_config); |
| 4292 | error ("Cannot adjust window size as specified"); | 4295 | error ("Cannot adjust window size as specified"); |
| @@ -6600,7 +6603,8 @@ this is automatically adjusted to a multiple of the frame column width. | |||
| 6600 | Third parameter VERTICAL-TYPE specifies the type of the vertical scroll | 6603 | Third parameter VERTICAL-TYPE specifies the type of the vertical scroll |
| 6601 | bar: left, right, or nil. | 6604 | bar: left, right, or nil. |
| 6602 | If WIDTH is nil, use the frame's scroll-bar width. | 6605 | If WIDTH is nil, use the frame's scroll-bar width. |
| 6603 | If TYPE is t, use the frame's scroll-bar type. */) | 6606 | If VERTICAL-TYPE is t, use the frame's scroll-bar type. |
| 6607 | Fourth parameter HORIZONTAL-TYPE is currently unused. */) | ||
| 6604 | (window, width, vertical_type, horizontal_type) | 6608 | (window, width, vertical_type, horizontal_type) |
| 6605 | Lisp_Object window, width, vertical_type, horizontal_type; | 6609 | Lisp_Object window, width, vertical_type, horizontal_type; |
| 6606 | { | 6610 | { |
diff --git a/src/xdisp.c b/src/xdisp.c index ff2c7d299e5..8c19b0976c8 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -9158,14 +9158,15 @@ update_menu_bar (f, save_match_data) | |||
| 9158 | /* Redisplay the menu bar in case we changed it. */ | 9158 | /* Redisplay the menu bar in case we changed it. */ |
| 9159 | #if defined (USE_X_TOOLKIT) || defined (HAVE_NTGUI) || defined (MAC_OS) \ | 9159 | #if defined (USE_X_TOOLKIT) || defined (HAVE_NTGUI) || defined (MAC_OS) \ |
| 9160 | || defined (USE_GTK) | 9160 | || defined (USE_GTK) |
| 9161 | if (FRAME_WINDOW_P (f) | 9161 | if (FRAME_WINDOW_P (f)) |
| 9162 | #if defined (MAC_OS) | 9162 | { |
| 9163 | /* All frames on Mac OS share the same menubar. So only the | 9163 | #ifdef MAC_OS |
| 9164 | selected frame should be allowed to set it. */ | 9164 | /* All frames on Mac OS share the same menubar. So only |
| 9165 | && f == SELECTED_FRAME () | 9165 | the selected frame should be allowed to set it. */ |
| 9166 | if (f == SELECTED_FRAME ()) | ||
| 9166 | #endif | 9167 | #endif |
| 9167 | ) | 9168 | set_frame_menubar (f, 0, 0); |
| 9168 | set_frame_menubar (f, 0, 0); | 9169 | } |
| 9169 | else | 9170 | else |
| 9170 | /* On a terminal screen, the menu bar is an ordinary screen | 9171 | /* On a terminal screen, the menu bar is an ordinary screen |
| 9171 | line, and this makes it get updated. */ | 9172 | line, and this makes it get updated. */ |
| @@ -16572,8 +16573,11 @@ display_mode_element (it, depth, field_width, precision, elt, props, risky) | |||
| 16572 | { | 16573 | { |
| 16573 | int bytepos = last_offset; | 16574 | int bytepos = last_offset; |
| 16574 | int charpos = string_byte_to_char (elt, bytepos); | 16575 | int charpos = string_byte_to_char (elt, bytepos); |
| 16576 | |||
| 16577 | if (precision <= 0) | ||
| 16578 | nchars = string_byte_to_char (elt, offset) - charpos; | ||
| 16575 | n += display_string (NULL, elt, Qnil, 0, charpos, | 16579 | n += display_string (NULL, elt, Qnil, 0, charpos, |
| 16576 | it, 0, prec, 0, | 16580 | it, 0, nchars, 0, |
| 16577 | STRING_MULTIBYTE (elt)); | 16581 | STRING_MULTIBYTE (elt)); |
| 16578 | } | 16582 | } |
| 16579 | break; | 16583 | break; |
| @@ -17825,7 +17829,7 @@ display_count_lines (start, start_byte, limit_byte, count, byte_pos_ptr) | |||
| 17825 | display them, and < 0 means obey the current buffer's value of | 17829 | display them, and < 0 means obey the current buffer's value of |
| 17826 | enable_multibyte_characters. | 17830 | enable_multibyte_characters. |
| 17827 | 17831 | ||
| 17828 | Value is the number of glyphs produced. */ | 17832 | Value is the number of columns displayed. */ |
| 17829 | 17833 | ||
| 17830 | static int | 17834 | static int |
| 17831 | display_string (string, lisp_string, face_string, face_string_pos, | 17835 | display_string (string, lisp_string, face_string, face_string_pos, |
diff --git a/src/xfns.c b/src/xfns.c index 2577272c122..cbdfa56dec4 100644 --- a/src/xfns.c +++ b/src/xfns.c | |||
| @@ -5313,6 +5313,7 @@ or directory must exist. ONLY-DIR-P is ignored." */) | |||
| 5313 | int result; | 5313 | int result; |
| 5314 | struct frame *f = SELECTED_FRAME (); | 5314 | struct frame *f = SELECTED_FRAME (); |
| 5315 | Lisp_Object file = Qnil; | 5315 | Lisp_Object file = Qnil; |
| 5316 | Lisp_Object decoded_file; | ||
| 5316 | Widget dialog, text, help; | 5317 | Widget dialog, text, help; |
| 5317 | Arg al[10]; | 5318 | Arg al[10]; |
| 5318 | int ac = 0; | 5319 | int ac = 0; |
| @@ -5453,7 +5454,9 @@ or directory must exist. ONLY-DIR-P is ignored." */) | |||
| 5453 | if (NILP (file)) | 5454 | if (NILP (file)) |
| 5454 | Fsignal (Qquit, Qnil); | 5455 | Fsignal (Qquit, Qnil); |
| 5455 | 5456 | ||
| 5456 | return unbind_to (count, file); | 5457 | decoded_file = DECODE_FILE (file); |
| 5458 | |||
| 5459 | return unbind_to (count, decoded_file); | ||
| 5457 | } | 5460 | } |
| 5458 | 5461 | ||
| 5459 | #endif /* USE_MOTIF */ | 5462 | #endif /* USE_MOTIF */ |
| @@ -5481,6 +5484,7 @@ directories. */) | |||
| 5481 | FRAME_PTR f = SELECTED_FRAME (); | 5484 | FRAME_PTR f = SELECTED_FRAME (); |
| 5482 | char *fn; | 5485 | char *fn; |
| 5483 | Lisp_Object file = Qnil; | 5486 | Lisp_Object file = Qnil; |
| 5487 | Lisp_Object decoded_file; | ||
| 5484 | int count = SPECPDL_INDEX (); | 5488 | int count = SPECPDL_INDEX (); |
| 5485 | struct gcpro gcpro1, gcpro2, gcpro3, gcpro4, gcpro5, gcpro6; | 5489 | struct gcpro gcpro1, gcpro2, gcpro3, gcpro4, gcpro5, gcpro6; |
| 5486 | char *cdef_file; | 5490 | char *cdef_file; |
| @@ -5521,7 +5525,9 @@ directories. */) | |||
| 5521 | if (NILP (file)) | 5525 | if (NILP (file)) |
| 5522 | Fsignal (Qquit, Qnil); | 5526 | Fsignal (Qquit, Qnil); |
| 5523 | 5527 | ||
| 5524 | return unbind_to (count, file); | 5528 | decoded_file = DECODE_FILE (file); |
| 5529 | |||
| 5530 | return unbind_to (count, decoded_file); | ||
| 5525 | } | 5531 | } |
| 5526 | 5532 | ||
| 5527 | #endif /* USE_GTK */ | 5533 | #endif /* USE_GTK */ |
diff --git a/src/xmenu.c b/src/xmenu.c index a311a1cfa6a..156c44c9bb0 100644 --- a/src/xmenu.c +++ b/src/xmenu.c | |||
| @@ -1807,8 +1807,11 @@ digest_single_submenu (start, end, top_level_items) | |||
| 1807 | wv->enabled = 1; | 1807 | wv->enabled = 1; |
| 1808 | wv->button_type = BUTTON_TYPE_NONE; | 1808 | wv->button_type = BUTTON_TYPE_NONE; |
| 1809 | wv->help = Qnil; | 1809 | wv->help = Qnil; |
| 1810 | save_wv = wv; | ||
| 1810 | } | 1811 | } |
| 1811 | save_wv = wv; | 1812 | else |
| 1813 | save_wv = first_wv; | ||
| 1814 | |||
| 1812 | prev_wv = 0; | 1815 | prev_wv = 0; |
| 1813 | i += MENU_ITEMS_PANE_LENGTH; | 1816 | i += MENU_ITEMS_PANE_LENGTH; |
| 1814 | } | 1817 | } |
diff --git a/src/xterm.c b/src/xterm.c index f839e222a47..640d7c553da 100644 --- a/src/xterm.c +++ b/src/xterm.c | |||
| @@ -7567,7 +7567,7 @@ x_catch_errors (dpy) | |||
| 7567 | Display *dpy; | 7567 | Display *dpy; |
| 7568 | { | 7568 | { |
| 7569 | int count = SPECPDL_INDEX (); | 7569 | int count = SPECPDL_INDEX (); |
| 7570 | struct x_error_message_stack *data = malloc (sizeof (*data)); | 7570 | struct x_error_message_stack *data = xmalloc (sizeof (*data)); |
| 7571 | Lisp_Object dummy; | 7571 | Lisp_Object dummy; |
| 7572 | #ifdef ENABLE_CHECKING | 7572 | #ifdef ENABLE_CHECKING |
| 7573 | dummy = make_number ((EMACS_INT)dpy + (EMACS_INT)x_error_message); | 7573 | dummy = make_number ((EMACS_INT)dpy + (EMACS_INT)x_error_message); |