📄 onews
字号:
*** There is a new data type called a char-table which is an arrayindexed by a character. Currently this is mostly equivalent to avector of length 256, but in the future, when a wider character set isin use, it will be different. To create one, call (make-char-table SUBTYPE INITIAL-VALUE)SUBTYPE is a symbol that identifies the specific use of thischaracter table. It can be any of these values: syntax-table display-table keyboard-translate-table case-tableThe function `char-table-subtype' returns the subtype of a char-table.You cannot alter the subtype of an existing char-table.A char-table has an element for each character code. It also has some"extra slots". The number of extra slots depends on the subtype andtheir use depends on the subtype. (Each subtype symbol has a`char-table-extra-slots' property that says how many extra slots tomake.) Use (char-table-extra-slot TABLE N) to access extra slot N and(set-char-table-extra-slot TABLE N VALUE) to store VALUE in slot N.A char-table T can have a parent, which should be another char-tableP. If you look for the value in T for character C, and the table Tactually holds nil, P's element for character C is used instead.The functions `char-table-parent' and `set-char-table-parent'let you read or set the parent of a char-table.To scan all the values in a char-table, do not try to loop through allpossible character codes. That would work for now, but will not workin the future. Instead, call map-char-table. (map-char-tableFUNCTION TABLE) calls FUNCTION once for each character or characterset that has a distinct value in TABLE. FUNCTION gets two arguments,RANGE and VALUE. RANGE specifies a range of TABLE that has oneuniform value, and VALUE is the value in TABLE for that range.Currently, RANGE is always a vector containing a single characterand it refers to that character alone. In the future, other kindsof ranges will occur. You can set the value for a given rangewith (set-char-table-range TABLE RANGE VALUE) and examine the valuefor a range with (char-table-range TABLE RANGE).*** Syntax tables are now represented as char-tables.All syntax tables other than the standard syntax tablenormally have the standard syntax table as their parent.Their subtype is `syntax-table'.*** Display tables are now represented as char-tables.Their subtype is `display-table'.*** Case tables are now represented as char-tables.Their subtype is `case-table'.*** The value of keyboard-translate-table may now be a char-tableinstead of a string. Normally the char-tables used for this purposehave the subtype `keyboard-translate-table', but that is not required.*** A new data type called a bool-vector is a vector of valuesthat are either t or nil. To create one, do (make-bool-vector LENGTH INITIAL-VALUE)** You can now specify, for each marker, how it should relocate whentext is inserted at the place where the marker points. This is calledthe "insertion type" of the marker.To set the insertion type, do (set-marker-insertion-type MARKER TYPE).If TYPE is t, it means the marker advances when text is inserted. IfTYPE is nil, it means the marker does not advance. (In Emacs 19.29,markers did not advance.)The function marker-insertion-type reports the insertion type of agiven marker. The function copy-marker takes a second argument TYPEwhich specifies the insertion type of the new copied marker.** When you create an overlay, you can specify the insertion type ofthe beginning and of the end. To do this, you can use two newarguments to make-overlay: front-advance and rear-advance.** The new function overlays-in returns a list of the overlays thatoverlap a specified range of the buffer. The returned list includesempty overlays at the beginning of this range, as well as within therange.** The new hook window-scroll-functions is run when a window has beenscrolled. The functions in this list are called just beforeredisplay, after the new window-start has been computed. Each functionis called with two arguments--the window that has been scrolled, and itsnew window-start position.This hook is useful for on-the-fly fontification and other featuresthat affect how the redisplayed text will look when it is displayed.The window-end value of the window is not valid when these functionsare called. The computation of window-end is byproduct of actualredisplay of the window contents, which means it has not yet happenedwhen the hook is run. Computing window-end specially in advance forthe sake of these functions would cause a slowdown.The hook functions can determine where the text on the window will endby calling vertical-motion starting with the window-start position.** The new hook redisplay-end-trigger-functions is run wheneverredisplay in window uses text that extends past a specified endtrigger position. You set the end trigger position with the functionset-window-redisplay-end-trigger. The functions are called with twoarguments: the window, and the end trigger position. Storing nil forthe end trigger position turns off the feature, and the trigger valueis automatically reset to nil just after the hook is run.You can use the function window-redisplay-end-trigger to read awindow's current end trigger value.** The new function insert-file-contents-literally inserts thecontents of a file without any character set translation or decoding.** The new function safe-length computes the length of a list.It never gets an error--it treats any non-list like nil.If given a circular list, it returns an upper bound for the numberof elements before the circularity.** replace-match now takes a fifth argument, SUBEXP. If SUBEXP isnon-nil, that says to replace just subexpression number SUBEXP of theregexp that was matched, not the entire match. For example, aftermatching `foo \(ba*r\)' calling replace-match with 1 as SUBEXP meansto replace just the text that matched `\(ba*r\)'.** The new keymap special-event-map defines bindings for certainevents that should be handled at a very low level--as soon as theyare read. The read-event function processes these events itself,and never returns them.Events that are handled in this way do not echo, they are nevergrouped into key sequences, and they never appear in the value oflast-command-event or (this-command-keys). They do not discard anumeric argument, they cannot be unread with unread-command-events,they may not appear in a keyboard macro, and they are not recordedin a keyboard macro while you are defining one.These events do, however, appear in last-input-event immediately afterthey are read, and this is the way for the event's definition to findthe actual event.The events types iconify-frame, make-frame-visible and delete-frameare normally handled in this way.** encode-time now supports simple date arithmetic by means ofout-of-range values for its SEC, MINUTE, HOUR, DAY, and MONTHarguments; for example, day 0 means the day preceding the given month.Also, the ZONE argument can now be a TZ-style string.** command-execute and call-interactively now accept an optional thirdargument KEYS. If specified and non-nil, this specifies the keysequence containing the events that were used to invoke the command.** The environment variable NAME, if set, now specifies the value of(user-full-name), when Emacs starts up.* User Editing Changes in Emacs 19.29** If you run out of memory.If you get the error message "Virtual memory exhausted", type C-x s.That way of saving files has the least additional memory needs. Emacs19.29 keeps a reserve of memory which it makes available when thiserror happens; that is to ensure that C-x s can complete its work.Once you have saved your data, you can exit and restart Emacs, or useM-x kill-some-buffers to free up space. If you kill bufferscontaining a substantial amount of text, you can go on editing.Do not use M-x buffer-menu to save or kill buffers when you are out ofmemory, because that needs a fair amount memory itself and you may nothave enough to get it started.** The format of compiled files has changed incompatibly.Byte-compiled files made with Emacs 19.29 normally use a new formatthat will not work in older Emacs versions. You can compile filesin the old format if you wish; see "Changes in compilation," below.** Emacs 19.29 supports the DEC Alpha.** Emacs runs on Windows NT.This port does not yet support windowing features. It works like atext-only terminal, but it does support a mouse.In general, support for non-GNU-like operating systems is not a highpriority for the GNU project. We merged in the support for Windows NTbecause that system is expected to be very widely used.** Emacs supports Motif widgets.You can build Emacs with Motif widgets by specifying --with-x-toolkit=motifwhen you run configure.Motif defines collections of windows called "tab groups", and uses thetab key and the cursor keys to move between windows in a tab group.Emacs naturally does not support this--it has other uses for the tabkey and cursor keys. Emacs does not support Motif accelerators either,because it uses its normal keymap event binding features.We give higher priority to operation with a free widget set than tooperation with a proprietary one.** If Emacs or the computer crashes, you can recover all the files youwere editing from their auto save files by typing M-x recover-session.This first shows you a list of recorded interrupted sessions. Movepoint to the one you choose, and type C-c C-c.Then recover-session asks about each of the files that were beingedited during that session, asking whether to recover that file. Ifyou answer y, it calls recover-file, which works in its normalfashion. It shows the dates of the original file and its auto-savefile and asks once again whether to recover that file.When recover-session is done, the files you've chosen to recoverare present in Emacs buffers. You should then save them.Only this--saving them--updates the files themselves.** Menu bar menus now stay up if you click on the menu bar item andrelease the mouse button within a certain amount of time. This is inthe X Toolkit version.** The menu bar menus have been rearranged and split up to make for abetter organization. Two new menu bar menus, Tools and Search,contain items that were formerly in the Files and Edit menus, as wellas some that did not exist in the menu bar menus before.** Emacs can now display on more than one X display at the same time.Use the command make-frame-on-display to create a frame, specifyingwhich display to use.** M-x talk-connect sets up a multi-user talk connectionvia Emacs. Specify the X display of the person you want to talk to.You can talk to any number of people (within reason) by usingthis command repeatedly to specify different people.Emacs does not make a fuss about security; the people who you talk tocan use all Emacs features, including visiting and editing files. Ifthis frightens you, don't use M-x talk-connect.** The range of integer values is now at least 2**28 on all machines.This means the maximum size of a buffer is at least 2**27-1,or 134,217,727.** When you start Emacs, you can now specify option names inlong GNU form (starting with `--') and you can abbreviate the names.You can now specify the options in any order.The previous requirements about the order of optionshave been eliminated.The -L or --directory option lets you specify an additionaldirectory to search for Lisp libraries (including librariesthat you specify with the -l or --load options).** Incremental search in Transient Mark mode, if the mark is alreadyactive, now leaves the mark active and does not change its position.You can make incremental search deactivate the mark once again withthis expression. (add-hook 'isearch-mode-hook 'deactivate-mark)** C-delete now deletes a word backwards. This is for compatibilitywith some editors in the PC world. (This key is not available onordinary ASCII terminals, because C-delete is not a distinct characteron those terminals.)** ESC ESC ESC is now a command to escape from various temporary modesand states.** M-x pc-bindings-mode sets up bindings compatible with many PC editors.In particular, Delete and its variants delete forward instead of backward.Use Backspace to delete backward.C-Backspace kills backward a word (as C-Delete normally would).M-Backspace does undo.Home and End move to beginning and end of lineC-Home and C-End move to beginning and end of buffer.** The key sequence for evaluating a Lisp expression using the minibufferis now ESC :. It used to be ESC ESC, but we moved it to make way forthe ESC ESC ESC feature, on the grounds that people who evaluate Lispexpressions are experienced users and can cope with a change.If you prefer the old ESC ESC binding, put in your `~/.emacs': (global-set-key "\e\e" 'eval-expression)** The f1 function key is now equivalent to the help key. This isdone with key-translation-map; delete the binding for f1 in that mapif you want to use f1 for something else.** Mouse-3, in the simplest case, still sets the region. But now, itplaces the mark where point was, and sets point where you click.(It used to set the mark where you click and leave point alone.)If you position point with Mouse-1, then scroll with the scroll barand use Mouse-3, Mouse-3 uses the position you specified with Mouse-1even if it has scrolled off the screen (and point is no longer there).This makes it easier to select a region with the mouse which is biggerthan a screenful.Any editing of the buffer, and any cursor motion or scrolling for anyreason other than the scroll bar, cancels the special state set up byMouse-1--so that a subsequent Mouse-3 click will use the actual valueof point.** C-mouse-3 now pops up a mode-specific menu of commands--normallythe same ones available in the mode's own menu bar menus.** C-mouse-2 now pops up a menu of faces, indentation, justification,and certain other text properties. This menu is also availablethrough the menu-bar Edit menu. It is meant for use with Enrichedmode.*** You can use this
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -