annotate man/msdog.texi @ 71544:70062eaec923

(ls in Lisp, Windows Keyboard, Windows Mouse) (Windows Processes, Windows Misc): Shorten the printed version by selectively conditioning less important portions by @ifnottex.
author Eli Zaretskii <eliz@gnu.org>
date Fri, 30 Jun 2006 13:27:10 +0000
parents 662c32135523
children 4d628cade603
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
1 @c This is part of the Emacs manual.
64890
3723093a21fd Update years in copyright notice; nfc.
Thien-Thi Nguyen <ttn@gnuvola.org>
parents: 64742
diff changeset
2 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
68639
dc2d5a6655a3 Update years in copyright notice; nfc.
Thien-Thi Nguyen <ttn@gnuvola.org>
parents: 68544
diff changeset
3 @c 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
4 @c See file emacs.texi for copying conditions.
70435
95f50a235a27 Rename `Emacs and Microsoft Windows' into `Microsoft Windows'.
Eli Zaretskii <eliz@gnu.org>
parents: 70159
diff changeset
5 @node Microsoft Windows, Manifesto, Mac OS, Top
70443
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
6 @appendix Emacs and Microsoft Windows/MS-DOS
68460
bb56c788af45 (MS-DOS): Rewrite intro to explain how this
Richard M. Stallman <rms@gnu.org>
parents: 64890
diff changeset
7 @cindex Microsoft Windows
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
8 @cindex MS-Windows, Emacs peculiarities
68460
bb56c788af45 (MS-DOS): Rewrite intro to explain how this
Richard M. Stallman <rms@gnu.org>
parents: 64890
diff changeset
9
69898
601830ae280c move MS-DOS material to emacs-xtra.texi
Karl Berry <karl@gnu.org>
parents: 68639
diff changeset
10 This section describes peculiarities of using Emacs on Microsoft
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
11 Windows. Some of these peculiarities are also relevant to Microsoft's
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
12 older MS-DOS ``operating system'' (also known as ``MS-DOG'').
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
13 However, Emacs features that are relevant @emph{only} to MS-DOS are
70443
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
14 described in a separate
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
15 @iftex
70472
8566e3f340ec msdog.texi (Microsoft Windows):
Eli Zaretskii <eliz@gnu.org>
parents: 70443
diff changeset
16 manual (@pxref{MS-DOS,,, emacs-xtra, Specialized Emacs Features}).
70443
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
17 @end iftex
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
18 @ifnottex
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
19 section (@pxref{MS-DOS}).
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
20 @end ifnottex
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
21
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
22
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
23 The behavior of Emacs on MS-Windows is reasonably similar to what is
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
24 documented in the rest of the manual, including support for long file
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
25 names, multiple frames, scroll bars, mouse menus, and subprocesses.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
26 However, a few special considerations apply, and they are described
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
27 here.
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
28
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
29 @menu
70443
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
30 * Text and Binary:: Text files use CRLF to terminate lines.
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
31 * Windows Files:: File-name conventions on Windows.
71468
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
32 * ls in Lisp:: Emulation of @code{ls} for Dired.
70443
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
33 * Windows HOME:: Where Emacs looks for your @file{.emacs}.
71470
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
34 * Windows Keyboard:: Windows-specific keyboard features.
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
35 * Windows Mouse:: Windows-specific mouse features.
70443
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
36 * Windows Processes:: Running subprocesses on Windows.
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
37 * Windows Printing:: How to specify the printer on MS-Windows.
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
38 * Windows Misc:: Miscellaneous Windows features.
70443
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
39 @ifnottex
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
40 * MS-DOS:: Using Emacs on MS-DOS (otherwise known as @dfn{MS-DOG}).
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
41 @end ifnottex
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
42 @end menu
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
43
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
44 @node Text and Binary
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
45 @section Text Files and Binary Files
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
46 @cindex text and binary files on MS-DOS/MS-Windows
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
47
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
48 GNU Emacs uses newline characters to separate text lines. This is the
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
49 convention used on GNU, Unix, and other Posix-compliant systems.
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
50
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
51 @cindex end-of-line conversion on MS-DOS/MS-Windows
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
52 By contrast, MS-DOS and MS-Windows normally use carriage-return linefeed,
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
53 a two-character sequence, to separate text lines. (Linefeed is the same
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
54 character as newline.) Therefore, convenient editing of typical files
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
55 with Emacs requires conversion of these end-of-line (EOL) sequences.
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
56 And that is what Emacs normally does: it converts carriage-return
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
57 linefeed into newline when reading files, and converts newline into
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
58 carriage-return linefeed when writing files. The same mechanism that
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
59 handles conversion of international character codes does this conversion
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
60 also (@pxref{Coding Systems}).
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
61
29853
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
62 @cindex cursor location, on MS-DOS
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
63 @cindex point location, on MS-DOS
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
64 One consequence of this special format-conversion of most files is
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
65 that character positions as reported by Emacs (@pxref{Position Info}) do
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
66 not agree with the file size information known to the operating system.
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
67
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
68 In addition, if Emacs recognizes from a file's contents that it uses
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
69 newline rather than carriage-return linefeed as its line separator, it
36169
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
70 does not perform EOL conversion when reading or writing that file.
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
71 Thus, you can read and edit files from GNU and Unix systems on MS-DOS
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
72 with no special effort, and they will retain their Unix-style
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
73 end-of-line convention after you edit them.
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
74
29853
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
75 The mode line indicates whether end-of-line translation was used for
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
76 the current buffer. If MS-DOS end-of-line translation is in use for the
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
77 buffer, the MS-Windows build of Emacs displays a backslash @samp{\} after
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
78 the coding system mnemonic near the beginning of the mode line
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
79 (@pxref{Mode Line}). If no EOL translation was performed, the string
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
80 @samp{(Unix)} is displayed instead of the backslash, to alert you that the
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
81 file's EOL format is not the usual carriage-return linefeed.
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
82
29853
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
83 @cindex DOS-to-Unix conversion of files
36169
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
84 To visit a file and specify whether it uses DOS-style or Unix-style
68544
d29761b06e4e (Text and Binary, MS-DOS and MULE): Fix xrefs.
Richard M. Stallman <rms@gnu.org>
parents: 68460
diff changeset
85 end-of-line, specify a coding system (@pxref{Text Coding}). For
36169
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
86 example, @kbd{C-x @key{RET} c unix @key{RET} C-x C-f foobar.txt}
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
87 visits the file @file{foobar.txt} without converting the EOLs; if some
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
88 line ends with a carriage-return linefeed pair, Emacs will display
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
89 @samp{^M} at the end of that line. Similarly, you can direct Emacs to
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
90 save a buffer in a specified EOL format with the @kbd{C-x @key{RET} f}
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
91 command. For example, to save a buffer with Unix EOL format, type
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
92 @kbd{C-x @key{RET} f unix @key{RET} C-x C-s}. If you visit a file
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
93 with DOS EOL conversion, then save it with Unix EOL format, that
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
94 effectively converts the file to Unix EOL style, like @code{dos2unix}.
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
95
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
96 @cindex untranslated file system
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
97 @findex add-untranslated-filesystem
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
98 When you use NFS, Samba, or some other similar method to access file
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
99 systems that reside on computers using GNU or Unix systems, Emacs
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
100 should not perform end-of-line translation on any files in these file
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
101 systems---not even when you create a new file. To request this,
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
102 designate these file systems as @dfn{untranslated} file systems by
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
103 calling the function @code{add-untranslated-filesystem}. It takes one
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
104 argument: the file system name, including a drive letter and
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
105 optionally a directory. For example,
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
106
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
107 @example
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
108 (add-untranslated-filesystem "Z:")
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
109 @end example
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
110
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
111 @noindent
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
112 designates drive Z as an untranslated file system, and
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
113
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
114 @example
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
115 (add-untranslated-filesystem "Z:\\foo")
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
116 @end example
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
117
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
118 @noindent
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
119 designates directory @file{\foo} on drive Z as an untranslated file
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
120 system.
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
121
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
122 Most often you would use @code{add-untranslated-filesystem} in your
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
123 @file{.emacs} file, or in @file{site-start.el} so that all the users at
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
124 your site get the benefit of it.
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
125
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
126 @findex remove-untranslated-filesystem
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
127 To countermand the effect of @code{add-untranslated-filesystem}, use
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
128 the function @code{remove-untranslated-filesystem}. This function takes
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
129 one argument, which should be a string just like the one that was used
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
130 previously with @code{add-untranslated-filesystem}.
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
131
36169
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
132 Designating a file system as untranslated does not affect character
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
133 set conversion, only end-of-line conversion. Essentially, it directs
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
134 Emacs to create new files with the Unix-style convention of using
86e871a073b6 Delete find-file-text and find-file-binary.
Richard M. Stallman <rms@gnu.org>
parents: 35188
diff changeset
135 newline at the end of a line. @xref{Coding Systems}.
29853
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
136
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
137 @vindex file-name-buffer-file-type-alist
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
138 @cindex binary files, on MS-DOS/MS-Windows
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
139 Some kinds of files should not be converted at all, because their
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
140 contents are not really text. Therefore, Emacs on MS-Windows distinguishes
29853
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
141 certain files as @dfn{binary files}. (This distinction is not part of
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
142 MS-Windows; it is made by Emacs only.) Binary files include executable
29853
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
143 programs, compressed archives, etc. Emacs uses the file name to decide
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
144 whether to treat a file as binary: the variable
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
145 @code{file-name-buffer-file-type-alist} defines the file-name patterns
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
146 that indicate binary files. If a file name matches one of the patterns
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
147 for binary files (those whose associations are of the type
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
148 @code{(@var{pattern} . t)}, Emacs reads and writes that file using the
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
149 @code{no-conversion} coding system (@pxref{Coding Systems}) which turns
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
150 off @emph{all} coding-system conversions, not only the EOL conversion.
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
151 @code{file-name-buffer-file-type-alist} also includes file-name patterns
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
152 for files which are known to be Windows-style text files with
29853
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
153 carriage-return linefeed EOL format, such as @file{CONFIG.SYS}; Emacs
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
154 always writes those files with Windows-style EOLs.
29853
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
155
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
156 If a file which belongs to an untranslated file system matches one of
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
157 the file-name patterns in @code{file-name-buffer-file-type-alist}, the
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
158 EOL conversion is determined by @code{file-name-buffer-file-type-alist}.
d49e929bbdf6 (Text and Binary): Separate description of EOL
Eli Zaretskii <eliz@gnu.org>
parents: 29107
diff changeset
159
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
160 @node Windows Files
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
161 @section File Names on MS-Windows
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
162 @cindex file names on MS-Windows
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
163
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
164 MS-Windows and MS-DOS normally use a backslash, @samp{\}, to
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
165 separate name units within a file name, instead of the slash used on
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
166 other systems. Emacs on MS-DOS/MS-Windows permits use of either slash or
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
167 backslash, and also knows about drive letters in file names.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
168
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
169 @cindex file-name completion, on MS-Windows
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
170 On MS-DOS/MS-Windows, file names are case-insensitive, so Emacs by
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
171 default ignores letter-case in file names during completion.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
172
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
173 @vindex w32-get-true-file-attributes
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
174 If the variable @code{w32-get-true-file-attributes} is
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
175 non-@code{nil} (the default), Emacs tries to determine the accurate
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
176 link counts for files. This option is only useful on the NT family of
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
177 Windows (2K/XP/2K3), and it considerably slows down Dired and other
71544
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
178 features, so use it only on fast machines.
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
179
71468
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
180 @node ls in Lisp
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
181 @section Emulation of @code{ls} on MS-Windows
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
182 @cindex Dired, and MS-Windows/MS-DOS
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
183 @cindex @code{ls} emulation
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
184
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
185 Dired normally uses the external program @code{ls} (or its close
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
186 work-alike) to produce the directory listing displayed in Dired
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
187 buffers (@pxref{Dired}). However, MS-Windows and MS-DOS systems don't
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
188 come with such a program, although several ports of @sc{gnu} @code{ls}
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
189 are available. Therefore, Emacs on those systems @emph{emulates}
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
190 @code{ls} in Lisp, by using the @file{ls-lisp.el} package. While
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
191 @file{ls-lisp.el} provides a reasonably full emulation of @code{ls},
71544
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
192 there are some options and features peculiar to that emulation;
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
193 @iftex
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
194 for more details, see the documentation of the variables whose names
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
195 begin with @code{ls-lisp}.
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
196 @end iftex
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
197 @ifnottex
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
198 they are described in this section.
71468
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
199
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
200 The @code{ls} emulation supports many of the @code{ls} switches, but
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
201 it doesn't support all of them. Here's the list of the switches it
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
202 does support: @option{-A}, @option{-a}, @option{-B}, @option{-C},
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
203 @option{-c}, @option{-i}, @option{-G}, @option{-g}, @option{-R},
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
204 @option{-r}, @option{-S}, @option{-s}, @option{-t}, @option{-U},
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
205 @option{-u}, and @option{-X}. The @option{-F} switch is partially
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
206 supported (it appends the character that classifies the file, but does
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
207 not prevent symlink following).
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
208
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
209 @vindex ls-lisp-use-insert-directory-program
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
210 On MS-Windows and MS-DOS, @file{ls-lisp.el} is preloaded when Emacs
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
211 is built, so the Lisp emulation of @code{ls} is always used on those
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
212 platforms. If you have a ported @code{ls}, setting
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
213 @code{ls-lisp-use-insert-directory-program} to a non-@code{nil} value
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
214 will revert to using an external program named by the variable
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
215 @code{insert-directory-program}.
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
216
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
217 @vindex ls-lisp-ignore-case
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
218 By default, @file{ls-lisp.el} uses a case-sensitive sort order for
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
219 the directory listing it produces; this is so the listing looks the
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
220 same as on other platforms. If you wish that the files be sorted in
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
221 case-insensitive order, set the variable @code{ls-lisp-ignore-case} to
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
222 a non-@code{nil} value.
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
223
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
224 @vindex ls-lisp-dirs-first
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
225 By default, files and subdirectories are sorted together, to emulate
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
226 the behavior of @code{ls}. However, native MS-Windows/MS-DOS file
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
227 managers list the directories before the files; if you want that
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
228 behavior, customize the option @code{ls-lisp-dirs-first} to a
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
229 non-@code{nil} value.
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
230
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
231 @vindex ls-lisp-verbosity
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
232 The variable @code{ls-lisp-verbosity} controls the file attributes
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
233 that @file{ls-lisp.el} displays. The value should be a list that
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
234 contains one or more of the symbols @code{links}, @code{uid}, and
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
235 @code{gid}. @code{links} means display the count of different file
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
236 names that are associated with (a.k.a.@: @dfn{links to}) the file's
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
237 data. @code{uid} means display the numerical identifier of the user
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
238 who owns the file. @code{gid} means display the numerical identifier
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
239 of the file owner's group. The default value is @code{(links uid gid)}
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
240 i.e.@: all the 3 optional attributes are displayed.
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
241
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
242 @vindex ls-lisp-emulation
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
243 The variable @code{ls-lisp-emulation} controls the flavour of the
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
244 @code{ls} emulation by setting the defaults for the 3 options
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
245 described above: @code{ls-lisp-ignore-case},
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
246 @code{ls-lisp-dirs-first}, and @code{ls-lisp-verbosity}. The value of
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
247 this option can be one of the following symbols:
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
248
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
249 @table @code
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
250 @item GNU
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
251 @itemx nil
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
252 Emulate @sc{gnu} systems; this is the default. This sets
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
253 @code{ls-lisp-ignore-case} and @code{ls-lisp-dirs-first} to
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
254 @code{nil}, and @code{ls-lisp-verbosity} to @code{(links uid gid)}.
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
255 @item UNIX
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
256 Emulate Unix systems. Like @code{GNU}, but sets
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
257 @code{ls-lisp-verbosity} to @code{(links uid)}.
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
258 @item MacOS
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
259 Emulate MacOS. Sets @code{ls-lisp-ignore-case} to @code{t}, and
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
260 @code{ls-lisp-dirs-first} and @code{ls-lisp-verbosity} to @code{nil}.
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
261 @item MS-Windows
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
262 Emulate MS-Windows. Sets @code{ls-lisp-ignore-case} and
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
263 @code{ls-lisp-dirs-first} to @code{t}, and @code{ls-lisp-verbosity} to
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
264 @code{(links)} on Windows NT/2K/XP/2K3 and to @code{nil} on Windows 9X.
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
265 Note that the default emulation is @emph{not} @code{MS-Windows}, even
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
266 on Windows, since many users of Emacs on those platforms prefer the
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
267 @sc{gnu} defaults.
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
268 @end table
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
269
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
270 @noindent
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
271 Any other value of @code{ls-lisp-emulation} means the same as
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
272 @code{GNU}. Note that this option needs to be set @emph{before}
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
273 @file{ls-lisp.el} is loaded, which means that on MS-Windows and MS-DOS
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
274 you will have to set the value from your @file{.emacs} file and then
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
275 restart Emacs, since @file{ls-lisp.el} is preloaded.
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
276
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
277 @vindex ls-lisp-support-shell-wildcards
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
278 The variable @code{ls-lisp-support-shell-wildcards} controls how
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
279 file-name patterns are supported: if it is non-@code{nil} (the
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
280 default), they are treated as shell-style wildcards; otherwise they
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
281 are treated as Emacs regular expressions.
71544
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
282 @end ifnottex
71468
d0f19f61af38 (ls in Lisp): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 70782
diff changeset
283
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
284 @node Windows HOME
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
285 @section HOME Directory on MS-Windows
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
286 @cindex @code{HOME} directory on MS-Windows
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
287
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
288 The MS-Windows equivalent of the @code{HOME} directory is the
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
289 @dfn{user-specific application data directory}. The actual location
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
290 depends on your Windows version and system configuration; typical values
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
291 are @file{C:\Documents and Settings\@var{username}\Application Data} on
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
292 Windows 2K/XP and later, and either @file{C:\WINDOWS\Application Data}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
293 or @file{C:\WINDOWS\Profiles\@var{username}\Application Data} on the
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
294 older Windows 9X/ME systems.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
295
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
296 @cindex init file @file{.emacs} on MS-Windows
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
297 The home directory is where your init file @file{.emacs} is stored.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
298 When Emacs starts, it first checks whether the environment variable
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
299 @env{HOME} is set. If it is, it looks for the init file in the
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
300 directory pointed by @env{HOME}. If @env{HOME} is not defined, Emacs
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
301 checks for an existing @file{.emacs} file in @file{C:\}, the root
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
302 directory of drive @file{C:}@footnote{
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
303 The check in @file{C:\} is in preference to the application data
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
304 directory for compatibility with older versions of Emacs, which didn't
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
305 check the application data directory.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
306 }. If there's no such file in @file{C:\}, Emacs next uses the Windows
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
307 system calls to find out the exact location of your application data
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
308 directory. If that fails as well, Emacs falls back to @file{C:\}.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
309
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
310 Whatever the final place is, Emacs sets the value of the @env{HOME}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
311 environment variable to point to it, and it will use that location for
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
312 other files and directories it normally creates in the user's home
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
313 directory.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
314
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
315 You can always find out where Emacs thinks is your home directory's
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
316 location by typing @kbd{C-x d ~/ @key{RET}}. This should present the
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
317 list of files in the home directory, and show its full name on the
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
318 first line. Likewise, to visit your init file, type @kbd{C-x C-f
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
319 ~/.emacs @key{RET}}.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
320
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
321 @cindex @file{_emacs} init file, MS-Windows
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
322 Because MS-DOS does not allow file names with leading dots, and
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
323 because older Windows systems made it hard to create files with such
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
324 names, the Windows port of Emacs supports an alternative name
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
325 @file{_emacs} as a fallback, if such a file exists in the home
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
326 directory, whereas @file{.emacs} does not.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
327
71470
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
328 @node Windows Keyboard
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
329 @section Keyboard Usage on MS-Windows
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
330 @cindex keyboard, MS-Windows
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
331
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
332 This section describes the Windows-specific features related to
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
333 keyboard input in Emacs.
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
334
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
335 @kindex F10 @r{(MS-Windows)}
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
336 @cindex menu bar access using keyboard @r{(MS-Windows)}
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
337 The @key{F10} key on Windows activates the menu bar in a way that
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
338 makes it possible to use the menus without a mouse. In this mode, the
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
339 arrow keys traverse the menus, @key{RET} selects a highlighted menu
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
340 item, and @key{ESC} closes the menu.
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
341
71544
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
342 @ifnottex
71470
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
343 @vindex w32-alt-is-meta
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
344 @cindex @code{Alt} key (MS-Windows)
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
345 By default, the key labeled @key{Alt} is mapped as the @key{META}
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
346 key. If you wish it to produce the @code{Alt} modifier instead, set
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
347 the variable @code{w32-alt-is-meta} to a @code{nil} value.
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
348
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
349 @vindex w32-capslock-is-shiftlock
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
350 By default, the @key{CapsLock} key only affects normal character
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
351 keys (it converts lower-case characters to their upper-case
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
352 variants). However, if you set the variable
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
353 @code{w32-capslock-is-shiftlock} to a non-@code{nil} value, the
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
354 @key{CapsLock} key will affect non-character keys as well, as if you
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
355 pressed the @key{Shift} key while typing the non-character key.
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
356
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
357 @vindex w32-enable-caps-lock
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
358 If the variable @code{w32-enable-caps-lock} is set to a @code{nil}
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
359 value, the @key{CapsLock} key produces the symbol @code{capslock}
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
360 instead of the shifted version of they keys. The default value is
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
361 @code{t}.
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
362
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
363 @vindex w32-enable-num-lock
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
364 @cindex keypad keys (MS-Windows)
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
365 Similarly, if @code{w32-enable-num-lock} is @code{nil}, the
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
366 @key{NumLock} key will produce the symbol @code{kp-numlock}. The
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
367 default is @code{t}, which causes @key{NumLock} to work as expected:
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
368 toggle the meaning of the keys on the numeric keypad.
71544
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
369 @end ifnottex
71470
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
370
71472
9f15a47055ac Fix last change.
Eli Zaretskii <eliz@gnu.org>
parents: 71470
diff changeset
371 @vindex w32-apps-modifier
9f15a47055ac Fix last change.
Eli Zaretskii <eliz@gnu.org>
parents: 71470
diff changeset
372 The variable @code{w32-apps-modifier} controls the effect of the
9f15a47055ac Fix last change.
Eli Zaretskii <eliz@gnu.org>
parents: 71470
diff changeset
373 @key{Apps} key (usually located between the right @key{Alt} and the
9f15a47055ac Fix last change.
Eli Zaretskii <eliz@gnu.org>
parents: 71470
diff changeset
374 right @key{Ctrl} keys). Its value can be one of the symbols
9f15a47055ac Fix last change.
Eli Zaretskii <eliz@gnu.org>
parents: 71470
diff changeset
375 @code{hyper}, @code{super}, @code{meta}, @code{alt}, @code{control},
9f15a47055ac Fix last change.
Eli Zaretskii <eliz@gnu.org>
parents: 71470
diff changeset
376 or @code{shift} for the respective modifier, or @code{nil} to appear
9f15a47055ac Fix last change.
Eli Zaretskii <eliz@gnu.org>
parents: 71470
diff changeset
377 as the key @code{apps}. The default is @code{nil}.
9f15a47055ac Fix last change.
Eli Zaretskii <eliz@gnu.org>
parents: 71470
diff changeset
378
71470
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
379 @vindex w32-lwindow-modifier
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
380 @vindex w32-rwindow-modifier
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
381 @vindex w32-scroll-lock-modifier
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
382 The variable @code{w32-lwindow-modifier} determines the effect of
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
383 the left Windows key (usually labeled with @key{start} and the Windows
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
384 logo). If its value is @code{nil} (the default), the key will produce
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
385 the symbol @code{lwindow}. Setting it to one of the symbols
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
386 @code{hyper}, @code{super}, @code{meta}, @code{alt}, @code{control},
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
387 or @code{shift} will produce the respective modifier. A similar
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
388 variable @code{w32-rwindow-modifier} controls the effect of the right
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
389 Windows key, and @code{w32-scroll-lock-modifier} does the same for the
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
390 @key{ScrLock} key. If these variables are set to @code{nil}, the
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
391 right Windows key produces the symbol @code{rwindow} and @key{ScrLock}
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
392 produces the symbol @code{scroll}.
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
393
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
394 @vindex w32-pass-alt-to-system
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
395 @cindex Windows system menu
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
396 @cindex @code{Alt} key invokes menu (Windows)
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
397 Emacs compiled as a native Windows application normally turns off
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
398 the Windows feature that tapping the @key{ALT} key invokes the Windows
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
399 menu. The reason is that the @key{ALT} serves as @key{META} in Emacs.
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
400 When using Emacs, users often press the @key{META} key temporarily and
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
401 then change their minds; if this has the effect of bringing up the
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
402 Windows menu, it alters the meaning of subsequent commands. Many
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
403 users find this frustrating.
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
404
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
405 You can re-enable Windows' default handling of tapping the @key{ALT}
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
406 key by setting @code{w32-pass-alt-to-system} to a non-@code{nil}
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
407 value.
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
408
71544
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
409 @ifnottex
71470
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
410 @vindex w32-pass-lwindow-to-system
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
411 @vindex w32-pass-rwindow-to-system
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
412 The variables @code{w32-pass-lwindow-to-system} and
71470
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
413 @code{w32-pass-rwindow-to-system} determine whether the respective
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
414 keys are passed to Windows or swallowed by Emacs. If the value is
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
415 @code{nil}, the respective key is silently swallowed by Emacs,
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
416 otherwise it is passed to Windows. The default is @code{t} for both
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
417 of these variables. Passing each of these keys to Windows produces
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
418 its normal effect: for example, @kbd{@key{Lwindow}} opens the
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
419 @code{Start} menu, etc.
71470
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
420
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
421 @vindex w32-recognize-altgr
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
422 @kindex AltGr @r{(MS-Windows)}
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
423 @cindex AltGr key (MS-Windows)
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
424 The variable @code{w32-recognize-altgr} controls whether the right
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
425 @key{Alt} and left @key{Ctrl} keys are recognized as the @key{AltGr}
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
426 key. The default is @code{t}, which means these keys produce
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
427 @code{AltGr}; setting them to @code{nil} causes these keys to be
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
428 interpreted normally (as the respective modifiers).
71544
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
429 @end ifnottex
71470
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
430
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
431 @node Windows Mouse
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
432 @section Mouse Usage on MS-Windows
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
433 @cindex mouse, and MS-Windows
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
434
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
435 This section describes the Windows-specific variables related to
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
436 mouse.
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
437
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
438 @vindex w32-mouse-button-tolerance
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
439 @cindex simulation of middle mouse button
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
440 The variable @code{w32-mouse-button-tolerance} specifies the
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
441 time interval, in milliseconds, for faking middle mouse button press
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
442 on 2-button mice. If both mouse buttons are depressed within this
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
443 time interval, Emacs generates a middle mouse button click event
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
444 instead of a double click on one of the buttons.
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
445
71544
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
446 @ifnottex
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
447 @vindex w32-pass-extra-mouse-buttons-to-system
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
448 If the variable @code{w32-pass-extra-mouse-buttons-to-system} is
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
449 non-@code{nil}, Emacs passes the fourth and fifth mouse buttons to
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
450 Windows.
71544
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
451 @end ifnottex
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
452
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
453 @vindex w32-swap-mouse-buttons
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
454 The variable @code{w32-swap-mouse-buttons} controls which of the 3
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
455 mouse buttons generates the @kbd{mouse-2} events. When it is
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
456 @code{nil} (the default), the middle button generates @kbd{mouse-2}
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
457 and the right button generates @kbd{mouse-3} events. If this variable
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
458 is non-@code{nil}, the roles of these two buttons are reversed.
71470
5785f48e4265 (Windows Keyboard): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71468
diff changeset
459
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
460 @node Windows Processes
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
461 @section Subprocesses on Windows 9X/ME and Windows NT/2K/XP
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
462 @cindex subprocesses on MS-Windows
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
463
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
464 @cindex DOS applications, running from Emacs
60110
f1ac3b1b3584 (MS-DOS Keyboard, MS-DOS Mouse): Split from MS-DOS Input node.
Richard M. Stallman <rms@gnu.org>
parents: 57368
diff changeset
465 Emacs compiled as a native Windows application (as opposed to the DOS
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
466 version) includes full support for asynchronous subprocesses.
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
467 In the Windows version, synchronous and asynchronous subprocesses work
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
468 fine on both
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
469 Windows 9X/ME and Windows NT/2K/XP as long as you run only 32-bit Windows
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
470 applications. However, when you run a DOS application in a subprocess,
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
471 you may encounter problems or be unable to run the application at all;
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
472 and if you run two DOS applications at the same time in two
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
473 subprocesses, you may have to reboot your system.
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
474
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
475 Since the standard command interpreter (and most command line utilities)
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
476 on Windows 9X are DOS applications, these problems are significant when
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
477 using that system. But there's nothing we can do about them; only
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
478 Microsoft can fix them.
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
479
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
480 If you run just one DOS application subprocess, the subprocess should
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
481 work as expected as long as it is ``well-behaved'' and does not perform
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
482 direct screen access or other unusual actions. If you have a CPU
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
483 monitor application, your machine will appear to be 100% busy even when
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
484 the DOS application is idle, but this is only an artifact of the way CPU
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
485 monitors measure processor load.
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
486
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
487 You must terminate the DOS application before you start any other DOS
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
488 application in a different subprocess. Emacs is unable to interrupt or
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
489 terminate a DOS subprocess. The only way you can terminate such a
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
490 subprocess is by giving it a command that tells its program to exit.
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
491
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
492 If you attempt to run two DOS applications at the same time in separate
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
493 subprocesses, the second one that is started will be suspended until the
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
494 first one finishes, even if either or both of them are asynchronous.
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
495
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
496 @cindex kill DOS application
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
497 If you can go to the first subprocess, and tell it to exit, the second
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
498 subprocess should continue normally. However, if the second subprocess
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
499 is synchronous, Emacs itself will be hung until the first subprocess
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
500 finishes. If it will not finish without user input, then you have no
39142
449f9371ac14 Mention Windows ME and Windows 2000 in the list of supported versions.
Eli Zaretskii <eliz@gnu.org>
parents: 38869
diff changeset
501 choice but to reboot if you are running on Windows 9X. If you are
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
502 running on Windows NT/2K/XP, you can use a process viewer application to kill
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
503 the appropriate instance of NTVDM instead (this will terminate both DOS
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
504 subprocesses).
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
505
39142
449f9371ac14 Mention Windows ME and Windows 2000 in the list of supported versions.
Eli Zaretskii <eliz@gnu.org>
parents: 38869
diff changeset
506 If you have to reboot Windows 9X in this situation, do not use the
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
507 @code{Shutdown} command on the @code{Start} menu; that usually hangs the
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
508 system. Instead, type @kbd{CTL-ALT-@key{DEL}} and then choose
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
509 @code{Shutdown}. That usually works, although it may take a few minutes
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
510 to do its job.
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
511
71544
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
512 @ifnottex
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
513 @vindex w32-quote-process-args
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
514 The variable @code{w32-quote-process-args} controls how the process
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
515 arguments are quoted. If it is non-@code{nil} means they are quoted
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
516 with the @code{"} character. If the value is a character, that
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
517 character will be used to escape any quote characters that appear;
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
518 otherwise a suitable escape character will be chosen based on the type
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
519 of the program.
71544
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
520 @end ifnottex
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
521
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
522 @node Windows Printing
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
523 @section Printing and MS-Windows
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
524
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
525 Printing commands, such as @code{lpr-buffer} (@pxref{Printing}) and
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
526 @code{ps-print-buffer} (@pxref{PostScript}) work in MS-DOS and
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
527 MS-Windows by sending the output to one of the printer ports, if a
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
528 Posix-style @code{lpr} program is unavailable. The same Emacs
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
529 variables control printing on all systems, but in some cases they have
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
530 different default values on MS-DOS and MS-Windows.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
531
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
532 Emacs on Windows automatically determines your default printer and
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
533 sets the variable @var{printer-name} to that printer's name. But in
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
534 some rare cases this can fail, or you may wish to use a different
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
535 printer from within Emacs. The rest of this section explains how to
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
536 tell Emacs which printer to use.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
537
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
538 @vindex printer-name@r{, (MS-DOS/MW-Windows)}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
539 If you want to use your local printer, then set the Lisp variable
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
540 @code{lpr-command} to @code{""} (its default value on Windows) and
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
541 @code{printer-name} to the name of the printer port---for example,
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
542 @code{"PRN"}, the usual local printer port or @code{"LPT2"}, or
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
543 @code{"COM1"} for a serial printer. You can also set
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
544 @code{printer-name} to a file name, in which case ``printed'' output
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
545 is actually appended to that file. If you set @code{printer-name} to
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
546 @code{"NUL"}, printed output is silently discarded (sent to the system
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
547 null device).
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
548
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
549 You can also use a printer shared by another machine by setting
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
550 @code{printer-name} to the UNC share name for that printer---for
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
551 example, @code{"//joes_pc/hp4si"}. (It doesn't matter whether you use
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
552 forward slashes or backslashes here.) To find out the names of shared
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
553 printers, run the command @samp{net view} from the command prompt to
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
554 obtain a list of servers, and @samp{net view @var{server-name}} to see
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
555 the names of printers (and directories) shared by that server.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
556 Alternatively, click the @samp{Network Neighborhood} icon on your
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
557 desktop, and look for machines which share their printers via the
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
558 network.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
559
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
560 @cindex @samp{net use}, and printing on MS-Windows
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
561 @cindex networked printers (MS-Windows)
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
562 If the printer doesn't appear in the output of @samp{net view}, or
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
563 if setting @code{printer-name} to the UNC share name doesn't produce a
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
564 hardcopy on that printer, you can use the @samp{net use} command to
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
565 connect a local print port such as @code{"LPT2"} to the networked
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
566 printer. For example, typing @kbd{net use LPT2: \\joes_pc\hp4si}@footnote{
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
567 Note that the @samp{net use} command requires the UNC share name to be
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
568 typed with the Windows-style backslashes, while the value of
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
569 @code{printer-name} can be set with either forward- or backslashes.}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
570 causes Windows to @dfn{capture} the @code{LPT2} port and redirect the
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
571 printed material to the printer connected to the machine @code{joes_pc}.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
572 After this command, setting @code{printer-name} to @code{"LPT2"}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
573 should produce the hardcopy on the networked printer.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
574
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
575 With some varieties of Windows network software, you can instruct
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
576 Windows to capture a specific printer port such as @code{"LPT2"}, and
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
577 redirect it to a networked printer via the @w{@code{Control
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
578 Panel->Printers}} applet instead of @samp{net use}.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
579
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
580 If you set @code{printer-name} to a file name, it's best to use an
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
581 absolute file name. Emacs changes the working directory according to
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
582 the default directory of the current buffer, so if the file name in
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
583 @code{printer-name} is relative, you will end up with several such
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
584 files, each one in the directory of the buffer from which the printing
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
585 was done.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
586
70782
9fb34710a5dd (Windows Printing): Mention non-support of plain text printing with some
Eli Zaretskii <eliz@gnu.org>
parents: 70472
diff changeset
587 If the value of @code{printer-name} is correct, but printing does
9fb34710a5dd (Windows Printing): Mention non-support of plain text printing with some
Eli Zaretskii <eliz@gnu.org>
parents: 70472
diff changeset
588 not produce the hardcopy on your printer, it is possible that your
9fb34710a5dd (Windows Printing): Mention non-support of plain text printing with some
Eli Zaretskii <eliz@gnu.org>
parents: 70472
diff changeset
589 printer does not support printing plain text (some cheap printers omit
9fb34710a5dd (Windows Printing): Mention non-support of plain text printing with some
Eli Zaretskii <eliz@gnu.org>
parents: 70472
diff changeset
590 this functionality). In that case, as a workaround, try the
9fb34710a5dd (Windows Printing): Mention non-support of plain text printing with some
Eli Zaretskii <eliz@gnu.org>
parents: 70472
diff changeset
591 PostScript print commands, described below, to the same printer
9fb34710a5dd (Windows Printing): Mention non-support of plain text printing with some
Eli Zaretskii <eliz@gnu.org>
parents: 70472
diff changeset
592
70153
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
593 @findex print-buffer @r{(MS-DOS)}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
594 @findex print-region @r{(MS-DOS)}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
595 @vindex lpr-headers-switches @r{(MS-DOS)}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
596 The commands @code{print-buffer} and @code{print-region} call the
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
597 @code{pr} program, or use special switches to the @code{lpr} program, to
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
598 produce headers on each printed page. MS-DOS and MS-Windows don't
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
599 normally have these programs, so by default, the variable
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
600 @code{lpr-headers-switches} is set so that the requests to print page
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
601 headers are silently ignored. Thus, @code{print-buffer} and
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
602 @code{print-region} produce the same output as @code{lpr-buffer} and
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
603 @code{lpr-region}, respectively. If you do have a suitable @code{pr}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
604 program (for example, from GNU Coreutils), set
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
605 @code{lpr-headers-switches} to @code{nil}; Emacs will then call
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
606 @code{pr} to produce the page headers, and print the resulting output as
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
607 specified by @code{printer-name}.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
608
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
609 @vindex print-region-function @r{(MS-DOS)}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
610 @cindex lpr usage under MS-DOS
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
611 @vindex lpr-command @r{(MS-DOS)}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
612 @vindex lpr-switches @r{(MS-DOS)}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
613 Finally, if you do have an @code{lpr} work-alike, you can set the
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
614 variable @code{lpr-command} to @code{"lpr"}. Then Emacs will use
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
615 @code{lpr} for printing, as on other systems. (If the name of the
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
616 program isn't @code{lpr}, set @code{lpr-command} to specify where to
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
617 find it.) The variable @code{lpr-switches} has its standard meaning
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
618 when @code{lpr-command} is not @code{""}. If the variable
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
619 @code{printer-name} has a string value, it is used as the value for the
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
620 @code{-P} option to @code{lpr}, as on Unix.
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
621
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
622 @findex ps-print-buffer @r{(MS-DOS)}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
623 @findex ps-spool-buffer @r{(MS-DOS)}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
624 @vindex ps-printer-name @r{(MS-DOS)}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
625 @vindex ps-lpr-command @r{(MS-DOS)}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
626 @vindex ps-lpr-switches @r{(MS-DOS)}
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
627 A parallel set of variables, @code{ps-lpr-command},
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
628 @code{ps-lpr-switches}, and @code{ps-printer-name} (@pxref{PostScript
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
629 Variables}), defines how PostScript files should be printed. These
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
630 variables are used in the same way as the corresponding variables
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
631 described above for non-PostScript printing. Thus, the value of
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
632 @code{ps-printer-name} is used as the name of the device (or file) to
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
633 which PostScript output is sent, just as @code{printer-name} is used
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
634 for non-PostScript printing. (There are two distinct sets of
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
635 variables in case you have two printers attached to two different
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
636 ports, and only one of them is a PostScript printer.)
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
637
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
638 The default value of the variable @code{ps-lpr-command} is @code{""},
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
639 which causes PostScript output to be sent to the printer port specified
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
640 by @code{ps-printer-name}, but @code{ps-lpr-command} can also be set to
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
641 the name of a program which will accept PostScript files. Thus, if you
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
642 have a non-PostScript printer, you can set this variable to the name of
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
643 a PostScript interpreter program (such as Ghostscript). Any switches
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
644 that need to be passed to the interpreter program are specified using
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
645 @code{ps-lpr-switches}. (If the value of @code{ps-printer-name} is a
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
646 string, it will be added to the list of switches as the value for the
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
647 @code{-P} option. This is probably only useful if you are using
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
648 @code{lpr}, so when using an interpreter typically you would set
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
649 @code{ps-printer-name} to something other than a string so it is
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
650 ignored.)
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
651
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
652 For example, to use Ghostscript for printing on the system's default
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
653 printer, put this in your @file{.emacs} file:
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
654
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
655 @example
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
656 (setq ps-printer-name t)
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
657 (setq ps-lpr-command "D:/gs6.01/bin/gswin32c.exe")
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
658 (setq ps-lpr-switches '("-q" "-dNOPAUSE" "-dBATCH"
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
659 "-sDEVICE=mswinpr2"
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
660 "-sPAPERSIZE=a4"))
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
661 @end example
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
662
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
663 @noindent
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
664 (This assumes that Ghostscript is installed in the
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
665 @file{D:/gs6.01} directory.)
63b105ced679 (Windows Files, Windows HOME, MS-Windows Printing): New nodes.
Eli Zaretskii <eliz@gnu.org>
parents: 69898
diff changeset
666
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
667 @node Windows Misc
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
668 @section Miscellaneous Windows-specific features
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
669
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
670 This section describes miscellaneous Windows-specific features.
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
671
71544
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
672 @ifnottex
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
673 @vindex w32-grab-focus-on-raise
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
674 @cindex frame focus policy, MS-Windows
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
675 The variable @code{w32-grab-focus-on-raise}, if set to a
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
676 non-@code{nil} value causes a frame to grab focus when it is raised.
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
677 The default is @code{t}, which fits well with the Windows default
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
678 click-to-focus policy.
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
679
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
680 @vindex w32-list-proportional-fonts
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
681 The variable @code{w32-list-proportional-fonts} controls whether
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
682 proportional fonts are included in the font selection dialog. If its
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
683 value is non-@code{nil}, these fonts will be included. The default is
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
684 @code{nil}.
71544
70062eaec923 (ls in Lisp, Windows Keyboard, Windows Mouse)
Eli Zaretskii <eliz@gnu.org>
parents: 71473
diff changeset
685 @end ifnottex
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
686
71473
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
687 @vindex w32-use-visible-system-caret
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
688 @cindex screen reader software, MS-Windows
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
689 The variable @code{w32-use-visible-system-caret} is a flag that
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
690 determines whether to make the system caret visible. The default is
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
691 @code{nil}, which means Emacs draws its own cursor to indicate the
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
692 position of point. A non-@code{nil} value means Emacs will indicate
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
693 point location by the system caret; this facilitates use of screen
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
694 reader software. When this variable is non-@code{nil}, other
662c32135523 (Windows Mouse): New section.
Eli Zaretskii <eliz@gnu.org>
parents: 71472
diff changeset
695 variables affecting the cursor display have no effect.
24095
8983dda2d520 Initial revision
Andrew Innes <andrewi@gnu.org>
parents:
diff changeset
696
70443
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
697 @ifnottex
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
698 @include msdog-xtra.texi
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
699 @end ifnottex
8e32c8ab08d7 (Microsoft Windows): Rename from "Emacs and Microsoft Windows". All
Eli Zaretskii <eliz@gnu.org>
parents: 70437
diff changeset
700
52401
695cf19ef79e Add arch taglines
Miles Bader <miles@gnu.org>
parents: 49600
diff changeset
701 @ignore
695cf19ef79e Add arch taglines
Miles Bader <miles@gnu.org>
parents: 49600
diff changeset
702 arch-tag: f39d2590-5dcc-4318-88d9-0eb73ca10fa2
695cf19ef79e Add arch taglines
Miles Bader <miles@gnu.org>
parents: 49600
diff changeset
703 @end ignore