34198
|
1 @c This is part of the Emacs manual.
|
64890
|
2 @c Copyright (C) 2000, 2001, 2002, 2003, 2004,
|
68639
|
3 @c 2005, 2006 Free Software Foundation, Inc.
|
34198
|
4 @c See file emacs.texi for copying conditions.
|
70435
|
5 @node Mac OS, Microsoft Windows, Antinews, Top
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
6 @appendix Emacs and Mac OS
|
34198
|
7 @cindex Mac OS
|
|
8 @cindex Macintosh
|
|
9
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
10 This section briefly describes the peculiarities of using Emacs
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
11 under Mac OS with native window system support. For Mac OS X, Emacs
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
12 can be built either without window system support, with X11, or with
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
13 Carbon API. This section only applies to the Carbon build. For Mac
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
14 OS Classic, Emacs can be built with or without Carbon API, and this
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
15 section applies to either of them because they run on the native
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
16 window system.
|
34198
|
17
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
18 Emacs built on Mac OS X supports most of its major features except
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
19 display support of PostScript images. The following features of Emacs
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
20 are not supported on Mac OS Classic: unexec (@code{dump-emacs}),
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
21 asynchronous subprocesses (@code{start-process}), and networking
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
22 (@code{open-network-stream}). As a result, packages such as Gnus,
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
23 GUD, and Comint do not work. Synchronous subprocesses
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
24 (@code{call-process}) are supported on non-Carbon build, but
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
25 specially-crafted external programs are needed. Since external
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
26 programs to handle commands such as @code{print-buffer} and
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
27 @code{diff} are not available on Mac OS Classic, they are not
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
28 supported. Non-Carbon build on Mac OS Classic does not support some
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
29 features such as file dialogs, drag-and-drop, and Unicode menus.
|
34198
|
30
|
|
31 @menu
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
32 * Input: Mac Input. Keyboard and mouse input on Mac.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
33 * Intl: Mac International. International character sets on Mac.
|
36163
|
34 * Env: Mac Environment Variables. Setting environment variables for Emacs.
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
35 * Directories: Mac Directories. Volumes and directories on Mac.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
36 * Font: Mac Font Specs. Specifying fonts on Mac.
|
36163
|
37 * Functions: Mac Functions. Mac-specific Lisp functions.
|
34198
|
38 @end menu
|
|
39
|
|
40 @node Mac Input
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
41 @section Keyboard and Mouse Input on Mac
|
36263
|
42 @cindex Meta (Mac OS)
|
|
43 @cindex keyboard coding (Mac OS)
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
44
|
67100
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
45 @vindex mac-control-modifier
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
46 @vindex mac-command-modifier
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
47 @vindex mac-option-modifier
|
71357
c2028c244c54
(Mac Input): Add description of mac-function-modifier.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
48 @vindex mac-function-modifier
|
c2028c244c54
(Mac Input): Add description of mac-function-modifier.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
49 On Mac, Emacs can use @key{control}, @key{command}, @key{option}, and
|
c2028c244c54
(Mac Input): Add description of mac-function-modifier.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
50 laptop @key{function} keys as any of Emacs modifier keys except
|
c2028c244c54
(Mac Input): Add description of mac-function-modifier.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
51 @key{SHIFT} (i.e., @key{ALT}, @key{CTRL}, @key{HYPER}, @key{META}, and
|
c2028c244c54
(Mac Input): Add description of mac-function-modifier.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
52 @key{SUPER}). The assignment is controlled by the variables
|
c2028c244c54
(Mac Input): Add description of mac-function-modifier.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
53 @code{mac-control-modifier}, @code{mac-command-modifier},
|
71361
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
54 @code{mac-option-modifier}, and @code{mac-function-modifier}. The value
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
55 for each of these variables can be one of the following symbols:
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
56 @code{alt}, @code{control}, @code{hyper}, @code{meta}, @code{super}, and
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
57 @code{nil} (no particular assignment). By default, the @key{control}
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
58 key works as @key{CTRL}, and the @key{command} key as @key{META}.
|
34198
|
59
|
67100
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
60 For the @key{option} key, if @code{mac-option-modifier} is set to
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
61 @code{nil}, which is the default, the key works as the normal
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
62 @key{option} key, i.e., dead-key processing will work. This is useful
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
63 for entering non-@acronym{ASCII} Latin characters directly from the
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
64 Mac keyboard, for example.
|
34198
|
65
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
66 Emacs recognizes the setting in the Keyboard control panel (Mac OS
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
67 Classic) or the International system preference pane (Mac OS X) and
|
71357
c2028c244c54
(Mac Input): Add description of mac-function-modifier.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
68 supports international and alternative keyboard layouts (e.g., Dvorak).
|
c2028c244c54
(Mac Input): Add description of mac-function-modifier.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
69 Selecting one of the layouts from the keyboard layout pull-down menu
|
c2028c244c54
(Mac Input): Add description of mac-function-modifier.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
70 will affect how the keys typed on the keyboard are interpreted.
|
34198
|
71
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
72 @vindex mac-pass-command-to-system
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
73 @vindex mac-pass-control-to-system
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
74 Mac OS intercepts and handles certain key combinations (e.g.,
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
75 @key{command}-@key{SPC} for switching input languages). These will not
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
76 be passed to Emacs. One can disable this interception by setting
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
77 @code{mac-pass-command-to-system} or @code{mac-pass-control-to-system}
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
78 to @code{nil}.
|
34198
|
79
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
80 @vindex mac-emulate-three-button-mouse
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
81 Especially for one-button mice, the multiple button feature can be
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
82 emulated by setting @code{mac-emulate-three-button-mouse} to @code{t}
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
83 or @code{reverse}. If set to @code{t} (@code{reverse}, respectively),
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
84 pressing the mouse button with the @key{option} key is recognized as
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
85 the second (third) button, and that with the @key{command} key is
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
86 recognized as the third (second) button.
|
34198
|
87
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
88 @vindex mac-wheel-button-is-mouse-2
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
89 For multi-button mice, the wheel button and the secondary button are
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
90 recognized as the second and the third button, respectively. If
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
91 @code{mac-wheel-button-is-mouse-2} is set to @code{nil}, their roles
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
92 are exchanged.
|
34198
|
93
|
|
94 @node Mac International
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
95 @section International Character Set Support on Mac
|
34198
|
96 @cindex Mac Roman coding system
|
36263
|
97 @cindex clipboard support (Mac OS)
|
34198
|
98
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
99 Mac uses non-standard encodings for the upper 128 single-byte
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
100 characters. They also deviate from the ISO 2022 standard by using
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
101 character codes in the range 128-159. The coding systems
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
102 @code{mac-roman}, @code{mac-centraleurroman}, and @code{mac-cyrillic}
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
103 are used to represent these Mac encodings.
|
34198
|
104
|
|
105 You can use input methods provided either by LEIM (@pxref{Input
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
106 Methods}) or Mac OS to enter international characters. To use the
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
107 former, see the International Character Set Support section of the
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
108 manual (@pxref{International}).
|
34198
|
109
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
110 Emacs on Mac OS automatically changes the value of
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
111 @code{keyboard-coding-system} according to the current keyboard
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
112 layout. So users don't need to set it manually, and even if set, it
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
113 will be changed when the keyboard layout change is detected next time.
|
34198
|
114
|
|
115 The Mac clipboard and the Emacs kill ring (@pxref{Killing}) are
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
116 synchronized by default: you can yank a piece of text and paste it
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
117 into another Mac application, or cut or copy one in another Mac
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
118 application and yank it into a Emacs buffer. This feature can be
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
119 disabled by setting @code{x-select-enable-clipboard} to @code{nil}.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
120 One can still do copy and paste with another application from the Edit
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
121 menu.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
122
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
123 On Mac, the role of the coding system for selection that is set by
|
68543
|
124 @code{set-selection-coding-system} (@pxref{Communication Coding}) is
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
125 two-fold. First, it is used as a preferred coding system for the
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
126 traditional text flavor that does not specify any particular encodings
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
127 and is mainly used by applications on Mac OS Classic. Second, it
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
128 specifies the intermediate encoding for the UTF-16 text flavor that is
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
129 mainly used by applications on Mac OS X.
|
34198
|
130
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
131 When pasting UTF-16 text data from the clipboard, it is first
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
132 converted to the encoding specified by the selection coding system
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
133 using the converter in the Mac OS system, and then decoded into the
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
134 Emacs internal encoding using the converter in Emacs. If the first
|
68036
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
135 conversion failed, then the UTF-16 data is directly converted to Emacs
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
136 internal encoding using the converter in Emacs. Copying UTF-16 text
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
137 to the clipboard goes through the inverse path. The reason for this
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
138 two-pass decoding is to avoid subtle differences in Unicode mappings
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
139 between the Mac OS system and Emacs such as various kinds of hyphens,
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
140 and to minimize users' customization. For example, users that mainly
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
141 use Latin characters would prefer Greek characters to be decoded into
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
142 the @code{mule-unicode-0100-24ff} charset, but Japanese users would
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
143 prefer them to be decoded into the @code{japanese-jisx0208} charset.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
144 Since the coding system for selection is automatically set according
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
145 to the system locale setting, users usually don't have to set it
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
146 manually.
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
147
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
148 The default language environment (@pxref{Language Environments}) is
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
149 set according to the locale setting at the startup time. On Mac OS,
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
150 the locale setting is consulted in the following order:
|
34198
|
151
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
152 @enumerate
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
153 @item
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
154 Environment variables @env{LC_ALL}, @env{LC_CTYPE} and @env{LANG} as
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
155 in other systems.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
156
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
157 @item
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
158 Preference @code{AppleLocale} that is set by default on Mac OS X 10.3
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
159 and later.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
160
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
161 @item
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
162 Preference @code{AppleLanguages} that is set by default on Mac OS X
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
163 10.1 and later.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
164
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
165 @item
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
166 Variable @code{mac-system-locale} that is derived from the system
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
167 language and region codes. This variable is available on all
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
168 supported Mac OS versions including Mac OS Classic.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
169 @end enumerate
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
170
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
171 The default values of almost all variables about coding systems are
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
172 also set according to the language environment. So usually you don't
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
173 have to customize these variables manually.
|
34198
|
174
|
|
175 @node Mac Environment Variables
|
|
176 @section Environment Variables and Command Line Arguments.
|
36263
|
177 @cindex environment variables (Mac OS)
|
34198
|
178
|
44890
01b93e5e53a7
Patch for building Emacs on Mac OS X. April 26, 2002. See ChangeLog,
Andrew Choi <akochoi@shaw.ca>
diff
changeset
|
179 On Mac OS X, when Emacs is run in a terminal, it inherits the values
|
01b93e5e53a7
Patch for building Emacs on Mac OS X. April 26, 2002. See ChangeLog,
Andrew Choi <akochoi@shaw.ca>
diff
changeset
|
180 of environment variables from the shell from which it is invoked.
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
181 However, when it is run from the Finder as a GUI application, it only
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
182 inherits environment variable values defined in the file
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
183 @file{~/.MacOSX/environment.plist} that affects all the applications
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
184 invoked from the Finder or the @command{open} command.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
185
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
186 Command line arguments are specified like
|
44890
01b93e5e53a7
Patch for building Emacs on Mac OS X. April 26, 2002. See ChangeLog,
Andrew Choi <akochoi@shaw.ca>
diff
changeset
|
187
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
188 @example
|
70299
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
189 /Applications/Emacs.app/Contents/MacOS/Emacs -g 80x25 &
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
190 @end example
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
191
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
192 @noindent
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
193 if Emacs is installed at @file{/Applications/Emacs.app}. If Emacs is
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
194 invoked like this, then it also inherits the values of environment
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
195 variables from the shell from which it is invoked.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
196
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
197 On Mac OS Classic, environment variables and command line arguments
|
44890
01b93e5e53a7
Patch for building Emacs on Mac OS X. April 26, 2002. See ChangeLog,
Andrew Choi <akochoi@shaw.ca>
diff
changeset
|
198 for Emacs can be set by modifying the @samp{STR#} resources 128 and
|
01b93e5e53a7
Patch for building Emacs on Mac OS X. April 26, 2002. See ChangeLog,
Andrew Choi <akochoi@shaw.ca>
diff
changeset
|
199 129, respectively. A common environment variable that one may want to
|
01b93e5e53a7
Patch for building Emacs on Mac OS X. April 26, 2002. See ChangeLog,
Andrew Choi <akochoi@shaw.ca>
diff
changeset
|
200 set is @samp{HOME}.
|
34198
|
201
|
|
202 The way to set an environment variable is by adding a string of the
|
|
203 form
|
|
204
|
|
205 @example
|
|
206 ENV_VAR=VALUE
|
|
207 @end example
|
|
208
|
|
209 @noindent
|
|
210 to resource @samp{STR#} number 128 using @code{ResEdit}. To set up the
|
|
211 program to use unibyte characters exclusively, for example, add the
|
|
212 string
|
|
213
|
|
214 @example
|
|
215 EMACS_UNIBYTE=1
|
|
216 @end example
|
|
217
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
218 @cindex Mac Preferences
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
219 Although Emacs on Mac does not support X resources (@pxref{X
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
220 Resources}) directly, one can use the Preferences system in place of X
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
221 resources. For example, adding the line
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
222
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
223 @example
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
224 Emacs.cursorType: bar
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
225 @end example
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
226
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
227 @noindent
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
228 to @file{~/.Xresources} in X11 corresponds to the execution of
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
229
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
230 @example
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
231 defaults write org.gnu.Emacs Emacs.cursorType bar
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
232 @end example
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
233
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
234 @noindent
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
235 on Mac OS X. One can use boolean or numeric values as well as string
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
236 values as follows:
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
237
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
238 @example
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
239 defaults write org.gnu.Emacs Emacs.toolBar -bool false
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
240 defaults write org.gnu.Emacs Emacs.lineSpacing -int 3
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
241 @end example
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
242
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
243 @noindent
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
244 Try @kbd{M-x man RET defaults RET} for the usage of the
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
245 @command{defaults} command. Alternatively, if you have Developer
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
246 Tools installed on Mac OS X, you can use Property List Editor to edit
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
247 the file @file{~/Library/Preferences/org.gnu.Emacs.plist}.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
248
|
34198
|
249
|
|
250 @node Mac Directories
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
251 @section Volumes and Directories on Mac
|
36263
|
252 @cindex file names (Mac OS)
|
34198
|
253
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
254 This node applies to Mac OS Classic only.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
255
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
256 The directory structure in Mac OS Classic is seen by Emacs as
|
34198
|
257
|
|
258 @example
|
36163
|
259 /@var{volumename}/@var{filename}
|
34198
|
260 @end example
|
|
261
|
36163
|
262 So when Emacs requests a file name, doing file name completion on
|
38865
|
263 @file{/} will display all volumes on the system. You can use @file{..}
|
|
264 to go up a directory level.
|
34198
|
265
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
266 On Mac OS Classic, to access files and folders on the desktop, look
|
44890
01b93e5e53a7
Patch for building Emacs on Mac OS X. April 26, 2002. See ChangeLog,
Andrew Choi <akochoi@shaw.ca>
diff
changeset
|
267 in the folder @file{Desktop Folder} in your boot volume (this folder
|
01b93e5e53a7
Patch for building Emacs on Mac OS X. April 26, 2002. See ChangeLog,
Andrew Choi <akochoi@shaw.ca>
diff
changeset
|
268 is usually invisible in the Mac @code{Finder}).
|
34198
|
269
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
270 On Mac OS Classic, Emacs creates the Mac folder
|
44890
01b93e5e53a7
Patch for building Emacs on Mac OS X. April 26, 2002. See ChangeLog,
Andrew Choi <akochoi@shaw.ca>
diff
changeset
|
271 @file{:Preferences:Emacs:} in the @file{System Folder} and uses it as
|
01b93e5e53a7
Patch for building Emacs on Mac OS X. April 26, 2002. See ChangeLog,
Andrew Choi <akochoi@shaw.ca>
diff
changeset
|
272 the temporary directory. Emacs maps the directory name @file{/tmp/}
|
01b93e5e53a7
Patch for building Emacs on Mac OS X. April 26, 2002. See ChangeLog,
Andrew Choi <akochoi@shaw.ca>
diff
changeset
|
273 to that. Therefore it is best to avoid naming a volume @file{tmp}.
|
01b93e5e53a7
Patch for building Emacs on Mac OS X. April 26, 2002. See ChangeLog,
Andrew Choi <akochoi@shaw.ca>
diff
changeset
|
274 If everything works correctly, the program should leave no files in it
|
01b93e5e53a7
Patch for building Emacs on Mac OS X. April 26, 2002. See ChangeLog,
Andrew Choi <akochoi@shaw.ca>
diff
changeset
|
275 when it exits. You should be able to set the environment variable
|
01b93e5e53a7
Patch for building Emacs on Mac OS X. April 26, 2002. See ChangeLog,
Andrew Choi <akochoi@shaw.ca>
diff
changeset
|
276 @code{TMPDIR} to use another directory but this folder will still be
|
01b93e5e53a7
Patch for building Emacs on Mac OS X. April 26, 2002. See ChangeLog,
Andrew Choi <akochoi@shaw.ca>
diff
changeset
|
277 created.
|
34198
|
278
|
|
279
|
|
280 @node Mac Font Specs
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
281 @section Specifying Fonts on Mac
|
36263
|
282 @cindex font names (Mac OS)
|
34198
|
283
|
36503
d7815b5b49d7
Minor clarifications. Explain that one normally specifies face attributes
Richard M. Stallman <rms@gnu.org>
diff
changeset
|
284 It is rare that you need to specify a font name in Emacs; usually
|
67100
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
285 you specify face attributes instead. For example, you can use 14pt
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
286 Courier by customizing the default face attributes for all frames:
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
287
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
288 @lisp
|
70299
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
289 (set-face-attribute 'default nil
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
290 :family "courier" :height 140)
|
67100
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
291 @end lisp
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
292
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
293 @noindent
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
294 Alternatively, an interactive one is also available
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
295 (@pxref{Face Customization}).
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
296
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
297 But when you do need to specify a font name in Emacs on Mac, use a
|
e58128155819
(Mac Input): Remove description of mac-command-key-is-meta. Add
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
298 standard X font name:
|
34198
|
299
|
36163
|
300 @smallexample
|
36413
|
301 -@var{maker}-@var{family}-@var{weight}-@var{slant}-@var{widthtype}-@var{style}@dots{}
|
|
302 @dots{}-@var{pixels}-@var{height}-@var{horiz}-@var{vert}-@var{spacing}-@var{width}-@var{charset}
|
36163
|
303 @end smallexample
|
34198
|
304
|
36163
|
305 @noindent
|
36503
d7815b5b49d7
Minor clarifications. Explain that one normally specifies face attributes
Richard M. Stallman <rms@gnu.org>
diff
changeset
|
306 @xref{Font X}. Wildcards are supported as they are on X.
|
34198
|
307
|
70299
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
308 Emacs on Mac OS Classic uses QuickDraw Text routines for drawing texts
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
309 by default. Emacs on Mac OS X uses @acronym{ATSUI, Apple Type Services
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
310 for Unicode Imaging} as well as QuickDraw Text, and most of the
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
311 characters other than Chinese, Japanese, and Korean ones are drawn using
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
312 the former by default.
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
313
|
70299
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
314 @acronym{ATSUI}-compatible fonts have maker name @code{apple} and
|
71593
|
315 charset @code{iso10646-1}. For example, 12-point Monaco can be specified
|
|
316 by the name:
|
|
317
|
|
318 @example
|
|
319 -apple-monaco-medium-r-normal--12-*-*-*-*-*-iso10646-1
|
|
320 @end example
|
|
321
|
|
322 Note that it must be specified in a format containing 14 @samp{-}s
|
|
323 (e.g., not by @samp{-apple-monaco-medium-r-normal--12-*-iso10646-1}),
|
|
324 because every @acronym{ATSUI}-compatible font is a scalable one.
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
325
|
70299
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
326 QuickDraw Text fonts have maker name @code{apple} and various charset
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
327 names other than @code{iso10646-1}. Native Apple fonts in Mac Roman
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
328 encoding has charset @code{mac-roman}. You can specify a
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
329 @code{mac-roman} font for @acronym{ASCII} characters like
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
330
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
331 @smalllisp
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
332 (add-to-list
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
333 'default-frame-alist
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
334 '(font . "-apple-monaco-medium-r-normal--13-*-*-*-*-*-mac-roman"))
|
70299
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
335 @end smalllisp
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
336
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
337 @noindent
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
338 but that does not extend to ISO-8859-1: specifying a @code{mac-roman}
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
339 font for Latin-1 characters introduces wrong glyphs.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
340
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
341 Native Apple Traditional Chinese, Simplified Chinese, Japanese,
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
342 Korean, Central European, Cyrillic, Symbol, and Dingbats fonts have
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
343 charsets @samp{big5-0}, @samp{gb2312.1980-0},
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
344 @samp{jisx0208.1983-sjis} and @samp{jisx0201.1976-0},
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
345 @samp{ksc5601.1989-0}, @samp{mac-centraleurroman},
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
346 @samp{mac-cyrillic}, @samp{mac-symbol}, and @samp{mac-dingbats},
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
347 respectively.
|
34198
|
348
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
349 The use of @code{create-fontset-from-fontset-spec} (@pxref{Defining
|
70299
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
350 Fontsets}) for defining fontsets often results in wrong ones especially
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
351 when using only OS-bundled QuickDraw Text fonts. The recommended way to
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
352 use them is to create a fontset using
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
353 @code{create-fontset-from-mac-roman-font}:
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
354
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
355 @lisp
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
356 (create-fontset-from-mac-roman-font
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
357 "-apple-courier-medium-r-normal--13-*-*-*-*-*-mac-roman"
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
358 nil "foo")
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
359 @end lisp
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
360
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
361 @noindent
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
362 and then optionally specifying Chinese, Japanese, or Korean font
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
363 families using @code{set-fontset-font}:
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
364
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
365 @lisp
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
366 (set-fontset-font "fontset-foo"
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
367 'chinese-gb2312 '("song" . "gb2312.1980-0"))
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
368 @end lisp
|
34198
|
369
|
|
370 Single-byte fonts converted from GNU fonts in BDF format, which are not
|
|
371 in the Mac Roman encoding, have foundry, family, and character sets
|
|
372 encoded in the names of their font suitcases. E.g., the font suitcase
|
|
373 @samp{ETL-Fixed-ISO8859-1} contains fonts which can be referred to by
|
|
374 the name @samp{-ETL-fixed-*-iso8859-1}.
|
|
375
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
376 @vindex mac-allow-anti-aliasing
|
70299
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
377 Mac OS X 10.2 or later can use two types of text renderings: Quartz 2D
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
378 (aka Core Graphics) and QuickDraw. By default, Emacs uses the former on
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
379 such versions. It can be changed by setting
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
380 @code{mac-allow-anti-aliasing} to @code{t} (Quartz 2D) or @code{nil}
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
381 (QuickDraw). Both @acronym{ATSUI} and QuickDraw Text drawings are
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
382 affected by the value of this variable.
|
ca785b8f7171
(Mac International): Now Carbon Emacs has ATSUI support.
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
383
|
34198
|
384
|
|
385 @node Mac Functions
|
36165
|
386 @section Mac-Specific Lisp Functions
|
36263
|
387 @cindex Lisp functions specific to Mac OS
|
34198
|
388
|
|
389 @findex do-applescript
|
|
390 The function @code{do-applescript} takes a string argument,
|
|
391 executes it as an AppleScript command, and returns the result as a
|
|
392 string.
|
|
393
|
38892
|
394 @findex mac-file-name-to-posix
|
|
395 @findex posix-file-name-to-mac
|
|
396 The function @code{mac-file-name-to-posix} takes a Mac file name and
|
38944
|
397 returns the GNU or Unix equivalent. The function
|
38892
|
398 @code{posix-file-name-to-mac} performs the opposite conversion. They
|
|
399 are useful for constructing AppleScript commands to be passed to
|
|
400 @code{do-applescript}.
|
52401
|
401
|
65633
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
402 @findex mac-set-file-creator
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
403 @findex mac-get-file-creator
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
404 @findex mac-set-file-type
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
405 @findex mac-get-file-type
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
406 The functions @code{mac-set-file-creator},
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
407 @code{mac-get-file-creator}, @code{mac-set-file-type}, and
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
408 @code{mac-get-file-type} can be used to set and get creator and file
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
409 codes.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
410
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
411 @findex mac-get-preference
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
412 The function @code{mac-get-preference} returns the preferences value
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
413 converted to a Lisp object for a specified key and application.
|
YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
diff
changeset
|
414
|
52401
|
415 @ignore
|
|
416 arch-tag: a822c2ab-4273-4997-927e-c153bb71dcf6
|
|
417 @end ignore
|