1 .\" See section COPYING for copyright and redistribution information.
2 .TH EMACS 1 "2007 April 13" "GNU Emacs 23.1.91"
6 emacs \- GNU project Emacs
12 .I command-line switches
22 written by the author of the original (PDP-10)
26 The primary documentation of GNU Emacs is in the GNU Emacs Manual,
27 which you can read using Info, either from Emacs or as a standalone
29 Please look there for complete and up-to-date documentation.
30 This man page is updated only when someone volunteers to do so; the
31 Emacs maintainers' priority goal is to minimize the amount of time
32 this man page takes away from other more useful projects.
34 The user functionality of GNU Emacs encompasses
37 editors do, and it is easily extensible since its
38 editing commands are written in Lisp.
41 has an extensive interactive help facility,
42 but the facility assumes that you know how to manipulate
45 CTRL-h or F1 enters the Help facility.
46 Help Tutorial (CTRL-h t) starts an interactive tutorial which can
47 teach beginners the fundamentals of
50 Help Apropos (CTRL-h a) helps you
51 find a command given its functionality, Help Character (CTRL-h c)
52 describes a given character's effect, and Help Function (CTRL-h f)
53 describes a given Lisp function specified by name.
56 Undo can undo several steps of modification to your buffers, so it is
57 easy to recover from editing mistakes.
60 many special packages handle mail reading (RMail) and sending (Mail),
61 outline editing (Outline), compiling (Compile), running subshells
64 windows (Shell), running a Lisp read-eval-print loop
65 (Lisp-Interaction-Mode), automated psychotherapy (Doctor), and much more.
67 There is an extensive reference manual, but
68 users of other Emacses
69 should have little trouble adapting even
74 to use basic features fairly rapidly by studying the tutorial and
75 using the self-documentation features.
78 The following options are of general interest:
85 .BI \-\-file " file\fR,\fP " \-\-find-file " file\fR,\fP " \-\-visit " file"
86 The same as specifying
88 directly as an argument.
91 Go to the line specified by
93 (do not insert a space between the "+" sign and
95 This applies only to the next file specified.
103 .BR \-q ", " \-\-no\-init\-file
104 Do not load an init file.
106 .B \-\-no\-site\-file
107 Do not load the site-wide startup file.
110 Do not load a saved desktop.
112 .BR \-nl ", " \-\-no\-shared\-memory
113 Do not use shared memory.
115 .BR \-Q ", " \-\-quick
116 Equivalent to "\-q \-\-no\-site\-file \-\-no\-splash".
119 Do not display a splash screen during start-up.
124 Lisp debugger during the processing of the user init file
126 This is useful for debugging problems in the init file.
128 .BI \-u " user\fR,\fP " \-\-user " user"
133 .BI \-t " file\fR,\fP " \-\-terminal " file"
136 as the terminal instead of using stdin/stdout.
137 This must be the first argument specified in the command line.
139 .BR \-\-multibyte ", " \-\-no-unibyte
140 Enable multibyte mode (enabled by default).
142 .BR \-\-unibyte ", " \-\-no-multibyte
148 version information and exit.
151 Display this help and exit.
154 The following options are lisp-oriented
155 (these options are processed in the order encountered):
158 .BI \-f " function\fR,\fP " \-\-funcall " function"
159 Execute the lisp function
162 .BI \-l " file\fR,\fP " \-\-load " file"
163 Load the lisp code in the file
166 .BI \-\-eval " expr\fR,\fP " \-\-execute " expr"
167 Evaluate the Lisp expression
171 The following options are useful when running
178 The editor will send messages to stderr.
179 This option must be the first in the argument list.
180 You must use \-l and \-f options to specify files to execute
181 and functions to call.
183 .BI \-\-script " file"
186 as an Emacs Lisp script.
188 .BI \-\-insert " file"
191 into the current buffer.
198 .BI \-L " dir\fR,\fP " \-\-directory " dir"
201 to the list of directories
203 searches for Lisp files.
206 .\" START DELETING HERE IF YOU'RE NOT USING X
207 .SS Using Emacs with X
209 has been tailored to work well with the X window system.
212 from under X windows, it will create its own X window to
214 You will probably want to start the editor as a background
215 process so that you can continue using your original window.
218 can be started with the following X switches:
222 Specify the name which should be assigned to the initial
225 This controls looking up X resources as well as the window title.
227 .BI \-T " name\fR,\fP " \-\-title " name"
228 Specify the title for the initial X window.
230 .BR \-r ", " \-rv ", " \-\-reverse\-video
233 window in reverse video.
235 .BI \-fn " font\fR,\fP " \-\-font " font"
238 window's font to that specified by
240 You will find the various
243 .I /usr/lib/X11/fonts
247 will only accept fixed width fonts.
248 Under the X11 Release 4 font-naming conventions, any font with the
249 value "m" or "c" in the eleventh field of the font name is a fixed
251 Furthermore, fonts whose name are of the form
253 are generally fixed width, as is the font
257 for more information.
259 When you specify a font, be sure to put a space between the
260 switch and the font name.
262 .BI \-\-xrm " resources"
263 Set additional X resources.
265 .BI "\-\-color\fR,\fP \-\-color=" mode
266 Override color mode for character terminals;
268 defaults to `auto', and can also be `never', `auto', `always',
269 or a mode name like `ansi8'.
271 .BI \-bw " pixels\fR,\fP " \-\-border\-width " pixels"
274 window's border width to the number of pixels specified by
276 Defaults to one pixel on each side of the window.
278 .BI \-ib " pixels\fR,\fP " \-\-internal\-border " pixels"
279 Set the window's internal border width to the number of pixels specified
282 Defaults to one pixel of padding on each side of the window.
284 .BI \-g " geometry\fR,\fP " \-\-geometry " geometry"
287 window's width, height, and position as specified.
288 The geometry specification is in the standard X format; see
290 for more information.
291 The width and height are specified in characters; the default is
293 See the Emacs manual, section "Options for Window Size and Position",
294 for information on how window sizes interact
295 with selecting or deselecting the tool bar and menu bar.
297 .BI \-lsp " pixels\fR,\fP " \-\-line\-spacing " pixels"
298 Additional space to put between lines.
300 .BR \-vb ", " \-\-vertical\-scroll\-bars
301 Enable vertical scrollbars.
303 .BR \-fh ", " \-\-fullheight
304 Make the first frame as high as the screen.
306 .BR \-fs ", " \-\-fullscreen
307 Make the first frame fullscreen.
309 .BR \-fw ", " \-\-fullwidth
310 Make the first frame as wide as the screen.
312 .BI \-fg " color\fR,\fP " \-\-foreground\-color " color"
313 On color displays, set the color of the text.
316 .I M\-x list\-colors\-display
317 for a list of valid color names.
319 .BI \-bg " color\fR,\fP " \-\-background\-color " color"
320 On color displays, set the color of the window's background.
322 .BI \-bd " color\fR,\fP " \-\-border\-color " color"
323 On color displays, set the color of the window's border.
325 .BI \-cr " color\fR,\fP " \-\-cursor\-color " color"
326 On color displays, set the color of the window's text cursor.
328 .BI \-ms " color\fR,\fP " \-\-mouse\-color " color"
329 On color displays, set the color of the window's mouse cursor.
331 .BI \-d " displayname\fR,\fP " \-\-display " displayname"
334 window on the display specified by
336 Must be the first option specified in the command line.
338 .BR \-nbi ", " \-\-no\-bitmap\-icon
339 Do not use picture of gnu for Emacs icon.
346 .BR \-nbc ", " \-\-no\-blinking\-cursor
347 Disable blinking cursor.
349 .BR \-nw ", " \-\-no\-window\-system
352 not to use its special interface to X.
353 If you use this switch when invoking
357 window, display is done in that window.
359 .BR \-D ", " \-\-basic\-display
360 This option disables many display features; use it for
366 default values for your
372 Use the following format:
374 .RI emacs. keyword : value
378 specifies the default value of
381 lets you set default values for the following keywords:
384 .BR background " (class " Background )
386 sets the window's background color.
388 .BR bitmapIcon " (class " BitmapIcon )
393 the window will iconify into the "kitchen sink."
395 .BR borderColor " (class " BorderColor )
397 sets the color of the window's border.
399 .BR borderWidth " (class " BorderWidth )
400 Sets the window's border width in pixels.
402 .BR cursorColor " (class " Foreground )
404 sets the color of the window's text cursor.
406 .BR cursorBlink " (class " CursorBlink )
407 Specifies whether to make the cursor blink.
414 to turn cursor blinking off.
416 .BR font " (class " Font )
417 Sets the window's text font.
419 .BR foreground " (class " Foreground )
421 sets the window's text color.
423 .BR fullscreen " (class " Fullscreen )
424 The desired fullscreen size.
425 The value can be one of
430 which correspond to the command-line options `\-fs', `\-fw', and
431 `\-fh', respectively.
432 Note that this applies to the initial frame only.
434 .BR geometry " (class " Geometry )
435 Sets the geometry of the
437 window (as described above).
439 .BR iconName " (class " Title )
440 Sets the icon name for the
444 .BR internalBorder " (class " BorderWidth )
445 Sets the window's internal border width in pixels.
447 .BR lineSpacing " (class " LineSpacing )
448 Additional space ("leading") between lines, in pixels.
450 .BR menuBar " (class " MenuBar )
451 Gives frames menu bars if
453 don't have menu bars if
455 See the Emacs manual, sections "Lucid Resources" and "LessTif
456 Resources", for how to control the appearance of the menu bar
459 .BR minibuffer " (class " Minibuffer )
462 don't make a minibuffer in this frame.
463 It will use a separate minibuffer frame instead.
465 .BR paneFont " (class " Font )
466 Font name for menu pane titles, in non-toolkit versions of
469 .BR pointerColor " (class " Foreground )
471 sets the color of the window's mouse cursor.
473 .BR privateColormap " (class " PrivateColormap )
476 use a private color map, in the case where the "default
483 .BR reverseVideo " (class " ReverseVideo )
488 the window will be displayed in reverse video.
490 .BR screenGamma " (class "ScreenGamma )
491 Gamma correction for colors, equivalent to the frame parameter
494 .BR scrollBarWidth " (class "ScrollBarWidth )
495 The scroll bar width in pixels, equivalent to the frame parameter
496 `scroll\-bar\-width'.
498 .BR selectionFont " (class " SelectionFont )
499 Font name for pop-up menu items, in non-toolkit versions of
501 (For toolkit versions, see the Emacs manual, sections
502 "Lucid Resources" and "LessTif Resources".)
504 .BR selectionTimeout " (class " SelectionTimeout )
505 Number of milliseconds to wait for a selection reply.
506 A value of 0 means wait as long as necessary.
508 .BR synchronous " (class " Synchronous )
509 Run Emacs in synchronous mode if
511 Synchronous mode is useful for debugging X problems.
513 .BR title " (class " Title )
514 Sets the title of the
518 .BR toolBar " (class " ToolBar )
519 Number of lines to reserve for the tool bar.
521 .BR useXIM " (class " UseXIM )
522 Turns off use of X input methods (XIM) if
527 .BR verticalScrollBars " (class " ScrollBars )
528 Gives frames scroll bars if
530 suppresses scroll bars if
533 .BR visualClass " (class " VisualClass )
534 Specify the "visual" that X should use.
535 This tells X how to handle colors.
536 The value should start with one of
548 is the number of color planes.
551 If you try to set color values while using a black and white display,
552 the window's characteristics will default as follows:
553 the foreground color will be set to black,
554 the background color will be set to white,
555 the border color will be set to grey,
556 and the text and mouse cursors will be set to black.
560 The following lists some of the mouse button bindings for the
569 MOUSE BUTTON FUNCTION
572 right Cut text into X cut buffer.
573 SHIFT-middle Cut text into X cut buffer.
574 SHIFT-right Paste text.
575 CTRL-middle Cut text into X cut buffer and kill it.
577 Select this window, then split it into two windows.
578 Same as typing CTRL\-x 2.
580 .\" START DELETING HERE IF YOU'RE NOT USING X MENUS
582 X buffer menu \(em hold the buttons and keys
583 down, wait for menu to appear, select buffer, and release.
584 Move mouse out of menu and release to cancel.
587 X help menu \(em pop up index card menu for Emacs help.
589 .\" STOP DELETING HERE IF YOU'RE NOT USING X MENUS
591 Select window with mouse, and delete all other windows.
592 Same as typing CTRL\-x 1.
594 .\" STOP DELETING HERE IF YOU'RE NOT USING X
600 You can order printed copies of the GNU Emacs Manual from the Free
601 Software Foundation, which develops GNU software.
602 See the file ORDERS for ordering information.
604 Your local Emacs maintainer might also have copies available.
605 As with all software and publications from FSF, everyone is permitted
606 to make and distribute copies of the Emacs manual.
607 The TeX source to the manual is also included in the Emacs source
612 /usr/local/share/info \(em files for the Info documentation browser.
613 The complete text of the Emacs reference manual is included in a
614 convenient tree structured form.
615 Also includes the Emacs Lisp Reference Manual, useful to anyone
616 wishing to write programs in the Emacs Lisp extension language.
618 /usr/local/share/emacs/$VERSION/lisp \(em Lisp source files and
619 compiled files that define most editing commands.
620 Some are preloaded; others are autoloaded from this directory when
623 /usr/local/libexec/emacs/$VERSION/$ARCH \(em various programs that are
626 /usr/local/share/emacs/$VERSION/etc \(em various files of information.
628 /usr/local/share/emacs/$VERSION/etc/DOC.* \(em contains the documentation
629 strings for the Lisp primitives and preloaded Lisp functions
631 They are stored here to reduce the size of Emacs proper.
633 /usr/local/share/emacs/$VERSION/etc/SERVICE lists people offering
634 various services to assist users of GNU Emacs, including education,
635 troubleshooting, porting and customization.
639 There is a mailing list, bug-gnu-emacs@gnu.org, for reporting Emacs
641 But before reporting something as a bug, please try to be sure that
642 it really is a bug, not a misunderstanding or a deliberate feature.
643 We ask you to read the section ``Reporting Emacs Bugs'' near the
644 end of the reference manual (or Info system) for hints on how and
646 Also, include the version number of the Emacs you are running in
647 \fIevery\fR bug report that you send in.
648 Bugs tend actually to be fixed if they can be isolated, so it is
649 in your interest to report them in such a way that they can be
652 Do not expect a personal answer to a bug report.
653 The purpose of reporting bugs is to get them fixed for everyone
654 in the next release, if possible.
655 For personal assistance, look in the SERVICE file (see above) for
656 a list of people who offer it.
658 Please do not send anything but bug reports to this mailing list.
659 For more information about Emacs mailing lists, see the
660 file /usr/local/share/emacs/$VERSION/etc/MAILINGLISTS.
665 is free; anyone may redistribute copies of
668 anyone under the terms stated in the
670 General Public License,
671 a copy of which accompanies each copy of
674 appears in the reference manual.
678 may sometimes be received packaged with distributions of Unix systems,
679 but it is never included in the scope of any license covering those
681 Such inclusion violates the terms on which distribution is permitted.
682 In fact, the primary purpose of the General Public License is to
683 prohibit anyone from attaching any other restrictions to
687 Richard Stallman encourages you to improve and extend
690 you contribute your extensions to the GNU library.
691 Eventually GNU (Gnu's Not Unix) will be a complete replacement
693 Everyone will be free to use, copy, study and change the GNU system.
707 was written by Richard Stallman and the Free Software Foundation.
708 Joachim Martillo and Robert Krawitz added the X features.
715 1995, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
716 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
718 Permission is granted to make and distribute verbatim copies of this
719 document provided the copyright notice and this permission notice are
720 preserved on all copies.
722 Permission is granted to copy and distribute modified versions of
723 this document under the conditions for verbatim copying, provided that
724 the entire resulting derived work is distributed under the terms of
725 a permission notice identical to this one.
727 Permission is granted to copy and distribute translations of this
728 document into another language, under the above conditions for
729 modified versions, except that this permission notice may be stated
730 in a translation approved by the Free Software Foundation.
732 .\" arch-tag: 04dfd376-b46e-4924-919a-cecc3b257eaa