1 <?xml version="1.0" encoding="UTF-8"?>
2 <?xml-stylesheet type="text/xsl" href="dactyl://content/help.xsl"?>
4 <!DOCTYPE document SYSTEM "dactyl://content/dtd">
8 title="&dactyl.appName; Command-line"
10 xmlns:html="&xmlns.html;">
12 <h1 tag="command-line-mode command-line mode-cmdline">Command Line mode</h1>
16 &dactyl.appName;'s Command Line mode is perhaps its most
17 powerful interface. In this mode, the command input bar at the
18 bottom of the window is given the keyboard focus for any of a
19 variety of required inputs. In addition to access to almost
20 every aspect of &dactyl.appName; and &dactyl.host;, the command
21 line provides power and comprehensive completion for all of its
22 commands, along with concise descriptions for each command and
23 all of its arguments. Couple this with persistent, searchable
24 command history, and you have a very efficient interface for
25 easily performing simple and complex tasks.
29 Included among the several command-line modes are Ex command
30 mode (the standard mode for entering commands), Find mode (for
31 searching the current page), Prompt mode (for selecting files,
32 confirming actions), and Hints mode (for selecting links and
33 other items on a page).
42 Opens the command line in Ex mode. This is the mode used
43 for entering the various commands listed in
49 <h2 tag="cmdline-editing">Command-line editing</h2>
52 <tags><![CDATA[c_<C-i>]]></tags>
54 <description short="true">
55 <p>Launch the external editor. See the <o>editor</o> option.</p>
60 <tags><![CDATA[c_<C-c>]]></tags>
62 <description short="true">
63 <p>Quit Command Line mode without executing.</p>
68 <tags><![CDATA[c_<C-]>]]></tags>
70 <description short="true">
71 <p>Expand a command-line abbreviation.</p>
76 <tags><![CDATA[c_<A-p> c_<Up> c_<cmd-prev-match>]]></tags>
81 Recall from command history the previous command line
82 which begins with the current input value.
88 <tags><![CDATA[c_<A-n> c_<Down> c_<cmd-next-match>]]></tags>
90 <spec><Down></spec>
93 Recall from command history the next command line
94 which begins with the current input value.
100 <tags><![CDATA[c_<C-p> c_<S-Up> c_<cmd-prev>]]></tags>
101 <spec><S-Up></spec>
103 <spec><PageUp></spec>
105 <p>Recall the previous command line from the history list.</p>
110 <tags><![CDATA[c_<C-n> c_<S-Down> c_<cmd-next>]]></tags>
111 <spec><S-Down></spec>
112 <spec><PageDown></spec>
114 <p>Recall the next command line from the history list.</p>
118 <h2 tag="cmdline-completion">Command-line completion</h2>
121 <tags><![CDATA[c_<Tab> c_<compl-next>]]></tags>
123 <spec><Tab></spec>
126 Complete the word in front of the cursor according to the behavior
127 specified in <o>wildmode</o>. If <o>wildmode</o> contains
128 <str>list</str> and there are multiple matches then the completion
129 menu window is opened.
135 <tags><![CDATA[c_<S-Tab> c_<compl-prev>]]></tags>
137 <spec><S-Tab></spec>
139 <p>Complete the previous full match when <o>wildmode</o> contains <str>full</str>.</p>
144 <tags><![CDATA[c_<A-Tab> c_<A-compl-next>]]></tags>
146 <spec><A-Tab></spec>
149 Similar to <k name="Tab" mode="c"/>, but the completion behavior is
150 specified by the <o>altwildmode</o> option.
156 <tags><![CDATA[c_<A-S-Tab> c_<A-compl-prev>]]></tags>
158 <spec><A-S-Tab></spec>
160 <p>The <k name="S-Tab" mode="c"/> equivalent for <o>altwildmode</o>.</p>
165 <tags><![CDATA[c_<A-f> c_<C-Tab> c_<compl-next-group>]]></tags>
166 <spec><C-Tab></spec>
168 <p>Select the next matching completion group.</p>
173 <tags><![CDATA[c_<A-S-F> c_<C-S-Tab> c_<compl-prev-group>]]></tags>
174 <spec><C-S-Tab></spec>
176 <p>Select the previous matching completion group.</p>
181 <h2 tag="cmdline-lines">Ex command lines</h2>
188 Multiple commands, separated by a <em>|</em> can be
189 given in a single command line and will be executed consecutively.
190 <em>|</em> can be included as an argument to a command by escaping
191 it with a backslash. E.g.
192 <code><ex>:map \|</ex> <ex>:echo <str>bar</str></ex><k name="CR"/></code>
194 Several commands process the entire command-line string literally.
195 These commands will include any <em>|</em> as part of their
196 argument string and so cannot be followed by another command. The
197 list of these commands is:
199 <li><ex>:abbreviate</ex></li>
200 <li><ex>:autocmd</ex></li>
201 <li><ex>:cabbreviate</ex></li>
202 <li><ex>:cmap</ex></li>
203 <li><ex>:cnoremap</ex></li>
204 <li><ex>:command</ex></li>
205 <li><ex>:delmacros</ex></li>
206 <li><ex>:delmarks</ex></li>
207 <li><ex>:delqmarks</ex></li>
208 <li><ex>:delstyle</ex></li>
209 <li><ex>:echo</ex></li>
210 <li><ex>:echoerr</ex></li>
211 <li><ex>:echomsg</ex></li>
212 <li><ex>:elseif</ex></li>
213 <li><ex>:execute</ex></li>
214 <li><ex>:highlight</ex></li>
215 <li><ex>:iabbreviate</ex></li>
216 <li><ex>:if</ex></li>
217 <li><ex>:imap</ex></li>
218 <li><ex>:inoremap</ex></li>
219 <li><ex>:javascript</ex></li>
220 <li><ex>:let</ex></li>
221 <li><ex>:map</ex></li>
222 <li><ex>:marks</ex></li>
223 <li><ex>:nmap</ex></li>
224 <li><ex>:nnoremap</ex></li>
225 <li><ex>:noremap</ex></li>
226 <li><ex>:open</ex></li>
227 <li><ex>:qmarks</ex></li>
228 <li><ex>:silent</ex></li>
229 <li><ex>:style</ex></li>
230 <li><ex>:styledisable</ex></li>
231 <li><ex>:styleenable</ex></li>
232 <li><ex>:styletoggle</ex></li>
233 <li><ex>:tabopen</ex></li>
234 <li><ex>:toolbarhide</ex></li>
235 <li><ex>:toolbarshow</ex></li>
236 <li><ex>:toolbartoggle</ex></li>
237 <li><ex>:vmap</ex></li>
238 <li><ex>:vnoremap</ex></li>
239 <li><ex>:winopen</ex></li>
240 <li><ex>:yank</ex></li>
246 <h3 tag="cmdline-arguments">Ex command-line arguments</h3>
249 Most Ex commands accept a number of options and arguments. Arguments and
250 options are generally separated by spaces, and treat a number of
251 characters, including <em>\</em>, <em>'</em>, <em>"</em>, and <em>|</em>,
252 specially. Moreover, certain arguments have their own special characters.
253 For instance, when using <ex>:set</ex> to change a <t>stringlist</t>
254 option, the comma character is used to separate elements of said list. Or
255 when calling <ex>:autocmd</ex>, the pattern given may be negated by
256 prefixing it with a <em>!</em>. In order to use these characters in
257 command arguments, stripped of their special meaning, they must be quoted.
260 <p tag="cmdline-quoting quoting">
261 &dactyl.appName; offers four distinct quoting styles, each with its own
262 distinct advantages and disadvantages. The first, and most basic, is the
263 automatic quoting applied to the commands listed in <ex>:bar</ex>. When
264 any of these commands is invoked, their final argument is always
265 interpreted literally. No characters have special meaning whatsoever, and
266 no care need be taken to quote anything. Additionally, the following three
267 optional quoting characters are available:
270 <dl dt="width: 8em;">
273 This is the most basic quoting character. When it is encountered
274 outside of single or double quotes, it forces the next character to be
275 interpreted literally. So, for instance, <tt>\\</tt> ⇒ <tt>\</tt>,
276 <tt>\'</tt> ⇒ <tt>'</tt>, <tt>\a</tt> ⇒ <tt>a</tt>, and
277 <tt>\␣</tt> ⇒ <tt>␣</tt>.
281 Any character inside single quotes aside from the ' character itself
282 is interpreted literally. To include a literal single quote, it must
283 be doubled. So, <code>'foo\ ''bar\\ baz\' ⇒ foo\ 'bar\\ baz\</code>
287 Any character inside of double quotes except for <em>"</em> and
288 <em>\</em> is interpreted literally. A literal double quote may be
289 included by preceding it with a backslash. Any other occurrence of a
290 backslash starts an escape sequence as in JSON strings.
291 Among the available escape sequences are:
292 <dl dt="width: 8em;">
293 <dt>\n</dt> <dd>A newline character.</dd>
294 <dt>\t</dt> <dd>A tab character.</dd>
295 <dt>\uxxxx</dt> <dd>Where each <em>x</em> is a digit between 0 and F, a Unicode character at code-point <em>xxxx</em>.</dd>
300 <p tag="cmdline-options">
301 Many Ex commands accept option arguments in addition to regular arguments.
302 Option arguments begin with a hyphen (<em>-</em>), and often have a short
303 form and a long form, such as <em>-name</em> and <em>-n</em>. Most options
304 accept arguments, which come after the option separated by either a space
305 or an equal sign. For instance, the following three forms,
306 <em>-name=<str>foo</str></em>, <em>-name <str>foo</str></em>, and
307 <em>-n <str>foo</str></em>, are all acceptable and entirely equivalent.
312 <!-- vim:se sts=4 sw=4 et: -->