Commit | Line | Data |
---|---|---|
5e56e175 | 1 | % Reference Card for Dired |
7616b390 GM |
2 | % Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, |
3 | % 2006, 2007 Free Software Foundation, Inc. | |
5e56e175 GM |
4 | |
5 | % This file is part of GNU Emacs. | |
6 | ||
7 | % GNU Emacs is free software; you can redistribute it and/or modify | |
8 | % it under the terms of the GNU General Public License as published by | |
9 | % the Free Software Foundation; either version 2, or (at your option) | |
10 | % any later version. | |
11 | ||
12 | % GNU Emacs is distributed in the hope that it will be useful, | |
13 | % but WITHOUT ANY WARRANTY; without even the implied warranty of | |
14 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
15 | % GNU General Public License for more details. | |
16 | ||
17 | % You should have received a copy of the GNU General Public License | |
18 | % along with GNU Emacs; see the file COPYING. If not, write to | |
364c38d3 LK |
19 | % the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
20 | % Boston, MA 02110-1301, USA. | |
5e56e175 GM |
21 | |
22 | % This file can be printed with 1, 2, or 3 columns per page (see below). | |
23 | % Specify how many you want here. Nothing else needs to be changed. | |
24 | %**start of header | |
25 | ||
26 | \newcount\columnsperpage | |
27 | ||
28 | \columnsperpage=2 | |
29 | ||
30 | % This file is intended to be processed by plain TeX (TeX82). | |
31 | % The reference card looks OK with 2 columns per page, portrait mode. | |
32 | % I haven't tried it with 3 columns per page. | |
33 | ||
34 | % This is a bit of a dirty hack on the GNU Emacs reference card | |
35 | % to produce a Dired reference card instead. | |
36 | ||
177c0ea7 JB |
37 | % I (Evgeny Roubinchtein, eroubinc@u.washington.edu) put this together |
38 | % because I wanted a Dired reference card, | |
5e56e175 GM |
39 | % but couldn't find anything on the 'net. |
40 | % Based mostly off Dired's describe-mode. | |
41 | ||
42 | ||
43 | \def\versionnumber{0.1} | |
7616b390 GM |
44 | \def\year{2007} % latest copyright year |
45 | \def\version{Mai 2006\ v\versionnumber} | |
5e56e175 GM |
46 | |
47 | \def\shortcopyrightnotice{\vskip 1ex plus 2 fill | |
48 | \centerline{\small \copyright\ \year\ Free Software Foundation, Inc. | |
49 | Permissions au dos. v\versionnumber}} | |
50 | ||
51 | \def\copyrightnotice{ | |
52 | \vskip 1ex plus 2 fill\begingroup\small | |
53 | \centerline{Copyright \copyright\ \year\ Free Software Foundation, Inc.} | |
54 | \centerline{conception de Stephen Gildea, \version} | |
55 | \centerline{pour GNU Emacs version 19 sur syst\`emes Unix} | |
7616b390 | 56 | \centerline{Mis \`a jour pour Dired en Mai 2000 par Evgeny Roubinchtein} |
5e56e175 GM |
57 | \centerline{Traduction fran\c{c}aise d'\'Eric Jacoboni} |
58 | ||
59 | Vous pouvez faire et distribuer des copies de cette carte, pourvu que | |
60 | la notice de copyright et cette note de permission soient pr\'eserv\'ees | |
61 | sur toutes les copies. | |
62 | ||
63 | Pour obtenir des copies du manuel de GNU Emacs, \'ecrivez \`a la Free Software | |
3ef97fb6 | 64 | Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
5e56e175 GM |
65 | |
66 | \endgroup} | |
67 | ||
68 | % make \bye not \outer so that the \def\bye in the \else clause below | |
69 | % can be scanned without complaint. | |
70 | \def\bye{\par\vfill\supereject\end} | |
71 | ||
72 | \newdimen\intercolumnskip %horizontal space between columns | |
73 | \newbox\columna %boxes to hold columns already built | |
74 | \newbox\columnb | |
75 | ||
76 | \def\ncolumns{\the\columnsperpage} | |
77 | ||
177c0ea7 | 78 | \message{[\ncolumns\space |
5e56e175 GM |
79 | column\if 1\ncolumns\else s\fi\space per page]} |
80 | ||
81 | \def\scaledmag#1{ scaled \magstep #1} | |
82 | ||
83 | % This multi-way format was designed by Stephen Gildea October 1986. | |
84 | % Note that the 1-column format is fontfamily-independent. | |
85 | \if 1\ncolumns %one-column format uses normal size | |
86 | \hsize 4in | |
87 | \vsize 10in | |
88 | \voffset -.7in | |
89 | \font\titlefont=\fontname\tenbf \scaledmag3 | |
90 | \font\headingfont=\fontname\tenbf \scaledmag2 | |
91 | \font\smallfont=\fontname\sevenrm | |
92 | \font\smallsy=\fontname\sevensy | |
93 | ||
94 | \footline{\hss\folio} | |
95 | \def\makefootline{\baselineskip10pt\hsize6.5in\line{\the\footline}} | |
96 | \else %2 or 3 columns uses prereduced size | |
97 | \hsize 3.4in | |
01108fab | 98 | \vsize 10in |
5e56e175 GM |
99 | \hoffset -.75in |
100 | \voffset -.745in | |
101 | \font\titlefont=cmbx10 \scaledmag2 | |
102 | \font\headingfont=cmbx10 \scaledmag1 | |
103 | \font\smallfont=cmr6 | |
104 | \font\smallsy=cmsy6 | |
105 | \font\eightrm=cmr8 | |
106 | \font\eightbf=cmbx8 | |
107 | \font\eightit=cmti8 | |
108 | \font\eighttt=cmtt8 | |
109 | \font\eightmi=cmmi8 | |
110 | \font\eightsy=cmsy8 | |
111 | \textfont0=\eightrm | |
112 | \textfont1=\eightmi | |
113 | \textfont2=\eightsy | |
114 | \def\rm{\eightrm} | |
115 | \def\bf{\eightbf} | |
116 | \def\it{\eightit} | |
117 | \def\tt{\eighttt} | |
118 | \normalbaselineskip=.8\normalbaselineskip | |
119 | \normallineskip=.8\normallineskip | |
120 | \normallineskiplimit=.8\normallineskiplimit | |
121 | \normalbaselines\rm %make definitions take effect | |
122 | ||
123 | \if 2\ncolumns | |
124 | \let\maxcolumn=b | |
125 | \footline{\hss\rm\folio\hss} | |
126 | \def\makefootline{\vskip 2in \hsize=6.86in\line{\the\footline}} | |
127 | \else \if 3\ncolumns | |
128 | \let\maxcolumn=c | |
129 | \nopagenumbers | |
130 | \else | |
131 | \errhelp{You must set \columnsperpage equal to 1, 2, or 3.} | |
132 | \errmessage{Illegal number of columns per page} | |
133 | \fi\fi | |
134 | ||
135 | \intercolumnskip=.46in | |
136 | \def\abc{a} | |
137 | \output={% %see The TeXbook page 257 | |
138 | % This next line is useful when designing the layout. | |
139 | %\immediate\write16{Column \folio\abc\space starts with \firstmark} | |
140 | \if \maxcolumn\abc \multicolumnformat \global\def\abc{a} | |
141 | \else\if a\abc | |
142 | \global\setbox\columna\columnbox \global\def\abc{b} | |
143 | %% in case we never use \columnb (two-column mode) | |
144 | \global\setbox\columnb\hbox to -\intercolumnskip{} | |
145 | \else | |
146 | \global\setbox\columnb\columnbox \global\def\abc{c}\fi\fi} | |
147 | \def\multicolumnformat{\shipout\vbox{\makeheadline | |
148 | \hbox{\box\columna\hskip\intercolumnskip | |
149 | \box\columnb\hskip\intercolumnskip\columnbox} | |
150 | \makefootline}\advancepageno} | |
151 | \def\columnbox{\leftline{\pagebody}} | |
152 | ||
153 | \def\bye{\par\vfill\supereject | |
154 | \if a\abc \else\null\vfill\eject\fi | |
155 | \if a\abc \else\null\vfill\eject\fi | |
177c0ea7 | 156 | \end} |
5e56e175 GM |
157 | \fi |
158 | ||
159 | % we won't be using math mode much, so redefine some of the characters | |
160 | % we might want to talk about | |
161 | \catcode`\^=12 | |
162 | \catcode`\_=12 | |
163 | ||
164 | \chardef\\=`\\ | |
165 | \chardef\{=`\{ | |
166 | \chardef\}=`\} | |
167 | ||
168 | \hyphenation{mini-buf-fer} | |
169 | \hyphenation{de-le-tion} | |
170 | ||
171 | \parindent 0pt | |
172 | \parskip 1ex plus .5ex minus .5ex | |
173 | ||
174 | \def\small{\smallfont\textfont2=\smallsy\baselineskip=.8\baselineskip} | |
175 | ||
176 | % newcolumn - force a new column. Use sparingly, probably only for | |
177 | % the first column of a page, which should have a title anyway. | |
178 | \outer\def\newcolumn{\vfill\eject} | |
179 | ||
180 | % title - page title. Argument is title text. | |
181 | \outer\def\title#1{{\titlefont\centerline{#1}}\vskip 1ex plus .5ex} | |
182 | ||
183 | % section - new major section. Argument is section name. | |
184 | \outer\def\section#1{\par\filbreak | |
185 | \vskip 3ex plus 2ex minus 2ex {\headingfont #1}\mark{#1}% | |
186 | \vskip 2ex plus 1ex minus 1.5ex} | |
187 | ||
188 | \newdimen\keyindent | |
189 | ||
190 | % beginindentedkeys...endindentedkeys - key definitions will be | |
191 | % indented, but running text, typically used as headings to group | |
192 | % definitions, will not. | |
193 | \def\beginindentedkeys{\keyindent=1em} | |
194 | \def\endindentedkeys{\keyindent=0em} | |
195 | \endindentedkeys | |
196 | ||
197 | % paralign - begin paragraph containing an alignment. | |
198 | % If an \halign is entered while in vertical mode, a parskip is never | |
199 | % inserted. Using \paralign instead of \halign solves this problem. | |
200 | \def\paralign{\vskip\parskip\halign} | |
201 | ||
202 | % \<...> - surrounds a variable name in a code example | |
203 | \def\<#1>{{\it #1\/}} | |
204 | ||
205 | % kbd - argument is characters typed literally. Like the Texinfo command. | |
206 | \def\kbd#1{{\tt#1}\null} %\null so not an abbrev even if period follows | |
207 | ||
208 | % beginexample...endexample - surrounds literal text, such a code example. | |
209 | % typeset in a typewriter font with line breaks preserved | |
210 | \def\beginexample{\par\leavevmode\begingroup | |
211 | \obeylines\obeyspaces\parskip0pt\tt} | |
212 | {\obeyspaces\global\let =\ } | |
213 | \def\endexample{\endgroup} | |
214 | ||
215 | % key - definition of a key. | |
216 | % \key{description of key}{key-name} | |
217 | % prints the description left-justified, and the key-name in a \kbd | |
218 | % form near the right margin. | |
01108fab | 219 | % First hfill tweaked from 0.75 to 0.8 to allow for longer descriptions. |
5e56e175 | 220 | \def\key#1#2{\leavevmode\hbox to \hsize{\vtop |
01108fab | 221 | {\hsize=.8\hsize\rightskip=1em |
5e56e175 GM |
222 | \hskip\keyindent\relax#1}\kbd{#2}\hfil}} |
223 | ||
224 | \newbox\metaxbox | |
225 | \setbox\metaxbox\hbox{\kbd{M-x }} | |
226 | \newdimen\metaxwidth | |
227 | \metaxwidth=\wd\metaxbox | |
228 | ||
229 | % metax - definition of a M-x command. | |
230 | % \metax{description of command}{M-x command-name} | |
231 | % Tries to justify the beginning of the command name at the same place | |
232 | % as \key starts the key name. (The "M-x " sticks out to the left.) | |
233 | \def\metax#1#2{\leavevmode\hbox to \hsize{\hbox to .75\hsize | |
234 | {\hskip\keyindent\relax#1\hfil}% | |
235 | \hskip -\metaxwidth minus 1fil | |
236 | \kbd{#2}\hfil}} | |
237 | ||
238 | % threecol - like "key" but with two key names. | |
239 | % for example, one for doing the action backward, and one for forward. | |
240 | \def\threecol#1#2#3{\hskip\keyindent\relax#1\hfil&\kbd{#2}\hfil\quad | |
241 | &\kbd{#3}\hfil\quad\cr} | |
242 | ||
243 | % I cannot figure out how to make all dired-x | |
244 | % commands fit on a page in two-column format | |
245 | \def\dx{\bf (DX)} | |
246 | ||
01108fab GM |
247 | % Set to non-zero to check for layout problems. |
248 | \overfullrule 0pt | |
249 | \nopagenumbers | |
250 | ||
5e56e175 GM |
251 | %**end of header |
252 | \f | |
253 | ||
254 | \title{Carte de r\'ef\'erence de Dired} | |
255 | ||
408ddec4 | 256 | \centerline{(bas\'e sur Dired de GNU Emacs 22.x)} |
5e56e175 GM |
257 | \centerline{Les commandes marqu\'ees par \dx{} n\'ecessitent dired-x} |
258 | ||
259 | % trim this down to fit everything on one page | |
260 | % \section{G\'en\'eral} | |
261 | % Avec dired, vous pouvez \'editer la liste des fichiers d'un r\'epertoire | |
262 | % (et, \'eventuellement, ses r\'epertoires au format 'ls -lR'). | |
263 | ||
264 | % L'\'edition d'un r\'epertoire signifie que vous pouvez visiter, | |
265 | % renommer, copier, compresser, compiler des fichiers. Dans le tampon | |
266 | % d'\'edition, vous pouvez modifier les attributs des fichiers, leur | |
177c0ea7 | 267 | % appliquer des commandes |
5e56e175 GM |
268 |