📄 news
字号:
** The new command `clone-indirect-buffer' can be used to createan indirect buffer that is a twin copy of the current buffer. Thecommand `clone-indirect-buffer-other-window', bound to C-x 4 c,does the same but displays the indirect buffer in another window.** New user options `backup-directory-alist' and`make-backup-file-name-function' control the placement of backups,typically in a single directory or in an invisible sub-directory.** New commands iso-iso2sgml and iso-sgml2iso convert between Latin-1characters and the corresponding SGML (HTML) entities.** New X resources recognized*** The X resource `synchronous', class `Synchronous', specifieswhether Emacs should run in synchronous mode. Synchronous modeis useful for debugging X problems.Example: emacs.synchronous: true*** The X resource `visualClass, class `VisualClass', specifies thevisual Emacs should use. The resource's value should be a string ofthe form `CLASS-DEPTH', where CLASS is the name of the visual class,and DEPTH is the requested color depth as a decimal number. Validvisual class names are TrueColor PseudoColor DirectColor StaticColor GrayScale StaticGrayVisual class names specified as X resource are case-insensitive, i.e.`pseudocolor', `Pseudocolor' and `PseudoColor' all have the samemeaning.The program `xdpyinfo' can be used to list the visual classessupported on your display, and which depths they have. If`visualClass' is not specified, Emacs uses the display's defaultvisual.Example: emacs.visualClass: TrueColor-8*** The X resource `privateColormap', class `PrivateColormap',specifies that Emacs should use a private colormap if it is using thedefault visual, and that visual is of class PseudoColor. Recognizedresource values are `true' or `on'.Example: emacs.privateColormap: true** Faces and frame parameters.There are four new faces `scroll-bar', `border', `cursor' and `mouse'.Setting the frame parameters `scroll-bar-foreground' and`scroll-bar-background' sets foreground and background color of face`scroll-bar' and vice versa. Setting frame parameter `border-color'sets the background color of face `border' and vice versa. Likewisefor frame parameters `cursor-color' and face `cursor', and frameparameter `mouse-color' and face `mouse'.Changing frame parameter `font' sets font-related attributes of the`default' face and vice versa. Setting frame parameters`foreground-color' or `background-color' sets the colors of the`default' face and vice versa.** New face `menu'.The face `menu' can be used to change colors and font of Emacs' menus.** New frame parameter `screen-gamma' for gamma correction.The new frame parameter `screen-gamma' specifies gamma-correction forcolors. Its value may be nil, the default, in which case no gammacorrection occurs, or a number > 0, usually a float, that specifiesthe screen gamma of a frame's display.PC monitors usually have a screen gamma of 2.2. smaller values resultin darker colors. You might want to try a screen gamma of 1.5 for LCDcolor displays. The viewing gamma Emacs uses is 0.4545. (1/2.2).The X resource name of this parameter is `screenGamma', class`ScreenGamma'.** Tabs and variable-width text.Tabs are now displayed with stretch properties; the width of a tab isdefined as a multiple of the normal character width of a frame, and isindependent of the fonts used in the text where the tab appears.Thus, tabs can be used to line up text in different fonts.** Enhancements of the Lucid menu bar*** The Lucid menu bar now supports the resource "margin". emacs.pane.menubar.margin: 5The default margin is 4 which makes the menu bar appear like theLessTif/Motif one.*** Arrows that indicate sub-menus are now drawn with shadows, as inLessTif and Motif.** A block cursor can be drawn as wide as the glyph under it under X.As an example: if a block cursor is over a tab character, it will bedrawn as wide as that tab on the display. To do this, set`x-stretch-cursor' to a non-nil value.** Empty display lines at the end of a buffer may be marked with abitmap (this is similar to the tilde displayed by vi and Less).This behavior is activated by setting the buffer-local variable`indicate-empty-lines' to a non-nil value. The default value of thisvariable is found in `default-indicate-empty-lines'.** There is a new "aggressive" scrolling method.When scrolling up because point is above the window start, if thevalue of the buffer-local variable `scroll-up-aggressively' is anumber, Emacs chooses a new window start so that point ends up thatfraction of the window's height from the top of the window.When scrolling down because point is below the window end, if thevalue of the buffer-local variable `scroll-down-aggressively' is anumber, Emacs chooses a new window start so that point ends up thatfraction of the window's height from the bottom of the window.** You can now easily create new *Info* buffers using eitherM-x clone-buffer, C-u m <entry> RET or C-u g <entry> RET.M-x clone-buffer can also be used on *Help* and several other specialbuffers.** The command `Info-search' now uses a search history.** Listing buffers with M-x list-buffers (C-x C-b) now showsabbreviated file names. Abbreviations can be customized by changing`directory-abbrev-alist'.** A new variable, backup-by-copying-when-privileged-mismatch, givesthe highest file uid for which backup-by-copying-when-mismatch will beforced on. The assumption is that uids less than or equal to thisvalue are special uids (root, bin, daemon, etc.--not real systemusers) and that files owned by these users should not change ownership,even if your system policy allows users other than root to edit them.The default is 200; set the variable to nil to disable the feature.** The rectangle commands now avoid inserting undesirable spaces,notably at the end of lines.All these functions have been rewritten to avoid inserting unwantedspaces, and an optional prefix now allows them to behave the old way.** The function `replace-rectangle' is an alias for `string-rectangle'.** The new command M-x string-insert-rectangle is like `string-rectangle',but inserts text instead of replacing it.** The new command M-x query-replace-regexp-eval acts likequery-replace-regexp, but takes a Lisp expression which is evaluatedafter each match to get the replacement text.** M-x query-replace recognizes a new command `e' (or `E') that letsyou edit the replacement string.** The new command mail-abbrev-complete-alias, bound to `M-TAB'(if you load the library `mailabbrev'), lets you complete mail aliasesin the text, analogous to lisp-complete-symbol.** The variable `echo-keystrokes' may now have a floating point value.** If your init file is compiled (.emacs.elc), `user-init-file' is setto the source name (.emacs.el), if that exists, after loading it.** The help string specified for a menu-item whose definition containsthe property `:help HELP' is now displayed under X, on MS-Windows, andMS-DOS, either in the echo area or with tooltips. Many standard menusdisplayed by Emacs now have help strings.--** New user option `read-mail-command' specifies a command to use toread mail from the menu etc.** The environment variable `EMACSLOCKDIR' is no longer used on MS-Windows.This environment variable was used when creating lock files. Emacs onMS-Windows does not use this variable anymore. This change was madebefore Emacs 21.1, but wasn't documented until now.** Highlighting of mouse-sensitive regions is now supported in theMS-DOS version of Emacs.** The new command `msdos-set-mouse-buttons' forces the MS-DOS versionof Emacs to behave as if the mouse had a specified number of buttons.This comes handy with mice that don't report their number of buttonscorrectly. One example is the wheeled mice, which report 3 buttons,but clicks on the middle button are not passed to the MS-DOS versionof Emacs.** Customize changes*** Customize now supports comments about customized items. Use the`State' menu to add comments, or give a prefix argument toM-x customize-set-variable or M-x customize-set-value. Note thatcustomization comments will cause the customizations to fail inearlier versions of Emacs.*** The new option `custom-buffer-done-function' says whether to killCustom buffers when you've done with them or just bury them (thedefault).*** If Emacs was invoked with the `-q' or `--no-init-file' options, itdoes not allow you to save customizations in your `~/.emacs' initfile. This is because saving customizations from such a session wouldwipe out all the other customizationss you might have on your initfile.** If Emacs was invoked with the `-q' or `--no-init-file' options, itdoes not save disabled and enabled commands for future sessions, toavoid overwriting existing customizations of this kind that arealready in your init file.** New features in evaluation commands*** The commands to evaluate Lisp expressions, such as C-M-x in Lispmodes, C-j in Lisp Interaction mode, and M-:, now bind the variablesprint-level, print-length, and debug-on-error based on the newcustomizable variables eval-expression-print-level,eval-expression-print-length, and eval-expression-debug-on-error.The default values for the first two of these variables are 12 and 4respectively, which means that `eval-expression' now prints at mostthe first 12 members of a list and at most 4 nesting levels deep (ifthe list is longer or deeper than that, an ellipsis `...' isprinted).<RET> or <mouse-2> on the printed text toggles between an abbreviatedprinted representation and an unabbreviated one.The default value of eval-expression-debug-on-error is t, so any errorduring evaluation produces a backtrace.*** The function `eval-defun' (C-M-x) now loads Edebug and instrumentscode when called with a prefix argument.** CC mode changes.Note: This release contains changes that might not be compatible withcurrent user setups (although it's believed that theseincompatibilities will only show in very uncommon circumstances).However, since the impact is uncertain, these changes may be rolledback depending on user feedback. Therefore there's no forwardcompatibility guarantee wrt the new features introduced in thisrelease.*** The hardcoded switch to "java" style in Java mode is gone.CC Mode used to automatically set the style to "java" when Java modeis entered. This has now been removed since it caused too muchconfusion.However, to keep backward compatibility to a certain extent, thedefault value for c-default-style now specifies the "java" style forjava-mode, but "gnu" for all other modes (as before). So you won'tnotice the change if you haven't touched that variable.*** New cleanups, space-before-funcall and compact-empty-funcall.Two new cleanups have been added to c-cleanup-list:space-before-funcall causes a space to be inserted before the openingparenthesis of a function call, which gives the style "foo (bar)".compact-empty-funcall causes any space before a function call openingparenthesis to be removed if there are no arguments to the function.It's typically useful together with space-before-funcall to get thestyle "foo (bar)" and "foo()".*** Some keywords now automatically trigger reindentation.Keywords like "else", "while", "catch" and "finally" have been made"electric" to make them reindent automatically when they continue anearlier statement. An example:for (i = 0; i < 17; i++) if (a[i]) res += a[i]->offset;elseHere, the "else" should be indented like the preceding "if", since itcontinues that statement. CC Mode will automatically reindent it afterthe "else" has been typed in full, since it's not until then it'spossible to decide whether it's a new statement or a continuation ofthe preceding "if".CC Mode uses Abbrev mode to achieve this, which is therefore turned onby default.*** M-a and M-e now moves by sentence in multiline strings.Previously these two keys only moved by sentence in comments, whichmeant that sentence movement didn't work in strings containingdocumentation or other natural language text.The reason it's only activated in multiline strings (i.e. strings thatcontain a newline, even when escaped by a '\') is to avoid stopping inthe short strings that often reside inside statements. Multilinestrings almost always contain text in a natural language, as opposedto other strings that typically contain format specifications,commands, etc. Also, it's not that bothersome that M-a and M-e missessentences in single line strings, since they're short anyway.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -